OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2010, 2011, 2012 Google Inc. All rights reserved. | 2 * Copyright (C) 2010, 2011, 2012 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 283 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
294 , m_client(0) | 294 , m_client(0) |
295 { | 295 { |
296 ASSERT(m_frameImpl); | 296 ASSERT(m_frameImpl); |
297 } | 297 } |
298 | 298 |
299 AssociatedURLLoader::~AssociatedURLLoader() | 299 AssociatedURLLoader::~AssociatedURLLoader() |
300 { | 300 { |
301 cancel(); | 301 cancel(); |
302 } | 302 } |
303 | 303 |
304 #define COMPILE_ASSERT_MATCHING_ENUM(webkit_name, webcore_name) \ | 304 #define STATIC_ASSERT_MATCHING_ENUM(webkit_name, webcore_name) \ |
305 COMPILE_ASSERT(static_cast<int>(webkit_name) == static_cast<int>(webcore_nam
e), mismatching_enums) | 305 static_assert(static_cast<int>(webkit_name) == static_cast<int>(webcore_name
), "mismatching enum values") |
306 | 306 |
307 COMPILE_ASSERT_MATCHING_ENUM(WebURLLoaderOptions::CrossOriginRequestPolicyDeny,
DenyCrossOriginRequests); | 307 STATIC_ASSERT_MATCHING_ENUM(WebURLLoaderOptions::CrossOriginRequestPolicyDeny, D
enyCrossOriginRequests); |
308 COMPILE_ASSERT_MATCHING_ENUM(WebURLLoaderOptions::CrossOriginRequestPolicyUseAcc
essControl, UseAccessControl); | 308 STATIC_ASSERT_MATCHING_ENUM(WebURLLoaderOptions::CrossOriginRequestPolicyUseAcce
ssControl, UseAccessControl); |
309 COMPILE_ASSERT_MATCHING_ENUM(WebURLLoaderOptions::CrossOriginRequestPolicyAllow,
AllowCrossOriginRequests); | 309 STATIC_ASSERT_MATCHING_ENUM(WebURLLoaderOptions::CrossOriginRequestPolicyAllow,
AllowCrossOriginRequests); |
310 | 310 |
311 COMPILE_ASSERT_MATCHING_ENUM(WebURLLoaderOptions::ConsiderPreflight, ConsiderPre
flight); | 311 STATIC_ASSERT_MATCHING_ENUM(WebURLLoaderOptions::ConsiderPreflight, ConsiderPref
light); |
312 COMPILE_ASSERT_MATCHING_ENUM(WebURLLoaderOptions::ForcePreflight, ForcePreflight
); | 312 STATIC_ASSERT_MATCHING_ENUM(WebURLLoaderOptions::ForcePreflight, ForcePreflight)
; |
313 COMPILE_ASSERT_MATCHING_ENUM(WebURLLoaderOptions::PreventPreflight, PreventPrefl
ight); | 313 STATIC_ASSERT_MATCHING_ENUM(WebURLLoaderOptions::PreventPreflight, PreventPrefli
ght); |
314 | 314 |
315 void AssociatedURLLoader::loadSynchronously(const WebURLRequest& request, WebURL
Response& response, WebURLError& error, WebData& data) | 315 void AssociatedURLLoader::loadSynchronously(const WebURLRequest& request, WebURL
Response& response, WebURLError& error, WebData& data) |
316 { | 316 { |
317 ASSERT(0); // Synchronous loading is not supported. | 317 ASSERT(0); // Synchronous loading is not supported. |
318 } | 318 } |
319 | 319 |
320 void AssociatedURLLoader::loadAsynchronously(const WebURLRequest& request, WebUR
LLoaderClient* client) | 320 void AssociatedURLLoader::loadAsynchronously(const WebURLRequest& request, WebUR
LLoaderClient* client) |
321 { | 321 { |
322 ASSERT(!m_loader); | 322 ASSERT(!m_loader); |
323 ASSERT(!m_client); | 323 ASSERT(!m_client); |
(...skipping 53 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
377 m_loader->cancel(); | 377 m_loader->cancel(); |
378 } | 378 } |
379 | 379 |
380 void AssociatedURLLoader::setDefersLoading(bool defersLoading) | 380 void AssociatedURLLoader::setDefersLoading(bool defersLoading) |
381 { | 381 { |
382 if (m_loader) | 382 if (m_loader) |
383 m_loader->setDefersLoading(defersLoading); | 383 m_loader->setDefersLoading(defersLoading); |
384 } | 384 } |
385 | 385 |
386 } // namespace blink | 386 } // namespace blink |
OLD | NEW |