| OLD | NEW |
| 1 /* | 1 /* |
| 2 * This file is part of Adblock Plus <https://adblockplus.org/>, | 2 * This file is part of Adblock Plus <https://adblockplus.org/>, |
| 3 * Copyright (C) 2006-2015 Eyeo GmbH | 3 * Copyright (C) 2006-2015 Eyeo GmbH |
| 4 * | 4 * |
| 5 * Adblock Plus is free software: you can redistribute it and/or modify | 5 * Adblock Plus is free software: you can redistribute it and/or modify |
| 6 * it under the terms of the GNU General Public License version 3 as | 6 * it under the terms of the GNU General Public License version 3 as |
| 7 * published by the Free Software Foundation. | 7 * published by the Free Software Foundation. |
| 8 * | 8 * |
| 9 * Adblock Plus is distributed in the hope that it will be useful, | 9 * Adblock Plus is distributed in the hope that it will be useful, |
| 10 * but WITHOUT ANY WARRANTY; without even the implied warranty of | 10 * but WITHOUT ANY WARRANTY; without even the implied warranty of |
| (...skipping 201 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 212 return contentType; | 212 return contentType; |
| 213 } | 213 } |
| 214 | 214 |
| 215 ////////////////////////////////////////////////////////////////////////////////
//////// | 215 ////////////////////////////////////////////////////////////////////////////////
//////// |
| 216 //WBPassthruSink | 216 //WBPassthruSink |
| 217 //Monitor and/or cancel every request and responde | 217 //Monitor and/or cancel every request and responde |
| 218 //WB makes, including images, sounds, scripts, etc | 218 //WB makes, including images, sounds, scripts, etc |
| 219 ////////////////////////////////////////////////////////////////////////////////
//////// | 219 ////////////////////////////////////////////////////////////////////////////////
//////// |
| 220 HRESULT WBPassthruSink::OnStart(LPCWSTR szUrl, IInternetProtocolSink *pOIProtSin
k, | 220 HRESULT WBPassthruSink::OnStart(LPCWSTR szUrl, IInternetProtocolSink *pOIProtSin
k, |
| 221 IInternetBindInfo *pOIBindInfo, DWORD grfPI, HAN
DLE_PTR dwReserved, | 221 IInternetBindInfo *pOIBindInfo, DWORD grfPI, HAN
DLE_PTR dwReserved, |
| 222 IInternetProtocol* pTargetProtocol, bool& handle
d) | 222 IInternetProtocol* pTargetProtocol) |
| 223 { | 223 { |
| 224 m_pTargetProtocol = pTargetProtocol; | 224 m_pTargetProtocol = pTargetProtocol; |
| 225 return BaseClass::OnStart(szUrl, pOIProtSink, pOIBindInfo, grfPI, dwReserved,
pTargetProtocol); | 225 return BaseClass::OnStart(szUrl, pOIProtSink, pOIBindInfo, grfPI, dwReserved,
pTargetProtocol); |
| 226 } | 226 } |
| 227 | 227 |
| 228 HRESULT WBPassthruSink::OnRead(void* pv, ULONG cb, ULONG* pcbRead) | 228 HRESULT WBPassthruSink::OnRead(void* pv, ULONG cb, ULONG* pcbRead) |
| 229 { | 229 { |
| 230 if (!pv || !pcbRead) | 230 if (!pv || !pcbRead) |
| 231 { | 231 { |
| 232 return E_POINTER; | 232 return E_POINTER; |
| (...skipping 200 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 433 } | 433 } |
| 434 | 434 |
| 435 return OnStart(szUrl, pOIProtSink, pOIBindInfo, grfPI, dwReserved, m_spInterne
tProtocol); | 435 return OnStart(szUrl, pOIProtSink, pOIBindInfo, grfPI, dwReserved, m_spInterne
tProtocol); |
| 436 } | 436 } |
| 437 | 437 |
| 438 STDMETHODIMP WBPassthru::Read(/* [in, out] */ void *pv,/* [in] */ ULONG cb,/* [o
ut] */ ULONG *pcbRead) | 438 STDMETHODIMP WBPassthru::Read(/* [in, out] */ void *pv,/* [in] */ ULONG cb,/* [o
ut] */ ULONG *pcbRead) |
| 439 { | 439 { |
| 440 WBPassthruSink* pSink = GetSink(); | 440 WBPassthruSink* pSink = GetSink(); |
| 441 return pSink->OnRead(pv, cb, pcbRead); | 441 return pSink->OnRead(pv, cb, pcbRead); |
| 442 } | 442 } |
| OLD | NEW |