OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 #include "content/renderer/render_view_impl.h" | 5 #include "content/renderer/render_view_impl.h" |
6 | 6 |
7 #include <algorithm> | 7 #include <algorithm> |
8 #include <cmath> | 8 #include <cmath> |
9 | 9 |
10 #include "base/auto_reset.h" | 10 #include "base/auto_reset.h" |
(...skipping 2016 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2027 } | 2027 } |
2028 } | 2028 } |
2029 | 2029 |
2030 if (content_initiated) { | 2030 if (content_initiated) { |
2031 const WebURLRequest& request = ds->request(); | 2031 const WebURLRequest& request = ds->request(); |
2032 switch (request.cachePolicy()) { | 2032 switch (request.cachePolicy()) { |
2033 case WebURLRequest::UseProtocolCachePolicy: // normal load. | 2033 case WebURLRequest::UseProtocolCachePolicy: // normal load. |
2034 document_state->set_load_type(DocumentState::LINK_LOAD_NORMAL); | 2034 document_state->set_load_type(DocumentState::LINK_LOAD_NORMAL); |
2035 break; | 2035 break; |
2036 case WebURLRequest::ReloadIgnoringCacheData: // reload. | 2036 case WebURLRequest::ReloadIgnoringCacheData: // reload. |
| 2037 case WebURLRequest::ReloadBypassingCache: // end-to-end reload. |
2037 document_state->set_load_type(DocumentState::LINK_LOAD_RELOAD); | 2038 document_state->set_load_type(DocumentState::LINK_LOAD_RELOAD); |
2038 break; | 2039 break; |
2039 case WebURLRequest::ReturnCacheDataElseLoad: // allow stale data. | 2040 case WebURLRequest::ReturnCacheDataElseLoad: // allow stale data. |
2040 document_state->set_load_type( | 2041 document_state->set_load_type( |
2041 DocumentState::LINK_LOAD_CACHE_STALE_OK); | 2042 DocumentState::LINK_LOAD_CACHE_STALE_OK); |
2042 break; | 2043 break; |
2043 case WebURLRequest::ReturnCacheDataDontLoad: // Don't re-post. | 2044 case WebURLRequest::ReturnCacheDataDontLoad: // Don't re-post. |
2044 document_state->set_load_type(DocumentState::LINK_LOAD_CACHE_ONLY); | 2045 document_state->set_load_type(DocumentState::LINK_LOAD_CACHE_ONLY); |
2045 break; | 2046 break; |
2046 } | 2047 } |
(...skipping 2002 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
4049 std::vector<gfx::Size> sizes; | 4050 std::vector<gfx::Size> sizes; |
4050 ConvertToFaviconSizes(icon_urls[i].sizes(), &sizes); | 4051 ConvertToFaviconSizes(icon_urls[i].sizes(), &sizes); |
4051 if (!url.isEmpty()) | 4052 if (!url.isEmpty()) |
4052 urls.push_back( | 4053 urls.push_back( |
4053 FaviconURL(url, ToFaviconType(icon_urls[i].iconType()), sizes)); | 4054 FaviconURL(url, ToFaviconType(icon_urls[i].iconType()), sizes)); |
4054 } | 4055 } |
4055 SendUpdateFaviconURL(urls); | 4056 SendUpdateFaviconURL(urls); |
4056 } | 4057 } |
4057 | 4058 |
4058 } // namespace content | 4059 } // namespace content |
OLD | NEW |