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

Side by Side Diff: chrome/utility/image_writer/image_writer_handler.h

Issue 2734773002: ImageWriter: Add ShouldResetImageWriter helper (Closed)
Patch Set: Add comment. Created 3 years, 9 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
« no previous file with comments | « no previous file | chrome/utility/image_writer/image_writer_handler.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 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 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_UTILITY_IMAGE_WRITER_IMAGE_WRITER_HANDLER_H_ 5 #ifndef CHROME_UTILITY_IMAGE_WRITER_IMAGE_WRITER_HANDLER_H_
6 #define CHROME_UTILITY_IMAGE_WRITER_IMAGE_WRITER_HANDLER_H_ 6 #define CHROME_UTILITY_IMAGE_WRITER_IMAGE_WRITER_HANDLER_H_
7 7
8 #include <stdint.h> 8 #include <stdint.h>
9 9
10 #include <memory> 10 #include <memory>
(...skipping 23 matching lines...) Expand all
34 // Methods for sending the different messages back to the |client_|. 34 // Methods for sending the different messages back to the |client_|.
35 // Generally should be called by image_writer::ImageWriter. 35 // Generally should be called by image_writer::ImageWriter.
36 virtual void SendProgress(int64_t progress); 36 virtual void SendProgress(int64_t progress);
37 virtual void SendSucceeded(); 37 virtual void SendSucceeded();
38 virtual void SendFailed(const std::string& error); 38 virtual void SendFailed(const std::string& error);
39 virtual void SendCancelled() {} 39 virtual void SendCancelled() {}
40 40
41 private: 41 private:
42 void Cancel(); 42 void Cancel();
43 43
44 bool ShouldResetImageWriter(const base::FilePath& image,
45 const base::FilePath& device);
46
44 extensions::mojom::RemovableStorageWriterClientPtr client_; 47 extensions::mojom::RemovableStorageWriterClientPtr client_;
45 std::unique_ptr<ImageWriter> image_writer_; 48 std::unique_ptr<ImageWriter> image_writer_;
46 }; 49 };
47 50
48 } // namespace image_writer 51 } // namespace image_writer
49 52
50 #endif // CHROME_UTILITY_IMAGE_WRITER_IMAGE_WRITER_HANDLER_H_ 53 #endif // CHROME_UTILITY_IMAGE_WRITER_IMAGE_WRITER_HANDLER_H_
OLDNEW
« no previous file with comments | « no previous file | chrome/utility/image_writer/image_writer_handler.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698