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

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

Issue 9406031: Makes it so the launcher only gets focus when using the keyboard. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years, 10 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 | Annotate | Revision Log
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 "ash/launcher/app_launcher_button.h" 7 #include "ash/launcher/app_launcher_button.h"
8 #include "ash/launcher/launcher_model.h" 8 #include "ash/launcher/launcher_model.h"
9 #include "ash/launcher/launcher_window_cycler.h" 9 #include "ash/launcher/launcher_window_cycler.h"
10 #include "ash/launcher/tabbed_launcher_button.h" 10 #include "ash/launcher/tabbed_launcher_button.h"
(...skipping 194 matching lines...) Expand 10 before | Expand all | Expand 10 after
205 205
206 const LauncherItems& items(model_->items()); 206 const LauncherItems& items(model_->items());
207 for (LauncherItems::const_iterator i = items.begin(); i != items.end(); ++i) { 207 for (LauncherItems::const_iterator i = items.begin(); i != items.end(); ++i) {
208 views::View* child = CreateViewForItem(*i); 208 views::View* child = CreateViewForItem(*i);
209 child->SetPaintToLayer(true); 209 child->SetPaintToLayer(true);
210 view_model_->Add(child, static_cast<int>(i - items.begin())); 210 view_model_->Add(child, static_cast<int>(i - items.begin()));
211 AddChildView(child); 211 AddChildView(child);
212 } 212 }
213 213
214 overflow_button_ = new views::ImageButton(this); 214 overflow_button_ = new views::ImageButton(this);
215 overflow_button_->set_focusable(true); 215 overflow_button_->set_accessibility_focusable(true);
216 overflow_button_->SetImage( 216 overflow_button_->SetImage(
217 views::CustomButton::BS_NORMAL, 217 views::CustomButton::BS_NORMAL,
218 rb.GetImageNamed(IDR_AURA_LAUNCHER_OVERFLOW).ToSkBitmap()); 218 rb.GetImageNamed(IDR_AURA_LAUNCHER_OVERFLOW).ToSkBitmap());
219 overflow_button_->SetImage( 219 overflow_button_->SetImage(
220 views::CustomButton::BS_HOT, 220 views::CustomButton::BS_HOT,
221 rb.GetImageNamed(IDR_AURA_LAUNCHER_OVERFLOW_HOT).ToSkBitmap()); 221 rb.GetImageNamed(IDR_AURA_LAUNCHER_OVERFLOW_HOT).ToSkBitmap());
222 overflow_button_->SetImage( 222 overflow_button_->SetImage(
223 views::CustomButton::BS_PUSHED, 223 views::CustomButton::BS_PUSHED,
224 rb.GetImageNamed(IDR_AURA_LAUNCHER_OVERFLOW_PUSHED).ToSkBitmap()); 224 rb.GetImageNamed(IDR_AURA_LAUNCHER_OVERFLOW_PUSHED).ToSkBitmap());
225 ConfigureChildView(overflow_button_); 225 ConfigureChildView(overflow_button_);
(...skipping 437 matching lines...) Expand 10 before | Expand all | Expand 10 after
663 return l10n_util::GetStringUTF16(IDS_AURA_APP_LIST_TITLE); 663 return l10n_util::GetStringUTF16(IDS_AURA_APP_LIST_TITLE);
664 664
665 case TYPE_BROWSER_SHORTCUT: 665 case TYPE_BROWSER_SHORTCUT:
666 return l10n_util::GetStringUTF16(IDS_AURA_CYCLER_TITLE); 666 return l10n_util::GetStringUTF16(IDS_AURA_CYCLER_TITLE);
667 } 667 }
668 return string16(); 668 return string16();
669 } 669 }
670 670
671 } // namespace internal 671 } // namespace internal
672 } // namespace ash 672 } // namespace ash
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698