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 scrollable list. In this case, we're going to show a date. When you swipe left, | |
* you'll see yesterday. Then the day before yesterday, and so on. Swiping right shows you tomorrow, and so on. | |
*/ | |
var win = Ti.UI.createWindow({ backgroundColor: '#fff' }); | |
var isAndroid = Ti.Platform.osname === 'android'; | |
/** | |
* Track where we are in the infinite scrollable views, and define how large of a step goes between each view. | |
*/ | |
var currentDate = new Date(), msIntervalBetweenViews = 1000/*ms*/ * 60/*s*/ * 60/*m*/ * 24/*h*/; |
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 is the Android version of the Tweetie-like pull to refresh table: | |
// http://developer.appcelerator.com/blog/2010/05/how-to-create-a-tweetie-like-pull-to-refresh-table.html | |
var win = Ti.UI.currentWindow; | |
var alertDialog = Titanium.UI.createAlertDialog({ | |
title: 'System Message', | |
buttonNames: ['OK'] | |
}); | |
var scrollView = Ti.UI.createScrollView({ |
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
function removeAllChildren(viewObject){ | |
//copy array of child object references because view's "children" property is live collection of child object references | |
var children = viewObject.children.slice(0); | |
for (var i = 0; i < children.length; ++i) { | |
viewObject.remove(children[i]); | |
} | |
} |
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 is a simple CommonJS module to wrap Titanium Ti.Network.HttpClient calls to interact with Drupal Services. | |
NOTE: Code updated at @TiConf using callback functions. | |
Tested using: | |
Drupal 6.24 | |
Services 3.1 | |
Titanium Mobile SDK 1.8.2 (Android 2.2 SDK) |
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
<?xml version="1.0" encoding="UTF-8"?> | |
<ti:app xmlns:ti="http://ti.appcelerator.org"> | |
<deployment-targets> | |
<target device="mobileweb">true</target> | |
<target device="iphone">true</target> | |
<target device="ipad">true</target> | |
<target device="android">true</target> | |
<target device="blackberry">false</target> | |
</deployment-targets> | |
<sdk-version>1.9.0.v20120213133135</sdk-version> |
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
/* | |
* Android API Guide | |
* http://developer.android.com/guide/topics/ui/actionbar.html | |
* Android Design Guide | |
* http://developer.android.com/design/patterns/actionbar.html | |
* Titanium Mobile will support someday | |
* https://jira.appcelerator.org/browse/TIMOB-2371 | |
*/ | |
var osName = Ti.Platform.osname, | |
isAndroid = osName==='android', |
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
#! /bin/bash | |
# inspired by Greg McCormick's (@crushmedianet) post | |
# http://crushmedia.net/2012/04/23/automated-build-of-titanium-iconloading-files/ | |
# updated 4 Aug 2012: creates clipped iPad backgrounds by cropping 768x1024, etc. | |
# create following base images + save in APPNAME/Resources/: | |
# appicon-android-512x512.png |
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
/build | |
/modules | |
/.DS_Store | |
/.settings | |
/.project | |
.DS_Store* | |
/Resources/.DS_Store* | |
build.log |
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
// Copyright Stephen Feather and other contributors. | |
// | |
// Permission is hereby granted, free of charge, to any person obtaining a | |
// copy of this software and associated documentation files (the | |
// "Software"), to deal in the Software without restriction, including | |
// without limitation the rights to use, copy, modify, merge, publish, | |
// distribute, sublicense, and/or sell copies of the Software, and to permit | |
// persons to whom the Software is furnished to do so, subject to the | |
// following conditions: | |
// |
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
// parsed from https://github.com/danielbruce/entypo/blob/master/config.yml | |
[ | |
{ | |
"name": "note", | |
"code": "0x266a", | |
"search": [ | |
"music", | |
"note", | |
"song" |
OlderNewer