OLD | NEW |
1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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 "mojo/services/native_viewport/native_viewport.h" | 5 #include "mojo/services/native_viewport/native_viewport.h" |
6 | 6 |
7 #include "base/memory/scoped_ptr.h" | 7 #include "base/memory/scoped_ptr.h" |
8 #include "ui/gfx/rect.h" | 8 #include "ui/gfx/rect.h" |
9 #include "ui/platform_window/platform_window_delegate.h" | 9 #include "ui/platform_window/platform_window_delegate.h" |
10 #include "ui/platform_window/win/win_window.h" | 10 #include "ui/platform_window/win/win_window.h" |
(...skipping 71 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
82 } | 82 } |
83 | 83 |
84 virtual void OnLostCapture() OVERRIDE { | 84 virtual void OnLostCapture() OVERRIDE { |
85 } | 85 } |
86 | 86 |
87 virtual void OnAcceleratedWidgetAvailable( | 87 virtual void OnAcceleratedWidgetAvailable( |
88 gfx::AcceleratedWidget widget) OVERRIDE { | 88 gfx::AcceleratedWidget widget) OVERRIDE { |
89 delegate_->OnAcceleratedWidgetAvailable(widget); | 89 delegate_->OnAcceleratedWidgetAvailable(widget); |
90 } | 90 } |
91 | 91 |
92 virtual void OnActivationChanged(bool active) OVERRIDE {} | |
93 | |
94 scoped_ptr<ui::PlatformWindow> platform_window_; | 92 scoped_ptr<ui::PlatformWindow> platform_window_; |
95 NativeViewportDelegate* delegate_; | 93 NativeViewportDelegate* delegate_; |
96 | 94 |
97 DISALLOW_COPY_AND_ASSIGN(NativeViewportWin); | 95 DISALLOW_COPY_AND_ASSIGN(NativeViewportWin); |
98 }; | 96 }; |
99 | 97 |
100 // static | 98 // static |
101 scoped_ptr<NativeViewport> NativeViewport::Create( | 99 scoped_ptr<NativeViewport> NativeViewport::Create( |
102 NativeViewportDelegate* delegate) { | 100 NativeViewportDelegate* delegate) { |
103 return scoped_ptr<NativeViewport>(new NativeViewportWin(delegate)).Pass(); | 101 return scoped_ptr<NativeViewport>(new NativeViewportWin(delegate)).Pass(); |
104 } | 102 } |
105 | 103 |
106 } // namespace services | 104 } // namespace services |
107 } // namespace mojo | 105 } // namespace mojo |
OLD | NEW |