| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 #include "ui/app_list/views/app_list_view.h" | 5 #include "ui/app_list/views/app_list_view.h" |
| 6 | 6 |
| 7 #include "base/string_util.h" | 7 #include "base/string_util.h" |
| 8 #include "ui/app_list/app_list_constants.h" | 8 #include "ui/app_list/app_list_constants.h" |
| 9 #include "ui/app_list/app_list_model.h" | 9 #include "ui/app_list/app_list_model.h" |
| 10 #include "ui/app_list/app_list_view_delegate.h" | 10 #include "ui/app_list/app_list_view_delegate.h" |
| (...skipping 89 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 100 #if defined(USE_AURA) | 100 #if defined(USE_AURA) |
| 101 GetWidget()->GetNativeWindow()->layer()->SetMasksToBounds(true); | 101 GetWidget()->GetNativeWindow()->layer()->SetMasksToBounds(true); |
| 102 GetBubbleFrameView()->set_background(new AppListBackground( | 102 GetBubbleFrameView()->set_background(new AppListBackground( |
| 103 GetBubbleFrameView()->bubble_border()->GetBorderCornerRadius(), | 103 GetBubbleFrameView()->bubble_border()->GetBorderCornerRadius(), |
| 104 app_list_main_view_->search_box_view())); | 104 app_list_main_view_->search_box_view())); |
| 105 set_background(NULL); | 105 set_background(NULL); |
| 106 #else | 106 #else |
| 107 set_background(new AppListBackground( | 107 set_background(new AppListBackground( |
| 108 GetBubbleFrameView()->bubble_border()->GetBorderCornerRadius(), | 108 GetBubbleFrameView()->bubble_border()->GetBorderCornerRadius(), |
| 109 app_list_main_view_->search_box_view())); | 109 app_list_main_view_->search_box_view())); |
| 110 |
| 111 // On non-aura the bubble has two widgets, and it's possible for the border |
| 112 // to be shown independently in odd situations. Explicitly hide the bubble |
| 113 // widget to ensure that any WM_WINDOWPOSCHANGED messages triggered by the |
| 114 // window manager do not have the SWP_SHOWWINDOW flag set which would cause |
| 115 // the border to be shown. See http://crbug.com/231687 . |
| 116 GetWidget()->Hide(); |
| 110 #endif | 117 #endif |
| 111 } | 118 } |
| 112 | 119 |
| 113 void AppListView::SetBubbleArrow(views::BubbleBorder::Arrow arrow) { | 120 void AppListView::SetBubbleArrow(views::BubbleBorder::Arrow arrow) { |
| 114 GetBubbleFrameView()->bubble_border()->set_arrow(arrow); | 121 GetBubbleFrameView()->bubble_border()->set_arrow(arrow); |
| 115 SizeToContents(); // Recalcuates with new border. | 122 SizeToContents(); // Recalcuates with new border. |
| 116 GetBubbleFrameView()->SchedulePaint(); | 123 GetBubbleFrameView()->SchedulePaint(); |
| 117 } | 124 } |
| 118 | 125 |
| 119 void AppListView::SetAnchorPoint(const gfx::Point& anchor_point) { | 126 void AppListView::SetAnchorPoint(const gfx::Point& anchor_point) { |
| (...skipping 103 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 223 | 230 |
| 224 void AppListView::OnSigninSuccess() { | 231 void AppListView::OnSigninSuccess() { |
| 225 OnSigninStatusChanged(); | 232 OnSigninStatusChanged(); |
| 226 } | 233 } |
| 227 | 234 |
| 228 SigninDelegate* AppListView::GetSigninDelegate() { | 235 SigninDelegate* AppListView::GetSigninDelegate() { |
| 229 return delegate_ ? delegate_->GetSigninDelegate() : NULL; | 236 return delegate_ ? delegate_->GetSigninDelegate() : NULL; |
| 230 } | 237 } |
| 231 | 238 |
| 232 } // namespace app_list | 239 } // namespace app_list |
| OLD | NEW |