| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 UI_MESSAGE_CENTER_VIEWS_DESKTOP_POPUP_ALIGNMENT_DELEGATE_H_ | 5 #ifndef UI_MESSAGE_CENTER_VIEWS_DESKTOP_POPUP_ALIGNMENT_DELEGATE_H_ |
| 6 #define UI_MESSAGE_CENTER_VIEWS_DESKTOP_POPUP_ALIGNMENT_DELEGATE_H_ | 6 #define UI_MESSAGE_CENTER_VIEWS_DESKTOP_POPUP_ALIGNMENT_DELEGATE_H_ |
| 7 | 7 |
| 8 #include <stdint.h> | 8 #include <stdint.h> |
| 9 | 9 |
| 10 #include "base/macros.h" | 10 #include "base/macros.h" |
| (...skipping 23 matching lines...) Expand all Loading... |
| 34 // Overridden from PopupAlignmentDelegate: | 34 // Overridden from PopupAlignmentDelegate: |
| 35 int GetToastOriginX(const gfx::Rect& toast_bounds) const override; | 35 int GetToastOriginX(const gfx::Rect& toast_bounds) const override; |
| 36 int GetBaseLine() const override; | 36 int GetBaseLine() const override; |
| 37 gfx::Rect GetWorkArea() const override; | 37 gfx::Rect GetWorkArea() const override; |
| 38 bool IsTopDown() const override; | 38 bool IsTopDown() const override; |
| 39 bool IsFromLeft() const override; | 39 bool IsFromLeft() const override; |
| 40 void RecomputeAlignment(const display::Display& display) override; | 40 void RecomputeAlignment(const display::Display& display) override; |
| 41 void ConfigureWidgetInitParamsForContainer( | 41 void ConfigureWidgetInitParamsForContainer( |
| 42 views::Widget* widget, | 42 views::Widget* widget, |
| 43 views::Widget::InitParams* init_params) override; | 43 views::Widget::InitParams* init_params) override; |
| 44 bool IsPrimaryDisplayForNotification() const override; |
| 44 | 45 |
| 45 private: | 46 private: |
| 46 friend class test::MessagePopupCollectionTest; | 47 friend class test::MessagePopupCollectionTest; |
| 47 | 48 |
| 48 enum PopupAlignment { | 49 enum PopupAlignment { |
| 49 POPUP_ALIGNMENT_TOP = 1 << 0, | 50 POPUP_ALIGNMENT_TOP = 1 << 0, |
| 50 POPUP_ALIGNMENT_LEFT = 1 << 1, | 51 POPUP_ALIGNMENT_LEFT = 1 << 1, |
| 51 POPUP_ALIGNMENT_BOTTOM = 1 << 2, | 52 POPUP_ALIGNMENT_BOTTOM = 1 << 2, |
| 52 POPUP_ALIGNMENT_RIGHT = 1 << 3, | 53 POPUP_ALIGNMENT_RIGHT = 1 << 3, |
| 53 }; | 54 }; |
| (...skipping 10 matching lines...) Expand all Loading... |
| 64 int64_t primary_display_id_; | 65 int64_t primary_display_id_; |
| 65 display::Screen* screen_; | 66 display::Screen* screen_; |
| 66 gfx::Rect work_area_; | 67 gfx::Rect work_area_; |
| 67 | 68 |
| 68 DISALLOW_COPY_AND_ASSIGN(DesktopPopupAlignmentDelegate); | 69 DISALLOW_COPY_AND_ASSIGN(DesktopPopupAlignmentDelegate); |
| 69 }; | 70 }; |
| 70 | 71 |
| 71 } // namespace message_center | 72 } // namespace message_center |
| 72 | 73 |
| 73 #endif // UI_MESSAGE_CENTER_VIEWS_DESKTOP_POPUP_ALIGNMENT_DELEGATE_H_ | 74 #endif // UI_MESSAGE_CENTER_VIEWS_DESKTOP_POPUP_ALIGNMENT_DELEGATE_H_ |
| OLD | NEW |