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

Unified Diff: ash/system/status_area_widget_delegate.cc

Issue 22291003: ash:Shelf Update Alternate Layout (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 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
Index: ash/system/status_area_widget_delegate.cc
diff --git a/ash/system/status_area_widget_delegate.cc b/ash/system/status_area_widget_delegate.cc
index 77d3cbf0f3f28a0ab86a6f82d41f156c6a2d98b9..a7781efa754328ad78eb9e0abd476422ef0516f9 100644
--- a/ash/system/status_area_widget_delegate.cc
+++ b/ash/system/status_area_widget_delegate.cc
@@ -5,6 +5,7 @@
#include "ash/system/status_area_widget_delegate.h"
#include "ash/ash_export.h"
+#include "ash/ash_switches.h"
#include "ash/focus_cycler.h"
#include "ash/shell.h"
#include "ash/shell_window_ids.h"
@@ -98,7 +99,8 @@ void StatusAreaWidgetDelegate::UpdateLayout() {
if (!child->visible())
continue;
if (!is_first_visible_child)
- columns->AddPaddingColumn(0, kTraySpacing);
+ columns->AddPaddingColumn(0, ash::switches::UseAlternateShelfLayout() ?
+ kAlternateTraySpacing : kTraySpacing);
Mr4D (OOO till 08-26) 2013/08/06 21:10:34 You might want to populate a variable before the f
Harry McCleave 2013/08/06 22:41:06 Done.
is_first_visible_child = false;
columns->AddColumn(views::GridLayout::CENTER, views::GridLayout::FILL,
0, /* resize percent */
@@ -124,7 +126,8 @@ void StatusAreaWidgetDelegate::UpdateLayout() {
if (!child->visible())
continue;
if (!is_first_visible_child)
- layout->AddPaddingRow(0, kTraySpacing);
+ layout->AddPaddingRow(0, ash::switches::UseAlternateShelfLayout() ?
+ kAlternateTraySpacing : kTraySpacing);
is_first_visible_child = false;
layout->StartRow(0, 0);
layout->AddView(child);

Powered by Google App Engine
This is Rietveld 408576698