if (editorState.selectionIsRange) {
WebCore::IntRect leftRect, rightRect;
int selectionDirection = LToR;
- if (!m_viewImpl->page()->getSelectionHandlers(leftRect, rightRect, selectionDirection))
- return;
-
+ m_viewImpl->page()->getSelectionHandlers(leftRect, rightRect, selectionDirection);
#if ENABLE(TIZEN_WEBKIT2_TILED_BACKING_STORE)
// Checking if this point is in viewport area. If the calcualated
// point/Left/Right point are in view port then draw else do not draw the
point = rightRect.maxXMinYCorner();
isPresentInViewPort = true;
}
+ else if (leftRect.y() < viewportRect.y() && rightRect.maxY() > viewportRect.maxY()) {
+ // If left and right selection handler is not present in the view port,
+ // always context menu shows middle of the view port.
+ // Selection on position element in case of selectAll handled same
+ // as other browser
+ point = viewportRect.center();
+ leftRect = viewportRect;
+ rightRect = viewportRect;
+ isPresentInViewPort = true;
+ }
if (isPresentInViewPort && editorState.isContentEditable) {
// In case of single line editor box.