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

Unified Diff: ash/common/shelf/wm_shelf.h

Issue 2093283002: mash: Convert all of //ash/system to use WmShelf (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 6 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: ash/common/shelf/wm_shelf.h
diff --git a/ash/common/shelf/wm_shelf.h b/ash/common/shelf/wm_shelf.h
index ac63988e3dfb38e4ab0bf009d27e88180282f313..d1011d06a5d8488a0bf54459a4757d14f61693da 100644
--- a/ash/common/shelf/wm_shelf.h
+++ b/ash/common/shelf/wm_shelf.h
@@ -25,6 +25,11 @@ class WmWindow;
// Used for accessing global state.
class ASH_EXPORT WmShelf {
public:
+ // Returns the shelf for the primary display. Useful in tests that only use
+ // a single display. In production code use WmRootWindowController::GetShelf()
+ // with the appropriate display's root window controller.
+ static WmShelf* ForPrimaryDisplay();
msw 2016/06/25 00:18:29 q: would you like to make this ForTesting? (based
James Cook 2016/06/25 01:20:58 As discussed offline, eliminated this in favor of
+
// Returns the window showing the shelf.
virtual WmWindow* GetWindow() = 0;
@@ -71,6 +76,9 @@ class ASH_EXPORT WmShelf {
virtual void AddObserver(WmShelfObserver* observer) = 0;
virtual void RemoveObserver(WmShelfObserver* observer) = 0;
+ // Simulates a virtual keyboard bounds update.
+ virtual void SetKeyboardBoundsForTesting(const gfx::Rect& bounds) = 0;
+
protected:
virtual ~WmShelf() {}
};

Powered by Google App Engine
This is Rietveld 408576698