| 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_COMMON_SYSTEM_TRAY_TRAY_POPUP_UTILS_H_ | 5 #ifndef ASH_COMMON_SYSTEM_TRAY_TRAY_POPUP_UTILS_H_ |
| 6 #define ASH_COMMON_SYSTEM_TRAY_TRAY_POPUP_UTILS_H_ | 6 #define ASH_COMMON_SYSTEM_TRAY_TRAY_POPUP_UTILS_H_ |
| 7 | 7 |
| 8 #include "ash/common/login_status.h" | 8 #include "ash/common/login_status.h" |
| 9 #include "ash/common/system/tray/tray_popup_ink_drop_style.h" | 9 #include "ash/common/system/tray/tray_popup_ink_drop_style.h" |
| 10 #include "ash/common/system/tray/tri_view.h" | 10 #include "ash/common/system/tray/tri_view.h" |
| (...skipping 144 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 155 static std::unique_ptr<views::InkDropMask> CreateInkDropMask( | 155 static std::unique_ptr<views::InkDropMask> CreateInkDropMask( |
| 156 TrayPopupInkDropStyle ink_drop_style, | 156 TrayPopupInkDropStyle ink_drop_style, |
| 157 const views::View* host); | 157 const views::View* host); |
| 158 | 158 |
| 159 // Returns true if it is possible to open WebUI settings in a browser window, | 159 // Returns true if it is possible to open WebUI settings in a browser window, |
| 160 // i.e., the user is logged in, not on the lock screen, and not in a secondary | 160 // i.e., the user is logged in, not on the lock screen, and not in a secondary |
| 161 // account flow. | 161 // account flow. |
| 162 static bool CanOpenWebUISettings(LoginStatus status); | 162 static bool CanOpenWebUISettings(LoginStatus status); |
| 163 | 163 |
| 164 private: | 164 private: |
| 165 // Returns the effective ink drop insets for |host| according to the |
| 166 // |ink_drop_style|. |
| 167 static gfx::Insets GetInkDropInsets(TrayPopupInkDropStyle ink_drop_style); |
| 168 |
| 165 // Returns the effective ink drop bounds for |host| according to the | 169 // Returns the effective ink drop bounds for |host| according to the |
| 166 // |ink_drop_style|. | 170 // |ink_drop_style|. |
| 167 static gfx::Rect GetInkDropBounds(TrayPopupInkDropStyle ink_drop_style, | 171 static gfx::Rect GetInkDropBounds(TrayPopupInkDropStyle ink_drop_style, |
| 168 const views::View* host); | 172 const views::View* host); |
| 169 | 173 |
| 170 DISALLOW_IMPLICIT_CONSTRUCTORS(TrayPopupUtils); | 174 DISALLOW_IMPLICIT_CONSTRUCTORS(TrayPopupUtils); |
| 171 }; | 175 }; |
| 172 | 176 |
| 173 } // namespace ash | 177 } // namespace ash |
| 174 | 178 |
| 175 #endif // ASH_COMMON_SYSTEM_TRAY_TRAY_POPUP_UTILS_H_ | 179 #endif // ASH_COMMON_SYSTEM_TRAY_TRAY_POPUP_UTILS_H_ |
| OLD | NEW |