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

Side by Side Diff: Source/core/inspector/InspectorFrontendHost.cpp

Issue 15333014: DevTools: InspectorFrontendHost::loadResourceSynchronously() builds ASCII-only results (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Removed comment Created 7 years, 7 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
« no previous file with comments | « LayoutTests/inspector/load-resource-synchronously-utf8-expected.txt ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 250 matching lines...) Expand 10 before | Expand all | Expand 10 after
261 261
262 String InspectorFrontendHost::loadResourceSynchronously(const String& url) 262 String InspectorFrontendHost::loadResourceSynchronously(const String& url)
263 { 263 {
264 ResourceRequest request(url); 264 ResourceRequest request(url);
265 request.setHTTPMethod("GET"); 265 request.setHTTPMethod("GET");
266 266
267 Vector<char> data; 267 Vector<char> data;
268 ResourceError error; 268 ResourceError error;
269 ResourceResponse response; 269 ResourceResponse response;
270 m_frontendPage->mainFrame()->loader()->loadResourceSynchronously(request, Do NotAllowStoredCredentials, error, response, data); 270 m_frontendPage->mainFrame()->loader()->loadResourceSynchronously(request, Do NotAllowStoredCredentials, error, response, data);
271 return String(data.data(), data.size()); 271 return String::fromUTF8(data.data(), data.size());
272 } 272 }
273 273
274 String InspectorFrontendHost::getSelectionBackgroundColor() 274 String InspectorFrontendHost::getSelectionBackgroundColor()
275 { 275 {
276 Color color = m_frontendPage->theme()->activeSelectionBackgroundColor(); 276 Color color = m_frontendPage->theme()->activeSelectionBackgroundColor();
277 return color.isValid() ? color.serialized() : ""; 277 return color.isValid() ? color.serialized() : "";
278 } 278 }
279 279
280 String InspectorFrontendHost::getSelectionForegroundColor() 280 String InspectorFrontendHost::getSelectionForegroundColor()
281 { 281 {
(...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after
326 { 326 {
327 return false; 327 return false;
328 } 328 }
329 329
330 String InspectorFrontendHost::hiddenPanels() 330 String InspectorFrontendHost::hiddenPanels()
331 { 331 {
332 return ""; 332 return "";
333 } 333 }
334 334
335 } // namespace WebCore 335 } // namespace WebCore
OLDNEW
« no previous file with comments | « LayoutTests/inspector/load-resource-synchronously-utf8-expected.txt ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698