Updating trunk VERSION from 2139.0 to 2140.0
[chromium-blink-merge.git] / components / web_modal / test_web_contents_modal_dialog_manager_delegate.h
blob3ca641acaa0bb1ed6686268f79f95a922d526e6a
1 // Copyright 2013 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
5 #ifndef COMPONENTS_WEB_MODAL_TEST_WEB_CONTENTS_MODAL_DIALOG_MANAGER_DELEGATE_H_
6 #define COMPONENTS_WEB_MODAL_TEST_WEB_CONTENTS_MODAL_DIALOG_MANAGER_DELEGATE_H_
8 #include "components/web_modal/web_contents_modal_dialog_manager_delegate.h"
10 #include "base/basictypes.h"
11 #include "base/compiler_specific.h"
13 namespace web_modal {
15 class TestWebContentsModalDialogManagerDelegate
16 : public WebContentsModalDialogManagerDelegate {
17 public:
18 TestWebContentsModalDialogManagerDelegate();
20 // WebContentsModalDialogManagerDelegate overrides:
21 virtual void SetWebContentsBlocked(content::WebContents* web_contents,
22 bool blocked) OVERRIDE;
24 virtual WebContentsModalDialogHost* GetWebContentsModalDialogHost() OVERRIDE;
26 virtual bool IsWebContentsVisible(
27 content::WebContents* web_contents) OVERRIDE;
29 void set_web_contents_visible(bool visible) {
30 web_contents_visible_ = visible;
33 void set_web_contents_modal_dialog_host(WebContentsModalDialogHost* host) {
34 web_contents_modal_dialog_host_ = host;
37 bool web_contents_blocked() const { return web_contents_blocked_; }
39 private:
40 bool web_contents_visible_;
41 bool web_contents_blocked_;
42 WebContentsModalDialogHost* web_contents_modal_dialog_host_; // Not owned.
44 DISALLOW_COPY_AND_ASSIGN(TestWebContentsModalDialogManagerDelegate);
47 } // namespace web_modal
49 #endif // COMPONENTS_WEB_MODAL_TEST_WEB_CONTENTS_MODAL_DIALOG_MANAGER_DELEGATE_H_