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

Unified Diff: ash/public/interfaces/shelf.mojom

Issue 2259153002: mash: Port ash_sysui ShelfDelegateMus impl to mojo:ash. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Sync and rebase. Created 4 years, 4 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/public/interfaces/BUILD.gn ('k') | ash/public/interfaces/shelf.typemap » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ash/public/interfaces/shelf.mojom
diff --git a/mash/shelf/public/interfaces/shelf.mojom b/ash/public/interfaces/shelf.mojom
similarity index 71%
rename from mash/shelf/public/interfaces/shelf.mojom
rename to ash/public/interfaces/shelf.mojom
index 077900260d27d46894f22f8b0deb5fa0e971e719..020a5577d5bf1cfe4b37ce6f58b9293df4d87b65 100644
--- a/mash/shelf/public/interfaces/shelf.mojom
+++ b/ash/public/interfaces/shelf.mojom
@@ -2,30 +2,36 @@
// 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 {
+ // Observers are immediately notified of the current shelf states when added.
AddObserver(associated ShelfObserver observer);
- SetAlignment(Alignment alignment);
- SetAutoHideBehavior(AutoHideBehavior auto_hide);
+ // Set the shelf alignment and auto-hide behavior. See WmShelf for details.
+ SetAlignment(ShelfAlignment alignment, int64 display_id);
+ SetAutoHideBehavior(ShelfAutoHideBehavior auto_hide, int64 display_id);
+ // Pin and unpin items on the shelf, or update shelf item images.
PinItem(ShelfItem item, associated ShelfItemDelegate delegate);
UnpinItem(string app_id);
-
SetItemImage(string app_id, skia.mojom.Bitmap image);
};
// 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.
« no previous file with comments | « ash/public/interfaces/BUILD.gn ('k') | ash/public/interfaces/shelf.typemap » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698