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

Unified Diff: ash/shelf/shelf_view.cc

Issue 78803002: Fixing focus highlight on high DPI devices for accessibility (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Addressed Created 7 years, 1 month 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
« no previous file with comments | « no previous file | ash/system/tray/actionable_view.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ash/shelf/shelf_view.cc
diff --git a/ash/shelf/shelf_view.cc b/ash/shelf/shelf_view.cc
index 87316fb5d57026741450468deee3d859d917de83..be39b94f2fe1be772dfd68bdba7b43160898682b 100644
--- a/ash/shelf/shelf_view.cc
+++ b/ash/shelf/shelf_view.cc
@@ -241,22 +241,6 @@ class LauncherFocusSearch : public views::FocusSearch {
DISALLOW_COPY_AND_ASSIGN(LauncherFocusSearch);
};
-class ShelfButtonFocusBorder : public views::FocusBorder {
- public:
- ShelfButtonFocusBorder() {}
- virtual ~ShelfButtonFocusBorder() {}
-
- private:
- // views::FocusBorder overrides:
- virtual void Paint(const View& view, gfx::Canvas* canvas) const OVERRIDE {
- gfx::Rect rect(view.GetLocalBounds());
- rect.Inset(1, 1);
- canvas->DrawRect(rect, kFocusBorderColor);
- }
-
- DISALLOW_COPY_AND_ASSIGN(ShelfButtonFocusBorder);
-};
-
// AnimationDelegate used when inserting a new item. This steadily increases the
// opacity of the layer as the animation progress.
class FadeInAnimationDelegate
@@ -954,7 +938,9 @@ views::View* ShelfView::CreateViewForItem(const LauncherItem& item) {
break;
}
view->set_context_menu_controller(this);
- view->set_focus_border(new ShelfButtonFocusBorder);
+ view->set_focus_border(views::FocusBorder::CreateSolidFocusBorder(
+ kFocusBorderColor,
+ gfx::Insets(1, 1, 1, 1)));
DCHECK(view);
ConfigureChildView(view);
« no previous file with comments | « no previous file | ash/system/tray/actionable_view.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698