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

Side by Side Diff: chrome/browser/tab_contents/thumbnail_generator.h

Issue 10805051: Add RenderViewHost* to DidStartLoading and DidStopLoading in (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 8 years, 5 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) 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 CHROME_BROWSER_TAB_CONTENTS_THUMBNAIL_GENERATOR_H_ 5 #ifndef CHROME_BROWSER_TAB_CONTENTS_THUMBNAIL_GENERATOR_H_
6 #define CHROME_BROWSER_TAB_CONTENTS_THUMBNAIL_GENERATOR_H_ 6 #define CHROME_BROWSER_TAB_CONTENTS_THUMBNAIL_GENERATOR_H_
7 7
8 #include <map> 8 #include <map>
9 #include <utility> 9 #include <utility>
10 #include <vector> 10 #include <vector>
(...skipping 103 matching lines...) Expand 10 before | Expand all | Expand 10 after
114 void UpdateThumbnail(content::WebContents* web_contents, 114 void UpdateThumbnail(content::WebContents* web_contents,
115 const SkBitmap& bitmap, 115 const SkBitmap& bitmap,
116 const ThumbnailGenerator::ClipResult& clip_result); 116 const ThumbnailGenerator::ClipResult& clip_result);
117 117
118 // Returns true if we should update the thumbnail of the given URL. 118 // Returns true if we should update the thumbnail of the given URL.
119 static bool ShouldUpdateThumbnail(Profile* profile, 119 static bool ShouldUpdateThumbnail(Profile* profile,
120 history::TopSites* top_sites, 120 history::TopSites* top_sites,
121 const GURL& url); 121 const GURL& url);
122 122
123 // content::WebContentsObserver overrides. 123 // content::WebContentsObserver overrides.
124 virtual void DidStartLoading() OVERRIDE; 124 virtual void DidStartLoading(
125 content::RenderViewHost* render_view_host) OVERRIDE;
125 virtual void StopNavigation() OVERRIDE; 126 virtual void StopNavigation() OVERRIDE;
126 127
127 private: 128 private:
128 virtual void WidgetDidReceivePaintAtSizeAck( 129 virtual void WidgetDidReceivePaintAtSizeAck(
129 content::RenderWidgetHost* widget, 130 content::RenderWidgetHost* widget,
130 int tag, 131 int tag,
131 const gfx::Size& size); 132 const gfx::Size& size);
132 133
133 // Asynchronously updates the thumbnail of the given tab. The caller must 134 // Asynchronously updates the thumbnail of the given tab. The caller must
134 // ensure that |web_contents| outlives ThumbnailGenerator so that the 135 // ensure that |web_contents| outlives ThumbnailGenerator so that the
(...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after
171 ThumbnailCallbackMap callback_map_; 172 ThumbnailCallbackMap callback_map_;
172 173
173 bool load_interrupted_; 174 bool load_interrupted_;
174 175
175 base::WeakPtrFactory<ThumbnailGenerator> weak_factory_; 176 base::WeakPtrFactory<ThumbnailGenerator> weak_factory_;
176 177
177 DISALLOW_COPY_AND_ASSIGN(ThumbnailGenerator); 178 DISALLOW_COPY_AND_ASSIGN(ThumbnailGenerator);
178 }; 179 };
179 180
180 #endif // CHROME_BROWSER_TAB_CONTENTS_THUMBNAIL_GENERATOR_H_ 181 #endif // CHROME_BROWSER_TAB_CONTENTS_THUMBNAIL_GENERATOR_H_
OLDNEW
« no previous file with comments | « chrome/browser/prerender/prerender_tab_helper.cc ('k') | chrome/browser/tab_contents/thumbnail_generator.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698