summaryrefslogtreecommitdiff
path: root/Source/WebCore/rendering/RenderThemeSafari.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'Source/WebCore/rendering/RenderThemeSafari.cpp')
-rw-r--r--Source/WebCore/rendering/RenderThemeSafari.cpp15
1 files changed, 9 insertions, 6 deletions
diff --git a/Source/WebCore/rendering/RenderThemeSafari.cpp b/Source/WebCore/rendering/RenderThemeSafari.cpp
index 23fd8b193..4ff0fd07c 100644
--- a/Source/WebCore/rendering/RenderThemeSafari.cpp
+++ b/Source/WebCore/rendering/RenderThemeSafari.cpp
@@ -1075,8 +1075,9 @@ bool RenderThemeSafari::paintSearchFieldCancelButton(RenderObject* o, const Pain
{
ASSERT(SafariThemeLibrary());
- Node* input = o->node()->shadowAncestorNode();
- ASSERT(input);
+ Node* input = o->node()->shadowHost();
+ if (!input)
+ input = o->node();
RenderObject* renderer = input->renderer();
ASSERT(renderer);
@@ -1129,8 +1130,9 @@ bool RenderThemeSafari::paintSearchFieldResultsDecoration(RenderObject* o, const
{
ASSERT(SafariThemeLibrary());
- Node* input = o->node()->shadowAncestorNode();
- ASSERT(input);
+ Node* input = o->node()->shadowHost();
+ if (!input)
+ input = o->node();
RenderObject* renderer = input->renderer();
ASSERT(renderer);
@@ -1152,8 +1154,9 @@ bool RenderThemeSafari::paintSearchFieldResultsButton(RenderObject* o, const Pai
{
ASSERT(SafariThemeLibrary());
- Node* input = o->node()->shadowAncestorNode();
- ASSERT(input);
+ Node* input = o->node()->shadowHost();
+ if (!input)
+ input = o->node();
RenderObject* renderer = input->renderer();
ASSERT(renderer);