| OLD | NEW |
| 1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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_ANDROID_COMPOSITOR_LAYER_TAB_HANDLE_LAYER_H_ | 5 #ifndef CHROME_BROWSER_ANDROID_COMPOSITOR_LAYER_TAB_HANDLE_LAYER_H_ |
| 6 #define CHROME_BROWSER_ANDROID_COMPOSITOR_LAYER_TAB_HANDLE_LAYER_H_ | 6 #define CHROME_BROWSER_ANDROID_COMPOSITOR_LAYER_TAB_HANDLE_LAYER_H_ |
| 7 | 7 |
| 8 #include <memory> | 8 #include <memory> |
| 9 | 9 |
| 10 #include "base/macros.h" | 10 #include "base/macros.h" |
| 11 #include "cc/layers/nine_patch_layer.h" | 11 #include "cc/layers/nine_patch_layer.h" |
| 12 #include "cc/layers/solid_color_layer.h" | 12 #include "cc/layers/solid_color_layer.h" |
| 13 #include "cc/layers/ui_resource_layer.h" | 13 #include "cc/layers/ui_resource_layer.h" |
| 14 #include "chrome/browser/android/compositor/layer/layer.h" | 14 #include "chrome/browser/android/compositor/layer/layer.h" |
| 15 #include "ui/android/resources/resource_manager.h" | 15 #include "ui/android/resources/resource_manager.h" |
| 16 | 16 |
| 17 namespace cc { | 17 namespace cc { |
| 18 class Layer; | 18 class Layer; |
| 19 class NinePatchLayer; | 19 class NinePatchLayer; |
| 20 } | 20 } |
| 21 | 21 |
| 22 namespace ui { | 22 namespace ui { |
| 23 class ResourceManager; | 23 class NinePatchResource; |
| 24 } | 24 } |
| 25 | 25 |
| 26 namespace android { | 26 namespace android { |
| 27 | 27 |
| 28 class LayerTitleCache; | 28 class LayerTitleCache; |
| 29 | 29 |
| 30 class TabHandleLayer : public Layer { | 30 class TabHandleLayer : public Layer { |
| 31 public: | 31 public: |
| 32 static scoped_refptr<TabHandleLayer> Create( | 32 static scoped_refptr<TabHandleLayer> Create( |
| 33 LayerTitleCache* layer_title_cache); | 33 LayerTitleCache* layer_title_cache); |
| 34 | 34 |
| 35 void SetProperties(int id, | 35 void SetProperties(int id, |
| 36 ui::ResourceManager::Resource* close_button_resource, | 36 ui::Resource* close_button_resource, |
| 37 ui::ResourceManager::Resource* tab_handle_resource, | 37 ui::NinePatchResource* tab_handle_resource, |
| 38 bool foreground, | 38 bool foreground, |
| 39 bool close_pressed, | 39 bool close_pressed, |
| 40 float toolbar_width, | 40 float toolbar_width, |
| 41 float x, | 41 float x, |
| 42 float y, | 42 float y, |
| 43 float width, | 43 float width, |
| 44 float height, | 44 float height, |
| 45 float content_offset_x, | 45 float content_offset_x, |
| 46 float close_button_alpha, | 46 float close_button_alpha, |
| 47 bool is_loading, | 47 bool is_loading, |
| (...skipping 17 matching lines...) Expand all Loading... |
| 65 | 65 |
| 66 float brightness_; | 66 float brightness_; |
| 67 bool foreground_; | 67 bool foreground_; |
| 68 | 68 |
| 69 DISALLOW_COPY_AND_ASSIGN(TabHandleLayer); | 69 DISALLOW_COPY_AND_ASSIGN(TabHandleLayer); |
| 70 }; | 70 }; |
| 71 | 71 |
| 72 } // namespace android | 72 } // namespace android |
| 73 | 73 |
| 74 #endif // CHROME_BROWSER_ANDROID_COMPOSITOR_LAYER_TAB_HANDLE_LAYER_H_ | 74 #endif // CHROME_BROWSER_ANDROID_COMPOSITOR_LAYER_TAB_HANDLE_LAYER_H_ |
| OLD | NEW |