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 : Buttons and edit Text repeated in listView
OpenGL ES rotate model in 3 axis
How to use SimpleAdapter.ViewBinder?
Android server-client application session issue
Android: corrupted TextView using .setShader()
Button on top of a Button with different Listeners [duplicate]
Android connect using WPS
Change View height on state selected
How can I optimize my BitmapTextureAtlas in AndEngine?
Working with images (playing cards)
ScrollView Android
How to make a sidebar menu
Always Errors in Android Kernel on Debian Sid
NullPointerException when i do insert into database (android)
Can i skip the first activity?
Activity Access Restriction Implementation in a Monodroid Application

Categories

HOME
azure-stream-analytics
gridview
wakanda
datastore
oracle-apex-5
socket.io
vscode-extensions
r-googlesheets
pdfbox
square
elasticsearch-5
rcloud
text-mining
x-cart
http-post
oledb
replication
ios10.2
flask-sqlalchemy
monit
jquery-callback
windows-server-2003
carrierwave
testcomplete
finagle
scatter3d
powershell-ise
playstation-portable
spring-security4
instantiation
indy10
arduino-ide
slacktextviewcontroller
baidu-map
processwire
searchkit
magento-1.9.2.4
datacachefactory
contract
term
trojan
zenhub
magic-draw
amq
custom-font
sundials
arules
rackspace-cloud
ampps
simplepie
flex-monkey
envi
async.js
nio2
sapi
ess
opserver
mod-proxy
lasso
airbrake
telepat
cross-join
at-job
codeplex
live555
functional-java
synapse
openargs
android-usb
gd-graph
code-duplication
nevron
font-awesome-4.0.0
device-width
sentestingkit
exponentiation
mbeans
presentation-layer
squishit
vs-android
office-2007
openfaces
request-headers
django-piston
silverlight-oob
wcf-instancing
google-wave
fdf
sqlobject
httpcookie
pbcopy

Resources

Mobile Apps Dev
Database Users
javascript
java
csharp
php
android
MS Developer
developer works
python
ios
c
html
jquery
RDBMS discuss
Cloud Virtualization
Database Dev&Adm
javascript
java
csharp
php
python
android
jquery
ruby
ios
html
Mobile App
Mobile App
Mobile App