Community Questions & Answers
Android splash screen orientation landscape
I cant seem to get my splash screen to automatically lock to 'landscape' as soon as my app window loads it corrects it orientation, but I cant get it to lock its orientation when the splash screen shows. I have tried many many different things, changing...
Changing font size of label when switching orientation
What's the easiest way to change the font size when switching orientation? I'd like to maintain a layout when switching...
orientationchange not working on android (Alloy)
I have a simple app which opens a new window when oriantation changes using Alloy. It works fine on my iPhone test device. On my android phone it doesn't work. It worked fine on both phones before i switched to Alloy. What seems to be the problem? Maybe a...
orientationModes not working on iPhone
iPhone, SDK 2.1.4.GA I have an app that allows Landscape and Portrait orientations but I want to open a windows that allows only Landscape orientation so I did: ~~~ createWindow = function () { generalWindow =...
Null pointer Exception on Orientation Change
Hi, On Orientation Change a force close occurs in Android and getting a null pointer Exception in log. The gesture orientaion change event works well for iphone /ipad & in case of Android it crashes. Kindly help out how to handle orientation change in...
Fix orientation as portrait in android with Tabgroup
Hi, I am creating an app in which I am using tabgroup. my app supports only portrait mode. I have tried to fix orientation using tiapp.xml file and windows orientation property. but nothing works for me. I am able to fix orientation with custom android...
Ti.Gesture is undefined
When i move one of my views from Resources/Views to Resources/iPhone/views I get the following error. 'undefined' is not an object (evaluating 'Ti.Gesture.addEventListener') It does not make sense to me. BEfore the move, the app runs fine on both...
How do I lock an Alloy app to a portrait orientation?
I have removed the landscape orientation properties in Tiapp.xml like so: ~~~ <orientations device="ipad"> <orientation>Ti.UI.PORTRAIT</orientation> ...
Changing view layouts with orientation change in Alloy
Hi, I would like to define separate layout XML for portrait and landscape. Based on the screen orientation, Appcelerator should load the corresponding layout XML and the TSS file. Our target SDK is 3.1.0GA and Alloy 1.1.1. Is this possible in...
My application rotate by 180° on launch
Hello ! I have a big issue with my application. When i launch my app, the splash screen is returned by 180° and the IOS simulator rotate too. I've tried lot of thing like modifiy my xml ~~~ <iphone> <orientations...
Android force orientation
Not really a question, but a note to other users. I've seen some posts asking how to force an app into landscape only or portrait only, but the answers there weren't working for me. I finally got it working, so I thought I would post how I did...
android app for portrait only
Hi, I want to make my app working for portrait mode only. i added this in tiapp.xml in android balise ~~~~~~ <application> <activity android:configChanges="keyboardHidden|orientation" ...
Alloy: splitView, positioning elements and orientationChange
Hi I work on an Alloy project under MacOs 10.8.x and use Titanium Studio 3.1.0 with SDK 3.1.0.GA. I use a splitView within a Tab and have problems positioning elements not only but especially when an orientation change event is happening. To demonstrate...
How do you change Label orientation?
I am using Titanium Alloy 3.0.2. I have a layout where the orientation of a few of the labels (these can be uneditable text fields) need to read from bottom to top. All other visual elements have standard orientation reading from left to right, so I am...
Device orientation does not reflect scrollview content resizing.
I have scrollview resize problem when device orientation changed. Check the code which I use for scrollView and orientation: function CreateLibraryControl(){ var libraryView = Titanium.UI.createWindow(root.combine($$.flexibleWindow, { title:...
Admob Integration
Please can any one help in how should I handle the orientation changes for "Admob" ads in my Android & iOS app so that It works well for both Portrait & Landscape modes.. Thanks...!!! :-)
Splashscreen appears as background in landscape mode
Hi, on my Android app, I've got a custom splashscreen (ie I have replaced default.png with my own image). It displays fine in portrait mode, disappears and the window in app.js appears. However if I rotate the device to landscape mode, the splash screen...
Android - Lock camera overlay to portrait
Is there any way to lock the camera overlay to portrait mode? My overlay is locked to landscape by default but I need to lock it to portrait. ~~~ var cameraOverlay = Ti.UI.createView(); var cameraButton = Ti.UI.createButton({ title:"Take...
Vimeo iframe - switch to landscape
Hi, I have a webview in portrait mode containing a vimeo iframe. When playing the video che player DOES NOT switch to landscape. Any idea how to force landscape when playing a vimeo clip from a webview, starting from from portrait mode? thank you!
When user want to change orientation of phone, my application show incorrect UI. Android
When user want to change orientation of phone, my application show incorrect UI. Phone OS: Android Titanium SDK: 3.0.2.GA My bug on video: http://www.youtube.com/watch?v=S0Yi-6ZKDcw ~~~ // create main app screen function ApplicationWindow() { var...
Forcing portrait on a window then opening an alertdialog in landscape will result in your window allowed to rotate to landscape
Hi, I had the same problem as issue #11213: https://jira.appcelerator.org/browse/TIMOB-11213?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel The issue seems like it is closed; however, I could not apply it to my app. Titanium 3.0.2 SDK,...
How to force a re-layout of an Alloy based screen
I am using Titanium 3.02 and Alloy 1.0 to create an iOS app. Most of the app is in portrait orientation but I have one window that is in landscape. When I open the landscape window everything works as expected but when i close the landscape window to...
forcing orientation doesnt work when you launch the app in a different orientation
Hi, I was able to force my app to portrait orientation after changing tiapp.xml and making some code changes. Everything seems to be working fine except for one case where I hold my phone in landscape mode and launch the app. in this case the app will...
Emulator 1280x800 orientation modes confusion
I am trying to run my app on a 1280x800 Emulator. The problem is that when I run it with `orientationModes : [Titanium.UI.PORTRAIT]` it runs in Landscape but with `Titanium.UI.LANDSCAPE_LEFT`, it runs in portrait. Could anyone please help me if this...
App orientation only in portrait mode
hello i start learning titanium studio and i create one demo project and in this app i want orientation only portrait mode please give me reply thanks in advance
Get orientation on load
Hello, I have some functions to run once my orientation changes, so I've made a: ~~~ Ti.Gesture.addEventListener('orientationchange', function(e){ // blablabla }); ~~~ However, I also want to run that through on application startup, so I've made the...
Image orientation issue with certain devices.
Hi, I am trying to display an image thumbnail inside a wrapper view in order to achieve an effect similar to this view. Black color is the border around image.  So i create a imageview inside a...
Getting force close in landscape mode by pressing a button
I have an application which shows a list of items in runtime,and by pressing a button the user can delete the checked item,in the portrait mode all the things work well but when I switch to landscape mode when the number of rows are more than 3 ,pressing...
Orientation mode as landscape for only one screen - iPhone
Hi all, Im developing an application which is compatible for iPhone. I'm navigating between 4 views. 1st View (Portrait) ---> 2nd View (Landscape) --> 3rd View (Portrait) ---> 4th View (Portrait) SO I have 3 Portrait views in my application and...
Disable Android landscape Mode
Hi everybody, I'm using both 1.5.1 and 1.6.0 (nightly build) versions to test my applications on Mac OS X. I'm trying to force my Android app to disable the landscape mode in : /build/android/AndroidManifest.xml by putting this instruction...
how to set the orientation
i have a app with tabs in Tiapp.xml i have ~~~ <iphone> <orientations device="iphone"> <orientation>Ti.UI.PORTRAIT</orientation> </orientations> <orientations...
Detecting Orientation change to make changes in UI
Hi Everyone, I have read a lot of posts about orientation changes, that how to detect orientation change etc. Like : ~~~ Ti.Gesture.addEventListener('orientationchange', function(e){ if(e.landscape === true){ // do something } }); ~~~ That I used if...
Android orientation change restart bug is back with SDK 3.0
Looks like the "android orientation change bug" is back. It was fixed in 2.1 but right now every time I change the orientation the app restarts on android. Somebody have a solution for the behavior? [Android: Application restarts when...
Orientation in option dialog
How to dismiss option dialog through coding during orientation. Because it is affecting the view if using default close during orientation iphone? Give me simple example
Status bar - differing position on iOS 5 and 6 - how to detect?
Hi I have a simple problem - when turning my app to landscape orientation, it resizes to the new width. In iOS 5 the status bar shifts to the top (in landscape). In iOS 6 however, the status bar stays where it was in portrait. This creates a difference in...
Can't lock video orientation on ios 6
1. Application type: mobile 2. Titanium SDK: 3.0.0 GA 3. Platform & version: iOS 6 4. Device: iOS simulator and physical device model - iPod touch and iPhone 5. Host Operating System: OSX 10.7.4 6. Titanium Studio: v3.0.1.201212181159 I am launching a...
IOS 6 Video player / window / orientation / ....... bug ?
I have a problem with video player/window orientation that I can't fix in IOS 6, it works fine in IOS 5. I have a window #1 locked in PORTRAIT MODE. From this window1 I open a new window #2 that I locked in LANDSCAPE MODE containing a video player with...
android splash screen orientation
Hi guys i want my android app splash screen to be shown only in potrait orientation but dont know how to do that need help with that
Android orientationModes problem issue
hello, i have problem with orientation modes, on Android devices (apple devices are all fine), im using Titanium SDK 2.1.4 GA. I have tried many things, even setting modes separately ~~~ win.orientationModes = [Ti.UI.PORTRAIT]; ~~~ but its not working,...
Splash screen appears during orientation change
Hi all, I've got an app supporting orientation changes fine. But occasionally (not always), the splash screen will appear during the orientation change before the app has a chance to scale and reposition the UI elements. It looks like its the result of a...
Orientation change GUI problem
hello i am developing an application using titanium. its almost complete. my problem is that its working very fine in portrait mode but in landscape mode its GUI is doing problem. i am giving top,left,height,width etc of elements according to the size of...
Lock splash orientation for android
sorry, I had search some question, but I still can't try out success. My platform is android, titanium sdk version is 2.1.3.v20120915120319. I had change code in my AndroidManifest.xml in my platform folder. ~~~ <!-- TI_APPLICATION...
iOS 6 Navbar and status bar overlapping
Hi, I am getting this error http://stackoverflow.com/questions/12567233/modal-dismissals-do-not-account-for-status-bar-new-ios-6-issue I want to orientation only in few windows (not all windows). So, I am managing like this. ~~~ var orientationChange =...
Supporting Oriention change on Alloy
I have noticed that Alloy just copy the styles into any created views, however, if I need to change the view's style after an orientation update event, I don't have any way to reach these styles. Is there any way to support it withing the styles folder...
app.js 'flips' it's orientation on load
I've set the orientation to landscape right using tiapp.xml, and every window/view behaves just fine except app.js, which 'flips' it's orientation to landscape right on it's initial load, which looks very unprofessional. How can I prevent...
SplitView Orientationchange issue for iPad in MasterWindow
I'm working on getting this code to work properly on the iPad from Screencasts.org tutorial: http://screencasts.org/episodes/ipad-app-javascript-using-titanium So far I've got everything working as it should except one issue. In the MasterWindow,...
Shake also Triggers Orientationchange
Hi All, This is strange: next function also Triggers when you shake the device, iPad 1, SDK is 1.7.5 Only when you test on the device, not in the emulator, anyone an idea? best Bob ~~~ Ti.Gesture.addEventListener('orientationchange',function(e) { ...
iPad rearranges my camera overaly view although I use only portrait mode.
Nothing special in this code: ~~~ var cameraOverlayView = createView(); // method that creates view //I am in simulator if(isInSimulator) { var simulationWindow = Titanium.UI.createWindow(); simulationWindow.add(cameraOverlayView); ...
Android orientation in tiapp.xml
Any way of locking android only to portrait mode in tiapp.xml I would like to avoid using separate android manifest xml file
How to add orientationModes for a window when using Alloy xml view
How do I add orientationModes for a window when using Alloy? ------------ I tried the following but it doesn't work: ~~~ <Window id="win" onOrientationchange="doSomething" orientationModes="[ Ti.UI.LANDSCAPE_LEFT, ...