| 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 677 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 688 if (m_state->booleanProperty(NetworkAgentState::bypassServiceWorker, false)) | 688 if (m_state->booleanProperty(NetworkAgentState::bypassServiceWorker, false)) |
| 689 request.setSkipServiceWorker(WebURLRequest::SkipServiceWorker::All); | 689 request.setSkipServiceWorker(WebURLRequest::SkipServiceWorker::All); |
| 690 | 690 |
| 691 willSendRequestInternal(frame, identifier, loader, request, redirectResponse, | 691 willSendRequestInternal(frame, identifier, loader, request, redirectResponse, |
| 692 initiatorInfo); | 692 initiatorInfo); |
| 693 | 693 |
| 694 if (!m_hostId.isEmpty()) | 694 if (!m_hostId.isEmpty()) |
| 695 request.addHTTPHeaderField( | 695 request.addHTTPHeaderField( |
| 696 HTTPNames::X_DevTools_Emulate_Network_Conditions_Client_Id, | 696 HTTPNames::X_DevTools_Emulate_Network_Conditions_Client_Id, |
| 697 AtomicString(m_hostId)); | 697 AtomicString(m_hostId)); |
| 698 |
| 699 request.setHTTPHeaderField( |
| 700 HTTPNames::X_DevTools_Request_Id, |
| 701 AtomicString(IdentifiersFactory::requestId(identifier))); |
| 698 } | 702 } |
| 699 | 703 |
| 700 void InspectorNetworkAgent::markResourceAsCached(unsigned long identifier) { | 704 void InspectorNetworkAgent::markResourceAsCached(unsigned long identifier) { |
| 701 frontend()->requestServedFromCache(IdentifiersFactory::requestId(identifier)); | 705 frontend()->requestServedFromCache(IdentifiersFactory::requestId(identifier)); |
| 702 } | 706 } |
| 703 | 707 |
| 704 void InspectorNetworkAgent::didReceiveResourceResponse( | 708 void InspectorNetworkAgent::didReceiveResourceResponse( |
| 705 LocalFrame* frame, | 709 LocalFrame* frame, |
| 706 unsigned long identifier, | 710 unsigned long identifier, |
| 707 DocumentLoader* loader, | 711 DocumentLoader* loader, |
| (...skipping 862 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1570 TaskRunnerHelper::get(TaskType::UnspecedLoading, | 1574 TaskRunnerHelper::get(TaskType::UnspecedLoading, |
| 1571 inspectedFrames->root()), | 1575 inspectedFrames->root()), |
| 1572 this, | 1576 this, |
| 1573 &InspectorNetworkAgent::removeFinishedReplayXHRFired) {} | 1577 &InspectorNetworkAgent::removeFinishedReplayXHRFired) {} |
| 1574 | 1578 |
| 1575 bool InspectorNetworkAgent::shouldForceCORSPreflight() { | 1579 bool InspectorNetworkAgent::shouldForceCORSPreflight() { |
| 1576 return m_state->booleanProperty(NetworkAgentState::cacheDisabled, false); | 1580 return m_state->booleanProperty(NetworkAgentState::cacheDisabled, false); |
| 1577 } | 1581 } |
| 1578 | 1582 |
| 1579 } // namespace blink | 1583 } // namespace blink |
| OLD | NEW |