| OLD | NEW |
| 1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 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 ASH_FRAME_HEADER_VIEW_H_ | 5 #ifndef ASH_FRAME_HEADER_VIEW_H_ |
| 6 #define ASH_FRAME_HEADER_VIEW_H_ | 6 #define ASH_FRAME_HEADER_VIEW_H_ |
| 7 | 7 |
| 8 #include <memory> | 8 #include <memory> |
| 9 | 9 |
| 10 #include "ash/ash_export.h" | 10 #include "ash/ash_export.h" |
| 11 #include "ash/public/interfaces/window_style.mojom.h" | 11 #include "ash/public/interfaces/window_style.mojom.h" |
| 12 #include "ash/shared/immersive_fullscreen_controller_delegate.h" | 12 #include "ash/shared/immersive_fullscreen_controller_delegate.h" |
| 13 #include "ash/shell_observer.h" | 13 #include "ash/shell_observer.h" |
| 14 #include "base/macros.h" | 14 #include "base/macros.h" |
| 15 #include "third_party/skia/include/core/SkColor.h" | 15 #include "third_party/skia/include/core/SkColor.h" |
| 16 #include "ui/views/view.h" | 16 #include "ui/views/view.h" |
| 17 | 17 |
| 18 namespace gfx { |
| 19 class ImageSkia; |
| 20 } |
| 21 |
| 18 namespace views { | 22 namespace views { |
| 19 class ImageView; | 23 class ImageView; |
| 20 class Widget; | 24 class Widget; |
| 21 } | 25 } |
| 22 | 26 |
| 23 namespace ash { | 27 namespace ash { |
| 24 | 28 |
| 25 class DefaultHeaderPainter; | 29 class DefaultHeaderPainter; |
| 26 class FrameCaptionButtonContainerView; | 30 class FrameCaptionButtonContainerView; |
| 27 | 31 |
| (...skipping 23 matching lines...) Expand all Loading... |
| 51 | 55 |
| 52 // Returns the amount of the view's pixels which should be on screen. | 56 // Returns the amount of the view's pixels which should be on screen. |
| 53 int GetPreferredOnScreenHeight(); | 57 int GetPreferredOnScreenHeight(); |
| 54 | 58 |
| 55 // Returns the view's preferred height. | 59 // Returns the view's preferred height. |
| 56 int GetPreferredHeight(); | 60 int GetPreferredHeight(); |
| 57 | 61 |
| 58 // Returns the view's minimum width. | 62 // Returns the view's minimum width. |
| 59 int GetMinimumWidth() const; | 63 int GetMinimumWidth() const; |
| 60 | 64 |
| 61 void UpdateAvatarIcon(); | 65 // Sets the avatar icon to be displayed on the frame header. |
| 66 void SetAvatarIcon(const gfx::ImageSkia& avatar); |
| 62 | 67 |
| 63 void SizeConstraintsChanged(); | 68 void SizeConstraintsChanged(); |
| 64 | 69 |
| 65 void SetFrameColors(SkColor active_frame_color, SkColor inactive_frame_color); | 70 void SetFrameColors(SkColor active_frame_color, SkColor inactive_frame_color); |
| 66 SkColor GetActiveFrameColor() const; | 71 SkColor GetActiveFrameColor() const; |
| 67 SkColor GetInactiveFrameColor() const; | 72 SkColor GetInactiveFrameColor() const; |
| 68 | 73 |
| 69 // views::View: | 74 // views::View: |
| 70 void Layout() override; | 75 void Layout() override; |
| 71 void OnPaint(gfx::Canvas* canvas) override; | 76 void OnPaint(gfx::Canvas* canvas) override; |
| (...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 110 bool is_immersive_delegate_ = true; | 115 bool is_immersive_delegate_ = true; |
| 111 | 116 |
| 112 bool did_layout_ = false; | 117 bool did_layout_ = false; |
| 113 | 118 |
| 114 DISALLOW_COPY_AND_ASSIGN(HeaderView); | 119 DISALLOW_COPY_AND_ASSIGN(HeaderView); |
| 115 }; | 120 }; |
| 116 | 121 |
| 117 } // namespace ash | 122 } // namespace ash |
| 118 | 123 |
| 119 #endif // ASH_FRAME_HEADER_VIEW_H_ | 124 #endif // ASH_FRAME_HEADER_VIEW_H_ |
| OLD | NEW |