How to make a gallery of webviews

149 views
Skip to first unread message

Yeradis

unread,
Aug 28, 2009, 2:24:38 AM8/28/09
to cw-android
Regars to every body

First all sorry by my english

Lets start

i know i´m asking to much

But i really want some of this

i was trying to make a listview of webviews but if the url is wrong it
shows shomething there , but if is correct then stay black and dont
show anything

What i want is a gallery of webviews a thumbnails of webviews , maibe
with a tablelayout , a gridlayout or with a Gallery
dont know

also i have other problem, i was trying to use the sample that appear
in one of the books to set each tab for a webview , i i did as you
said dinamycally , the problem ? well , the page open in the browser
instead the web view , i dont know if that happen because are shorts
url and get redirected or because using it dinamically
because if i do like in the book the web pages load inside the tabview

any idea ? any help is welcome :D

Thanks
with no more bye bye

Mark Murphy

unread,
Aug 28, 2009, 3:56:21 AM8/28/09
to cw-an...@googlegroups.com
> also i have other problem, i was trying to use the sample that appear
> in one of the books to set each tab for a webview , i i did as you
> said dinamycally , the problem ? well , the page open in the browser
> instead the web view , i dont know if that happen because are shorts
> url and get redirected or because using it dinamically
> because if i do like in the book the web pages load inside the tabview

Somebody else reported a problem like this on one of the Android Google
Groups, and we determined that the problem was a redirect. Either attach a
WebViewClient and use shouldOverrideUrlLoading() to force the redirect to
stay in the WebView, or try to load pages that do not involve redirects.

--
Mark Murphy (a Commons Guy)
http://commonsware.com
Android App Developer Books: http://commonsware.com/books.html


Yeradis

unread,
Aug 28, 2009, 8:51:16 AM8/28/09
to cw-android
It is working now , thanks for your reply

;)

now i need to get a pic from that webview and build a gallery with
those images :S

somthing like :

wv.setDrawingCacheEnabled(true)

loadurl

Bitmap bmp = wv.getDrawingCache();

?
:D

On Aug 28, 9:56 am, "Mark Murphy" <mmur...@commonsware.com> wrote:
> > also i have other problem, i was trying to use the  sample that appear
> > in one of the books to set each tab for a webview , i i did as you
> > said dinamycally , the problem ?  well , the page open in the browser
> > instead the web view , i dont know if that happen because are shorts
> > url and get redirected or because using it dinamically
> > because if i do like in the book the web pages load inside the tabview
>
> Somebody else reported a problem like this on one of the Android Google
> Groups, and we determined that the problem was a redirect. Either attach a
> WebViewClient and use shouldOverrideUrlLoading() to force the redirect to
> stay in the WebView, or try to load pages that do not involve redirects.
>
> --
> Mark Murphy (a Commons Guy)http://commonsware.com

Yeradis

unread,
Aug 28, 2009, 8:55:45 AM8/28/09
to cw-android
i had saw a capturePicture() in the webview :O
Reply all
Reply to author
Forward
0 new messages