summaryrefslogtreecommitdiffstats
path: root/chrome/browser/automation/ui_controls_gtk.cc
diff options
context:
space:
mode:
authorjoi@chromium.org <joi@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2011-12-06 12:23:48 +0000
committerjoi@chromium.org <joi@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2011-12-06 12:23:48 +0000
commitccf2231b71685fedbd0a9effdce6875a77a27ccc (patch)
tree34c4eb7684a25adad0c690b60026fa9f9891ee01 /chrome/browser/automation/ui_controls_gtk.cc
parent1def7bde8cb1b33e7cc033aef1881b64505a7447 (diff)
downloadchromium_src-ccf2231b71685fedbd0a9effdce6875a77a27ccc.zip
chromium_src-ccf2231b71685fedbd0a9effdce6875a77a27ccc.tar.gz
chromium_src-ccf2231b71685fedbd0a9effdce6875a77a27ccc.tar.bz2
Revert 113183 - Revert 113177 - process all ui events before posting closure because menu depends on ui events to quit.
Add new RunClosureAfterAllPendingUIEvents for toolkit views. BUG=104359 TEST=BookmarkBarViewTest in interactive_ui_tests will pass Review URL: http://codereview.chromium.org/8799020 Reason for revert: http://build.chromium.org/p/chromium.chromiumos/builders/Linux%20ChromeOS%20Aura/builds/1514 Reason for un-revert: The test succeeded before the original revert, looks like it's just flaky. TBR=oshima@chromium.org Review URL: http://codereview.chromium.org/8821012 TBR=joi@chromium.org Review URL: http://codereview.chromium.org/8820010 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@113189 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/automation/ui_controls_gtk.cc')
-rw-r--r--chrome/browser/automation/ui_controls_gtk.cc9
1 files changed, 9 insertions, 0 deletions
diff --git a/chrome/browser/automation/ui_controls_gtk.cc b/chrome/browser/automation/ui_controls_gtk.cc
index 32e3100..8826609 100644
--- a/chrome/browser/automation/ui_controls_gtk.cc
+++ b/chrome/browser/automation/ui_controls_gtk.cc
@@ -310,4 +310,13 @@ void MoveMouseToCenterAndPress(GtkWidget* widget,
}
#endif
+#if defined(TOOLKIT_VIEWS)
+void RunClosureAfterAllPendingUIEvents(const base::Closure& task) {
+ // Send noop event and run task.
+ int x, y;
+ gdk_window_at_pointer(&x, &y);
+ SendMouseMoveNotifyWhenDone(x, y, task);
+}
+#endif
+
} // namespace ui_controls