Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
cleanup views and images, still need remote image fix for Nook
- Loading branch information
1 parent
ee2731b
commit 44a9eab
Showing
10 changed files
with
78 additions
and
437 deletions.
There are no files selected for viewing
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 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 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 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 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,45 +1,16 @@ | ||
// create table view data object | ||
Ti.include('../common.js'); | ||
|
||
var data = [ | ||
{title:'Basic', hasChild:true, test:'../examples/image_view_basic.js'}, | ||
{title:'Animated', hasChild:true, test:'../examples/image_view_animated.js'}, | ||
{title:'Image File', hasChild:true, test:'../examples/image_view_file.js'}, | ||
{title:'Remote Image', hasChild:true, test:'../examples/image_view_remote.js'}, | ||
{title:'Image Scaling', hasChild:true, test:'../examples/image_view_scaling.js'}, | ||
{title:'Image View Positioning', hasChild:true, test:'../examples/image_view_positioning.js'}, | ||
{title:'Image View Encoding', hasChild:true, test:'../examples/image_view_encoding.js'} | ||
|
||
{title:'Image View Encoding', hasChild:true, test:'../examples/image_view_encoding.js'}, | ||
{title:'Image Rapid Update', hasChild:true, test:'../examples/image_view_updateimages.js'}, | ||
{title:'Android drawable resource', hasChild:true, test:'image_view_resource.js'} | ||
]; | ||
|
||
// add iphone specific tests | ||
if (Titanium.Platform.name == 'iPhone OS') | ||
{ | ||
data.push({title:'Image Blob', hasChild:true, test:'../examples/image_view_blob.js'}); | ||
data.push({title:'Image Masking', hasChild:true, test:'../examples/image_mask.js'}); | ||
data.push({title:'Image Toolbar', hasChild:true, test:'../examples/image_view_toolbar.js'}); | ||
} | ||
|
||
data.push({title:'Image Rapid Update', hasChild:true, test:'../examples/image_view_updateimages.js'}); | ||
if (Titanium.Platform.name == 'android') { | ||
data.push({title:'Android drawable resource', hasChild:true, test:'image_view_resource.js'}); | ||
} | ||
|
||
// create table view | ||
var tableview = Titanium.UI.createTableView({ | ||
data:data | ||
}); | ||
|
||
// create table view event listener | ||
tableview.addEventListener('click', function(e) | ||
{ | ||
if (e.rowData.test) | ||
{ | ||
var win = Titanium.UI.createWindow({ | ||
url:e.rowData.test, | ||
title:e.rowData.title | ||
}); | ||
Titanium.UI.currentTab.open(win,{animated:true}); | ||
} | ||
}); | ||
Titanium.UI.currentWindow.add(NookKS.createNavigationTableView(data)); | ||
|
||
// add table view to the window | ||
Titanium.UI.currentWindow.add(tableview); |
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 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 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,62 +1,20 @@ | ||
Ti.include('../common.js'); | ||
|
||
//create table view data object | ||
var data = [ | ||
{title:'Events Propagation', hasChild:true, test:'../examples/view_event_propagation.js'}, | ||
{title:'Events Interaction', hasChild:true, test:'../examples/view_event_interaction.js'}, | ||
{title:'Image Views', hasChild:true, test:'../examples/image_views.js'}, | ||
{title:'Scroll Views', hasChild:true, test:'../examples/scroll_views.js'}, | ||
{title:'Table Views', hasChild:true, test:'../examples/table_views.js'}, | ||
{title:'Web Views', hasChild:true, test:'../examples/web_views.js'}, | ||
{title:'Alert Dialog', hasChild:true, test:'../examples/alert.js'}, | ||
{title:'Options Dialog', hasChild:true, test:'../examples/options_dialog.js'}, | ||
{title:'Remove Views', hasChild:true, test:'../examples/remove_views.js'}, | ||
{title:'zIndex', hasChild:true, test:'../examples/views_zindex.js'}, | ||
{title:'Email Dialog', hasChild:true, test:'../examples/email_dialog.js'}, | ||
{title:'Map View', hasChild:true, test:'../examples/map_view.js'}, | ||
{title:'View w/ Size', hasChild:true, test:'../examples/view_with_size.js'} | ||
|
||
{title:'Events Propagation', test:'../examples/view_event_propagation.js'}, | ||
{title:'Events Interaction', test:'../examples/view_event_interaction.js'}, | ||
{title:'Image Views', test:'../examples/image_views.js'}, | ||
{title:'Scroll Views', test:'../examples/scroll_views.js'}, | ||
{title:'Table Views', test:'../examples/table_views.js'}, | ||
{title:'Web Views', test:'../examples/web_views.js'}, | ||
{title:'Alert Dialog', test:'../examples/alert.js'}, | ||
{title:'Options Dialog', test:'../examples/options_dialog.js'}, | ||
{title:'Remove Views', test:'../examples/remove_views.js'}, | ||
{title:'zIndex', test:'../examples/views_zindex.js'}, | ||
{title:'Email Dialog', test:'../examples/email_dialog.js'}, | ||
{title:'Map View', test:'../examples/map_view.js'}, | ||
{title:'View w/ Size', test:'../examples/view_with_size.js'} | ||
]; | ||
|
||
if (Titanium.Platform.name == 'iPhone OS') | ||
{ | ||
data.push({title:'Map View with Routing', hasChild:true, test:'../examples/map_view2.js'}); | ||
data.push({title:'Events', hasChild:true, test:'../examples/view_events.js'}); | ||
data.push({title:'Events with Views', hasChild:true, test:'../examples/view_events_2.js'}); | ||
data.push({title:'Coverflow View', hasChild:true, test:'../examples/coverflow.js'}); | ||
data.push({title:'Dashboard View', hasChild:true, test:'../examples/dashboard.js'}); | ||
data.push({title:'Auto Height', hasChild:true, test:'../examples/views_auto_height.js'}); | ||
data.push({title:'Min Height', hasChild:true, test:'../examples/views_min_height.js'}); | ||
data.push({title:'Mixing Views', hasChild:true, test:'../examples/mixing_views_1.js'}); | ||
// data.push({title:'Web View Repaint', hasChild:true, test:'../examples/webview_repaint.js'}); | ||
data.push({title:'Gradient', hasChild:true, test:'../examples/gradient.js'}); | ||
data.push({title:'Hide/Show', hasChild:true, test:'../examples/view_hide_show.js'}); | ||
|
||
Ti.include("version.js"); | ||
|
||
if (isiOS4Plus()) | ||
{ | ||
data.push({title:'Hi-Res Image', wintitle:"Fence", hasChild:true, test:'../examples/hi_res_image.js'}); | ||
data.push({title:'Hi-Res Image 2', wintitle:"Dog", hasChild:true, test:'../examples/hi_res_image2.js'}); | ||
} | ||
data.push({title:'Hi-Res Image remote', wintitle:"Remote dog", hasChild:true, test:'../examples/hi_res_image_remote.js'}); | ||
} | ||
|
||
// create table view | ||
var tableview = Titanium.UI.createTableView({ | ||
data:data | ||
}); | ||
|
||
// create table view event listener | ||
tableview.addEventListener('click', function(e) | ||
{ | ||
if (e.rowData.test) | ||
{ | ||
var win = Titanium.UI.createWindow({ | ||
url:e.rowData.test, | ||
title:e.rowData.wintitle || e.rowData.title | ||
}); | ||
Titanium.UI.currentTab.open(win,{animated:true}); | ||
} | ||
}); | ||
|
||
// add table view to the window | ||
Titanium.UI.currentWindow.add(tableview); | ||
Titanium.UI.currentWindow.add(NookKS.createNavigationTableView(data)); |
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
Oops, something went wrong.