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

Side by Side Diff: components/web_modal/web_contents_modal_dialog_manager_unittest.cc

Issue 623133002: replace OVERRIDE and FINAL with override and final in components/ (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 "components/web_modal/web_contents_modal_dialog_manager.h" 5 #include "components/web_modal/web_contents_modal_dialog_manager.h"
6 6
7 #include <map> 7 #include <map>
8 8
9 #include "base/memory/scoped_ptr.h" 9 #include "base/memory/scoped_ptr.h"
10 #include "components/web_modal/single_web_contents_dialog_manager.h" 10 #include "components/web_modal/single_web_contents_dialog_manager.h"
(...skipping 35 matching lines...) Expand 10 before | Expand all | Expand 10 after
46 NativeWebContentsModalDialog dialog, 46 NativeWebContentsModalDialog dialog,
47 SingleWebContentsDialogManagerDelegate* delegate, 47 SingleWebContentsDialogManagerDelegate* delegate,
48 NativeManagerTracker* tracker) 48 NativeManagerTracker* tracker)
49 : delegate_(delegate), 49 : delegate_(delegate),
50 dialog_(dialog), 50 dialog_(dialog),
51 tracker_(tracker) { 51 tracker_(tracker) {
52 if (tracker_) 52 if (tracker_)
53 tracker_->SetState(NativeManagerTracker::NOT_SHOWN); 53 tracker_->SetState(NativeManagerTracker::NOT_SHOWN);
54 } 54 }
55 55
56 virtual void Show() OVERRIDE { 56 virtual void Show() override {
57 if (tracker_) 57 if (tracker_)
58 tracker_->SetState(NativeManagerTracker::SHOWN); 58 tracker_->SetState(NativeManagerTracker::SHOWN);
59 } 59 }
60 virtual void Hide() OVERRIDE { 60 virtual void Hide() override {
61 if (tracker_) 61 if (tracker_)
62 tracker_->SetState(NativeManagerTracker::HIDDEN); 62 tracker_->SetState(NativeManagerTracker::HIDDEN);
63 } 63 }
64 virtual void Close() OVERRIDE { 64 virtual void Close() override {
65 if (tracker_) 65 if (tracker_)
66 tracker_->SetState(NativeManagerTracker::CLOSED); 66 tracker_->SetState(NativeManagerTracker::CLOSED);
67 delegate_->WillClose(dialog_); 67 delegate_->WillClose(dialog_);
68 } 68 }
69 virtual void Focus() OVERRIDE { 69 virtual void Focus() override {
70 } 70 }
71 virtual void Pulse() OVERRIDE { 71 virtual void Pulse() override {
72 } 72 }
73 virtual void HostChanged(WebContentsModalDialogHost* new_host) OVERRIDE { 73 virtual void HostChanged(WebContentsModalDialogHost* new_host) override {
74 } 74 }
75 virtual NativeWebContentsModalDialog dialog() OVERRIDE { 75 virtual NativeWebContentsModalDialog dialog() override {
76 return dialog_; 76 return dialog_;
77 } 77 }
78 78
79 void StopTracking() { 79 void StopTracking() {
80 tracker_ = NULL; 80 tracker_ = NULL;
81 } 81 }
82 82
83 private: 83 private:
84 SingleWebContentsDialogManagerDelegate* delegate_; 84 SingleWebContentsDialogManagerDelegate* delegate_;
85 NativeWebContentsModalDialog dialog_; 85 NativeWebContentsModalDialog dialog_;
(...skipping 284 matching lines...) Expand 10 before | Expand all | Expand 10 after
370 370
371 test_api->CloseAllDialogs(); 371 test_api->CloseAllDialogs();
372 372
373 EXPECT_FALSE(delegate->web_contents_blocked()); 373 EXPECT_FALSE(delegate->web_contents_blocked());
374 EXPECT_FALSE(manager->IsDialogActive()); 374 EXPECT_FALSE(manager->IsDialogActive());
375 for (int i = 0; i < kWindowCount; i++) 375 for (int i = 0; i < kWindowCount; i++)
376 EXPECT_EQ(NativeManagerTracker::CLOSED, trackers[i].state_); 376 EXPECT_EQ(NativeManagerTracker::CLOSED, trackers[i].state_);
377 } 377 }
378 378
379 } // namespace web_modal 379 } // namespace web_modal
OLDNEW
« no previous file with comments | « components/web_modal/web_contents_modal_dialog_manager.h ('k') | components/webdata/common/web_data_results.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698