Index: ash/public/interfaces/shelf.mojom |
diff --git a/mash/shelf/public/interfaces/shelf.mojom b/ash/public/interfaces/shelf.mojom |
similarity index 77% |
rename from mash/shelf/public/interfaces/shelf.mojom |
rename to ash/public/interfaces/shelf.mojom |
index 077900260d27d46894f22f8b0deb5fa0e971e719..285af1ef5419cec23368b4ac9d8e210862235bda 100644 |
--- a/mash/shelf/public/interfaces/shelf.mojom |
+++ b/ash/public/interfaces/shelf.mojom |
@@ -2,19 +2,22 @@ |
// Use of this source code is governed by a BSD-style license that can be |
// found in the LICENSE file. |
-module mash.shelf.mojom; |
+module ash.mojom; |
-import "mash/shelf/public/interfaces/shelf_constants.mojom"; |
import "skia/public/interfaces/bitmap.mojom"; |
-// TODO(msw): Add support for multiple displays (with unified and multi-shelf). |
+// These values match ash::ShelfAlignment. |
+enum ShelfAlignment { BOTTOM, LEFT, RIGHT, BOTTOM_LOCKED, }; |
-// The Shelf controller allows clients (eg. Chrome) to control the mash shelf. |
+// These values match ash::ShelfAutoHideBehavior. |
+enum ShelfAutoHideBehavior { ALWAYS, NEVER, HIDDEN, }; |
+ |
+// The Shelf controller allows clients (eg. Chrome) to control the ash shelf. |
interface ShelfController { |
AddObserver(associated ShelfObserver observer); |
James Cook
2016/08/19 22:43:31
Does the observer get notified with the current st
msw
2016/08/19 23:05:54
Done.
|
- SetAlignment(Alignment alignment); |
- SetAutoHideBehavior(AutoHideBehavior auto_hide); |
+ SetAlignment(ShelfAlignment alignment, int64 display_id); |
James Cook
2016/08/19 22:43:31
Q: Where does Chrome set the alignment/auto-hide b
msw
2016/08/19 23:05:54
Yeah, ChromeMashShelfController sets the alignment
|
+ SetAutoHideBehavior(ShelfAutoHideBehavior auto_hide, int64 display_id); |
PinItem(ShelfItem item, associated ShelfItemDelegate delegate); |
UnpinItem(string app_id); |
@@ -24,8 +27,9 @@ interface ShelfController { |
// ShelfObserver is notified on shelf changes; used to persist profile settings. |
interface ShelfObserver { |
- OnAlignmentChanged(Alignment alignment); |
- OnAutoHideBehaviorChanged(AutoHideBehavior auto_hide); |
+ OnShelfCreated(int64 display_id); |
+ OnAlignmentChanged(ShelfAlignment alignment, int64 display_id); |
+ OnAutoHideBehaviorChanged(ShelfAutoHideBehavior auto_hide, int64 display_id); |
}; |
// ShelfItemDelegate handles command execution and observes shelf item changes. |