Community Questions & Answers
Image visible= false/true savedata
I work in Android. I have a button. When I press the button the image changes from visible / not visible. I can save the configuration as (visible / not visible)? (if I close the application I want to be saved) I have worked with sqlite databse, but do...
How to change the button image when selected and deselected
So basically I have buttons that have the same image when the window is accessed. When one of the buttons is clicked, the button changes image. What I would like to happen is once a different button is clicked, the previous button that is clicked should go...
image property in Button
Hi ! What is this image property in Button ? Doc says "the image to display on the button to the left of the title". It seems to be different from backgroundImage and it would be great. But when I set it to an image path, my button disappear.
button in left side of iPhone
how to get a button to go into the left hand side of the iPhone. Looking for the information for newest OS version. This will be just for iPhone/ iPod. Don't know my SDK version so sorry. I am using the iPhone simulator for testing my app. Also I am using...
How to insert a Button under a ListView with Alloy?
How to insert a Button under a ListView with alloy? The following doesn't work ~~~ <Alloy> <Window title="Match details"> <ListView id="list_matches_details"> <View> <Button>My...
Font outline or shadow?
I need to make my text stand out a little more on top of pictures. Is there a way to add shadows/glow/ or an outline to a buttons text or label?
Changing labels on button click
I am trying to have the label change in the same position depending on the button that is clicked. For example, when my monday button is clicked, the monday label will appear, if the tuesday button is clicked, the monday label disappears and the tuesday...
Buttons Preventing ScrollableView Scrolling & Views Won't Hold Variables
- Application type: mobile - Titanium SDK: 3.0.0.GA - Platform & version: iOS 6.1 - Device: iOS simulator - Host Operating System: OSX 10.8.3 - Titanium Studio: CLI 3.1.0 My problem is that I have a ScrollableView filled with buttons that won't...
the content of my window doesn't appear
Hi every body i have a problem which i will try to explain it as possible as i can ! i create a button which take me to another window but when i click the button the window oppen but its content doesn't appear i dn't know where is the problem because...
How to ignore transparent pixels on touch
Is there a way to ignore the transparent pixels of view / imageView / button when it's touched and them keeps the event propagation? Because I'm build one app that has a ScrollableView and above it a button non rectangular, so that the user can go to the...
Cascaded images Zindex position not working
i have some buttons which are cascaded horizontally.if i click any button,that button should come on top between other buttons(zoom effect). can any body please suggest me how to get this effect..here is my code.. ~~~ var win =...
How to check longpress on button if its still onpressed (in Alloy)
I created a rotate function and add a control plus (+) and a minus (-) button to rotate left or right. ~~~ <View id="rotateViewContainer"> <Button id="rotateLeftButton" onClick="doRotateLeft"...
Button on a tableViewRow
Hi Everyone, I am creating a button and adding to a tableViewRow. I have many rows in my tableView. the button is invisible first which I did by making : ~~~ visible: false ~~~ When I click on a row the button should be visible. I am doing it as...
How change (visible: false -> visible:true) with the button?
hello. How change (visible: false -> visible:true) with the button? var webview = Titanium.UI.createWebView({ url:'http://google.com/', visible: false }); botonnavegador.addEventListener('click', function(e){ ?????????????????????}); thanks
Android 2 row button title possible?
Is it possible to add a 2 row button title on Android? In Iphone I added 2 labels as subviews, well I know in Android it isn't possible So how can I get arround that? I tried the \n\r trick doesn't do nothing... It just wordwraps at the button...
Button Transparency
Anyone know how to make a button WITH and image obey the alpha channel stuff for transparency? I thought this would work, but it doesn't. If I load sample.png into Photoshop, you can see the transparency layer is in fact there. I am placing my button...
Up-Side-Down Button?
Hell there I am trying to make an up-side-down button. A picture(in link) shows what I mean. http://usandfriends.homenet.org/OTHER/CapturAe.PNG
Button executes eventListener from it's row
Hello readers, I've created a tableview which (of course) has rows. These rows have label, a button and a 'click' eventListener. When the row has been clicked it should open a window, when the button has been clicked, it should delete it's data from the...
Tableview swipe to delete
Hi guys, I know that in tableview view, if i set the editable to be true, i can swipe the row i want to delete and the delete button will appear. But now, I want to know if I can add other button when i swipe? For example, when i swipe the row, instead...
Left side for button
How do you make a button go into the left hand corner at the top of the screen
Open Window after clicking button
Hi there, I have an application with a main window. When clicking on a button in the title bar, a second Window should open. MainWindow.js ~~~ function MainWindow() { var self =...
Android Hardware Back Button
Hi...!!! I am working on app which has lots of navigation from one window to another and that too in Tabs.. What I am doing is on 1 tab I am opening a window which has got a tableview inside of it.. And on clicking of a row in that tableview we are closing...
createButton stretches backgroundImage in iPad project
Hello, in my iPhone/iPad project I've some buttons created this way: ~~~ var homeBtn = Ti.UI.createButton({ top:'25%', left:'1%', title:" ", backgroundImage:'/graphics/Home_off.png', backgroundSelectedImage:'/graphics/Home_on.png', ...
Issue with navigation Back button press action
created button in window.js ~~~ var btn_back =Ti.UI.createButton({ height:30, width:53, backgroundImage:'images/back@2x.png', backgroundSelectedImage:'images/backSelected@2x.png' }); ~~~ add left side button to the navigation bar for the...
Back Button Image not showing
I've got the below: ~~~ this.button.addEventListener('click', function(e) { var tutorial = Ti.UI.createWindow({ url : 'ui/tutorial.js', backgroundImage : 'bg.png', title : 'Tutorial', barImage : 'navbar.png', _parent:...
AlertDialog with textfield in it? possible?
Can I create a AlertDialog with a textfield in it? I don't want to be able to submit if the textfield doesn't have something written in it.. The dialog must have Ok and Cancel buttons as well
Removing button from tableviewrow
I've recently been updating an app of mine for iPhone 5 while also adding new features, and I've noticed a bug has emerged that wasn't there. I currently have tableviews that, when a row is swiped, a button is added. If the button is clicked, or the row...
Creating a glossy type button to work in android and IOS
hi all i'm very new to tss i had done some coding to create a glossy buttons for my apps with reference to css3 glossy buttons but i got stuck how to add padding and shadows to my button plz help me out
"Back" button in title bar?
How would I generate a button in a new window's title bar with the "Back" arrow-alike aesthetic?
Animation stops on iPhone app resume
Hi, I use this function to move some imageView in my iPhone app: ~~~ function startImageViewAnimation() { var m = require("ui/common/moveTo"); var platformHeight = Ti.Platform.displayCaps.platformHeight; m.moveTo({ view :...
Animations
Hi all i'm new to mobile development kindly share me tutorials/videos of animation module or properties used in titanium studio. As i'm beginner to mobile development kindly share me tutorials/videos with examples it would be grateful........
browsing file to from webview android
i created a webview in the app. and in the HTML page i used a form to upload pics from android devices to the server. if i use the default device browser, it works great, i can browse from the gallery, select and upload any pics but if i open the same page...
Button Event
if i make a loop to create group of buttons like that:- `for(var i=0;i<5;i++){ var button = Titanium.UI.createButton({ ..... }) } ` I want to know each button the user clicked ,but after creating the...
Legal to Use Custom Image for a Button in the LeftNavButton of a ToolBar?
Hi all- I have the below: ~~~ <NavigationGroup> <Window title='Test'> <LeftNavButton> <Button id='myButton' /> </LeftNavButton> </Window> </NavigationGroup> ~~~ Within my Alloy .tss file, I...
Nine-patch image can't work
Android API: 4.1 x86 Titanium SDK: 3.1.0GA View: ~~~ <Button id="testBtn"/> ~~~ Tss: ~~~ "#testBtn": { backgroundImage: '/images/custom-slider-right.png', backgroundSelectedImage:'/images/custom-slider-left.png', ...
Button inside TableViewRow. How to get row.index
Hi, I have a button inside a TableViewRow and would like to get the row index when I click on that button. When I print out "e.source.parent" inside the button-click event I'll end up with "Ti.UI.TableViewRow" which should be right....
Autowidth of a button
I use this code to assign a title to a button and automatically adjust its width ~~~ var btn=Ti.UI.createButton( { title:'text', width:Ti.UI.SIZE }); ~~~ when I do this code, the button grows horizontally to fit the new text ~~~ btn.setTitle('a...
How to create Radio-Button, Checkbox and Textfield in Android-App
Anybody any idea, how i can create radio-buttons, checkboxes, Textfields for a survey-app in android? I've try it with webview and html-code but it's not a great solution :(
syntax error unexpected token ":" and "height"
var Stores= Titanium.UI.createButton({ title:"Stores", width:"25%", height:"10%", bottom:"24%", left:"34%", id:"stores" }) whats wrong
Android drawable icon button image
On the View: ~~~ <View> <Button class="folderBtn" /> ... ~~~ On the style: ~~~ ".folderBtn": { backgroundImage: Ti.Android.R.drawable.ic_menu_archive } ~~~ But this does not work, the button come with no image. If I use...
Animate a map with a button!
Hi! Can someone explain me why this code i wrote do not work? When i press the buttom... the map would go down from 200 to 300 in 1 sec, but the code give me an error in the part "tView.animate(anim);" ~~~ var win = Ti.UI.createWindow({title :...
Android Windows Dont Animate
when my button get clicked, then is executed this code: ~~~ but_iniciar.addEventListener('click',function(e) { var win = Ti.UI.createWindow({ url:"home.js" }); win.open({animated:true}); }) ~~~ but the problem is that the...
Certain images crash titanium when used as a backgroundImage
My designer provided me with the following two png images: http://forums.askmrrobot.com/images/button-refresh.png http://forums.askmrrobot.com/images/button-load.png If I set the first image as the backgroundImage of a view, it works just fine. If I...
Hiding and Showing Buttons on a Toolbar with Alloy
Is there a way to hide and show buttons on a toolbar with Alloy? I have a Toolbar as such which is placed on index.xml, under a ScrollableView: ~~~ <Toolbar layout='horizontal'> <Button id='b1'>B1</Button> <Button...
Does Alloy Buttongrid Use Density Specific Folders for Android?
Wondering if the buttongrid image gathering from id will use the high/medium/low folder set up like the rest of Titanium? The buttongrid documentation seems to be pretty specific on where it wants the image to be: The ButtonGrid expects to find the image...
Debugging the backgroundColor Property of a Button - Not Showing Through
Hi all- I have an Alloy Button: ~~~ <Button id='login'>Login</Button> ~~~ That is styled as such ~~~ '#login': { backgroundColor: '#0098db', borderRadius: 5, color: '#8F9191', top: 150, height: 35, width: 300, font: { ...
Setting a Button's Font Properties with Alloy Styles
How can I set the font properties of a button using Alloy styles? I am trying the below, but the styles do not apply to the button (as they do in the Label control). Is this also possible inline within the button control, and if so, how so? Thanks in...
How to Increase the speed of the app within?
Currently my code is running perfectly, except for the fact that it is very slow. Can I know how or what can I do in order to increase the speed of the app? Also my home button is slowest of them all, please help me. ~~~ var url = "working...
Android: Uncaught type error:cannot call method open of null
Hi all, i have a problem in my app everytime i click a button to open another window it doesn't work and i get this message " Uncaught type Error: cannot call method 'open'of null" Please can someone help to resolve this Thanks for all the...
Button touch area
Hi all, Using newest titanium and alloy. Im having a problem with a simple button, after clicking on the button 6-7 times it stops reacting. Its simply "sleeps" the click event for a couple of seconds and then i can click again. Anybody else...