android


1 Activity, 2 Fragments and setting orientation


I have an Activity where the 1st Fragment (whose orientation is locked) solicits input from a user. This data is used to determine how to orient the 2nd Fragment. This orientation will also be locked.
I am guessing I will have to make a call to setRequestedOrientation( ActivityInfo.SCREEN_ORIENTATION_PORTRAIT) either from the Activity or the 2nd Fragment.
My question is where best to do this. Does it really make a difference? Can this action be performed w/o undergoing an Activity restart?
If changing the setRequestedOrientation state requires the screen to rotate then it will restart the activity.
For example if you request ActivityInfo.SCREEN_ORIENTATION_PORTRAIT while the screen is in landscape, it will restart.
However it will not restart if the phone is already in that orientation.

Related Links

Android xml nullpointer exception xml parser
Application wide background
Crash upon screen being unlocked
Swapping Screens in Android with Button Click
IntelliJ 12 + ActionBarSherlock setttings: Could not find class 'android.support.v4.app.FragmentActivity'
align a table in different layouts?
Asynchtask with splashScreen
Position of android emulator with windows panel on the top of the screen
How to get Weekly Weather forecast from yahoo API
perform query on database for array of words
Use Youtube api player with android fragment
Cannot notifyDataSetChanged() on an opened Spinner
Bluetooth File transfer on Android(even restricted types)
Change of Data in a ListView in Android
Navigation Type (Fixed Tabs + Swipe)
PySide QML project on android

Categories

HOME
localization
twig
hessian
entity-framework-core
3d-reconstruction
hpc
x264
mapbox
character
special-characters
vimdiff
text-mining
heat
parameter-passing
screen-readers
standards
easyphp
identity-management
boost-icl
charles
microsoft-ocr
user-experience
imagemap
highstock
android-sharedpreferences
nstimer
wcag
iis-express
boost-asio
send
anki
left-join
turfjs
jbutton
rselenium
slacktextviewcontroller
dm-script
diacritics
demo
skylink
apriori
softmax
http-request
xmldocument
memory-mapping
procfile
jide
hammer.js
insight
google-cse
aquamacs
compiler-design
css-transforms
d3-force-directed
swingworker
slackware
pure-css
jquery-jscrollpane
refinerycms
grass
phpgrid
file-move
page.js
cgi-bin
doctype
evolus-pencil
eoferror
wso2greg
rdflib
fail2ban
exceldatareader
infosphere-spl
variadic-templates
cosine-similarity
teaspoon
imagefilter
menubar
mysql-error-1044
observium
dolby-audio-api
diem
mantle
intersect
subgraph
thttpd
apache-whirr
apache-commons-dbutils
automationelement
svk
diagrams
luajava
hbm2java
folding
pos-for-.net
cuda.net
movieplayer
netbeans6.1

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