18bcbed890bc3ce4d7a057a8f32cab53fa534672eTorne (Richard Coles)// Copyright 2013 The Chromium Authors. All rights reserved.
28bcbed890bc3ce4d7a057a8f32cab53fa534672eTorne (Richard Coles)// Use of this source code is governed by a BSD-style license that can be
38bcbed890bc3ce4d7a057a8f32cab53fa534672eTorne (Richard Coles)// found in the LICENSE file.
48bcbed890bc3ce4d7a057a8f32cab53fa534672eTorne (Richard Coles)
58bcbed890bc3ce4d7a057a8f32cab53fa534672eTorne (Richard Coles)#ifndef COMPONENTS_WEB_MODAL_TEST_WEB_CONTENTS_MODAL_DIALOG_MANAGER_DELEGATE_H_
68bcbed890bc3ce4d7a057a8f32cab53fa534672eTorne (Richard Coles)#define COMPONENTS_WEB_MODAL_TEST_WEB_CONTENTS_MODAL_DIALOG_MANAGER_DELEGATE_H_
78bcbed890bc3ce4d7a057a8f32cab53fa534672eTorne (Richard Coles)
88bcbed890bc3ce4d7a057a8f32cab53fa534672eTorne (Richard Coles)#include "components/web_modal/web_contents_modal_dialog_manager_delegate.h"
98bcbed890bc3ce4d7a057a8f32cab53fa534672eTorne (Richard Coles)
108bcbed890bc3ce4d7a057a8f32cab53fa534672eTorne (Richard Coles)#include "base/basictypes.h"
118bcbed890bc3ce4d7a057a8f32cab53fa534672eTorne (Richard Coles)#include "base/compiler_specific.h"
128bcbed890bc3ce4d7a057a8f32cab53fa534672eTorne (Richard Coles)
138bcbed890bc3ce4d7a057a8f32cab53fa534672eTorne (Richard Coles)namespace web_modal {
148bcbed890bc3ce4d7a057a8f32cab53fa534672eTorne (Richard Coles)
158bcbed890bc3ce4d7a057a8f32cab53fa534672eTorne (Richard Coles)class TestWebContentsModalDialogManagerDelegate
168bcbed890bc3ce4d7a057a8f32cab53fa534672eTorne (Richard Coles)    : public WebContentsModalDialogManagerDelegate {
178bcbed890bc3ce4d7a057a8f32cab53fa534672eTorne (Richard Coles) public:
188bcbed890bc3ce4d7a057a8f32cab53fa534672eTorne (Richard Coles)  TestWebContentsModalDialogManagerDelegate();
198bcbed890bc3ce4d7a057a8f32cab53fa534672eTorne (Richard Coles)
208bcbed890bc3ce4d7a057a8f32cab53fa534672eTorne (Richard Coles)  // WebContentsModalDialogManagerDelegate overrides:
218bcbed890bc3ce4d7a057a8f32cab53fa534672eTorne (Richard Coles)  virtual void SetWebContentsBlocked(content::WebContents* web_contents,
228bcbed890bc3ce4d7a057a8f32cab53fa534672eTorne (Richard Coles)                                     bool blocked) OVERRIDE;
238bcbed890bc3ce4d7a057a8f32cab53fa534672eTorne (Richard Coles)
248bcbed890bc3ce4d7a057a8f32cab53fa534672eTorne (Richard Coles)  virtual WebContentsModalDialogHost* GetWebContentsModalDialogHost() OVERRIDE;
258bcbed890bc3ce4d7a057a8f32cab53fa534672eTorne (Richard Coles)
268bcbed890bc3ce4d7a057a8f32cab53fa534672eTorne (Richard Coles)  virtual bool IsWebContentsVisible(
278bcbed890bc3ce4d7a057a8f32cab53fa534672eTorne (Richard Coles)      content::WebContents* web_contents) OVERRIDE;
288bcbed890bc3ce4d7a057a8f32cab53fa534672eTorne (Richard Coles)
298bcbed890bc3ce4d7a057a8f32cab53fa534672eTorne (Richard Coles)  void set_web_contents_visible(bool visible) {
308bcbed890bc3ce4d7a057a8f32cab53fa534672eTorne (Richard Coles)    web_contents_visible_ = visible;
318bcbed890bc3ce4d7a057a8f32cab53fa534672eTorne (Richard Coles)  }
328bcbed890bc3ce4d7a057a8f32cab53fa534672eTorne (Richard Coles)
338bcbed890bc3ce4d7a057a8f32cab53fa534672eTorne (Richard Coles)  void set_web_contents_modal_dialog_host(WebContentsModalDialogHost* host) {
348bcbed890bc3ce4d7a057a8f32cab53fa534672eTorne (Richard Coles)    web_contents_modal_dialog_host_ = host;
358bcbed890bc3ce4d7a057a8f32cab53fa534672eTorne (Richard Coles)  }
368bcbed890bc3ce4d7a057a8f32cab53fa534672eTorne (Richard Coles)
378bcbed890bc3ce4d7a057a8f32cab53fa534672eTorne (Richard Coles)  bool web_contents_blocked() const { return web_contents_blocked_; }
388bcbed890bc3ce4d7a057a8f32cab53fa534672eTorne (Richard Coles)
398bcbed890bc3ce4d7a057a8f32cab53fa534672eTorne (Richard Coles) private:
408bcbed890bc3ce4d7a057a8f32cab53fa534672eTorne (Richard Coles)  bool web_contents_visible_;
418bcbed890bc3ce4d7a057a8f32cab53fa534672eTorne (Richard Coles)  bool web_contents_blocked_;
428bcbed890bc3ce4d7a057a8f32cab53fa534672eTorne (Richard Coles)  WebContentsModalDialogHost* web_contents_modal_dialog_host_;  // Not owned.
438bcbed890bc3ce4d7a057a8f32cab53fa534672eTorne (Richard Coles)
448bcbed890bc3ce4d7a057a8f32cab53fa534672eTorne (Richard Coles)  DISALLOW_COPY_AND_ASSIGN(TestWebContentsModalDialogManagerDelegate);
458bcbed890bc3ce4d7a057a8f32cab53fa534672eTorne (Richard Coles)};
468bcbed890bc3ce4d7a057a8f32cab53fa534672eTorne (Richard Coles)
478bcbed890bc3ce4d7a057a8f32cab53fa534672eTorne (Richard Coles)}  // namespace web_modal
488bcbed890bc3ce4d7a057a8f32cab53fa534672eTorne (Richard Coles)
498bcbed890bc3ce4d7a057a8f32cab53fa534672eTorne (Richard Coles)#endif  // COMPONENTS_WEB_MODAL_TEST_WEB_CONTENTS_MODAL_DIALOG_MANAGER_DELEGATE_H_
50