android


How to use saved instance state and restore instance state?


I have an application with a tab activity. The activity hosts 2 activities with a list of items. I have implemented checkboxes to each of the items also. On orientation change, I have set the tab activity to be oriented to the left hand side of the screen. ie. the tab activity and the child activity are recreated. If i press the menu button to display the check boxes and checks a few items and if the orientation is changed, the checked items will not be shown in the check boxes. I handled the display of checkboxes while orientation change using the SharedPreferences.
I am putting the checked items to an arraylist. the arraylist cannot be transacted through the SharedPrefereces.
I want the checked items to remain checked on orientation change.
Does anyone have any clue?
You may store this arraylist in the host Activity through a interface like this: Custom event listener on Android app . But if there aren't so many checkboxes I would divide arraylist into simple kay-value preferences and store them as a Shared Preferences.

Related Links

Issue with SAXparser
To post a photo in Twitter in android in a button click ? [closed]
How can i use iterator to get each data from arraylist of hashmaps in android?
Android MediaPlayer.getCurrentPosition not updating
How to Create Live Wallpaper container?
Send new URL to Chrome in Android while using Chrome Remote Debugging
Getting Static Map From Google Maps - Do I have a memory leak?
How do i use and set custom listview adapter within a Thread?
Displaying data from DB in a table. Android
Correct way to using fragments in another fragment in Android
Get the Sender Auth Token for GCM in android
How to implement AddTextChangedListener on a Custom ListView (BaseAdapter)
The way to access sdcard files without relation to file name in Android application
Can't Solve the Error - View requires API level 14 (current min is 8): <GridLayout>
How can I use “AND” and “OR” in SQLiteDatabase.delete(…) method?
Universal Android application for tablet and mobile

Categories

HOME
oracle12c
gdb
apache-flink
apache-jena
webdriver
gpu
package
graphics
can
nuget
r-googlesheets
static-site
tivoli
soa
aws-cli
big-o
babeljs
pearson-correlation
code-coverage
lanczos
elasticsearch-5
categorical-data
comsol
flash-player
qsqlquery
parameter-passing
feathersjs
template-engine
git-extensions
imessage
sigma.js
gmm
swagger-2.0
ember-cli
gmock
game-theory
froala
syntax-highlighting
asymptotic-complexity
sinch
autodesk-designautomation
git-squash
rselenium
openwhisk
nested-lists
pdw-file-browser
batching
roblox
magento-1.9.2.4
modernizr
bc
jvmti
signals-slots
doc
glm-math
smoothstate.js
apollostack
berkeley-db-je
launchctl
carrot2
arq
avx
arules
custom-lists
ziparchive
pacemaker
i386
swizzling
freepbx
ikiwiki
iokit
r-package
vigenere
jdi
branch-and-bound
omnifaces
teamcity-9.1
snackbar
qtwebengine
adehabitathr
device-tree
linkedin-jsapi
ss7
ray
asdf
process-explorer
poker
onload-event
dopostback
onmousemove
boost-msm
xcode3.2
cakephp-1.2
box2d-iphone
landscape-portrait
fsevents
lr
mathematical-notation
httpcookie
xslcompiledtransform
wspbuilder

Resources

Database Users
RDBMS discuss
Database Dev&Adm
javascript
java
csharp
php
android
javascript
java
csharp
php
python
android
jquery
ruby
ios
html
Mobile App
Mobile App
Mobile App