Services menu doesn't show up after you defocus/refocus the Safari window.
authorenrica@apple.com <enrica@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 7 Aug 2014 00:45:58 +0000 (00:45 +0000)
committerenrica@apple.com <enrica@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 7 Aug 2014 00:45:58 +0000 (00:45 +0000)
commitf661433e854a05505a6bf31cff1b734b22a001c5
tree7d6fe9b488e231645140df8fbd5b3b805f20886b
parentb97377c5a140ded90911a46dc7da4aff173f3375
Services menu doesn't show up after you defocus/refocus the Safari window.
https://bugs.webkit.org/show_bug.cgi?id=135678
<rdar://problem/17929247>

Reviewed by Tim Horton.

In setSelection we create a SelectionRectGatherer::Notifier object that will notify
SelectionOverlayController about changes to the selection rects.
Upon creation, the list of selections rects is cleared, since it is populated by
the code that collects the selection rects. That code is never called
when setSelection won't change the selection, which the case when the window is
activated. The fix consists in postponing the SelectionRectGatherer::Notifier object
creation until we know for sure that the selection is indeed going to change.

* rendering/RenderView.cpp:
(WebCore::RenderView::setSelection):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@172195 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Source/WebCore/ChangeLog
Source/WebCore/rendering/RenderView.cpp