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

Unified Diff: chrome/browser/ui/ash/launcher/arc_app_deferred_launcher_controller.cc

Issue 2551243002: Use ChromeLauncherControllerImpl::GetItem; cleanup. (Closed)
Patch Set: Add early return to ShelfModel::Set. Created 4 years 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: chrome/browser/ui/ash/launcher/arc_app_deferred_launcher_controller.cc
diff --git a/chrome/browser/ui/ash/launcher/arc_app_deferred_launcher_controller.cc b/chrome/browser/ui/ash/launcher/arc_app_deferred_launcher_controller.cc
index 965cc8429189feb4319a98180e0e20c3d16bffec..459433c5fb40927967d980fc639dbfd622cecb2c 100644
--- a/chrome/browser/ui/ash/launcher/arc_app_deferred_launcher_controller.cc
+++ b/chrome/browser/ui/ash/launcher/arc_app_deferred_launcher_controller.cc
@@ -196,7 +196,8 @@ void ArcAppDeferredLauncherController::RegisterDeferredLaunch(
const ash::ShelfID shelf_id = owner_->GetShelfIDForAppID(shelf_app_id);
// We are allowed to apply new deferred controller only over shortcut.
- if (shelf_id && owner_->GetItem(shelf_id).type != ash::TYPE_APP_SHORTCUT)
+ const ash::ShelfItem* item = owner_->GetItem(shelf_id);
+ if (item && item->type != ash::TYPE_APP_SHORTCUT)
return;
ArcAppDeferredLauncherItemController* controller =

Powered by Google App Engine
This is Rietveld 408576698