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

Unified Diff: ash/shell/window_watcher_shelf_item_delegate.cc

Issue 2860503002: mash: Replace int ShelfIDs with AppLaunchID strings. (Closed)
Patch Set: Restore AppLaunchId class via using ShelfID = AppLaunchId; cleanup. Created 3 years, 7 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/shell/window_watcher_shelf_item_delegate.cc
diff --git a/ash/shell/window_watcher_shelf_item_delegate.cc b/ash/shell/window_watcher_shelf_item_delegate.cc
index 6fcea5c956f38d770ca69b02c00d962183a031be..2aa89e830044dcd3d74c2b8729c7cbbe2d1994b8 100644
--- a/ash/shell/window_watcher_shelf_item_delegate.cc
+++ b/ash/shell/window_watcher_shelf_item_delegate.cc
@@ -14,8 +14,8 @@ namespace shell {
WindowWatcherShelfItemDelegate::WindowWatcherShelfItemDelegate(
ShelfID id,
WindowWatcher* watcher)
- : ShelfItemDelegate(AppLaunchId()), id_(id), watcher_(watcher) {
- DCHECK_NE(id_, kInvalidShelfID);
+ : ShelfItemDelegate(id), watcher_(watcher) {
+ DCHECK(!id.IsEmpty());
DCHECK(watcher_);
}
@@ -26,7 +26,7 @@ void WindowWatcherShelfItemDelegate::ItemSelected(
int64_t display_id,
ShelfLaunchSource source,
const ItemSelectedCallback& callback) {
- aura::Window* window = watcher_->GetWindowByID(id_);
+ aura::Window* window = watcher_->GetWindowByID(shelf_id());
if (window->type() == ui::wm::WINDOW_TYPE_PANEL)
wm::MoveWindowToDisplay(window, display_id);
window->Show();

Powered by Google App Engine
This is Rietveld 408576698