| OLD | NEW |
| 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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 <QuartzCore/QuartzCore.h> | 5 #include <QuartzCore/QuartzCore.h> |
| 6 | 6 |
| 7 #include "chrome/browser/renderer_host/render_widget_host_view_mac.h" | 7 #include "chrome/browser/renderer_host/render_widget_host_view_mac.h" |
| 8 | 8 |
| 9 #include "base/debug/trace_event.h" | 9 #include "base/debug/trace_event.h" |
| 10 #include "base/logging.h" | 10 #include "base/logging.h" |
| (...skipping 826 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 837 // |is_accelerated_compositing_active()| is flipped when the compositor output | 837 // |is_accelerated_compositing_active()| is flipped when the compositor output |
| 838 // should be shown/hidden. | 838 // should be shown/hidden. |
| 839 // Show/hide the view belonging to the compositor here. | 839 // Show/hide the view belonging to the compositor here. |
| 840 plugin_container_manager_.set_gpu_rendering_active(show_gpu_widget); | 840 plugin_container_manager_.set_gpu_rendering_active(show_gpu_widget); |
| 841 | 841 |
| 842 gfx::PluginWindowHandle root_handle = | 842 gfx::PluginWindowHandle root_handle = |
| 843 plugin_container_manager_.root_container_handle(); | 843 plugin_container_manager_.root_container_handle(); |
| 844 if (root_handle != gfx::kNullPluginWindow) { | 844 if (root_handle != gfx::kNullPluginWindow) { |
| 845 AcceleratedPluginView* view = ViewForPluginWindowHandle(root_handle); | 845 AcceleratedPluginView* view = ViewForPluginWindowHandle(root_handle); |
| 846 DCHECK(view); | 846 DCHECK(view); |
| 847 [view setViewForGL]; |
| 847 bool visible = | 848 bool visible = |
| 848 plugin_container_manager_.SurfaceShouldBeVisible(root_handle); | 849 plugin_container_manager_.SurfaceShouldBeVisible(root_handle); |
| 849 [[view window] disableScreenUpdatesUntilFlush]; | 850 [[view window] disableScreenUpdatesUntilFlush]; |
| 850 [view setHidden:!visible]; | 851 [view setHidden:!visible]; |
| 851 } | 852 } |
| 852 } | 853 } |
| 853 | 854 |
| 854 void RenderWidgetHostViewMac::HandleDelayedGpuViewHiding() { | 855 void RenderWidgetHostViewMac::HandleDelayedGpuViewHiding() { |
| 855 if (needs_gpu_visibility_update_after_repaint_) { | 856 if (needs_gpu_visibility_update_after_repaint_) { |
| 856 UpdateRootGpuViewVisibility(false); | 857 UpdateRootGpuViewVisibility(false); |
| (...skipping 1724 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2581 if (!string) return NO; | 2582 if (!string) return NO; |
| 2582 | 2583 |
| 2583 // If the user is currently using an IME, confirm the IME input, | 2584 // If the user is currently using an IME, confirm the IME input, |
| 2584 // and then insert the text from the service, the same as TextEdit and Safari. | 2585 // and then insert the text from the service, the same as TextEdit and Safari. |
| 2585 [self confirmComposition]; | 2586 [self confirmComposition]; |
| 2586 [self insertText:string]; | 2587 [self insertText:string]; |
| 2587 return YES; | 2588 return YES; |
| 2588 } | 2589 } |
| 2589 | 2590 |
| 2590 @end | 2591 @end |
| OLD | NEW |