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
// ------------------------- | |
// TabGroup&Tabの定義と表示 | |
// ------------------------- | |
// | |
// ※余談ですが、SplitViewをコンテナとしてTabGroupを持つ事が出来ません。 | |
// そういう構成を組みたい場合はwin3.jsサンプルのようにViewを分割し、 | |
// 左側のViewにTabGroupをセットするようなやり方になります。 | |
// | |
var tabGroup = Ti.UI.createTabGroup(); | |
tabGroup.addTab(Ti.UI.createTab({ |
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
// Test Runner - Online Code Debuging Framework for Titanium Mobile(iOS) | |
var tabGroup = Titanium.UI.createTabGroup(); | |
tabGroup.addTab(Titanium.UI.createTab({ | |
icon:'KS_nav_views.png', | |
title:'Test Runner', | |
window: Titanium.UI.createWindow({ | |
title:'Test Runner', | |
backgroundColor:'#fff', | |
url: 'testrunner.js' | |
}) |
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
// Test Runner - Online Code Debuging Framework for Titanium Mobile(iOS) | |
var tabGroup = Titanium.UI.createTabGroup(); | |
tabGroup.addTab(Titanium.UI.createTab({ | |
icon:'KS_nav_views.png', | |
title:'Test Runner', | |
window: Titanium.UI.createWindow({ | |
title:'Test Runner', | |
backgroundColor:'#fff', | |
url: 'testrunner.js' | |
}) |
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'); | |
Titanium.UI.iPhone.statusBarStyle = Titanium.UI.iPhone.StatusBar.OPAQUE_BLACK; | |
// 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
Ti.Media.showCamera({ | |
success : function(event) { | |
alert('Your photo was saved to the Photo Gallery'); | |
}, | |
cancel : function() { | |
}, | |
error : function(error) { | |
var message; | |
if (error.code == Ti.Media.NO_CAMERA) { | |
message = 'Device does not have video recording capabilities'; |
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
// (1) ウィンドウ(Window)を作る | |
var window = Titanium.UI.createWindow({ | |
backgroundColor : 'white' | |
}); | |
// (2)ボタン(Button)を作る | |
var button = Titanium.UI.createButton({ | |
title : 'カメラ', | |
top : 10, | |
left : 100, |
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 module = require('jp.msmc.filterablecamera'); | |
var presets = { | |
/* | |
* Normal | |
*/ | |
Normal : new module.Filter(function() { | |
// NO OPERATION | |
}), | |
/* | |
* Gray |
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
#----------------------------------------------------------------------- | |
# InputDialog for Titanium Mobile (by @donayama) | |
# | |
# Original JS Version by @k0sukey | |
# http://k0sukey.tumblr.com/post/17082188960 | |
#----------------------------------------------------------------------- | |
# Sample | |
#----------------------------------------------------------------------- | |
# InputDialog = require 'InputDialog' | |
# |
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 log = require("/api/Log"); | |
var os = Ti.Platform.osname; | |
// The TiShadow build of the Titanium SDK does not cache CommonJS modules loaded | |
// from the applicationDataDirectory. This is so that if an update to the app is | |
// deployed, i.e. a file in the applicationDataDirectory is modified, the changes | |
// while be loaded. That said loading a CommonJS module every time that it is loaded | |
// make the deployed bundle run slowly. So we will manage the caching of those | |
// modules here in the code. |
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 window = Ti.UI.createWindow(); | |
var mapView = Ti.Map.createView({ | |
bottom : 44 | |
}); | |
var flex = Ti.UI.createButton({ | |
systemButton : Ti.UI.iPhone.SystemButton.FLEXIBLE_SPACE | |
}); | |
var button1 = Ti.UI.createButton({ |
OlderNewer