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

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

Issue 307943002: Oilpan: Prepare moving InspectorController and InspectorAgents to oilpan. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 years, 6 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
OLDNEW
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 224 matching lines...) Expand 10 before | Expand all | Expand 10 after
235 bool InspectorPageAgent::dataContent(const char* data, unsigned size, const Stri ng& textEncodingName, bool withBase64Encode, String* result) 235 bool InspectorPageAgent::dataContent(const char* data, unsigned size, const Stri ng& textEncodingName, bool withBase64Encode, String* result)
236 { 236 {
237 if (withBase64Encode) { 237 if (withBase64Encode) {
238 *result = base64Encode(data, size); 238 *result = base64Encode(data, size);
239 return true; 239 return true;
240 } 240 }
241 241
242 return decodeBuffer(data, size, textEncodingName, result); 242 return decodeBuffer(data, size, textEncodingName, result);
243 } 243 }
244 244
245 PassOwnPtr<InspectorPageAgent> InspectorPageAgent::create(Page* page, InjectedSc riptManager* injectedScriptManager, InspectorClient* client, InspectorOverlay* o verlay) 245 PassOwnPtrWillBeRawPtr<InspectorPageAgent> InspectorPageAgent::create(Page* page , InjectedScriptManager* injectedScriptManager, InspectorClient* client, Inspect orOverlay* overlay)
246 { 246 {
247 return adoptPtr(new InspectorPageAgent(page, injectedScriptManager, client, overlay)); 247 return adoptPtrWillBeNoop(new InspectorPageAgent(page, injectedScriptManager , client, overlay));
248 } 248 }
249 249
250 // static 250 // static
251 void InspectorPageAgent::resourceContent(ErrorString* errorString, LocalFrame* f rame, const KURL& url, String* result, bool* base64Encoded) 251 void InspectorPageAgent::resourceContent(ErrorString* errorString, LocalFrame* f rame, const KURL& url, String* result, bool* base64Encoded)
252 { 252 {
253 DocumentLoader* loader = assertDocumentLoader(errorString, frame); 253 DocumentLoader* loader = assertDocumentLoader(errorString, frame);
254 if (!loader) 254 if (!loader)
255 return; 255 return;
256 if (!cachedResourceContent(cachedResource(frame, url), result, base64Encoded )) 256 if (!cachedResourceContent(cachedResource(frame, url), result, base64Encoded ))
257 *errorString = "No resource with given URL found"; 257 *errorString = "No resource with given URL found";
(...skipping 1010 matching lines...) Expand 10 before | Expand all | Expand 10 after
1268 } 1268 }
1269 return true; 1269 return true;
1270 } 1270 }
1271 1271
1272 void InspectorPageAgent::setShowViewportSizeOnResize(ErrorString*, bool show, co nst bool* showGrid) 1272 void InspectorPageAgent::setShowViewportSizeOnResize(ErrorString*, bool show, co nst bool* showGrid)
1273 { 1273 {
1274 m_state->setBoolean(PageAgentState::showSizeOnResize, show); 1274 m_state->setBoolean(PageAgentState::showSizeOnResize, show);
1275 m_state->setBoolean(PageAgentState::showGridOnResize, showGrid && *showGrid) ; 1275 m_state->setBoolean(PageAgentState::showGridOnResize, showGrid && *showGrid) ;
1276 } 1276 }
1277 1277
1278 void InspectorPageAgent::trace(Visitor* visitor)
1279 {
1280 visitor->trace(m_page);
1281 InspectorBaseAgent::trace(visitor);
1282 }
1283
1278 } // namespace WebCore 1284 } // namespace WebCore
1279 1285
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698