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

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

Issue 3037006: Let PaintAtAck send an int tag instead of the TransportDIB handle. (Closed)
Patch Set: '' Created 10 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
OLDNEW
1 // Copyright (c) 2009 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2009 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 62 matching lines...) Expand 10 before | Expand all | Expand 10 after
73 #endif 73 #endif
74 74
75 private: 75 private:
76 // RenderWidgetHostPaintingObserver implementation. 76 // RenderWidgetHostPaintingObserver implementation.
77 virtual void WidgetWillDestroyBackingStore(RenderWidgetHost* widget, 77 virtual void WidgetWillDestroyBackingStore(RenderWidgetHost* widget,
78 BackingStore* backing_store); 78 BackingStore* backing_store);
79 virtual void WidgetDidUpdateBackingStore(RenderWidgetHost* widget); 79 virtual void WidgetDidUpdateBackingStore(RenderWidgetHost* widget);
80 80
81 virtual void WidgetDidReceivePaintAtSizeAck( 81 virtual void WidgetDidReceivePaintAtSizeAck(
82 RenderWidgetHost* widget, 82 RenderWidgetHost* widget,
83 const TransportDIB::Handle& dib_handle, 83 int tag,
84 const gfx::Size& size); 84 const gfx::Size& size);
85 85
86 // NotificationObserver interface. 86 // NotificationObserver interface.
87 virtual void Observe(NotificationType type, 87 virtual void Observe(NotificationType type,
88 const NotificationSource& source, 88 const NotificationSource& source,
89 const NotificationDetails& details); 89 const NotificationDetails& details);
90 90
91 // Indicates that the given widget has changed is visibility. 91 // Indicates that the given widget has changed is visibility.
92 void WidgetShown(RenderWidgetHost* widget); 92 void WidgetShown(RenderWidgetHost* widget);
93 void WidgetHidden(RenderWidgetHost* widget); 93 void WidgetHidden(RenderWidgetHost* widget);
(...skipping 17 matching lines...) Expand all
111 base::OneShotTimer<ThumbnailGenerator> timer_; 111 base::OneShotTimer<ThumbnailGenerator> timer_;
112 112
113 // A list of all RWHs that have been shown and need to have their thumbnail 113 // A list of all RWHs that have been shown and need to have their thumbnail
114 // expired at some time in the future with the "slop" time has elapsed. This 114 // expired at some time in the future with the "slop" time has elapsed. This
115 // list will normally have 0 or 1 items in it. 115 // list will normally have 0 or 1 items in it.
116 std::vector<RenderWidgetHost*> shown_hosts_; 116 std::vector<RenderWidgetHost*> shown_hosts_;
117 117
118 // See the setter above. 118 // See the setter above.
119 bool no_timeout_; 119 bool no_timeout_;
120 120
121 // Map of callback objects by TransportDIB::Handle. 121 // Map of callback objects by sequence number.
122 struct AsyncRequestInfo; 122 struct AsyncRequestInfo;
123 typedef std::map<TransportDIB::Handle, 123 typedef std::map<int,
124 linked_ptr<AsyncRequestInfo> > ThumbnailCallbackMap; 124 linked_ptr<AsyncRequestInfo> > ThumbnailCallbackMap;
125 ThumbnailCallbackMap callback_map_; 125 ThumbnailCallbackMap callback_map_;
126 126
127 DISALLOW_COPY_AND_ASSIGN(ThumbnailGenerator); 127 DISALLOW_COPY_AND_ASSIGN(ThumbnailGenerator);
128 }; 128 };
129 129
130 #endif // CHROME_BROWSER_TAB_CONTENTS_THUMBNAIL_GENERATOR_H_ 130 #endif // CHROME_BROWSER_TAB_CONTENTS_THUMBNAIL_GENERATOR_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698