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

Side by Side Diff: chrome/browser/ui/ash/chrome_screenshot_taker.h

Issue 706013004: Move non-browser specific ScreenshotTaker code to ui/snapshot. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix win dependencies and browser_tests. Created 6 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
OLDNEW
(Empty)
1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 #ifndef CHROME_BROWSER_UI_ASH_CHROME_SCREENSHOT_TAKER_H_
6 #define CHROME_BROWSER_UI_ASH_CHROME_SCREENSHOT_TAKER_H_
7
8 #include "ash/screenshot_delegate.h"
9 #include "chrome/browser/notifications/notification.h"
10 #include "components/screenshot_taker/screenshot_taker.h"
11
12 class ChromeScreenshotTaker : public ash::ScreenshotDelegate,
13 public ScreenshotTakerClient,
14 public ScreenshotTakerObserver {
15 public:
16 ChromeScreenshotTaker();
17 ~ChromeScreenshotTaker() override;
18
19 ScreenshotTaker* screenshot_taker() { return screenshot_taker_.get(); }
20
21 // ash::ScreenshotDelegate:
22 void HandleTakeScreenshotForAllRootWindows() override;
23 void HandleTakePartialScreenshot(aura::Window* window,
24 const gfx::Rect& rect) override;
25 bool CanTakeScreenshot() override;
26
27 // ScreenshotTakerClient:
28 void PrepareWritableFileAndRunOnBlockingPool(
29 const base::FilePath& path,
30 WritableFileCallback callback_on_blocking_pool) override;
31
32 // ScreenshotTakerObserver:
33 void OnScreenshotCompleted(ScreenshotTakerObserver::Result result,
34 const base::FilePath& screenshot_path) override;
35
36 private:
37 #if defined(OS_CHROMEOS)
38 Notification* CreateNotification(
39 ScreenshotTakerObserver::Result screenshot_result,
40 const base::FilePath& screenshot_path);
41 #endif
42
43 scoped_ptr<ScreenshotTaker> screenshot_taker_;
44
45 DISALLOW_COPY_AND_ASSIGN(ChromeScreenshotTaker);
46 };
47
48 #endif // CHROME_BROWSER_UI_ASH_CHROME_SCREENSHOT_TAKER_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698