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

Side by Side Diff: Source/WebCore/platform/chromium/support/WebHTTPBody.cpp

Issue 13497009: Remove ENABLE(FILE_SYSTEM) compile-time flag. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: added CodeGeneratorInspector.py change Created 7 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 | Annotate | Revision Log
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2009 Google Inc. All rights reserved. 2 * Copyright (C) 2009 Google Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions are 5 * modification, are permitted provided that the following conditions are
6 * met: 6 * met:
7 * 7 *
8 * * Redistributions of source code must retain the above copyright 8 * * Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * * Redistributions in binary form must reproduce the above 10 * * Redistributions in binary form must reproduce the above
(...skipping 85 matching lines...) Expand 10 before | Expand all | Expand 10 after
96 result.modificationTime = element.m_expectedFileModificationTime; 96 result.modificationTime = element.m_expectedFileModificationTime;
97 #endif 97 #endif
98 break; 98 break;
99 #if ENABLE(BLOB) 99 #if ENABLE(BLOB)
100 case FormDataElement::encodedBlob: 100 case FormDataElement::encodedBlob:
101 result.type = Element::TypeBlob; 101 result.type = Element::TypeBlob;
102 result.url = element.m_url; 102 result.url = element.m_url;
103 result.blobURL = element.m_url; // FIXME: deprecate this. 103 result.blobURL = element.m_url; // FIXME: deprecate this.
104 break; 104 break;
105 #endif 105 #endif
106 #if ENABLE(FILE_SYSTEM)
107 case FormDataElement::encodedURL: 106 case FormDataElement::encodedURL:
108 result.type = Element::TypeURL; 107 result.type = Element::TypeURL;
109 result.url = element.m_url; 108 result.url = element.m_url;
110 result.fileStart = element.m_fileStart; 109 result.fileStart = element.m_fileStart;
111 result.fileLength = element.m_fileLength; 110 result.fileLength = element.m_fileLength;
112 result.modificationTime = element.m_expectedFileModificationTime; 111 result.modificationTime = element.m_expectedFileModificationTime;
113 break; 112 break;
114 #endif
115 default: 113 default:
116 ASSERT_NOT_REACHED(); 114 ASSERT_NOT_REACHED();
117 return false; 115 return false;
118 } 116 }
119 117
120 return true; 118 return true;
121 } 119 }
122 120
123 void WebHTTPBody::appendData(const WebData& data) 121 void WebHTTPBody::appendData(const WebData& data)
124 { 122 {
(...skipping 12 matching lines...) Expand all
137 void WebHTTPBody::appendFileRange(const WebString& filePath, long long fileStart , long long fileLength, double modificationTime) 135 void WebHTTPBody::appendFileRange(const WebString& filePath, long long fileStart , long long fileLength, double modificationTime)
138 { 136 {
139 #if ENABLE(BLOB) 137 #if ENABLE(BLOB)
140 ensureMutable(); 138 ensureMutable();
141 m_private->appendFileRange(filePath, fileStart, fileLength, modificationTime ); 139 m_private->appendFileRange(filePath, fileStart, fileLength, modificationTime );
142 #endif 140 #endif
143 } 141 }
144 142
145 void WebHTTPBody::appendURLRange(const WebURL& url, long long start, long long l ength, double modificationTime) 143 void WebHTTPBody::appendURLRange(const WebURL& url, long long start, long long l ength, double modificationTime)
146 { 144 {
147 #if ENABLE(FILE_SYSTEM)
148 // Currently we only support filesystem URL. 145 // Currently we only support filesystem URL.
149 ASSERT(KURL(url).protocolIs("filesystem")); 146 ASSERT(KURL(url).protocolIs("filesystem"));
150 ensureMutable(); 147 ensureMutable();
151 m_private->appendURLRange(url, start, length, modificationTime); 148 m_private->appendURLRange(url, start, length, modificationTime);
152 #endif
153 } 149 }
154 150
155 void WebHTTPBody::appendBlob(const WebURL& blobURL) 151 void WebHTTPBody::appendBlob(const WebURL& blobURL)
156 { 152 {
157 #if ENABLE(BLOB) 153 #if ENABLE(BLOB)
158 ASSERT(KURL(blobURL).protocolIs("blob")); 154 ASSERT(KURL(blobURL).protocolIs("blob"));
159 ensureMutable(); 155 ensureMutable();
160 m_private->appendBlob(blobURL); 156 m_private->appendBlob(blobURL);
161 #endif 157 #endif
162 } 158 }
(...skipping 45 matching lines...) Expand 10 before | Expand all | Expand 10 after
208 } 204 }
209 205
210 void WebHTTPBody::ensureMutable() 206 void WebHTTPBody::ensureMutable()
211 { 207 {
212 ASSERT(!isNull()); 208 ASSERT(!isNull());
213 if (!m_private->hasOneRef()) 209 if (!m_private->hasOneRef())
214 assign(static_cast<WebHTTPBodyPrivate*>(m_private->copy().leakRef())); 210 assign(static_cast<WebHTTPBodyPrivate*>(m_private->copy().leakRef()));
215 } 211 }
216 212
217 } // namespace WebKit 213 } // namespace WebKit
OLDNEW
« no previous file with comments | « Source/WebCore/platform/chromium/MIMETypeRegistryChromium.cpp ('k') | Source/WebCore/platform/network/BlobData.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698