X-Git-Url: http://review.tizen.org/git/?a=blobdiff_plain;f=Source%2FWebCore%2Frendering%2FInlineTextBox.cpp;h=f5f821bb2ec4fbac53ce05bc21d326c57b01b58d;hb=f81ad874ea9b40b47fb48aece92cc2edccb518a7;hp=19a3b1b7e576c7e8b2e4fdad8a17261d4b6dd0e7;hpb=558b59d04871dfc4ca78a3a79a58281798a79d11;p=framework%2Fweb%2Fwebkit-efl.git diff --git a/Source/WebCore/rendering/InlineTextBox.cpp b/Source/WebCore/rendering/InlineTextBox.cpp index 19a3b1b..f5f821b 100644 --- a/Source/WebCore/rendering/InlineTextBox.cpp +++ b/Source/WebCore/rendering/InlineTextBox.cpp @@ -852,6 +852,21 @@ void InlineTextBox::paintSelection(GraphicsContext* context, const FloatPoint& b // See if we have a selection to paint at all. int sPos, ePos; selectionStartEnd(sPos, ePos); +#if ENABLE(TIZEN_WEBKIT2_TEXT_SELECTION_NOT_PAINT_SELECTION_FOR_INPUTBOX) + Node* shadowAncestor = 0; + if (renderer() && renderer()->node()) + shadowAncestor = renderer()->node()->shadowAncestorNode(); + + if (shadowAncestor && (shadowAncestor->renderer()->isTextField() || shadowAncestor->renderer()->isTextArea())) { + if (selectionState() != RenderObject::SelectionBoth) { + RenderObject* startObj = textRenderer()->view()->selectionStart(); + RenderObject* endObj = textRenderer()->view()->selectionEnd(); + if (!(startObj->node()->isInShadowTree() && endObj->node()->isInShadowTree())) + return; + } + } +#endif + if (sPos >= ePos) return;