Index: chrome/browser/ui/views/exclusive_access_bubble_views.cc |
diff --git a/chrome/browser/ui/views/exclusive_access_bubble_views.cc b/chrome/browser/ui/views/exclusive_access_bubble_views.cc |
index 502849025c2369703cbfad0126685971602f632d..160ae8c6a0c6e38d3938d82865879c52148da229 100644 |
--- a/chrome/browser/ui/views/exclusive_access_bubble_views.cc |
+++ b/chrome/browser/ui/views/exclusive_access_bubble_views.cc |
@@ -399,8 +399,7 @@ ExclusiveAccessBubbleViews::ExclusiveAccessBubbleViews( |
// Create the contents view. |
ui::Accelerator accelerator(ui::VKEY_UNKNOWN, ui::EF_NONE); |
bool got_accelerator = |
- bubble_view_context_->GetBubbleAssociatedWidget()->GetAccelerator( |
- IDC_FULLSCREEN, &accelerator); |
+ bubble_view_context_->GetAccelerator2(IDC_FULLSCREEN, &accelerator); |
DCHECK(got_accelerator); |
view_ = new ExclusiveAccessView(this, accelerator.GetShortcutText(), url, |
bubble_type_); |
@@ -413,8 +412,7 @@ ExclusiveAccessBubbleViews::ExclusiveAccessBubbleViews( |
views::Widget::InitParams params(views::Widget::InitParams::TYPE_POPUP); |
params.opacity = views::Widget::InitParams::TRANSLUCENT_WINDOW; |
params.ownership = views::Widget::InitParams::WIDGET_OWNS_NATIVE_WIDGET; |
- params.parent = |
- bubble_view_context_->GetBubbleAssociatedWidget()->GetNativeView(); |
+ params.parent = bubble_view_context_->GetNativeView(); |
// The simplified UI just shows a notice; clicks should go through to the |
// underlying window. |
params.accept_events = |
@@ -543,10 +541,6 @@ void ExclusiveAccessBubbleViews::UpdateBounds() { |
} |
} |
-views::View* ExclusiveAccessBubbleViews::GetBrowserRootView() const { |
- return bubble_view_context_->GetBubbleAssociatedWidget()->GetRootView(); |
-} |
- |
void ExclusiveAccessBubbleViews::AnimationProgressed( |
const gfx::Animation* animation) { |
if (animated_attribute_ == ANIMATED_ATTRIBUTE_OPACITY) { |
@@ -575,8 +569,7 @@ void ExclusiveAccessBubbleViews::AnimationEnded( |
gfx::Rect ExclusiveAccessBubbleViews::GetPopupRect( |
bool ignore_animation_state) const { |
gfx::Size size(view_->GetPreferredSize()); |
- gfx::Rect widget_bounds = bubble_view_context_->GetBubbleAssociatedWidget() |
- ->GetClientAreaBoundsInScreen(); |
+ gfx::Rect widget_bounds = bubble_view_context_->GetClientAreaBoundsInScreen(); |
int x = widget_bounds.x() + (widget_bounds.width() - size.width()) / 2; |
int top_container_bottom = widget_bounds.y(); |
@@ -612,20 +605,15 @@ gfx::Rect ExclusiveAccessBubbleViews::GetPopupRect( |
} |
gfx::Point ExclusiveAccessBubbleViews::GetCursorScreenPoint() { |
- gfx::Point cursor_pos = |
- gfx::Screen::GetScreenFor( |
- bubble_view_context_->GetBubbleAssociatedWidget()->GetNativeView()) |
- ->GetCursorScreenPoint(); |
- views::View::ConvertPointFromScreen(GetBrowserRootView(), &cursor_pos); |
- return cursor_pos; |
+ return bubble_view_context_->GetCursorScreenPoint(); |
} |
bool ExclusiveAccessBubbleViews::WindowContainsPoint(gfx::Point pos) { |
- return GetBrowserRootView()->HitTestPoint(pos); |
+ return bubble_view_context_->HitTestPoint(pos); |
} |
bool ExclusiveAccessBubbleViews::IsWindowActive() { |
- return bubble_view_context_->GetBubbleAssociatedWidget()->IsActive(); |
+ return bubble_view_context_->IsParentActive(); |
} |
void ExclusiveAccessBubbleViews::Hide() { |