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

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

Issue 1548153002: Switch to standard integer types in chrome/. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 12 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 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>
9
8 #include <string> 10 #include <string>
9 11
10 #include "chrome/utility/image_writer/image_writer.h" 12 #include "chrome/utility/image_writer/image_writer.h"
11 #include "chrome/utility/utility_message_handler.h" 13 #include "chrome/utility/utility_message_handler.h"
12 #include "ipc/ipc_message.h" 14 #include "ipc/ipc_message.h"
13 15
14 namespace base { 16 namespace base {
15 class FilePath; 17 class FilePath;
16 } 18 }
17 19
18 namespace image_writer { 20 namespace image_writer {
19 21
20 // A handler for messages related to writing images. This class is added as a 22 // A handler for messages related to writing images. This class is added as a
21 // handler in ChromeContentUtilityClient. 23 // handler in ChromeContentUtilityClient.
22 class ImageWriterHandler : public UtilityMessageHandler { 24 class ImageWriterHandler : public UtilityMessageHandler {
23 public: 25 public:
24 ImageWriterHandler(); 26 ImageWriterHandler();
25 ~ImageWriterHandler() override; 27 ~ImageWriterHandler() override;
26 28
27 // Methods for sending the different messages back to the browser process. 29 // Methods for sending the different messages back to the browser process.
28 // Generally should be called by chrome::image_writer::ImageWriter. 30 // Generally should be called by chrome::image_writer::ImageWriter.
29 virtual void SendSucceeded(); 31 virtual void SendSucceeded();
30 virtual void SendCancelled(); 32 virtual void SendCancelled();
31 virtual void SendFailed(const std::string& message); 33 virtual void SendFailed(const std::string& message);
32 virtual void SendProgress(int64 progress); 34 virtual void SendProgress(int64_t progress);
33 35
34 private: 36 private:
35 bool OnMessageReceived(const IPC::Message& message) override; 37 bool OnMessageReceived(const IPC::Message& message) override;
36 38
37 // Small wrapper for sending on the UtilityProcess. 39 // Small wrapper for sending on the UtilityProcess.
38 void Send(IPC::Message* msg); 40 void Send(IPC::Message* msg);
39 41
40 // Message handlers. 42 // Message handlers.
41 void OnWriteStart(const base::FilePath& image, const base::FilePath& device); 43 void OnWriteStart(const base::FilePath& image, const base::FilePath& device);
42 void OnVerifyStart(const base::FilePath& image, const base::FilePath& device); 44 void OnVerifyStart(const base::FilePath& image, const base::FilePath& device);
43 void OnCancel(); 45 void OnCancel();
44 46
45 scoped_ptr<ImageWriter> image_writer_; 47 scoped_ptr<ImageWriter> image_writer_;
46 }; 48 };
47 49
48 } // namespace image_writer 50 } // namespace image_writer
49 51
50 #endif // CHROME_UTILITY_IMAGE_WRITER_IMAGE_WRITER_HANDLER_H_ 52 #endif // CHROME_UTILITY_IMAGE_WRITER_IMAGE_WRITER_HANDLER_H_
OLDNEW
« no previous file with comments | « chrome/utility/image_writer/image_writer.cc ('k') | chrome/utility/image_writer/image_writer_handler.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698