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

Side by Side Diff: chrome/browser/renderer_host/render_widget_host_view.h

Issue 66013: Fix problems correctly invalidating/repainting when our updated paint rect fo... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 11 years, 8 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 | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2006-2008 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2006-2008 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 CHROME_BROWSER_RENDERER_HOST_RENDER_WIDGET_HOST_VIEW_H_ 5 #ifndef CHROME_BROWSER_RENDERER_HOST_RENDER_WIDGET_HOST_VIEW_H_
6 #define CHROME_BROWSER_RENDERER_HOST_RENDER_WIDGET_HOST_VIEW_H_ 6 #define CHROME_BROWSER_RENDERER_HOST_RENDER_WIDGET_HOST_VIEW_H_
7 7
8 #include "base/gfx/native_widget_types.h" 8 #include "base/gfx/native_widget_types.h"
9 #include "base/shared_memory.h" 9 #include "base/shared_memory.h"
10 #include "webkit/glue/webplugin.h" 10 #include "webkit/glue/webplugin.h"
(...skipping 73 matching lines...) Expand 10 before | Expand all | Expand 10 after
84 // Sets the cursor to the one associated with the specified cursor_type 84 // Sets the cursor to the one associated with the specified cursor_type
85 virtual void UpdateCursor(const WebCursor& cursor) = 0; 85 virtual void UpdateCursor(const WebCursor& cursor) = 0;
86 86
87 // Indicates whether the page has finished loading. 87 // Indicates whether the page has finished loading.
88 virtual void SetIsLoading(bool is_loading) = 0; 88 virtual void SetIsLoading(bool is_loading) = 0;
89 89
90 // Enable or disable IME for the view. 90 // Enable or disable IME for the view.
91 virtual void IMEUpdateStatus(int control, const gfx::Rect& caret_rect) = 0; 91 virtual void IMEUpdateStatus(int control, const gfx::Rect& caret_rect) = 0;
92 92
93 // Informs the view that a portion of the widget's backing store was painted. 93 // Informs the view that a portion of the widget's backing store was painted.
94 // The view should copy the given rect from the backing store of the render 94 // The view should ensure this gets copied to the screen.
95 // widget onto the screen. 95 //
96 // There are subtle performance implications here. The RenderWidget gets sent
97 // a paint ack after this returns, so if the view only ever invalidates in
98 // response to this, then on Windows, where WM_PAINT has lower priority than
99 // events which can cause renderer resizes/paint rect updates, e.g.
100 // drag-resizing can starve painting; this function thus provides the view its
101 // main chance to ensure it stays painted and not just invalidated. On the
102 // other hand, if this always blindly paints, then if we're already in the
103 // midst of a paint on the callstack, we can double-paint unnecessarily.
104 // (Worse, we might recursively call RenderWidgetHost::GetBackingStore().)
105 // Thus implementers should generally paint as much of |rect| as possible
106 // synchronously with as little overpainting as possible.
96 virtual void DidPaintRect(const gfx::Rect& rect) = 0; 107 virtual void DidPaintRect(const gfx::Rect& rect) = 0;
97 108
98 // Informs the view that a portion of the widget's backing store was scrolled 109 // Informs the view that a portion of the widget's backing store was scrolled
99 // by dx pixels horizontally and dy pixels vertically. The view should copy 110 // by dx pixels horizontally and dy pixels vertically. The view should copy
100 // the exposed pixels from the backing store of the render widget (which has 111 // the exposed pixels from the backing store of the render widget (which has
101 // already been scrolled) onto the screen. 112 // already been scrolled) onto the screen.
102 virtual void DidScrollRect( 113 virtual void DidScrollRect(
103 const gfx::Rect& rect, int dx, int dy) = 0; 114 const gfx::Rect& rect, int dx, int dy) = 0;
104 115
105 // Notifies the View that the renderer has ceased to exist. 116 // Notifies the View that the renderer has ceased to exist.
(...skipping 27 matching lines...) Expand all
133 144
134 // Whether the window can be activated. Autocomplete popup windows for example 145 // Whether the window can be activated. Autocomplete popup windows for example
135 // cannot be activated. Default is true. 146 // cannot be activated. Default is true.
136 bool activatable_; 147 bool activatable_;
137 148
138 private: 149 private:
139 DISALLOW_COPY_AND_ASSIGN(RenderWidgetHostView); 150 DISALLOW_COPY_AND_ASSIGN(RenderWidgetHostView);
140 }; 151 };
141 152
142 #endif // CHROME_BROWSER_RENDERER_HOST_RENDER_WIDGET_HOST_VIEW_H_ 153 #endif // CHROME_BROWSER_RENDERER_HOST_RENDER_WIDGET_HOST_VIEW_H_
OLDNEW
« no previous file with comments | « chrome/browser/renderer_host/render_widget_host.cc ('k') | chrome/browser/renderer_host/render_widget_host_view_gtk.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698