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 "content/browser/renderer_host/render_widget_host_view_win.h" | 5 #include "content/browser/renderer_host/render_widget_host_view_win.h" |
6 | 6 |
7 #include <algorithm> | 7 #include <algorithm> |
8 #include <map> | 8 #include <map> |
9 #include <peninputpanel_i.c> | 9 #include <peninputpanel_i.c> |
10 #include <stack> | 10 #include <stack> |
(...skipping 529 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
540 | 540 |
541 void RenderWidgetHostViewWin::InitAsPopup( | 541 void RenderWidgetHostViewWin::InitAsPopup( |
542 RenderWidgetHostView* parent_host_view, const gfx::Rect& pos) { | 542 RenderWidgetHostView* parent_host_view, const gfx::Rect& pos) { |
543 close_on_deactivate_ = true; | 543 close_on_deactivate_ = true; |
544 DoPopupOrFullscreenInit(parent_host_view->GetNativeView(), pos, | 544 DoPopupOrFullscreenInit(parent_host_view->GetNativeView(), pos, |
545 WS_EX_TOOLWINDOW); | 545 WS_EX_TOOLWINDOW); |
546 } | 546 } |
547 | 547 |
548 void RenderWidgetHostViewWin::InitAsFullscreen( | 548 void RenderWidgetHostViewWin::InitAsFullscreen( |
549 RenderWidgetHostView* reference_host_view) { | 549 RenderWidgetHostView* reference_host_view) { |
550 gfx::Rect pos = gfx::Screen::GetDisplayNearestWindow( | 550 gfx::Rect pos = gfx::Screen::GetNativeScreen()->GetDisplayNearestWindow( |
551 reference_host_view->GetNativeView()).bounds(); | 551 reference_host_view->GetNativeView()).bounds(); |
552 is_fullscreen_ = true; | 552 is_fullscreen_ = true; |
553 DoPopupOrFullscreenInit(ui::GetWindowToParentTo(true), pos, 0); | 553 DoPopupOrFullscreenInit(ui::GetWindowToParentTo(true), pos, 0); |
554 } | 554 } |
555 | 555 |
556 RenderWidgetHost* RenderWidgetHostViewWin::GetRenderWidgetHost() const { | 556 RenderWidgetHost* RenderWidgetHostViewWin::GetRenderWidgetHost() const { |
557 return render_widget_host_; | 557 return render_widget_host_; |
558 } | 558 } |
559 | 559 |
560 void RenderWidgetHostViewWin::WasShown() { | 560 void RenderWidgetHostViewWin::WasShown() { |
(...skipping 2569 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
3130 // receive a focus change in the context of a pointer down message, it means | 3130 // receive a focus change in the context of a pointer down message, it means |
3131 // that the pointer down message occurred on the edit field and we should | 3131 // that the pointer down message occurred on the edit field and we should |
3132 // display the on screen keyboard | 3132 // display the on screen keyboard |
3133 if (!received_focus_change_after_pointer_down_ && virtual_keyboard_) | 3133 if (!received_focus_change_after_pointer_down_ && virtual_keyboard_) |
3134 DisplayOnScreenKeyboardIfNeeded(); | 3134 DisplayOnScreenKeyboardIfNeeded(); |
3135 received_focus_change_after_pointer_down_ = false; | 3135 received_focus_change_after_pointer_down_ = false; |
3136 pointer_down_context_ = false; | 3136 pointer_down_context_ = false; |
3137 } | 3137 } |
3138 | 3138 |
3139 } // namespace content | 3139 } // namespace content |
OLD | NEW |