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

Side by Side Diff: components/mus/public/cpp/tests/window_server_test_base.h

Issue 1656123002: Moves accelerator registration to WindowManager (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: fix mandoline Created 4 years, 10 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 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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 COMPONENTS_MUS_PUBLIC_CPP_TESTS_WINDOW_SERVER_TEST_BASE_H_ 5 #ifndef COMPONENTS_MUS_PUBLIC_CPP_TESTS_WINDOW_SERVER_TEST_BASE_H_
6 #define COMPONENTS_MUS_PUBLIC_CPP_TESTS_WINDOW_SERVER_TEST_BASE_H_ 6 #define COMPONENTS_MUS_PUBLIC_CPP_TESTS_WINDOW_SERVER_TEST_BASE_H_
7 7
8 #include "base/macros.h" 8 #include "base/macros.h"
9 #include "base/memory/scoped_ptr.h" 9 #include "base/memory/scoped_ptr.h"
10 #include "components/mus/public/cpp/window_manager_delegate.h" 10 #include "components/mus/public/cpp/window_manager_delegate.h"
(...skipping 62 matching lines...) Expand 10 before | Expand all | Expand 10 after
73 void OnConnectionLost(WindowTreeConnection* connection) override; 73 void OnConnectionLost(WindowTreeConnection* connection) override;
74 74
75 // WindowManagerDelegate: 75 // WindowManagerDelegate:
76 void SetWindowManagerClient(WindowManagerClient* client) override; 76 void SetWindowManagerClient(WindowManagerClient* client) override;
77 bool OnWmSetBounds(Window* window, gfx::Rect* bounds) override; 77 bool OnWmSetBounds(Window* window, gfx::Rect* bounds) override;
78 bool OnWmSetProperty(Window* window, 78 bool OnWmSetProperty(Window* window,
79 const std::string& name, 79 const std::string& name,
80 scoped_ptr<std::vector<uint8_t>>* new_data) override; 80 scoped_ptr<std::vector<uint8_t>>* new_data) override;
81 Window* OnWmCreateTopLevelWindow( 81 Window* OnWmCreateTopLevelWindow(
82 std::map<std::string, std::vector<uint8_t>>* properties) override; 82 std::map<std::string, std::vector<uint8_t>>* properties) override;
83 void OnAccelerator(uint32_t id, mojom::EventPtr event) override;
83 84
84 // InterfaceFactory<WindowTreeClient>: 85 // InterfaceFactory<WindowTreeClient>:
85 void Create(mojo::ApplicationConnection* connection, 86 void Create(mojo::ApplicationConnection* connection,
86 mojo::InterfaceRequest<mojom::WindowTreeClient> request) override; 87 mojo::InterfaceRequest<mojom::WindowTreeClient> request) override;
87 88
88 // Used to receive the most recent window tree connection loaded by an embed 89 // Used to receive the most recent window tree connection loaded by an embed
89 // action. 90 // action.
90 WindowTreeConnection* most_recent_connection_; 91 WindowTreeConnection* most_recent_connection_;
91 92
92 private: 93 private:
93 mojom::WindowTreeHostPtr host_; 94 mojom::WindowTreeHostPtr host_;
94 95
95 // The window server connection held by the window manager (app running at 96 // The window server connection held by the window manager (app running at
96 // the root window). 97 // the root window).
97 WindowTreeConnection* window_manager_; 98 WindowTreeConnection* window_manager_;
98 99
99 // A test can override the WM-related behaviour by installing its own 100 // A test can override the WM-related behaviour by installing its own
100 // WindowManagerDelegate during the test. 101 // WindowManagerDelegate during the test.
101 WindowManagerDelegate* window_manager_delegate_; 102 WindowManagerDelegate* window_manager_delegate_;
102 103
103 bool window_tree_connection_destroyed_; 104 bool window_tree_connection_destroyed_;
104 105
105 MOJO_DISALLOW_COPY_AND_ASSIGN(WindowServerTestBase); 106 MOJO_DISALLOW_COPY_AND_ASSIGN(WindowServerTestBase);
106 }; 107 };
107 108
108 } // namespace mus 109 } // namespace mus
109 110
110 #endif // COMPONENTS_MUS_PUBLIC_CPP_TESTS_WINDOW_SERVER_TEST_BASE_H_ 111 #endif // COMPONENTS_MUS_PUBLIC_CPP_TESTS_WINDOW_SERVER_TEST_BASE_H_
OLDNEW
« no previous file with comments | « components/mus/public/cpp/lib/window_tree_client_impl.cc ('k') | components/mus/public/cpp/tests/window_server_test_base.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698