| OLD | NEW |
| 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 #include "chrome/browser/ui/ash/screenshot_taker.h" | 5 #include "chrome/browser/ui/ash/screenshot_taker.h" |
| 6 | 6 |
| 7 #include <climits> | 7 #include <climits> |
| 8 #include <string> | 8 #include <string> |
| 9 | 9 |
| 10 #include "ash/shell.h" | 10 #include "ash/shell.h" |
| (...skipping 27 matching lines...) Expand all Loading... |
| 38 #include "ui/base/clipboard/scoped_clipboard_writer.h" | 38 #include "ui/base/clipboard/scoped_clipboard_writer.h" |
| 39 #include "ui/base/l10n/l10n_util.h" | 39 #include "ui/base/l10n/l10n_util.h" |
| 40 #include "ui/base/resource/resource_bundle.h" | 40 #include "ui/base/resource/resource_bundle.h" |
| 41 #include "ui/gfx/image/image.h" | 41 #include "ui/gfx/image/image.h" |
| 42 #include "ui/snapshot/snapshot.h" | 42 #include "ui/snapshot/snapshot.h" |
| 43 | 43 |
| 44 #if defined(OS_CHROMEOS) | 44 #if defined(OS_CHROMEOS) |
| 45 #include "chrome/browser/chromeos/drive/file_system_interface.h" | 45 #include "chrome/browser/chromeos/drive/file_system_interface.h" |
| 46 #include "chrome/browser/chromeos/drive/file_system_util.h" | 46 #include "chrome/browser/chromeos/drive/file_system_util.h" |
| 47 #include "chrome/browser/chromeos/file_manager/open_util.h" | 47 #include "chrome/browser/chromeos/file_manager/open_util.h" |
| 48 #include "chrome/browser/chromeos/login/user_manager.h" | 48 #include "chrome/browser/chromeos/login/users/user_manager.h" |
| 49 #include "chrome/browser/notifications/desktop_notification_service.h" | 49 #include "chrome/browser/notifications/desktop_notification_service.h" |
| 50 #include "chrome/browser/notifications/desktop_notification_service_factory.h" | 50 #include "chrome/browser/notifications/desktop_notification_service_factory.h" |
| 51 #include "chromeos/login/login_state.h" | 51 #include "chromeos/login/login_state.h" |
| 52 #endif | 52 #endif |
| 53 | 53 |
| 54 namespace { | 54 namespace { |
| 55 // The minimum interval between two screenshot commands. It has to be | 55 // The minimum interval between two screenshot commands. It has to be |
| 56 // more than 1000 to prevent the conflict of filenames. | 56 // more than 1000 to prevent the conflict of filenames. |
| 57 const int kScreenshotMinimumIntervalInMS = 1000; | 57 const int kScreenshotMinimumIntervalInMS = 1000; |
| 58 | 58 |
| (...skipping 564 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 623 } | 623 } |
| 624 | 624 |
| 625 void ScreenshotTaker::SetScreenshotBasenameForTest( | 625 void ScreenshotTaker::SetScreenshotBasenameForTest( |
| 626 const std::string& basename) { | 626 const std::string& basename) { |
| 627 screenshot_basename_for_test_ = basename; | 627 screenshot_basename_for_test_ = basename; |
| 628 } | 628 } |
| 629 | 629 |
| 630 void ScreenshotTaker::SetScreenshotProfileForTest(Profile* profile) { | 630 void ScreenshotTaker::SetScreenshotProfileForTest(Profile* profile) { |
| 631 profile_for_test_ = profile; | 631 profile_for_test_ = profile; |
| 632 } | 632 } |
| OLD | NEW |