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

Side by Side Diff: ui/views/widget/desktop_aura/desktop_window_tree_host_win.h

Issue 1565013002: Don't send touch events to windows like menus when the touch occurs outside the menu bounds. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Remove include Created 4 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 unified diff | Download patch
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef UI_VIEWS_WIDGET_DESKTOP_AURA_DESKTOP_WINDOW_TREE_HOST_WIN_H_ 5 #ifndef UI_VIEWS_WIDGET_DESKTOP_AURA_DESKTOP_WINDOW_TREE_HOST_WIN_H_
6 #define UI_VIEWS_WIDGET_DESKTOP_AURA_DESKTOP_WINDOW_TREE_HOST_WIN_H_ 6 #define UI_VIEWS_WIDGET_DESKTOP_AURA_DESKTOP_WINDOW_TREE_HOST_WIN_H_
7 7
8 #include "base/macros.h" 8 #include "base/macros.h"
9 #include "base/memory/weak_ptr.h"
9 #include "ui/aura/window_tree_host.h" 10 #include "ui/aura/window_tree_host.h"
11 #include "ui/events/event.h"
10 #include "ui/views/views_export.h" 12 #include "ui/views/views_export.h"
11 #include "ui/views/widget/desktop_aura/desktop_window_tree_host.h" 13 #include "ui/views/widget/desktop_aura/desktop_window_tree_host.h"
12 #include "ui/views/win/hwnd_message_handler_delegate.h" 14 #include "ui/views/win/hwnd_message_handler_delegate.h"
13 #include "ui/wm/public/animation_host.h" 15 #include "ui/wm/public/animation_host.h"
14
15 namespace aura { 16 namespace aura {
16 namespace client { 17 namespace client {
17 class DragDropClient; 18 class DragDropClient;
18 class FocusClient; 19 class FocusClient;
19 class ScopedTooltipDisabler; 20 class ScopedTooltipDisabler;
20 } 21 }
21 } 22 }
22 23
23 namespace views { 24 namespace views {
24 class DesktopCursorClient; 25 class DesktopCursorClient;
(...skipping 171 matching lines...) Expand 10 before | Expand all | Expand 10 after
196 Widget* GetWidget(); 197 Widget* GetWidget();
197 const Widget* GetWidget() const; 198 const Widget* GetWidget() const;
198 HWND GetHWND() const; 199 HWND GetHWND() const;
199 200
200 private: 201 private:
201 void SetWindowTransparency(); 202 void SetWindowTransparency();
202 203
203 // Returns true if a modal window is active in the current root window chain. 204 // Returns true if a modal window is active in the current root window chain.
204 bool IsModalWindowActive() const; 205 bool IsModalWindowActive() const;
205 206
207 // Posts an event to the event processor. Invoked as a task.
208 void PostEventToProcessor(const ui::Event& event);
209
206 scoped_ptr<HWNDMessageHandler> message_handler_; 210 scoped_ptr<HWNDMessageHandler> message_handler_;
207 scoped_ptr<aura::client::FocusClient> focus_client_; 211 scoped_ptr<aura::client::FocusClient> focus_client_;
208 212
209 // TODO(beng): Consider providing an interface to DesktopNativeWidgetAura 213 // TODO(beng): Consider providing an interface to DesktopNativeWidgetAura
210 // instead of providing this route back to Widget. 214 // instead of providing this route back to Widget.
211 internal::NativeWidgetDelegate* native_widget_delegate_; 215 internal::NativeWidgetDelegate* native_widget_delegate_;
212 216
213 DesktopNativeWidgetAura* desktop_native_widget_aura_; 217 DesktopNativeWidgetAura* desktop_native_widget_aura_;
214 218
215 aura::Window* content_window_; 219 aura::Window* content_window_;
(...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after
248 corewm::TooltipWin* tooltip_; 252 corewm::TooltipWin* tooltip_;
249 253
250 // Visibility of the cursor. On Windows we can have multiple root windows and 254 // Visibility of the cursor. On Windows we can have multiple root windows and
251 // the implementation of ::ShowCursor() is based on a counter, so making this 255 // the implementation of ::ShowCursor() is based on a counter, so making this
252 // member static ensures that ::ShowCursor() is always called exactly once 256 // member static ensures that ::ShowCursor() is always called exactly once
253 // whenever the cursor visibility state changes. 257 // whenever the cursor visibility state changes.
254 static bool is_cursor_visible_; 258 static bool is_cursor_visible_;
255 259
256 scoped_ptr<aura::client::ScopedTooltipDisabler> tooltip_disabler_; 260 scoped_ptr<aura::client::ScopedTooltipDisabler> tooltip_disabler_;
257 261
262 // The WeakPtrFactories below must occur last in the class definition so they
263 // get destroyed last.
264 base::WeakPtrFactory<DesktopWindowTreeHostWin> weak_factory_;
265
258 DISALLOW_COPY_AND_ASSIGN(DesktopWindowTreeHostWin); 266 DISALLOW_COPY_AND_ASSIGN(DesktopWindowTreeHostWin);
259 }; 267 };
260 268
261 } // namespace views 269 } // namespace views
262 270
263 #endif // UI_VIEWS_WIDGET_DESKTOP_AURA_DESKTOP_WINDOW_TREE_HOST_WIN_H_ 271 #endif // UI_VIEWS_WIDGET_DESKTOP_AURA_DESKTOP_WINDOW_TREE_HOST_WIN_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698