Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(164)

Side by Side Diff: content/public/browser/render_widget_host_view.h

Issue 1952003002: Mac: Plumb AcceleratedWidgetMac through RWHVMac (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Move out of base Created 4 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
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 #ifndef CONTENT_PUBLIC_BROWSER_RENDER_WIDGET_HOST_VIEW_H_ 5 #ifndef CONTENT_PUBLIC_BROWSER_RENDER_WIDGET_HOST_VIEW_H_
6 #define CONTENT_PUBLIC_BROWSER_RENDER_WIDGET_HOST_VIEW_H_ 6 #define CONTENT_PUBLIC_BROWSER_RENDER_WIDGET_HOST_VIEW_H_
7 7
8 #include <memory> 8 #include <memory>
9 9
10 #include "base/strings/string16.h" 10 #include "base/strings/string16.h"
11 #include "build/build_config.h" 11 #include "build/build_config.h"
12 #include "content/common/content_export.h" 12 #include "content/common/content_export.h"
13 #include "third_party/WebKit/public/web/WebInputEvent.h" 13 #include "third_party/WebKit/public/web/WebInputEvent.h"
14 #include "third_party/skia/include/core/SkBitmap.h" 14 #include "third_party/skia/include/core/SkBitmap.h"
15 #include "third_party/skia/include/core/SkColor.h" 15 #include "third_party/skia/include/core/SkColor.h"
16 #include "third_party/skia/include/core/SkRegion.h" 16 #include "third_party/skia/include/core/SkRegion.h"
17 #include "ui/gfx/native_widget_types.h" 17 #include "ui/gfx/native_widget_types.h"
18 18
19 class GURL; 19 class GURL;
20 20
21 namespace gfx { 21 namespace gfx {
22 class Rect; 22 class Rect;
23 class Size; 23 class Size;
24 } 24 }
25 25
26 namespace ui { 26 namespace ui {
27 class TextInputClient; 27 class TextInputClient;
28 class AcceleratedWidgetMac;
28 } 29 }
29 30
30 namespace content { 31 namespace content {
31 32
32 class RenderWidgetHost; 33 class RenderWidgetHost;
33 class RenderWidgetHostViewFrameSubscriber; 34 class RenderWidgetHostViewFrameSubscriber;
34 35
35 // RenderWidgetHostView is an interface implemented by an object that acts as 36 // RenderWidgetHostView is an interface implemented by an object that acts as
36 // the "View" portion of a RenderWidgetHost. The RenderWidgetHost and its 37 // the "View" portion of a RenderWidgetHost. The RenderWidgetHost and its
37 // associated RenderProcessHost own the "Model" in this case which is the 38 // associated RenderProcessHost own the "Model" in this case which is the
(...skipping 115 matching lines...) Expand 10 before | Expand all | Expand 10 after
153 // |subscriber| is now owned by this object, it will be called only on the 154 // |subscriber| is now owned by this object, it will be called only on the
154 // UI thread. 155 // UI thread.
155 virtual void BeginFrameSubscription( 156 virtual void BeginFrameSubscription(
156 std::unique_ptr<RenderWidgetHostViewFrameSubscriber> subscriber) = 0; 157 std::unique_ptr<RenderWidgetHostViewFrameSubscriber> subscriber) = 0;
157 158
158 // End subscribing for frame presentation events. FrameSubscriber will be 159 // End subscribing for frame presentation events. FrameSubscriber will be
159 // deleted after this call. 160 // deleted after this call.
160 virtual void EndFrameSubscription() = 0; 161 virtual void EndFrameSubscription() = 0;
161 162
162 #if defined(OS_MACOSX) 163 #if defined(OS_MACOSX)
164 // Return the accelerated widget which hosts the CALayers that draw the
165 // content of the view in GetNativeView. This may be null.
166 virtual ui::AcceleratedWidgetMac* GetAcceleratedWidgetMac() const = 0;
167
163 // Set the view's active state (i.e., tint state of controls). 168 // Set the view's active state (i.e., tint state of controls).
164 virtual void SetActive(bool active) = 0; 169 virtual void SetActive(bool active) = 0;
165 170
166 // Brings up the dictionary showing a definition for the selected text. 171 // Brings up the dictionary showing a definition for the selected text.
167 virtual void ShowDefinitionForSelection() = 0; 172 virtual void ShowDefinitionForSelection() = 0;
168 173
169 // Returns |true| if Mac OS X text to speech is supported. 174 // Returns |true| if Mac OS X text to speech is supported.
170 virtual bool SupportsSpeech() const = 0; 175 virtual bool SupportsSpeech() const = 0;
171 // Tells the view to speak the currently selected text. 176 // Tells the view to speak the currently selected text.
172 virtual void SpeakSelection() = 0; 177 virtual void SpeakSelection() = 0;
173 // Returns |true| if text is currently being spoken by Mac OS X. 178 // Returns |true| if text is currently being spoken by Mac OS X.
174 virtual bool IsSpeaking() const = 0; 179 virtual bool IsSpeaking() const = 0;
175 // Stops speaking, if it is currently in progress. 180 // Stops speaking, if it is currently in progress.
176 virtual void StopSpeaking() = 0; 181 virtual void StopSpeaking() = 0;
177 #endif // defined(OS_MACOSX) 182 #endif // defined(OS_MACOSX)
178 }; 183 };
179 184
180 } // namespace content 185 } // namespace content
181 186
182 #endif // CONTENT_PUBLIC_BROWSER_RENDER_WIDGET_HOST_VIEW_H_ 187 #endif // CONTENT_PUBLIC_BROWSER_RENDER_WIDGET_HOST_VIEW_H_
OLDNEW
« no previous file with comments | « content/browser/renderer_host/render_widget_host_view_mus.cc ('k') | content/test/test_render_view_host.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698