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

Side by Side Diff: chrome/browser/ui/views/accessibility/invert_bubble_view.cc

Issue 683583003: Standardize usage of virtual/override/final specifiers. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 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 unified diff | Download patch
« no previous file with comments | « chrome/browser/ui/views/accessibility/accessibility_event_router_views_unittest.cc ('k') | no next file » | 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 "chrome/browser/ui/views/accessibility/invert_bubble_view.h" 5 #include "chrome/browser/ui/views/accessibility/invert_bubble_view.h"
6 6
7 #include "base/prefs/pref_service.h" 7 #include "base/prefs/pref_service.h"
8 #include "chrome/browser/profiles/profile.h" 8 #include "chrome/browser/profiles/profile.h"
9 #include "chrome/browser/ui/browser.h" 9 #include "chrome/browser/ui/browser.h"
10 #include "chrome/browser/ui/views/frame/browser_view.h" 10 #include "chrome/browser/ui/views/frame/browser_view.h"
(...skipping 20 matching lines...) Expand all
31 "https://chrome.google.com/webstore/detail/djcfdncoelnlbldjfhinnjlhdjlikmph" ; 31 "https://chrome.google.com/webstore/detail/djcfdncoelnlbldjfhinnjlhdjlikmph" ;
32 const char kDarkThemeSearchUrl[] = 32 const char kDarkThemeSearchUrl[] =
33 "https://chrome.google.com/webstore/search-themes/dark"; 33 "https://chrome.google.com/webstore/search-themes/dark";
34 const char kLearnMoreUrl[] = 34 const char kLearnMoreUrl[] =
35 "https://groups.google.com/a/googleproductforums.com/d/topic/chrome/Xrco2HsX S-8/discussion"; 35 "https://groups.google.com/a/googleproductforums.com/d/topic/chrome/Xrco2HsX S-8/discussion";
36 36
37 class InvertBubbleView : public views::BubbleDelegateView, 37 class InvertBubbleView : public views::BubbleDelegateView,
38 public views::LinkListener { 38 public views::LinkListener {
39 public: 39 public:
40 InvertBubbleView(Browser* browser, views::View* anchor_view); 40 InvertBubbleView(Browser* browser, views::View* anchor_view);
41 virtual ~InvertBubbleView(); 41 ~InvertBubbleView() override;
42 42
43 private: 43 private:
44 // Overridden from views::BubbleDelegateView: 44 // Overridden from views::BubbleDelegateView:
45 virtual void Init() override; 45 void Init() override;
46 46
47 // Overridden from views::LinkListener: 47 // Overridden from views::LinkListener:
48 virtual void LinkClicked(views::Link* source, int event_flags) override; 48 void LinkClicked(views::Link* source, int event_flags) override;
49 49
50 void OpenLink(const std::string& url, int event_flags); 50 void OpenLink(const std::string& url, int event_flags);
51 51
52 Browser* browser_; 52 Browser* browser_;
53 views::Link* high_contrast_; 53 views::Link* high_contrast_;
54 views::Link* dark_theme_; 54 views::Link* dark_theme_;
55 views::Link* learn_more_; 55 views::Link* learn_more_;
56 views::Link* close_; 56 views::Link* close_;
57 57
58 DISALLOW_COPY_AND_ASSIGN(InvertBubbleView); 58 DISALLOW_COPY_AND_ASSIGN(InvertBubbleView);
(...skipping 102 matching lines...) Expand 10 before | Expand all | Expand 10 after
161 views::View* anchor = browser_view->toolbar()->app_menu(); 161 views::View* anchor = browser_view->toolbar()->app_menu();
162 if (gfx::IsInvertedColorScheme() && anchor && anchor->GetWidget() && 162 if (gfx::IsInvertedColorScheme() && anchor && anchor->GetWidget() &&
163 !pref_service->GetBoolean(prefs::kInvertNotificationShown)) { 163 !pref_service->GetBoolean(prefs::kInvertNotificationShown)) {
164 pref_service->SetBoolean(prefs::kInvertNotificationShown, true); 164 pref_service->SetBoolean(prefs::kInvertNotificationShown, true);
165 InvertBubbleView* delegate = new InvertBubbleView(browser, anchor); 165 InvertBubbleView* delegate = new InvertBubbleView(browser, anchor);
166 views::BubbleDelegateView::CreateBubble(delegate)->Show(); 166 views::BubbleDelegateView::CreateBubble(delegate)->Show();
167 } 167 }
168 } 168 }
169 169
170 } // namespace chrome 170 } // namespace chrome
OLDNEW
« no previous file with comments | « chrome/browser/ui/views/accessibility/accessibility_event_router_views_unittest.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698