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

Unified Diff: ui/display/desktop.h

Issue 2108933003: Reorder browser list on workspace switch (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Moved code into ChromeBrowserMainExtraPartsX11 Created 4 years, 5 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
Index: ui/display/desktop.h
diff --git a/ui/display/desktop.h b/ui/display/desktop.h
new file mode 100644
index 0000000000000000000000000000000000000000..fd2ebd1c836e869cc96cb51b5dce49f14929ba0e
--- /dev/null
+++ b/ui/display/desktop.h
@@ -0,0 +1,36 @@
+// Copyright 2016 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#ifndef UI_DISPLAY_DESKTOP_H_
+#define UI_DISPLAY_DESKTOP_H_
+
+#include "base/lazy_instance.h"
+#include "base/observer_list.h"
+#include "ui/display/display_export.h"
+
+namespace display {
+
+class DesktopObserver;
+
+class DISPLAY_EXPORT Desktop {
+ public:
+ // Retreives the Desktop singleton.
+ static Desktop* GetDesktop();
Tom (Use chromium acct) 2016/07/06 18:19:11 GetDesktop currently is not used anywhere, but Chr
sky 2016/07/06 20:33:05 Yes. Here is what I recommend doing: . remove all
Tom (Use chromium acct) 2016/07/06 22:29:16 Done.
+
+ // Sets the Desktop singleton instance.
+ static void SetDesktopInstance(Desktop* desktop);
+
+ void AddObserver(DesktopObserver* observer);
+ void RemoveObserver(DesktopObserver* observer);
+
+ protected:
+ Desktop();
+ ~Desktop();
+
+ base::ObserverList<DesktopObserver> desktop_observer_list_;
+};
+
+} // namespace display
+
+#endif

Powered by Google App Engine
This is Rietveld 408576698