Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(174)

Unified Diff: ui/aura/remote_root_window_host_win.cc

Issue 147203004: aura: Remove event-dispatch methods from WindowTreeHostDelegate interface. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: win Created 6 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « ui/aura/remote_root_window_host_win.h ('k') | ui/aura/root_window.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/aura/remote_root_window_host_win.cc
diff --git a/ui/aura/remote_root_window_host_win.cc b/ui/aura/remote_root_window_host_win.cc
index bce58869dda4ccd039fbbacd2b40578683c9f726..e203e662ecc287365a95ff11916ba2165656701c 100644
--- a/ui/aura/remote_root_window_host_win.cc
+++ b/ui/aura/remote_root_window_host_win.cc
@@ -485,6 +485,10 @@ void RemoteWindowTreeHostWin::OnDeviceScaleFactorChanged(
void RemoteWindowTreeHostWin::PrepareForShutdown() {
}
+ui::EventProcessor* RemoteWindowTreeHostWin::GetEventProcessor() {
+ return delegate_->GetEventProcessor();
+}
+
void RemoteWindowTreeHostWin::CancelComposition() {
if (!host_)
return;
@@ -522,7 +526,7 @@ void RemoteWindowTreeHostWin::OnMouseMoved(int32 x, int32 y, int32 flags) {
gfx::Point location = PointFromNativeEvent(x, y);
ui::MouseEvent event(ui::ET_MOUSE_MOVED, location, location, flags, 0);
- delegate_->OnHostMouseEvent(&event);
+ SendEventToProcessor(&event);
}
void RemoteWindowTreeHostWin::OnMouseButton(
@@ -537,7 +541,7 @@ void RemoteWindowTreeHostWin::OnMouseButton(
int x_offset = params.is_horizontal_wheel ? params.extra : 0;
int y_offset = !params.is_horizontal_wheel ? params.extra : 0;
ui::MouseWheelEvent wheel_event(mouse_event, x_offset, y_offset);
- delegate_->OnHostMouseEvent(&wheel_event);
+ SendEventToProcessor(&wheel_event);
} else if (params.event_type == ui::ET_MOUSE_PRESSED) {
// TODO(shrikant): Ideally modify code in event.cc by adding automatic
// tracking of double clicks in synthetic MouseEvent constructor code.
@@ -553,9 +557,9 @@ void RemoteWindowTreeHostWin::OnMouseButton(
mouse_event.SetClickCount(1);
}
last_mouse_click_event_ .reset(new ui::MouseEvent(mouse_event));
- delegate_->OnHostMouseEvent(&mouse_event);
+ SendEventToProcessor(&mouse_event);
} else {
- delegate_->OnHostMouseEvent(&mouse_event);
+ SendEventToProcessor(&mouse_event);
}
}
@@ -596,7 +600,7 @@ void RemoteWindowTreeHostWin::OnTouchDown(int32 x,
location,
pointer_id,
base::TimeDelta::FromMicroseconds(timestamp));
- delegate_->OnHostTouchEvent(&event);
+ SendEventToProcessor(&event);
}
void RemoteWindowTreeHostWin::OnTouchUp(int32 x,
@@ -608,7 +612,7 @@ void RemoteWindowTreeHostWin::OnTouchUp(int32 x,
location,
pointer_id,
base::TimeDelta::FromMicroseconds(timestamp));
- delegate_->OnHostTouchEvent(&event);
+ SendEventToProcessor(&event);
}
void RemoteWindowTreeHostWin::OnTouchMoved(int32 x,
@@ -620,7 +624,7 @@ void RemoteWindowTreeHostWin::OnTouchMoved(int32 x,
location,
pointer_id,
base::TimeDelta::FromMicroseconds(timestamp));
- delegate_->OnHostTouchEvent(&event);
+ SendEventToProcessor(&event);
}
void RemoteWindowTreeHostWin::OnFileSaveAsDone(bool success,
@@ -744,7 +748,7 @@ void RemoteWindowTreeHostWin::DispatchKeyboardMessage(ui::EventType type,
ui::KeyboardCodeForWindowsKeyCode(vkey),
flags,
is_character);
- delegate_->OnHostKeyEvent(&event);
+ SendEventToProcessor(&event);
}
}
« no previous file with comments | « ui/aura/remote_root_window_host_win.h ('k') | ui/aura/root_window.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698