[android-developers] Re: Webkit - prevent reload of page when screen is popped out..?

2008-11-23 Thread Mark Murphy

> I have an app using the WebKit that I'm developing.  In my onCreate()
> method I'm loading my page:
>
>   browser = (WebView) findViewById(R.id.webkit);
>   browser.getSettings().setJavaScriptEnabled(true);
>   browser.loadUrl("file:///android_asset/mystuff.html");
>
> However, this fires off when the keyboard is popped out.  What do I
> need to do in order to have the browser only load on the initial start
> of the app and not do a complete reload of the page when the
> orientation is changed?

I have a series of blog posts over on AndroidGuys.com on this topic.
Search for "Rotational Forces". There are several options, and you'll need
to determine which one best fits your situation.

--
Mark Murphy (a Commons Guy)
http://commonsware.com
_The Busy Coder's Guide to Android Development_ Version 1.4 Published!



--~--~-~--~~~---~--~~
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
[EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
-~--~~~~--~~--~--~---



[android-developers] Re: Webkit - prevent reload of page when screen is popped out..?

2008-11-23 Thread David Orriss Jr

Thanks Mark.. I'll check it out.

Love your book, by the way.

On Sun, Nov 23, 2008 at 1:10 PM, Mark Murphy <[EMAIL PROTECTED]> wrote:
>
>> I have an app using the WebKit that I'm developing.  In my onCreate()
>> method I'm loading my page:
>>
>>   browser = (WebView) findViewById(R.id.webkit);
>>   browser.getSettings().setJavaScriptEnabled(true);
>>   browser.loadUrl("file:///android_asset/mystuff.html");
>>
>> However, this fires off when the keyboard is popped out.  What do I
>> need to do in order to have the browser only load on the initial start
>> of the app and not do a complete reload of the page when the
>> orientation is changed?
>
> I have a series of blog posts over on AndroidGuys.com on this topic.
> Search for "Rotational Forces". There are several options, and you'll need
> to determine which one best fits your situation.
>
> --
> Mark Murphy (a Commons Guy)
> http://commonsware.com
> _The Busy Coder's Guide to Android Development_ Version 1.4 Published!
>
>
>
> >
>



-- 
David Orriss Jr.

My blog: http://www.codethought.com/blog

--~--~-~--~~~---~--~~
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
[EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
-~--~~~~--~~--~--~---



[android-developers] Re: Webkit - prevent reload of page when screen is popped out..?

2008-11-23 Thread Mark Murphy

> Thanks Mark.. I'll check it out.
>
> Love your book, by the way.

Thanks!

If you're on the Warescription and have Version 1.4, the first three blog
posts are already in the chapter on Rotation Events. The fourth and fifth
posts, coming up this week, should appear in Version 1.9.

--
Mark Murphy (a Commons Guy)
http://commonsware.com
_The Busy Coder's Guide to Android Development_ Version 1.4 Published!



--~--~-~--~~~---~--~~
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
[EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
-~--~~~~--~~--~--~---



[android-developers] Re: Webkit - prevent reload of page when screen is popped out..?

2008-11-23 Thread David Orriss Jr

I'm on the Warescription.. No other way to get that book as far as I'm
concerned.. :-)

On Sun, Nov 23, 2008 at 1:20 PM, Mark Murphy <[EMAIL PROTECTED]> wrote:
>
>> Thanks Mark.. I'll check it out.
>>
>> Love your book, by the way.
>
> Thanks!
>
> If you're on the Warescription and have Version 1.4, the first three blog
> posts are already in the chapter on Rotation Events. The fourth and fifth
> posts, coming up this week, should appear in Version 1.9.
>
> --
> Mark Murphy (a Commons Guy)
> http://commonsware.com
> _The Busy Coder's Guide to Android Development_ Version 1.4 Published!
>
>
>
> >
>



-- 
David Orriss Jr.

My blog: http://www.codethought.com/blog

--~--~-~--~~~---~--~~
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
[EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
-~--~~~~--~~--~--~---



[android-developers] Re: Webkit - prevent reload of page when screen is popped out..?

2008-11-25 Thread vorun

look at WebViewDemo

On Nov 23, 1:08 pm, "David Orriss Jr" <[EMAIL PROTECTED]> wrote:
> Hi,
>
> I have an app using the WebKit that I'm developing.  In my onCreate()
> method I'm loading my page:
>
>                 browser = (WebView) findViewById(R.id.webkit);
>                 browser.getSettings().setJavaScriptEnabled(true);
>                 browser.loadUrl("file:///android_asset/mystuff.html");
>
> However, this fires off when the keyboard is popped out.  What do I
> need to do in order to have the browser only load on the initial start
> of the app and not do a complete reload of the page when the
> orientation is changed?
>
> --
> David Orriss Jr.
>
> My blog:http://www.codethought.com/blog

--~--~-~--~~~---~--~~
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
[EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
-~--~~~~--~~--~--~---