OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 #ifndef CHROME_BROWSER_MEDIA_GALLERIES_MEDIA_GALLERIES_DIALOG_CONTROLLER_H_ | 5 #ifndef CHROME_BROWSER_MEDIA_GALLERIES_MEDIA_GALLERIES_DIALOG_CONTROLLER_H_ |
6 #define CHROME_BROWSER_MEDIA_GALLERIES_MEDIA_GALLERIES_DIALOG_CONTROLLER_H_ | 6 #define CHROME_BROWSER_MEDIA_GALLERIES_MEDIA_GALLERIES_DIALOG_CONTROLLER_H_ |
7 | 7 |
8 #include <stddef.h> | 8 #include <stddef.h> |
9 | 9 |
10 #include <vector> | 10 #include <vector> |
(...skipping 50 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
61 | 61 |
62 // The title of the dialog view. | 62 // The title of the dialog view. |
63 virtual base::string16 GetHeader() const = 0; | 63 virtual base::string16 GetHeader() const = 0; |
64 | 64 |
65 // Explanatory text directly below the title. | 65 // Explanatory text directly below the title. |
66 virtual base::string16 GetSubtext() const = 0; | 66 virtual base::string16 GetSubtext() const = 0; |
67 | 67 |
68 // Initial state of whether the dialog's confirmation button will be enabled. | 68 // Initial state of whether the dialog's confirmation button will be enabled. |
69 virtual bool IsAcceptAllowed() const = 0; | 69 virtual bool IsAcceptAllowed() const = 0; |
70 | 70 |
71 // Should the dialog present UI for the user to view the entry contents. | |
72 virtual bool ShouldShowFolderViewer(const Entry& entry) const = 0; | |
73 | |
74 // The titles for different sections of entries. Empty hides the header. | 71 // The titles for different sections of entries. Empty hides the header. |
75 virtual std::vector<base::string16> GetSectionHeaders() const = 0; | 72 virtual std::vector<base::string16> GetSectionHeaders() const = 0; |
76 | 73 |
77 // Get the set of permissions for the |index|th section. The size of the | 74 // Get the set of permissions for the |index|th section. The size of the |
78 // vector returned from GetSectionHeaders() defines the number of sections. | 75 // vector returned from GetSectionHeaders() defines the number of sections. |
79 virtual Entries GetSectionEntries(size_t index) const = 0; | 76 virtual Entries GetSectionEntries(size_t index) const = 0; |
80 | 77 |
81 // The text for an auxiliary button. Empty hides the button. | 78 // The text for an auxiliary button. Empty hides the button. |
82 virtual base::string16 GetAuxiliaryButtonText() const = 0; | 79 virtual base::string16 GetAuxiliaryButtonText() const = 0; |
83 | 80 |
84 // Called when an auxiliary button is clicked. | 81 // Called when an auxiliary button is clicked. |
85 virtual void DidClickAuxiliaryButton() = 0; | 82 virtual void DidClickAuxiliaryButton() = 0; |
86 | 83 |
87 // An entry checkbox was toggled. | 84 // An entry checkbox was toggled. |
88 virtual void DidToggleEntry(MediaGalleryPrefId id, bool selected) = 0; | 85 virtual void DidToggleEntry(MediaGalleryPrefId id, bool selected) = 0; |
89 | 86 |
90 // A folder viewer button was clicked for one of the entries. | |
91 virtual void DidClickOpenFolderViewer(MediaGalleryPrefId id) = 0; | |
92 | |
93 // The forget command in the context menu was selected. | 87 // The forget command in the context menu was selected. |
94 virtual void DidForgetEntry(MediaGalleryPrefId id) = 0; | 88 virtual void DidForgetEntry(MediaGalleryPrefId id) = 0; |
95 | 89 |
96 // The text for the accept button. | 90 // The text for the accept button. |
97 virtual base::string16 GetAcceptButtonText() const = 0; | 91 virtual base::string16 GetAcceptButtonText() const = 0; |
98 | 92 |
99 // The dialog is being deleted. | 93 // The dialog is being deleted. |
100 virtual void DialogFinished(bool accepted) = 0; | 94 virtual void DialogFinished(bool accepted) = 0; |
101 | 95 |
102 virtual ui::MenuModel* GetContextMenu(MediaGalleryPrefId id) = 0; | 96 virtual ui::MenuModel* GetContextMenu(MediaGalleryPrefId id) = 0; |
103 | 97 |
104 virtual content::WebContents* WebContents() = 0; | 98 virtual content::WebContents* WebContents() = 0; |
105 | 99 |
106 protected: | 100 protected: |
107 MediaGalleriesDialogController(); | 101 MediaGalleriesDialogController(); |
108 virtual ~MediaGalleriesDialogController(); | 102 virtual ~MediaGalleriesDialogController(); |
109 | 103 |
110 DISALLOW_COPY_AND_ASSIGN(MediaGalleriesDialogController); | 104 DISALLOW_COPY_AND_ASSIGN(MediaGalleriesDialogController); |
111 }; | 105 }; |
112 | 106 |
113 #endif // CHROME_BROWSER_MEDIA_GALLERIES_MEDIA_GALLERIES_DIALOG_CONTROLLER_H_ | 107 #endif // CHROME_BROWSER_MEDIA_GALLERIES_MEDIA_GALLERIES_DIALOG_CONTROLLER_H_ |
OLD | NEW |