| OLD | NEW |
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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 APPS_UI_NATIVE_APP_WINDOW_H_ | 5 #ifndef APPS_UI_NATIVE_APP_WINDOW_H_ |
| 6 #define APPS_UI_NATIVE_APP_WINDOW_H_ | 6 #define APPS_UI_NATIVE_APP_WINDOW_H_ |
| 7 | 7 |
| 8 #include "apps/app_window.h" | 8 #include "apps/app_window.h" |
| 9 #include "components/web_modal/web_contents_modal_dialog_host.h" | 9 #include "components/web_modal/web_contents_modal_dialog_host.h" |
| 10 #include "third_party/skia/include/core/SkColor.h" | 10 #include "third_party/skia/include/core/SkColor.h" |
| (...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 42 virtual void UpdateDraggableRegions( | 42 virtual void UpdateDraggableRegions( |
| 43 const std::vector<extensions::DraggableRegion>& regions) = 0; | 43 const std::vector<extensions::DraggableRegion>& regions) = 0; |
| 44 | 44 |
| 45 // Returns the region used by frameless windows for dragging. May return NULL. | 45 // Returns the region used by frameless windows for dragging. May return NULL. |
| 46 virtual SkRegion* GetDraggableRegion() = 0; | 46 virtual SkRegion* GetDraggableRegion() = 0; |
| 47 | 47 |
| 48 // Called when the window shape is changed. If |region| is NULL then the | 48 // Called when the window shape is changed. If |region| is NULL then the |
| 49 // window is restored to the default shape. | 49 // window is restored to the default shape. |
| 50 virtual void UpdateShape(scoped_ptr<SkRegion> region) = 0; | 50 virtual void UpdateShape(scoped_ptr<SkRegion> region) = 0; |
| 51 | 51 |
| 52 // Set whether the window should receive all keyboard events including task |
| 53 // switching keys. |
| 54 virtual void SetInterceptAllKeys(bool want_all_keys) = 0; |
| 55 |
| 52 // Allows the window to handle unhandled keyboard messages coming back from | 56 // Allows the window to handle unhandled keyboard messages coming back from |
| 53 // the renderer. | 57 // the renderer. |
| 54 virtual void HandleKeyboardEvent( | 58 virtual void HandleKeyboardEvent( |
| 55 const content::NativeWebKeyboardEvent& event) = 0; | 59 const content::NativeWebKeyboardEvent& event) = 0; |
| 56 | 60 |
| 57 // Returns true if the window has no frame, as for a window opened by | 61 // Returns true if the window has no frame, as for a window opened by |
| 58 // chrome.app.window.create with the option 'frame' set to 'none'. | 62 // chrome.app.window.create with the option 'frame' set to 'none'. |
| 59 virtual bool IsFrameless() const = 0; | 63 virtual bool IsFrameless() const = 0; |
| 60 | 64 |
| 61 // Returns information about the window's frame. | 65 // Returns information about the window's frame. |
| (...skipping 28 matching lines...) Expand all Loading... |
| 90 // Returns false if the underlying native window ignores alpha transparency | 94 // Returns false if the underlying native window ignores alpha transparency |
| 91 // when compositing. | 95 // when compositing. |
| 92 virtual bool CanHaveAlphaEnabled() const = 0; | 96 virtual bool CanHaveAlphaEnabled() const = 0; |
| 93 | 97 |
| 94 virtual ~NativeAppWindow() {} | 98 virtual ~NativeAppWindow() {} |
| 95 }; | 99 }; |
| 96 | 100 |
| 97 } // namespace apps | 101 } // namespace apps |
| 98 | 102 |
| 99 #endif // APPS_UI_NATIVE_APP_WINDOW_H_ | 103 #endif // APPS_UI_NATIVE_APP_WINDOW_H_ |
| OLD | NEW |