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
3 // found in the LICENSE file.
5 #ifndef COMPONENTS_APP_MODAL_DIALOGS_JAVASCRIPT_DIALOG_MANAGER_H_
6 #define COMPONENTS_APP_MODAL_DIALOGS_JAVASCRIPT_DIALOG_MANAGER_H_
8 #include "base/memory/scoped_ptr.h"
11 class JavaScriptDialogManager;
14 class JavaScriptDialogExtensionsClient;
15 class JavaScriptNativeDialogFactory;
17 // Returns a JavaScriptDialogManager that creates real dialogs.
18 // It returns a Singleton instance of JavaScriptDialogManager,
19 // which should not be deleted.
20 content::JavaScriptDialogManager* GetJavaScriptDialogManagerInstance();
22 // Sets the JavaScriptNativeDialogFactory used to create platform specific
23 // dialog window implementation.
24 void SetJavaScriptNativeDialogFactory(
25 scoped_ptr<JavaScriptNativeDialogFactory> factory);
27 // JavaScript dialog may be opened by an extensions/app, thus needs
28 // access to extensions functionality. This sets a client interface to
29 // access //extensions.
30 void SetJavaScriptDialogExtensionsClient(
31 scoped_ptr<JavaScriptDialogExtensionsClient> client);
33 #endif // COMPONENTS_APP_MODAL_DIALOGS_JAVASCRIPT_DIALOG_MANAGER_H_