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

Side by Side Diff: content/browser/frame_host/web_contents_screenshot_manager.h

Issue 49823002: Move navigation and frame tree classes to a new frame_host/ directory. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fixing gyp and adding TODO. Created 7 years, 1 month 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) 2013 The Chromium Authors. All rights reserved. 1 // Copyright (c) 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 #ifndef CONTENT_BROWSER_WEB_CONTENTS_WEB_CONTENTS_SCREENSHOT_MANAGER_H_ 5 #ifndef CONTENT_BROWSER_FRAME_HOST_WEB_CONTENTS_SCREENSHOT_MANAGER_H_
6 #define CONTENT_BROWSER_WEB_CONTENTS_WEB_CONTENTS_SCREENSHOT_MANAGER_H_ 6 #define CONTENT_BROWSER_FRAME_HOST_WEB_CONTENTS_SCREENSHOT_MANAGER_H_
7 7
8 #include "base/compiler_specific.h" 8 #include "base/compiler_specific.h"
9 #include "base/memory/weak_ptr.h" 9 #include "base/memory/weak_ptr.h"
10 #include "base/time/time.h" 10 #include "base/time/time.h"
11 #include "content/common/content_export.h" 11 #include "content/common/content_export.h"
12 12
13 class SkBitmap; 13 class SkBitmap;
14 14
15 namespace content { 15 namespace content {
16 16
17 class NavigationControllerImpl; 17 class NavigationControllerImpl;
18 class NavigationEntryImpl; 18 class NavigationEntryImpl;
19 class RenderViewHost; 19 class RenderViewHost;
20 class ScreenshotData; 20 class ScreenshotData;
21 21
22 // WebContentsScreenshotManager takes care of taking image-captures for the 22 // WebContentsScreenshotManager takes care of taking image-captures for the
23 // current navigation entry of a NavigationControllerImpl, and managing these 23 // current navigation entry of a NavigationControllerImpl, and managing these
24 // captured images. These image-captures are used for history navigation using 24 // captured images. These image-captures are used for history navigation using
25 // overscroll gestures. 25 // overscroll gestures.
26 // TODO(nasko): Rename this to better reflect that it is used for
27 // navigation entries and not WebContents.
26 class CONTENT_EXPORT WebContentsScreenshotManager { 28 class CONTENT_EXPORT WebContentsScreenshotManager {
27 public: 29 public:
28 explicit WebContentsScreenshotManager(NavigationControllerImpl* controller); 30 explicit WebContentsScreenshotManager(NavigationControllerImpl* controller);
29 virtual ~WebContentsScreenshotManager(); 31 virtual ~WebContentsScreenshotManager();
30 32
31 // Takes a screenshot of the last-committed entry of the controller. 33 // Takes a screenshot of the last-committed entry of the controller.
32 void TakeScreenshot(); 34 void TakeScreenshot();
33 35
34 // Clears screenshots of all navigation entries. 36 // Clears screenshots of all navigation entries.
35 void ClearAllScreenshots(); 37 void ClearAllScreenshots();
(...skipping 43 matching lines...) Expand 10 before | Expand all | Expand 10 after
79 base::WeakPtrFactory<WebContentsScreenshotManager> screenshot_factory_; 81 base::WeakPtrFactory<WebContentsScreenshotManager> screenshot_factory_;
80 82
81 base::Time last_screenshot_time_; 83 base::Time last_screenshot_time_;
82 int min_screenshot_interval_ms_; 84 int min_screenshot_interval_ms_;
83 85
84 DISALLOW_COPY_AND_ASSIGN(WebContentsScreenshotManager); 86 DISALLOW_COPY_AND_ASSIGN(WebContentsScreenshotManager);
85 }; 87 };
86 88
87 } // namespace content 89 } // namespace content
88 90
89 #endif // CONTENT_BROWSER_WEB_CONTENTS_WEB_CONTENTS_SCREENSHOT_MANAGER_H_ 91 #endif // CONTENT_BROWSER_FRAME_HOST_WEB_CONTENTS_SCREENSHOT_MANAGER_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698