summaryrefslogtreecommitdiffstats
path: root/ui
diff options
context:
space:
mode:
authorpkotwicz@chromium.org <pkotwicz@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2012-02-24 18:33:27 +0000
committerpkotwicz@chromium.org <pkotwicz@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2012-02-24 18:33:27 +0000
commita89fde96d910dce92e81dd4e0613704d31367d27 (patch)
treef3c1f489de934c2b72890e36ea5004bddc50e08e /ui
parent6e2d3d229024a3a0038c8a5c169bfd948a5c4939 (diff)
downloadchromium_src-a89fde96d910dce92e81dd4e0613704d31367d27.zip
chromium_src-a89fde96d910dce92e81dd4e0613704d31367d27.tar.gz
chromium_src-a89fde96d910dce92e81dd4e0613704d31367d27.tar.bz2
Revert 123500 - When locking the screen via Ctrl-Shift-L from wrench menu,
login screen menus do not work, because wrench menu is not fully closed. Made Noop events always make it to inner loop in the nested_dispatcher such that the menu can fully close itself via noop event. Bug=113247 Testing=Manual Review URL: https://chromiumcodereview.appspot.com/9381008 TBR=pkotwicz@chromium.org Review URL: https://chromiumcodereview.appspot.com/9460011 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@123511 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'ui')
-rw-r--r--ui/base/cocoa/events_mac.mm4
-rw-r--r--ui/base/events.h3
-rw-r--r--ui/base/win/events_win.cc6
-rw-r--r--ui/base/x/events_x.cc15
4 files changed, 4 insertions, 24 deletions
diff --git a/ui/base/cocoa/events_mac.mm b/ui/base/cocoa/events_mac.mm
index a3ae73b..f40d755 100644
--- a/ui/base/cocoa/events_mac.mm
+++ b/ui/base/cocoa/events_mac.mm
@@ -179,10 +179,6 @@ bool GetScrollOffsets(const base::NativeEvent& native_event,
return false;
}
-bool IsNoopEvent(base::NativeEvent event) {
- return ([event type] == NSApplicationDefined && [event subtype] == 0);
-}
-
base::NativeEvent CreateNoopEvent() {
return [NSEvent otherEventWithType:NSApplicationDefined
location:NSZeroPoint
diff --git a/ui/base/events.h b/ui/base/events.h
index 0334d10..354c186 100644
--- a/ui/base/events.h
+++ b/ui/base/events.h
@@ -169,9 +169,6 @@ UI_EXPORT bool GetGestureTimes(const base::NativeEvent& native_event,
double* start_time,
double* end_time);
-// Returns true if event is noop.
-UI_EXPORT bool IsNoopEvent(base::NativeEvent event);
-
// Creates and returns no-op event.
UI_EXPORT base::NativeEvent CreateNoopEvent();
diff --git a/ui/base/win/events_win.cc b/ui/base/win/events_win.cc
index 0207e31..d3557f2 100644
--- a/ui/base/win/events_win.cc
+++ b/ui/base/win/events_win.cc
@@ -266,13 +266,9 @@ void UpdateDeviceList() {
NOTIMPLEMENTED();
}
-bool IsNoopEvent(base::NativeEvent event) {
- return event.message == WM_USER + 310;
-}
-
base::NativeEvent CreateNoopEvent() {
MSG event = { NULL };
- event.message = WM_USER + 310;
+ event.message = WM_USER;
return event;
}
diff --git a/ui/base/x/events_x.cc b/ui/base/x/events_x.cc
index c1ad3e1..56da7b9 100644
--- a/ui/base/x/events_x.cc
+++ b/ui/base/x/events_x.cc
@@ -399,12 +399,6 @@ float GetTouchParamFromXEvent(XEvent* xev,
return default_value;
}
-Atom GetNoopEventAtom() {
- return XInternAtom(
- base::MessagePumpX::GetDefaultXDisplay(),
- "noop", False);
-}
-
} // namespace
namespace ui {
@@ -718,11 +712,6 @@ void UpdateDeviceList() {
TouchFactory::GetInstance()->UpdateDeviceList(display);
}
-bool IsNoopEvent(base::NativeEvent event) {
- return (event->type == ClientMessage &&
- event->xclient.message_type == GetNoopEventAtom());
-}
-
base::NativeEvent CreateNoopEvent() {
static XEvent* noop = NULL;
if (!noop) {
@@ -739,7 +728,9 @@ base::NativeEvent CreateNoopEvent() {
#else
// Make sure we use atom from current xdisplay, which may
// change during the test.
- noop->xclient.message_type = GetNoopEventAtom();
+ noop->xclient.message_type = XInternAtom(
+ base::MessagePumpX::GetDefaultXDisplay(),
+ "noop", False);
#endif
return noop;
}