Did you actually try WebViewClient.shouldInterceptRequest?  I'm looking 
through old code of mine that suggests it will work.  Also, you should try 
searching for "WebViewClient shouldInterceptRequest" to see what places 
like StackOverflow say.

Doug

On Sunday, December 14, 2014 10:39:21 AM UTC-8, Krystian Lewandowski wrote:
>
> Hi Doug,
> I mean, I can get the page and there is onLoadResource I missed last time, 
> but another question is - even if I get a resource, how to inject it? 
> Callbacks, in this case, serve kind of notification purpose there is no way 
> to replace loaded resource (whatever it actually is) or inject custom 
> "loader" instead. At least at the moment I don't see a solution.
>
> Thank you for ideas,
> Krystian
>
> W dniu niedziela, 14 grudnia 2014 18:30:15 UTC+1 użytkownik Doug napisał:
>>
>> It's been a long time since I've been active on it, but I believe you can 
>> intercept everything that passes through a url, both what would be loaded 
>> by navigation, image, and ajax.  Give it a try and implement all the 
>> callbacks exposed by webview, log a simple message, and see how it goes.
>>
>> Doug
>>
>> On Saturday, December 13, 2014 1:53:56 PM UTC-8, Krystian Lewandowski 
>> wrote:
>>>
>>> Thank you for the idea. Though, I don't think it will work. What about 
>>> AJAX, objects, images requests? I assume shouldInterceptRequest isn't 
>>> called for these.
>>>
>>> Krystian
>>>
>>> W dniu sobota, 13 grudnia 2014 22:14:33 UTC+1 użytkownik Doug napisał:
>>>>
>>>> You could use a WebViewClient to intercept everything a WebView is 
>>>> trying to fetch and fetch it yourself using whatever API suits your needs.
>>>>
>>>> Doug
>>>>
>>>> On Friday, December 12, 2014 12:15:35 PM UTC-8, Krystian Lewandowski 
>>>> wrote:
>>>>>
>>>>> Hi,
>>>>> I'm trying to update ConnectivityManager.requestRouteToHost 
>>>>> implementation from deprecated one to ConnectivityManager.requestNetwork 
>>>>> introduced in Lollipop. It supports Sockets, SocketFactories, 
>>>>> URLConnections - this is fine. The only thing missing at the moment is 
>>>>> WebView support. Application's requirement is to route WebView.loadUrl 
>>>>> requests via specific interface, but I can't see how it could be done 
>>>>> with 
>>>>> the new API (I can't use setProcessDefaultNetwork).
>>>>>
>>>>> I looked at WebView API but couldn't find anything new that would 
>>>>> support changed routing API. Is it supported, am I missing something?
>>>>>
>>>>> Thank you,
>>>>> Krystian
>>>>>
>>>>

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"Android Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to android-developers+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to