titanium-modules

How to retrive values from Database in Titanium Alloy?

烂漫一生 提交于 2019-12-06 22:47:33
I'm new to Titanium API. I want to know how to retrieve values from DB and display in UI. I created a model and inserted a row. My code is as below, Model: var moment = require('alloy/moment'); exports.definition = { config : { "columns": { "id":"text", "LanguageName":"text" }, "adapter": { "type": "sql", "collection_name": "UserLanguage" } }, extendModel: function(Model) { _.extend(Model.prototype, { }); return Model; }, extendCollection: function(Collection) { _.extend(Collection.prototype, { }); return Collection; } }; View: <Alloy> <Window id="changeLangWindow" title="Plan India"> <Picker

Appcelerator Titanium: how to record video?

橙三吉。 提交于 2019-12-06 12:05:53
How to record video in Appcelerator Titanium and store in a specific location ? I am using an Android 2.3.6 device. This gist: https://gist.github.com/832488 does not seem to work as suggested / expected. It starts the video capture intent var intent = Titanium.Android.createIntent({ action: 'android.media.action.VIDEO_CAPTURE' }); as an activityForResult but the callback in Titanium.Android.currentActivity.startActivityForResult(intent, function(e) { ... }); is never called, none of notifications in code appear and the video is stored in some default location. The KitchenSink app does not

Exception Occured While Building Android project

戏子无情 提交于 2019-12-06 06:24:54
问题 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

Add overlay over top of ZBar scanner

给你一囗甜甜゛ 提交于 2019-12-05 12:13:06
I'm using the ZBar SDK to read QR codes on iPhone, however I want to add some text to the bottom of the camera/scanner view that is instructional text for the user. Here is what I have so far: UIView *cameraOverlayView = [[UIView alloc] initWithFrame:[[UIScreen mainScreen] applicationFrame]]; cameraOverlayView.backgroundColor = [UIColor redColor]; UILabel *instructionLabel = [[UILabel alloc] initWithFrame:[[UIScreen mainScreen] applicationFrame]]; [instructionLabel setTextColor:[UIColor grayColor]]; [instructionLabel setBackgroundColor:[UIColor clearColor]]; [instructionLabel setFont:[UIFont

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

Building Native View using iOS module and using them in Titanium

夙愿已清 提交于 2019-12-04 13:19:49
问题 I want to build an iOS module in which I have a viewController class with its .xib file. now the problem is how to call that view from my titanium code. I know that there are view proxy available but dont know how to use them due to not so good documentation. Till now I have created a module where non graphical data can be passed but what about getting View controller from my module. I have already checked the appcelerator wiki, but that was not helpful Any tutorial that will guide me will be

Titanium Android module upgrade to SDK 6.0.0

心已入冬 提交于 2019-12-04 12:55:44
问题 I am trying too recompile my old modules to 6.0.0.GA sdk as its mandatory to make it work on 6 and above sdk. But I am not able to build it as its giving error. Development environment: Android NDK r13b Titanium SDK 6.0.0.GA Appcelerator studio 4.8.0 CLI version 5.0.10 Android SDK 23 I am getting this error : BUILD FAILED /Users/krishna/Library/Application Support/Titanium/mobilesdk/osx/6.0.0.GA/module/android/build.xml:347: The following error occurred while executing this line: /Users

Titanium Android module upgrade to SDK 6.0.0

一曲冷凌霜 提交于 2019-12-03 08:07:48
I am trying too recompile my old modules to 6.0.0.GA sdk as its mandatory to make it work on 6 and above sdk. But I am not able to build it as its giving error. Development environment: Android NDK r13b Titanium SDK 6.0.0.GA Appcelerator studio 4.8.0 CLI version 5.0.10 Android SDK 23 I am getting this error : BUILD FAILED /Users/krishna/Library/Application Support/Titanium/mobilesdk/osx/6.0.0.GA/module/android/build.xml:347: The following error occurred while executing this line: /Users/krishna/Library/Application Support/Titanium/mobilesdk/osx/6.0.0.GA/module/android/build.xml:302: exec

iOS LocationManager is not updating location (Titanium Appcelerator module)

蓝咒 提交于 2019-12-02 10:28:41
I've made Appcelerator Titanium Module for fetching device's rotaion and location. Source can be found on GitHub . The problem is that it fetches only one cached location but device motion data is OK and it is refreshing. I don't use delegate, I pull that data in my Titanium Javascript Code. If I set "City Run" in Simulator -> Debug -> Location nothing happens. The same cached location is returning. Pulling of location is OK because I tried with native app wich does this: textView.text = [NSString stringWithFormat:@"%f %f\n%@", locationManager.location.coordinate.longitude, locationManager

Is a TiTouchImageView working in an alloy project? [UPDATE]

允我心安 提交于 2019-12-02 08:42:45
I am currently developing a titanium app for android and iOs including an imageView which should be scrollable and scalable (via a slider). I already get this to work on iOs but on Android it is really hard to achieve the scrolling behaviour. I decided to use the TiTouchImageView module but the documentation only shows how to use it in a non-Alloy project. My current code looks like this: if (Ti.Platform.osname == "android") { var TiTouchImageView = require('org.iotashan.TiTouchImageView'); var androidImageView = TiTouchImageView.createView({ top: 0, left: 0, zoom: originalScaleValue, maxZoom: