This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[ERROR] Error loading: http://av.vimeo.com/62775/077/47509302.mp4?token=1314875606_5906d25ae0e3fb9705a5421dc41c00d6, Error: Error Domain=WebKitErrorDomain Code=204 "Plug-in handled load" UserInfo=0xaa2b900 {NSErrorFailingURLStringKey=http://av.vimeo.com/62775/077/47509302.mp4?token=1314875606_5906d25ae0e3fb9705a5421dc41c00d6, WebKitErrorMIMETypeKey=video/mp4, NSErrorFailingURLKey=http://av.vimeo.com/62775/077/47509302.mp4?token=1314875606_5906d25ae0e3fb9705a5421dc41c00d6, NSLocalizedDescription=Plug-in handled load} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// this sets the background color of the master UIView (when there are no windows/tab groups on it) | |
Titanium.UI.setBackgroundColor('#000'); | |
// create tab group | |
var tabGroup = Titanium.UI.createTabGroup(); | |
// | |
// create base UI tab and root window | |
// |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// OPEN / INSTALL DATABASE -- SAFE | |
var db = Ti.Database.install('/mydata/dynamicdata.sqlite', 'dynamicdata'); | |
// RESULT SET OBJECT | |
var rs = db.execute('select * from tbl1'); | |
alert('Rows in table:' + rs.rowCount); | |
while(rs.isValidRow()){ | |
Ti.API.info(rs.field(0) + ':' + rs.field(1)); | |
rs.next(); | |
} | |
rs.close(); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// OPEN / INSTALL DATABASE -- SAFE | |
var db = Ti.Database.install('/mydata/dynamicdata.sqlite', 'dynamicdata'); | |
// RESULT SET OBJECT | |
var rs = db.execute('select * from tbl1'); | |
alert('Rows in table:' + rs.rowCount); | |
while(rs.isValidRow()){ | |
Ti.API.info(rs.field(0) + ':' + rs.field(1)); | |
rs.next(); | |
} | |
rs.close(); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var win = Ti.UI.createWindow({ | |
backgroundColor:'white', | |
modal: true, | |
title:'BarCamp London #bcl9' | |
}); | |
var anno = Ti.Map.createAnnotation({ | |
latitude:51.528069, | |
pincolor:Titanium.Map.ANNOTATION_GREEN, | |
longitude:-0.102707, |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var bigNumber = 324; | |
var label = Ti.UI.createLabel({ | |
text: bigNumber, | |
left: 0, | |
height: 40, | |
font: {fontWeight: 'normal', fontSize: 22}, | |
color: '#fff', | |
textAlign: 'center', | |
right: 0, | |
zIndex: 0 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// this sets the background color of the master UIView (when there are no windows/tab groups on it) | |
Titanium.UI.setBackgroundColor('#fff'); | |
// | |
// create base UI tab and root window | |
// | |
var win1 = Titanium.UI.createWindow({ | |
title: 'Funny Faces', | |
backgroundColor: '#fff' | |
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// | |
// blog.clearlyinnovative.com | |
// Aaron K. Saunders | |
// Clearly Innovative Inc | |
// | |
// @see https://github.com/aaronksaunders/Appcelerator-Cocoafish-Native-Module | |
// | |
var cocoafishMgr = require('com.ci.cocoafish'); | |
Ti.API.info("module is => " + cocoafishMgr); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//////////////////////push_notifications.js/////////////////////// | |
var apns = function(){ | |
var pref = require('preferences').preferences; | |
Titanium.Network.registerForPushNotifications({ | |
types: [ | |
Titanium.Network.NOTIFICATION_TYPE_BADGE, | |
Titanium.Network.NOTIFICATION_TYPE_ALERT | |
], | |
success:function(e) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* We're going to create an infinite loading table view. Whenever you get close to the bottom, we'll load more rows. | |
*/ | |
var win = Ti.UI.createWindow({ backgroundColor: '#fff' }); | |
var isAndroid = Ti.Platform.osname === 'android'; | |
/** | |
* Create our UI elements. | |
*/ | |
var table = Ti.UI.createTableView({ top: 0, right: 0, bottom: 0, left: 0 }); |