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

Unified Diff: ash/mus/window_manager.h

Issue 2777223002: Gets chrome --mus some what working (Closed)
Patch Set: fix mac Created 3 years, 9 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 | « ash/mus/test/wm_test_helper.cc ('k') | ash/mus/window_manager.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ash/mus/window_manager.h
diff --git a/ash/mus/window_manager.h b/ash/mus/window_manager.h
index 8fb375048c4e9468124cf1e12d9d398a18da83b6..dde061ab91e6014099619d0fd2f9e5061c8881cc 100644
--- a/ash/mus/window_manager.h
+++ b/ash/mus/window_manager.h
@@ -10,6 +10,7 @@
#include <memory>
#include <set>
+#include "ash/common/shell_delegate.h"
#include "ash/root_window_controller.h"
#include "base/macros.h"
#include "base/memory/ref_counted.h"
@@ -43,7 +44,8 @@ namespace ash {
class RootWindowController;
class ScreenMus;
-class ShellDelegate;
+
+enum class Config;
namespace test {
class AshTestHelper;
@@ -61,15 +63,21 @@ class WmTestHelper;
class WindowManager : public aura::WindowManagerDelegate,
public aura::WindowTreeClientDelegate {
public:
- explicit WindowManager(service_manager::Connector* connector);
+ WindowManager(service_manager::Connector* connector, Config config);
~WindowManager() override;
void Init(std::unique_ptr<aura::WindowTreeClient> window_tree_client,
- const scoped_refptr<base::SequencedWorkerPool>& blocking_pool);
+ const scoped_refptr<base::SequencedWorkerPool>& blocking_pool,
+ std::unique_ptr<ash::ShellDelegate> shell_delegate = nullptr);
+
+ // Blocks waiting for the initial set of displays.
+ bool WaitForInitialDisplays();
// Called during shutdown to delete all the RootWindowControllers.
void DeleteAllRootWindowControllers();
+ Config config() const { return config_; }
+
ScreenMus* screen() { return screen_.get(); }
aura::WindowTreeClient* window_tree_client() {
@@ -182,6 +190,8 @@ class WindowManager : public aura::WindowManagerDelegate,
service_manager::Connector* connector_;
display::mojom::DisplayControllerPtr display_controller_;
+ const Config config_;
+
std::unique_ptr<::wm::WMState> wm_state_;
std::unique_ptr<aura::PropertyConverter> property_converter_;
@@ -203,8 +213,9 @@ class WindowManager : public aura::WindowManagerDelegate,
scoped_refptr<base::SequencedWorkerPool> blocking_pool_;
- // Only set in tests. If non-null this is used as the shell delegate.
- std::unique_ptr<ShellDelegate> shell_delegate_for_test_;
+ // The ShellDelegate to install. This may be null, in which case
+ // ShellDelegateMus is used.
+ std::unique_ptr<ShellDelegate> shell_delegate_;
// See WmShellMus's constructor for details. Tests may set to false.
bool create_session_state_delegate_stub_for_test_ = true;
« no previous file with comments | « ash/mus/test/wm_test_helper.cc ('k') | ash/mus/window_manager.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698