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

Side by Side Diff: services/ui/ws/window_tree.cc

Issue 2316553003: mash: Add autoclick app. (Closed)
Patch Set: uint32 Created 4 years, 3 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 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 #include "services/ui/ws/window_tree.h" 5 #include "services/ui/ws/window_tree.h"
6 6
7 #include <stddef.h> 7 #include <stddef.h>
8 8
9 #include <utility> 9 #include <utility>
10 10
(...skipping 1032 matching lines...) Expand 10 before | Expand all | Expand 10 after
1043 } 1043 }
1044 1044
1045 bool WindowTree::EventMatchesPointerWatcher(const ui::Event& event) const { 1045 bool WindowTree::EventMatchesPointerWatcher(const ui::Event& event) const {
1046 if (!has_pointer_watcher_) 1046 if (!has_pointer_watcher_)
1047 return false; 1047 return false;
1048 if (!event.IsPointerEvent()) 1048 if (!event.IsPointerEvent())
1049 return false; 1049 return false;
1050 if (pointer_watcher_want_moves_ && event.type() == ui::ET_POINTER_MOVED) 1050 if (pointer_watcher_want_moves_ && event.type() == ui::ET_POINTER_MOVED)
1051 return true; 1051 return true;
1052 return event.type() == ui::ET_POINTER_DOWN || 1052 return event.type() == ui::ET_POINTER_DOWN ||
1053 event.type() == ui::ET_POINTER_UP; 1053 event.type() == ui::ET_POINTER_UP ||
1054 event.type() == ui::ET_POINTER_WHEEL_CHANGED;
1054 } 1055 }
1055 1056
sadrul 2016/09/13 14:55:13 Can you move this part out in a separate CL with a
riajiang 2016/09/13 15:05:49 Sure.
1056 void WindowTree::NewWindow( 1057 void WindowTree::NewWindow(
1057 uint32_t change_id, 1058 uint32_t change_id,
1058 Id transport_window_id, 1059 Id transport_window_id,
1059 mojo::Map<mojo::String, mojo::Array<uint8_t>> transport_properties) { 1060 mojo::Map<mojo::String, mojo::Array<uint8_t>> transport_properties) {
1060 std::map<std::string, std::vector<uint8_t>> properties; 1061 std::map<std::string, std::vector<uint8_t>> properties;
1061 if (!transport_properties.is_null()) { 1062 if (!transport_properties.is_null()) {
1062 properties = 1063 properties =
1063 transport_properties.To<std::map<std::string, std::vector<uint8_t>>>(); 1064 transport_properties.To<std::map<std::string, std::vector<uint8_t>>>();
1064 } 1065 }
1065 client()->OnChangeCompleted( 1066 client()->OnChangeCompleted(
(...skipping 610 matching lines...) Expand 10 before | Expand all | Expand 10 after
1676 } 1677 }
1677 1678
1678 bool WindowTree::IsWindowRootOfAnotherTreeForAccessPolicy( 1679 bool WindowTree::IsWindowRootOfAnotherTreeForAccessPolicy(
1679 const ServerWindow* window) const { 1680 const ServerWindow* window) const {
1680 WindowTree* tree = window_server_->GetTreeWithRoot(window); 1681 WindowTree* tree = window_server_->GetTreeWithRoot(window);
1681 return tree && tree != this; 1682 return tree && tree != this;
1682 } 1683 }
1683 1684
1684 } // namespace ws 1685 } // namespace ws
1685 } // namespace ui 1686 } // namespace ui
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698