Bookmark sync promo for Views.
[chromium-blink-merge.git] / chrome / browser / ui / views / browser_dialogs.h
blob30d12a5f556f2c6d072ccde431aabaca4a5db8ec
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 CHROME_BROWSER_UI_VIEWS_BROWSER_DIALOGS_H_
6 #define CHROME_BROWSER_UI_VIEWS_BROWSER_DIALOGS_H_
8 #include "base/memory/scoped_ptr.h"
9 #include "ui/gfx/native_widget_types.h"
11 // This file contains functions for running a variety of browser dialogs and
12 // popups. The dialogs here are the ones that the caller does not need to
13 // access the class of the popup. It allows us to break dependencies by
14 // allowing the callers to not depend on the classes implementing the dialogs.
15 // TODO: Make as many of these methods as possible cross platform, and move them
16 // into chrome/browser/ui/browser_dialogs.h.
18 class BookmarkBubbleDelegate;
19 class BookmarkBubbleViewObserver;
20 class Browser;
21 class BrowserView;
22 class EditSearchEngineControllerDelegate;
23 class FindBar;
24 class GURL;
25 class Profile;
26 class TemplateURL;
28 namespace extensions {
29 class Extension;
32 namespace views {
33 class View;
36 namespace chrome {
38 // Shows or hides the bookmark bubble anchored to the supplied view.
39 void ShowBookmarkBubbleView(views::View* anchor_view,
40 BookmarkBubbleViewObserver* observer,
41 scoped_ptr<BookmarkBubbleDelegate> delegate,
42 Profile* profile,
43 const GURL& url,
44 bool newly_bookmarked);
45 void HideBookmarkBubbleView();
46 bool IsBookmarkBubbleViewShowing();
48 // Creates and returns a find bar for the given browser window. See FindBarWin.
49 FindBar* CreateFindBar(BrowserView* browser_view);
51 // Shows a dialog box that allows a search engine to be edited. |template_url|
52 // is the search engine being edited. If it is NULL, then the dialog will add a
53 // new search engine with the data the user supplies. |delegate| is an object
54 // to be notified when the user is done editing, or NULL. If NULL, the dialog
55 // will update the model with the user's edits directly.
56 void EditSearchEngine(gfx::NativeWindow parent,
57 TemplateURL* template_url,
58 EditSearchEngineControllerDelegate* delegate,
59 Profile* profile);
61 // Shows the create chrome app shortcut dialog box.
62 void ShowCreateChromeAppShortcutsDialog(gfx::NativeWindow parent_window,
63 Profile* profile,
64 const extensions::Extension* app);
66 } // namespace chrome
68 #endif // CHROME_BROWSER_UI_VIEWS_BROWSER_DIALOGS_H_