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

Side by Side Diff: ash/launcher/launcher_view.cc

Issue 14584004: Remove ash-disable-launcher-per-display flag (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 7 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 unified diff | Download patch
« no previous file with comments | « ash/display/display_controller_unittest.cc ('k') | ash/root_window_controller.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "ash/launcher/launcher_view.h" 5 #include "ash/launcher/launcher_view.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 8
9 #include "ash/ash_constants.h" 9 #include "ash/ash_constants.h"
10 #include "ash/ash_switches.h" 10 #include "ash/ash_switches.h"
(...skipping 1235 matching lines...) Expand 10 before | Expand all | Expand 10 after
1246 gfx::Size pref = button->GetPreferredSize(); 1246 gfx::Size pref = button->GetPreferredSize();
1247 button->SetTabImage(item.image); 1247 button->SetTabImage(item.image);
1248 if (pref != button->GetPreferredSize()) 1248 if (pref != button->GetPreferredSize())
1249 AnimateToIdealBounds(); 1249 AnimateToIdealBounds();
1250 else 1250 else
1251 button->SchedulePaint(); 1251 button->SchedulePaint();
1252 ReflectItemStatus(item, button); 1252 ReflectItemStatus(item, button);
1253 break; 1253 break;
1254 } 1254 }
1255 case TYPE_BROWSER_SHORTCUT: 1255 case TYPE_BROWSER_SHORTCUT:
1256 if (!Shell::IsLauncherPerDisplayEnabled())
1257 break;
1258 // Fallthrough for the new Launcher since it needs to show the activation 1256 // Fallthrough for the new Launcher since it needs to show the activation
1259 // change as well. 1257 // change as well.
1260 case TYPE_APP_SHORTCUT: 1258 case TYPE_APP_SHORTCUT:
1261 case TYPE_WINDOWED_APP: 1259 case TYPE_WINDOWED_APP:
1262 case TYPE_PLATFORM_APP: 1260 case TYPE_PLATFORM_APP:
1263 case TYPE_APP_PANEL: { 1261 case TYPE_APP_PANEL: {
1264 LauncherButton* button = static_cast<LauncherButton*>(view); 1262 LauncherButton* button = static_cast<LauncherButton*>(view);
1265 ReflectItemStatus(item, button); 1263 ReflectItemStatus(item, button);
1266 // The browser shortcut is currently not a "real" item and as such the 1264 // The browser shortcut is currently not a "real" item and as such the
1267 // the image is bogous as well. We therefore keep the image as is for it. 1265 // the image is bogous as well. We therefore keep the image as is for it.
(...skipping 340 matching lines...) Expand 10 before | Expand all | Expand 10 after
1608 bool LauncherView::ShouldShowTooltipForView(const views::View* view) const { 1606 bool LauncherView::ShouldShowTooltipForView(const views::View* view) const {
1609 if (view == GetAppListButtonView() && 1607 if (view == GetAppListButtonView() &&
1610 Shell::GetInstance()->GetAppListWindow()) 1608 Shell::GetInstance()->GetAppListWindow())
1611 return false; 1609 return false;
1612 const LauncherItem* item = LauncherItemForView(view); 1610 const LauncherItem* item = LauncherItemForView(view);
1613 return (!item || delegate_->ShouldShowTooltip(*item)); 1611 return (!item || delegate_->ShouldShowTooltip(*item));
1614 } 1612 }
1615 1613
1616 } // namespace internal 1614 } // namespace internal
1617 } // namespace ash 1615 } // namespace ash
OLDNEW
« no previous file with comments | « ash/display/display_controller_unittest.cc ('k') | ash/root_window_controller.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698