| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2011 Google Inc. All rights reserved. | 2 * Copyright (C) 2011 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 878 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 889 if (url.isEmpty()) | 889 if (url.isEmpty()) |
| 890 return String(); | 890 return String(); |
| 891 Frame* frame = mainFrame(); | 891 Frame* frame = mainFrame(); |
| 892 if (!frame) | 892 if (!frame) |
| 893 return String(); | 893 return String(); |
| 894 CachedResource* resource = cachedResource(frame, KURL(ParsedURLString, url))
; | 894 CachedResource* resource = cachedResource(frame, KURL(ParsedURLString, url))
; |
| 895 if (!resource) | 895 if (!resource) |
| 896 return String(); | 896 return String(); |
| 897 String deprecatedHeaderSourceMapURL = resource->response().httpHeaderField(d
eprecatedSourceMapHttpHeader); | 897 String deprecatedHeaderSourceMapURL = resource->response().httpHeaderField(d
eprecatedSourceMapHttpHeader); |
| 898 if (!deprecatedHeaderSourceMapURL.isEmpty()) { | 898 if (!deprecatedHeaderSourceMapURL.isEmpty()) { |
| 899 m_page->console()->addMessage(NetworkMessageSource, WarningMessageLevel,
"Resource is served with deprecated header X-SourceMap, SourceMap should be use
d instead.", url, 0); | 899 // FIXME: add deprecated console message here. |
| 900 return deprecatedHeaderSourceMapURL; | 900 return deprecatedHeaderSourceMapURL; |
| 901 } | 901 } |
| 902 return resource->response().httpHeaderField(sourceMapHttpHeader); | 902 return resource->response().httpHeaderField(sourceMapHttpHeader); |
| 903 } | 903 } |
| 904 | 904 |
| 905 // static | 905 // static |
| 906 DocumentLoader* InspectorPageAgent::assertDocumentLoader(ErrorString* errorStrin
g, Frame* frame) | 906 DocumentLoader* InspectorPageAgent::assertDocumentLoader(ErrorString* errorStrin
g, Frame* frame) |
| 907 { | 907 { |
| 908 FrameLoader* frameLoader = frame->loader(); | 908 FrameLoader* frameLoader = frame->loader(); |
| 909 DocumentLoader* documentLoader = frameLoader ? frameLoader->documentLoader()
: 0; | 909 DocumentLoader* documentLoader = frameLoader ? frameLoader->documentLoader()
: 0; |
| (...skipping 344 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1254 } | 1254 } |
| 1255 | 1255 |
| 1256 void InspectorPageAgent::setShowViewportSizeOnResize(ErrorString*, bool show, co
nst bool* showGrid) | 1256 void InspectorPageAgent::setShowViewportSizeOnResize(ErrorString*, bool show, co
nst bool* showGrid) |
| 1257 { | 1257 { |
| 1258 m_state->setBoolean(PageAgentState::showSizeOnResize, show); | 1258 m_state->setBoolean(PageAgentState::showSizeOnResize, show); |
| 1259 m_state->setBoolean(PageAgentState::showGridOnResize, showGrid && *showGrid)
; | 1259 m_state->setBoolean(PageAgentState::showGridOnResize, showGrid && *showGrid)
; |
| 1260 } | 1260 } |
| 1261 | 1261 |
| 1262 } // namespace WebCore | 1262 } // namespace WebCore |
| 1263 | 1263 |
| OLD | NEW |