Android Question Prevent reload webview

Blue.Sky

Active Member
Licensed User
Longtime User
Hi
I wrote payment getway that show in webview
In rotation activity,webview reload url
Can i prevent reload url and show previous webview data?(without disable rotation)
 

stevel05

Expert
Licensed User
Longtime User
As with all views, the Webview will be destroyed when the device is rotated, so the only options are to reload the data, or prevent the rotation. That's the way Android works.

It's possible that the page may be (or could be) cached within the browser (webview) depending on the page configuration, but it would still need to be reloaded.
 
Upvote 0

eurojam

Well-Known Member
Licensed User
Longtime User
you can also force your app to be in only one mode (portrait or landscape), then there will be no reloading at all...
 
Upvote 0

Blue.Sky

Active Member
Licensed User
Longtime User
But i had see app that not reload webview when rotation
 
Upvote 0

Blue.Sky

Active Member
Licensed User
Longtime User
you can also force your app to be in only one mode (portrait or landscape), then there will be no reloading at all...
I know but i wouldn't use it
 
Upvote 0

stevel05

Expert
Licensed User
Longtime User
But i had see app that not reload webview when rotation

Are you sure? It can be very quick, try the attached project. I can see a transform on my Nexus 7 as it fades out and then in, but on my Sony Experia you couldn't tell that it reloads.
 

Attachments

  • wvrottest.zip
    6.6 KB · Views: 301
Upvote 0

Blue.Sky

Active Member
Licensed User
Longtime User
Are you sure? It can be very quick, try the attached project. I can see a transform on my Nexus 7 as it fades out and then in, but on my Sony Experia you couldn't tell that it reloads.
Yeh i sure
 
Upvote 0

stevel05

Expert
Licensed User
Longtime User
What is the app that doesn't reload?
 
Upvote 0

Similar Threads

Cookies are required to use this site. You must accept them to continue using the site. Learn more…