Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 /* | 1 /* |
| 2 * Copyright (C) 2007, 2008 Apple Inc. All rights reserved. | 2 * Copyright (C) 2007, 2008 Apple Inc. All rights reserved. |
| 3 * Copyright (C) 2008 Matt Lilek <webkit@mattlilek.com> | 3 * Copyright (C) 2008 Matt Lilek <webkit@mattlilek.com> |
| 4 * | 4 * |
| 5 * Redistribution and use in source and binary forms, with or without | 5 * Redistribution and use in source and binary forms, with or without |
| 6 * modification, are permitted provided that the following conditions | 6 * modification, are permitted provided that the following conditions |
| 7 * are met: | 7 * are met: |
| 8 * | 8 * |
| 9 * 1. Redistributions of source code must retain the above copyright | 9 * 1. Redistributions of source code must retain the above copyright |
| 10 * notice, this list of conditions and the following disclaimer. | 10 * notice, this list of conditions and the following disclaimer. |
| (...skipping 249 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 260 | 260 |
| 261 String InspectorFrontendHost::loadResourceSynchronously(const String& url) | 261 String InspectorFrontendHost::loadResourceSynchronously(const String& url) |
| 262 { | 262 { |
| 263 ResourceRequest request(url); | 263 ResourceRequest request(url); |
| 264 request.setHTTPMethod("GET"); | 264 request.setHTTPMethod("GET"); |
| 265 | 265 |
| 266 Vector<char> data; | 266 Vector<char> data; |
| 267 ResourceError error; | 267 ResourceError error; |
| 268 ResourceResponse response; | 268 ResourceResponse response; |
| 269 m_frontendPage->mainFrame()->loader()->loadResourceSynchronously(request, Do NotAllowStoredCredentials, error, response, data); | 269 m_frontendPage->mainFrame()->loader()->loadResourceSynchronously(request, Do NotAllowStoredCredentials, error, response, data); |
| 270 return String(data.data(), data.size()); | 270 // |data| contains raw UTF8 bytes of the |url| contents. |
|
vsevik
2013/05/21 07:40:45
Please remove this comment
| |
| 271 return String::fromUTF8(data.data(), data.size()); | |
| 271 } | 272 } |
| 272 | 273 |
| 273 String InspectorFrontendHost::getSelectionBackgroundColor() | 274 String InspectorFrontendHost::getSelectionBackgroundColor() |
| 274 { | 275 { |
| 275 Color color = m_frontendPage->theme()->activeSelectionBackgroundColor(); | 276 Color color = m_frontendPage->theme()->activeSelectionBackgroundColor(); |
| 276 return color.isValid() ? color.serialized() : ""; | 277 return color.isValid() ? color.serialized() : ""; |
| 277 } | 278 } |
| 278 | 279 |
| 279 String InspectorFrontendHost::getSelectionForegroundColor() | 280 String InspectorFrontendHost::getSelectionForegroundColor() |
| 280 { | 281 { |
| (...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 325 { | 326 { |
| 326 return false; | 327 return false; |
| 327 } | 328 } |
| 328 | 329 |
| 329 String InspectorFrontendHost::hiddenPanels() | 330 String InspectorFrontendHost::hiddenPanels() |
| 330 { | 331 { |
| 331 return ""; | 332 return ""; |
| 332 } | 333 } |
| 333 | 334 |
| 334 } // namespace WebCore | 335 } // namespace WebCore |
| OLD | NEW |