just came across a pop-under which does the popup creation in mousedown and the hiding in mousedown. Can probably be fixed by using the same UserGestureIndicator::Token for related events
Created attachment 181979 [details] Layout test
Created attachment 182278 [details] Patch
Comment on attachment 182278 [details] Patch Nice solution.
Comment on attachment 182278 [details] Patch Clearing flags on attachment: 182278 Committed r139419: <http://trac.webkit.org/changeset/139419>
All reviewed patches have been landed. Closing bug.