titanium

what are the best Practices for developing applications using Titanium Framework targeting iPhone & Android?

依然范特西╮ 提交于 2019-12-05 02:27:19
问题 I am planning to develop an application using Titanium Framework for iPhone and Android. Can someone list the best practices, do's and don'ts for the development using your experience with the framework? 回答1: this is more of a tip then anything but so far my favorite function has been the tt.os in tweetanium that handles passing of vars of functions to the correct platform. and an example of how they use it 回答2: First of all, there's the Appcelerator guide on Titanium's best practices: https:

Xcode duplicate symbol _main

孤街浪徒 提交于 2019-12-05 01:28:33
I'm getting the following error in Xcode 3.2.1 on Snow Leopard 10.6.2 whenever I try to compile any iPhone application generated by Appcelerator Titanium. However, the build error only appears when I select iPhone simulator on the architecture menu and if I select the iPhone device, I am able to run the app on my device . Further more, the iPhone simulator launches successfully and executes the program directly from the Titanium environment which uses Xcode to build . Why is this happening ? ld: duplicate symbol _main in Resources/libTitanium.a(main.o) and /Users/prithviraj/Documents/project

Back button exits application in android using appcelerator titanium

微笑、不失礼 提交于 2019-12-04 23:44:47
问题 I am new to Titanium Development. In Native android if we press back button only current activity will be closed and it will go back to the previous activity but when I press the back button in Android using Titanium it exits from the application. How can I change this behaviour? 回答1: There are two types of windows like, lightweight and heavyweight. If you create a lightweight window in Titanium android than on back button press it will exist from your application. You can achieve what you

Keyboard shortcuts for Titanium IDE in MAC

瘦欲@ 提交于 2019-12-04 21:48:39
I'm new to appcelerator titanium IDE, previously I was working on Xcode. In xcode I'm relied on the keyboard shortcuts for saving my coding time. Now I'm struggling with titanium, because I don't know any keyboard shortcuts in titanium IDE. In Xcode commenting a block of code ( cmd+\ ), shifting them to left( cmd+} ) or right( cmd+{ ) was very easy. In titanium now I'm manually doing it for each line of code ! Can anybody help me to find the shortcuts for titanium IDE in MAC ? If this is not the right place to ask this question. please pardon me Midhun, Titanium IDE is just same as Eclipse IDE

navigate between multiple windows in titanium

本小妞迷上赌 提交于 2019-12-04 17:24:58
Let's assume I have 3 files Window1.js , Window2.js and Window3.js . I can navigate from Window1 to Window2 and from Window2 to Window3 with no problem. When I want to come back from window3 to window2 I do: window3.close(); Now I'm on window2 and want to go back to window1, so I did: window2.close(); . But instead that got my back to window3 not to window1 as I wanted. Is there any way to get back to window1? Can someone explain me how to navigate between this windows in titanium?Thanks have a look at this: the wiki provides a cool video with example code . maybe you can provide some could to

how to live view in Titanium?

白昼怎懂夜的黑 提交于 2019-12-04 17:21:30
My team have been developing Titanium in the past few months, and now we are facing a problem: when we make changes on the View code(change its font, its background or size) , it takes a long time ( about 1 minute ) until we see the result displayed on device. that is really a big waste of time. I saw the TiShadow already, it's great, but it only support js code( like Alloy.createTableList... ), doesn't support the Alloy XML( I mean you can't see your changes displayed on the screen once change the .xml or .tss file ) I also checked 'forgedUI', but unfortunately it's just an UI design tool,

appcelerator titanium: Creating a new file

醉酒当歌 提交于 2019-12-04 15:28:22
How to create a new file in appcelerator titanium. var Settings = Titanium.Filesystem.getFile(Titanium.Filesystem.tempDirectory,'Settings'); Ti.API.info("Created Settings: " + Settings.createDirectory()); Ti.API.info('Settings ' + Settings); var newFile = Titanium.Filesystem.getFile(Settings.nativePath,'Settings.txt'); newFile.write('line 1\n'); Ti.API.info('newfile: '+newFile.read()); The Above code is not working... Try creating the file before writing to the file: var Settings = Titanium.Filesystem.getFile(Titanium.Filesystem.tempDirectory,'Settings'); Ti.API.info("Created Settings: " +

Titanium Alloy ListView Nested Model Array of Tags

天大地大妈咪最大 提交于 2019-12-04 14:44:20
问题 I am using Titanium Alloy version 3.2. I have a collection of posts in a listview. My data looks like this: [ { username: 'dude', imageUrl: 'url', tags: ['tag1','tag2','tag3'] }, { username: 'wheres', imageUrl: 'url', tags: ['tag1'] }, { username: 'my', imageUrl: 'url', tags: ['tag1','tag2','tag3','tag4'] }, { username: 'car', imageUrl: 'url', tags: ['tag1','tag2'] } ] And here is the xml. This works only for username and image. I can't figure out how to add the tags to each post. <ListView

How to upload images from iPhone app developed using Titanium

爱⌒轻易说出口 提交于 2019-12-04 13:53:23
问题 I finally landed up in developing an iPhone app using Titanium Mobile. Now the problem I face is, Im able to run the app, and the app also sends the image to the server. But Im not able to see the file that got uploaded to the server. I have pasted the iPhone app's code to send image to the server and also, the PHP file that would receive the file from the app. var win = Titanium.UI.currentWindow; var ind=Titanium.UI.createProgressBar({ width:200, height:50, min:0, max:1, value:0, style

Exception Occured While Building Android project

落爺英雄遲暮 提交于 2019-12-04 13:47:37
OS: Linux mint 14. Following error occurs when I try to run my project. [TRACE] Writing out AndroidManifest.xml [ERROR] Exception occured while building Android project: [ERROR] Traceback (most recent call last): [ERROR] File "/home/aqeel/.titanium/mobilesdk/linux/3.1.0.GA/android/builder.py", line 2528, in <module> [ERROR] builder.build_and_run(False, avd_id, debugger_host=debugger_host, profiler_host=profiler_host) [ERROR] File "/home/aqeel/.titanium/mobilesdk/linux/3.1.0.GA/android/builder.py", line 2264, in build_and_run [ERROR] self.manifest_changed = self.generate_android_manifest