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

Side by Side Diff: pdf/document_loader.h

Issue 2828413005: Clang format pdf/ (Closed)
Patch Set: Manual tweaks Created 3 years, 8 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 | « pdf/chunk_stream.cc ('k') | pdf/document_loader.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 (c) 2010 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2010 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 PDF_DOCUMENT_LOADER_H_ 5 #ifndef PDF_DOCUMENT_LOADER_H_
6 #define PDF_DOCUMENT_LOADER_H_ 6 #define PDF_DOCUMENT_LOADER_H_
7 7
8 #include <stddef.h> 8 #include <stddef.h>
9 #include <stdint.h> 9 #include <stdint.h>
10 10
(...skipping 92 matching lines...) Expand 10 before | Expand all | Expand 10 after
103 // Number was chosen in crbug.com/78264#c8 103 // Number was chosen in crbug.com/78264#c8
104 enum { kDefaultRequestSize = 65536 }; 104 enum { kDefaultRequestSize = 65536 };
105 105
106 Client* const client_; 106 Client* const client_;
107 std::string url_; 107 std::string url_;
108 pp::URLLoader loader_; 108 pp::URLLoader loader_;
109 pp::CompletionCallbackFactory<DocumentLoader> loader_factory_; 109 pp::CompletionCallbackFactory<DocumentLoader> loader_factory_;
110 ChunkStream chunk_stream_; 110 ChunkStream chunk_stream_;
111 bool partial_document_; 111 bool partial_document_;
112 bool request_pending_; 112 bool request_pending_;
113 typedef std::list<std::pair<size_t, size_t> > PendingRequests; 113 typedef std::list<std::pair<size_t, size_t>> PendingRequests;
114 PendingRequests pending_requests_; 114 PendingRequests pending_requests_;
115 // The starting position of the HTTP request currently being processed. 115 // The starting position of the HTTP request currently being processed.
116 size_t current_request_offset_; 116 size_t current_request_offset_;
117 // The size of the byte range the current HTTP request must download before 117 // The size of the byte range the current HTTP request must download before
118 // being cancelled. 118 // being cancelled.
119 size_t current_request_size_; 119 size_t current_request_size_;
120 // The actual byte range size of the current HTTP request. This may be larger 120 // The actual byte range size of the current HTTP request. This may be larger
121 // than |current_request_size_| and the request may be cancelled before 121 // than |current_request_size_| and the request may be cancelled before
122 // reaching |current_request_offset_| + |current_request_extended_size_|. 122 // reaching |current_request_offset_| + |current_request_extended_size_|.
123 size_t current_request_extended_size_; 123 size_t current_request_extended_size_;
124 char buffer_[kDefaultRequestSize]; 124 char buffer_[kDefaultRequestSize];
125 uint32_t current_pos_; 125 uint32_t current_pos_;
126 uint32_t current_chunk_size_; 126 uint32_t current_chunk_size_;
127 uint32_t current_chunk_read_; 127 uint32_t current_chunk_read_;
128 uint32_t document_size_; 128 uint32_t document_size_;
129 bool header_request_; 129 bool header_request_;
130 bool is_multipart_; 130 bool is_multipart_;
131 std::string multipart_boundary_; 131 std::string multipart_boundary_;
132 uint32_t requests_count_; 132 uint32_t requests_count_;
133 std::vector<std::vector<unsigned char> > chunk_buffer_; 133 std::vector<std::vector<unsigned char>> chunk_buffer_;
134 }; 134 };
135 135
136 } // namespace chrome_pdf 136 } // namespace chrome_pdf
137 137
138 #endif // PDF_DOCUMENT_LOADER_H_ 138 #endif // PDF_DOCUMENT_LOADER_H_
OLDNEW
« no previous file with comments | « pdf/chunk_stream.cc ('k') | pdf/document_loader.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698