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

Side by Side Diff: chrome/browser/geolocation/geolocation_permission_context_unittest.cc

Issue 648653003: Standardize usage of virtual/override/final in chrome/browser/ (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 2 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
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/geolocation/geolocation_permission_context.h" 5 #include "chrome/browser/geolocation/geolocation_permission_context.h"
6 6
7 #include <set> 7 #include <set>
8 #include <string> 8 #include <string>
9 #include <utility> 9 #include <utility>
10 10
(...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after
49 49
50 using content::MockRenderProcessHost; 50 using content::MockRenderProcessHost;
51 51
52 52
53 // ClosedInfoBarTracker ------------------------------------------------------- 53 // ClosedInfoBarTracker -------------------------------------------------------
54 54
55 // We need to track which infobars were closed. 55 // We need to track which infobars were closed.
56 class ClosedInfoBarTracker : public content::NotificationObserver { 56 class ClosedInfoBarTracker : public content::NotificationObserver {
57 public: 57 public:
58 ClosedInfoBarTracker(); 58 ClosedInfoBarTracker();
59 virtual ~ClosedInfoBarTracker(); 59 ~ClosedInfoBarTracker() override;
60 60
61 // content::NotificationObserver: 61 // content::NotificationObserver:
62 virtual void Observe(int type, 62 void Observe(int type,
63 const content::NotificationSource& source, 63 const content::NotificationSource& source,
64 const content::NotificationDetails& details) override; 64 const content::NotificationDetails& details) override;
65 65
66 size_t size() const { return removed_infobars_.size(); } 66 size_t size() const { return removed_infobars_.size(); }
67 67
68 bool Contains(infobars::InfoBar* infobar) const; 68 bool Contains(infobars::InfoBar* infobar) const;
69 void Clear(); 69 void Clear();
70 70
71 private: 71 private:
72 FRIEND_TEST_ALL_PREFIXES(GeolocationPermissionContextTests, TabDestroyed); 72 FRIEND_TEST_ALL_PREFIXES(GeolocationPermissionContextTests, TabDestroyed);
73 content::NotificationRegistrar registrar_; 73 content::NotificationRegistrar registrar_;
74 std::set<infobars::InfoBar*> removed_infobars_; 74 std::set<infobars::InfoBar*> removed_infobars_;
(...skipping 700 matching lines...) Expand 10 before | Expand all | Expand 10 after
775 // it is the embedder. 775 // it is the embedder.
776 EXPECT_EQ(map->GetLastUsage(requesting_frame_0.GetOrigin(), 776 EXPECT_EQ(map->GetLastUsage(requesting_frame_0.GetOrigin(),
777 requesting_frame_0.GetOrigin(), 777 requesting_frame_0.GetOrigin(),
778 CONTENT_SETTINGS_TYPE_GEOLOCATION).ToDoubleT(), 778 CONTENT_SETTINGS_TYPE_GEOLOCATION).ToDoubleT(),
779 13); 779 13);
780 EXPECT_EQ(map->GetLastUsage(requesting_frame_1.GetOrigin(), 780 EXPECT_EQ(map->GetLastUsage(requesting_frame_1.GetOrigin(),
781 requesting_frame_0.GetOrigin(), 781 requesting_frame_0.GetOrigin(),
782 CONTENT_SETTINGS_TYPE_GEOLOCATION).ToDoubleT(), 782 CONTENT_SETTINGS_TYPE_GEOLOCATION).ToDoubleT(),
783 11); 783 11);
784 } 784 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698