If user scrolls a WebView and selected text gets offscreen,
context_menu doesn't disappear and sometimes overlaps with the URL bar.
Patch adds some logic to hide the context_menu when the selected text
is offscreen.
Reviewed by: Antonio Gomes, DONGJUN KiM, Jaesik Chang
Change-Id: I149be40b35897ff9962f79fe877c277cd3d0dca9
Signed-off-by: ByungJun Kim <bj1987.kim@samsung.com>
return false;
}
+ if ((popup_position.y() - webview_y < webview_y) || (popup_position.x() - webview_x < webview_x))
+ return false;
int draw_direction;
CastToSelectionControllerEfl(controller)->ChangeContextMenuPosition(popup_position,
draw_direction);
+
+ if ((popup_position.y() > webview_height) || (popup_position.x() > webview_width))
+ return false;
+
switch(draw_direction) {
case 0:
elm_ctxpopup_direction_priority_set(popup_,