Reputation: 19081
I am developing a web-based Android application using PhoneGap
and Eclipse IDE
on Windows.
My development's scope is limited to Tablets. More specifically to the Samsung Galaxy Tab 10.1.
So basically, I develop on Eclipse, and test the app on the Tablet using Eclipse's Run command.
Everything works great until i rotate the Tablet. The app crashes.
Therefore I cannot test my CSS
media queries during this dev phase.
Is there a way to circumvent or fix this behavior ?
(other than testing the app in Portrait mode, then close it to test it in landscape mode)
Note: Using the Android Emulator on Windows is NOT an option.
Phonegap 1.4
Android 3.2
Eclipse IDE for JavaScript Web Developers ( Indigo Service Release 1 )
Here is my app's Log, starting from the moment i rotate the Tablet.
Upvotes: 0
Views: 547
Reputation: 3099
And ensure you're building on at least an 4.0 Android SDK otherwise "screenSize" will flag as an error!
Upvotes: 0
Reputation: 484
I am wondering what your manifest file looks like. Of the manifest is not your problem, its probably in the assets either your css or js
Do you have: android:resizeable="true"
Here is the relevant parts of my manifest that may help:
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
<activity android:name="com.phonegap.DroidGap" android:label="@string/app_name"
android:configChanges="orientation|keyboardHidden">
<intent-filter>
</intent-filter>
I hope this helps...
Upvotes: 0
Reputation: 23273
Try adding this:
android:configChanges="orientation|screenSize|keyboardHidden"
as your config change parameter in your apps AndroidManifest.xml to see if it fixes your issue.
I have a Samsung Tab 10.1 and if you don't have the proper configuration changes setup in your manifest your whole app will be reloaded on conf change.
Upvotes: 2