titanium

Calendar on iPhone simulator

和自甴很熟 提交于 2019-12-07 07:30:39
问题 How can I access the calendar on the iPhone simulator? I'm using Titanium to make an app, and I've created an event. It should have worked, and now I want to test if it is saved correctly in the calendar. Can anyone tell me how I can open it? Thanks Tjekkles 回答1: Update for Lion : To get to the User Library folder, follow these instructions. There doesn't seem to be any way to access the calendar from the simulator, unfortunately. However, as I found in this thread, you can find the SQLLite3

SVG in Titanium Desktop?

青春壹個敷衍的年華 提交于 2019-12-07 05:49:11
问题 I'm running the 1.1.0 SDK of Titanium Desktop and only my SVG text elements are rendered properly. SVG methods such as getBBox() give error messages. The application works well outside the Titanium environment - that is: Chrome, Firefox, Safari. Any ideas on how to solve this? (What browser + version is really running inside Titanium??) Thanks. Edit: Example SVG code: <svg width="400" height="400" viewBox="0 0 400 400" xmlns="http://www.w3.org/2000/svg" version="1.1"> <title>Example

Titanium Creating Image file: file.write(blob) not creating the correct file

独自空忆成欢 提交于 2019-12-07 05:21:38
问题 I am trying to read a .PNG file using Titanium 1.8.1 Here is my code to read file. var f = Ti.Filesystem.getFile(Ti.Filesystem.resourcesDirectory, 'KS_nav_views.png'); var blob = f.read(); When I create a new file using the above blob object, the new file thus created is not same as the original file. Here is my code to create the new file. var outputDir = Titanium.Filesystem.getFile(Titanium.Filesystem.externalStorageDirectory,'output'); outputDir.createDirectory(); var newFile = Titanium

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

PhoneGap or Appcelerator Implementation

旧巷老猫 提交于 2019-12-06 22:36:27
This is more of an advice question rather than a specific question. I am developing an application for mobile devices. Its basic functionality will be to open PDF files, Video files, and to open certain webpages. Would this be best implemented in PhoneGap or Appcelerator? PhoneGap and Appcelerator Titanium are both very popular open-source JavaScript frameworks for packaging and deploying mobile applications. At Universal Mind, we have clients that leverage both and clearly both frameworks have countless successful implementations on numerous platforms. However, there are enough significant

titanium mobile date picker from text field

余生长醉 提交于 2019-12-06 16:08:16
I want to do the following: when people click on a text field they see a date picker. they click "done" button at the top and the date picker disappears and they are back on the form. How can I accomplish this using titanium mobile for iphone ios? MRT You can use Textbox AddeventListener and Animation function. like var donebtn = Ti.UI.createButton({ title : "Done", }); var toolbar_pick = Ti.UI.iOS.createToolbar({ backgroundColor : "#f00", bottom : -50, items :[donebtn], barColor :'#000', }); var _date = Ti.UI.createPicker({ type:Ti.UI.PICKER_TYPE_DATE, minDate : new Date, bottom :-320 , });

Keyboard shortcuts for Titanium IDE in MAC

左心房为你撑大大i 提交于 2019-12-06 15:23:10
问题 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

Titanium: Where is the SQLite DB Stored?

我是研究僧i 提交于 2019-12-06 14:59:33
I started a titanium app that uses a sqlite db. I'm getting strange DB results so just want to browse the database using FF SQLite Manager but I'm not sure where the database is? This is the code that creates the db (part): var db = (function() { //create an object which will be our public API var api = {}; //maintain a database connection we can use var conn = Titanium.Database.open('quote'); I'm running Titanium studio on a Mac. Thanks, Billy i thought it was something like /Library/Application\ Support/iPhone\ Simulator/.../your.app.id/.. have a look. consider that there are two /Library

Titanium UI之TableViews组件

喜欢而已 提交于 2019-12-06 14:20:34
TableViews 1、为tableView增加数据 2、Row的属性 3、自定义Row,Row组,Row Section 4、在TableView的搜索 5、TableView的事件 内容 Ti里面创建一个TableView,如下: var table = new Titanium . UI . createTableView ({ /* properties */ }); 这是其包含的属性: height and width top and left backgroundColor and backgroundImage rowHeight / minRowHeight / maxRowHeight – 控制行的尺寸 headerTitle / headerView footerTitle / footerView scrollable (boolean) –控制tableView的滚动,纵向滚动条 为TableView添加数据 TableView的一行是一个Ti.UI.TableViewRow对象,当然,你可以通过此对象来控制该行。 Ti.UI.createTableViewRow(),此方法用来创建一个TableViewRow对象。 你可以通过javascript来循环的创建此对象。 Object literals as rows // 通过json来做为数据 var

Titanium 用户界面之布局结构及核心代码块

被刻印的时光 ゝ 提交于 2019-12-06 14:20:02
以 Tab为界面基础的界面 关于Tab的建议 以 窗口为界面基础 目标 在本节,你将会看到Ti应用的核心代码块。 我们将会讨论Tab组件,windows窗口以及他们的核心功能 。 内容 如果用开发web的方式来比拟Ti里面的界面,, 一个Ti的窗口相当于一个web页面,一个Ti的View相当于一个DIV。概念上,Ti里面的windows是一个顶级的容器,就像web里面的页面,如JSP等。 Ti里面的Views组件可以看成是一个含有style的能够装入内容的容器。 Windows和View,两者都可以包含其他内容(按钮、视图等),而且必须包含在一个窗口,或者web页面。 Ti 中的Tab groups 和 web中的tab groups一个样,在Web中,Tab有时被称作一个UI组件,但是一般都用Div来实现Tab的功能。在移动开发的应用中,用的最多的应该是一组导航菜单或者是一些导航链接。 那么,我们现在就来看看如何使用tab groups,views,windows 去组织你的UI。移动应用一般使用两个基本的布局方式:tab布局和windows布局。如图所示: 使用Tab布局 在一个使用tab布局的应用中,一般使用一个Tab group来包含多个tabs。而每个Tab又包含一个windows。每个windows包含你所需要的组件,如按钮,input等等。使用Tab的基本代码如下所示