OLD | NEW |
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 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_UI_BROWSER_WINDOW_H_ | 5 #ifndef CHROME_BROWSER_UI_BROWSER_WINDOW_H_ |
6 #define CHROME_BROWSER_UI_BROWSER_WINDOW_H_ | 6 #define CHROME_BROWSER_UI_BROWSER_WINDOW_H_ |
7 #pragma once | 7 #pragma once |
8 | 8 |
9 #include "chrome/browser/tab_contents/navigation_entry.h" | 9 #include "chrome/browser/tab_contents/navigation_entry.h" |
10 #include "chrome/common/content_settings_types.h" | 10 #include "chrome/common/content_settings_types.h" |
(...skipping 18 matching lines...) Expand all Loading... |
29 struct NativeWebKeyboardEvent; | 29 struct NativeWebKeyboardEvent; |
30 | 30 |
31 namespace gfx { | 31 namespace gfx { |
32 class Rect; | 32 class Rect; |
33 } | 33 } |
34 | 34 |
35 namespace views { | 35 namespace views { |
36 class Window; | 36 class Window; |
37 } | 37 } |
38 | 38 |
| 39 class Extension; |
| 40 |
39 //////////////////////////////////////////////////////////////////////////////// | 41 //////////////////////////////////////////////////////////////////////////////// |
40 // BrowserWindow interface | 42 // BrowserWindow interface |
41 // An interface implemented by the "view" of the Browser window. | 43 // An interface implemented by the "view" of the Browser window. |
42 // | 44 // |
43 // NOTE: All getters may return NULL. | 45 // NOTE: All getters may return NULL. |
44 class BrowserWindow { | 46 class BrowserWindow { |
45 public: | 47 public: |
46 // Show the window, or activates it if it's already visible. | 48 // Show the window, or activates it if it's already visible. |
47 virtual void Show() = 0; | 49 virtual void Show() = 0; |
48 | 50 |
(...skipping 239 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
288 // be handled in HandleKeyboardEvent() method as a normal keyboard shortcut, | 290 // be handled in HandleKeyboardEvent() method as a normal keyboard shortcut, |
289 // |*is_keyboard_shortcut| should be set to true. | 291 // |*is_keyboard_shortcut| should be set to true. |
290 virtual bool PreHandleKeyboardEvent(const NativeWebKeyboardEvent& event, | 292 virtual bool PreHandleKeyboardEvent(const NativeWebKeyboardEvent& event, |
291 bool* is_keyboard_shortcut) = 0; | 293 bool* is_keyboard_shortcut) = 0; |
292 | 294 |
293 // Allows the BrowserWindow object to handle the specified keyboard event, | 295 // Allows the BrowserWindow object to handle the specified keyboard event, |
294 // if the renderer did not process it. | 296 // if the renderer did not process it. |
295 virtual void HandleKeyboardEvent(const NativeWebKeyboardEvent& event) = 0; | 297 virtual void HandleKeyboardEvent(const NativeWebKeyboardEvent& event) = 0; |
296 | 298 |
297 // Shows the create web app shortcut dialog box. | 299 // Shows the create web app shortcut dialog box. |
298 virtual void ShowCreateShortcutsDialog(TabContents* tab_contents) = 0; | 300 virtual void ShowCreateWebAppShortcutsDialog(TabContents* tab_contents) = 0; |
| 301 |
| 302 // Shows the create chrome app shortcut dialog box. |
| 303 virtual void ShowCreateChromeAppShortcutsDialog(Profile* profile, |
| 304 const Extension* app) = 0; |
299 | 305 |
300 // Clipboard commands applied to the whole browser window. | 306 // Clipboard commands applied to the whole browser window. |
301 virtual void Cut() = 0; | 307 virtual void Cut() = 0; |
302 virtual void Copy() = 0; | 308 virtual void Copy() = 0; |
303 virtual void Paste() = 0; | 309 virtual void Paste() = 0; |
304 | 310 |
305 // Switches between available tabstrip display modes. | 311 // Switches between available tabstrip display modes. |
306 virtual void ToggleTabStripMode() = 0; | 312 virtual void ToggleTabStripMode() = 0; |
307 | 313 |
308 #if defined(OS_MACOSX) | 314 #if defined(OS_MACOSX) |
(...skipping 57 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
366 | 372 |
367 // Returns the ToolbarView. | 373 // Returns the ToolbarView. |
368 virtual ToolbarView* GetToolbarView() const = 0; | 374 virtual ToolbarView* GetToolbarView() const = 0; |
369 #endif | 375 #endif |
370 | 376 |
371 protected: | 377 protected: |
372 virtual ~BrowserWindowTesting() {} | 378 virtual ~BrowserWindowTesting() {} |
373 }; | 379 }; |
374 | 380 |
375 #endif // CHROME_BROWSER_UI_BROWSER_WINDOW_H_ | 381 #endif // CHROME_BROWSER_UI_BROWSER_WINDOW_H_ |
OLD | NEW |