OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2009 Apple Inc. All rights reserved. | 2 * Copyright (C) 2009 Apple Inc. All rights reserved. |
3 * Copyright (C) 2011 Google Inc. All rights reserved. | 3 * Copyright (C) 2011 Google Inc. All rights reserved. |
4 * Copyright (C) 2009 Joseph Pecoraro | 4 * Copyright (C) 2009 Joseph Pecoraro |
5 * | 5 * |
6 * Redistribution and use in source and binary forms, with or without | 6 * Redistribution and use in source and binary forms, with or without |
7 * modification, are permitted provided that the following conditions | 7 * modification, are permitted provided that the following conditions |
8 * are met: | 8 * are met: |
9 * | 9 * |
10 * 1. Redistributions of source code must retain the above copyright | 10 * 1. Redistributions of source code must retain the above copyright |
(...skipping 2304 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2315 if (!node) | 2315 if (!node) |
2316 return; | 2316 return; |
2317 m_injectedScriptManager->injectedScriptHost()->addInspectedObject(adoptPtr(n
ew InspectableNode(node))); | 2317 m_injectedScriptManager->injectedScriptHost()->addInspectedObject(adoptPtr(n
ew InspectableNode(node))); |
2318 } | 2318 } |
2319 | 2319 |
2320 void InspectorDOMAgent::getRelayoutBoundary(ErrorString* errorString, int nodeId
, int* relayoutBoundaryNodeId) | 2320 void InspectorDOMAgent::getRelayoutBoundary(ErrorString* errorString, int nodeId
, int* relayoutBoundaryNodeId) |
2321 { | 2321 { |
2322 Node* node = assertNode(errorString, nodeId); | 2322 Node* node = assertNode(errorString, nodeId); |
2323 if (!node) | 2323 if (!node) |
2324 return; | 2324 return; |
2325 LayoutObject* renderer = node->renderer(); | 2325 LayoutObject* renderer = node->layoutObject(); |
2326 if (!renderer) { | 2326 if (!renderer) { |
2327 *errorString = "No renderer for node, perhaps orphan or hidden node"; | 2327 *errorString = "No renderer for node, perhaps orphan or hidden node"; |
2328 return; | 2328 return; |
2329 } | 2329 } |
2330 while (renderer && !renderer->isDocumentElement() && !renderer->isRelayoutBo
undaryForInspector()) | 2330 while (renderer && !renderer->isDocumentElement() && !renderer->isRelayoutBo
undaryForInspector()) |
2331 renderer = renderer->container(); | 2331 renderer = renderer->container(); |
2332 Node* resultNode = renderer ? renderer->generatingNode() : node->ownerDocume
nt(); | 2332 Node* resultNode = renderer ? renderer->generatingNode() : node->ownerDocume
nt(); |
2333 *relayoutBoundaryNodeId = pushNodePathToFrontend(resultNode); | 2333 *relayoutBoundaryNodeId = pushNodePathToFrontend(resultNode); |
2334 } | 2334 } |
2335 | 2335 |
(...skipping 43 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2379 visitor->trace(m_revalidateTask); | 2379 visitor->trace(m_revalidateTask); |
2380 visitor->trace(m_searchResults); | 2380 visitor->trace(m_searchResults); |
2381 #endif | 2381 #endif |
2382 visitor->trace(m_history); | 2382 visitor->trace(m_history); |
2383 visitor->trace(m_domEditor); | 2383 visitor->trace(m_domEditor); |
2384 visitor->trace(m_listener); | 2384 visitor->trace(m_listener); |
2385 InspectorBaseAgent::trace(visitor); | 2385 InspectorBaseAgent::trace(visitor); |
2386 } | 2386 } |
2387 | 2387 |
2388 } // namespace blink | 2388 } // namespace blink |
OLD | NEW |