mirror of
				https://github.com/flynx/ImageGrid.git
				synced 2025-10-31 11:20:09 +00:00 
			
		
		
		
	...
Signed-off-by: Alex A. Naanou <alex.nanou@gmail.com>
This commit is contained in:
		
							parent
							
								
									47dd396ee9
								
							
						
					
					
						commit
						20f1685782
					
				| @ -6,6 +6,7 @@ | ||||
| **********************************************************************/ | ||||
| 
 | ||||
| define(function(require){ var module = {} | ||||
| console.log('>>> data') | ||||
| 
 | ||||
| 
 | ||||
| 
 | ||||
| @ -88,6 +89,7 @@ define(function(require){ var module = {} | ||||
| 
 | ||||
| // Data class methods and API...
 | ||||
| //
 | ||||
| var DataClassPrototype = | ||||
| module.DataClassPrototype = { | ||||
| 	// NOTE: we consider the input list sorted...
 | ||||
| 	fromList: function(list){ | ||||
| @ -111,6 +113,7 @@ module.DataClassPrototype = { | ||||
| 
 | ||||
| // Data object methods and API...
 | ||||
| //
 | ||||
| var DataPrototype = | ||||
| module.DataPrototype = { | ||||
| 
 | ||||
| 	/*****************************************************************/ | ||||
| @ -1464,6 +1467,8 @@ module.DataPrototype = { | ||||
| 
 | ||||
| // Main Data object...
 | ||||
| //
 | ||||
| var Data =  | ||||
| module.Data = | ||||
| function Data(json){ | ||||
| 	// in case this is called as a function (without new)...
 | ||||
| 	if(this.constructor.name != 'Data'){ | ||||
| @ -1479,9 +1484,8 @@ function Data(json){ | ||||
| 
 | ||||
| 	return this | ||||
| } | ||||
| module.Data = Data | ||||
| Data.__proto__ = module.DataClassPrototype | ||||
| Data.prototype = module.DataPrototype | ||||
| Data.__proto__ = DataClassPrototype | ||||
| Data.prototype = DataPrototype | ||||
| Data.prototype.constructor = Data | ||||
| 
 | ||||
| 
 | ||||
|  | ||||
| @ -6,16 +6,18 @@ | ||||
| **********************************************************************/ | ||||
| 
 | ||||
| define(function(require){ var module = {} | ||||
| console.log('>>> ribbons') | ||||
| 
 | ||||
| //var DEBUG = DEBUG != null ? DEBUG : true
 | ||||
| 
 | ||||
| 
 | ||||
| 
 | ||||
| /*********************************************************************/ | ||||
| //
 | ||||
| // This xpects the folowing HTML structure...
 | ||||
| //
 | ||||
| // Unpopulated:
 | ||||
| // NOTE: there can be only .ribbon-set element.
 | ||||
| // NOTE: there can be only one .ribbon-set element.
 | ||||
| //
 | ||||
| //	<div class="viewer">
 | ||||
| //		<div class="ribbon-set"></div>
 | ||||
| @ -46,6 +48,7 @@ define(function(require){ var module = {} | ||||
| //
 | ||||
| /*********************************************************************/ | ||||
| 
 | ||||
| var RibbonsClassPrototype = | ||||
| module.RibbonsClassPrototype = { | ||||
| 	// NOTE: these will return unattached objects...
 | ||||
| 	createViewer: function(){ | ||||
| @ -69,15 +72,16 @@ module.RibbonsClassPrototype = { | ||||
| 
 | ||||
| // XXX this is a low level interface, not a set of actions...
 | ||||
| // XXX test
 | ||||
| var RibbonsPrototype = | ||||
| module.RibbonsPrototype = { | ||||
| 	//
 | ||||
| 	//	.viewer (jQuery object)
 | ||||
| 	//
 | ||||
| 	 | ||||
| 	// Constructors...
 | ||||
| 	createViewer: module.RibbonsClassPrototype.createViewer, | ||||
| 	createRibbon: module.RibbonsClassPrototype.createRibbon, | ||||
| 	createImage: module.RibbonsClassPrototype.createImage, | ||||
| 	createViewer: RibbonsClassPrototype.createViewer, | ||||
| 	createRibbon: RibbonsClassPrototype.createRibbon, | ||||
| 	createImage: RibbonsClassPrototype.createImage, | ||||
| 
 | ||||
| 	// NOTE: these accept gids or jQuery objects...
 | ||||
| 	getRibbon: function(target){ | ||||
| @ -386,6 +390,8 @@ module.RibbonsPrototype = { | ||||
| 
 | ||||
| // Main Ribbons object...
 | ||||
| //
 | ||||
| var Ribbons = | ||||
| module.Ribbons = | ||||
| function Ribbons(viewer){ | ||||
| 	// in case this is called as a function (without new)...
 | ||||
| 	if(this.constructor.name != 'Ribbons'){ | ||||
| @ -394,9 +400,8 @@ function Ribbons(viewer){ | ||||
| 
 | ||||
| 	return this | ||||
| } | ||||
| module.Ribbons = Ribbons | ||||
| Ribbons.__proto__ = module.RibbonsClassPrototype | ||||
| Ribbons.prototype = module.RibbonsPrototype | ||||
| Ribbons.__proto__ = RibbonsClassPrototype | ||||
| Ribbons.prototype = RibbonsPrototype | ||||
| Ribbons.prototype.constructor = Ribbons | ||||
| 
 | ||||
| 
 | ||||
|  | ||||
| @ -22,11 +22,13 @@ var nw = require('nw') | ||||
| // XXX load only the actualy used here modules...
 | ||||
| var actions = require('actions') | ||||
| var data = require('data') | ||||
| var ribbons = require('ribbons') | ||||
| 
 | ||||
| 
 | ||||
| 
 | ||||
| /*********************************************************************/ | ||||
| 
 | ||||
| // XXX add this to the global doc...
 | ||||
| window.GLOBAL_KEYBOARD = { | ||||
| 	'Global bindings': { | ||||
| 		doc: 'NOTE: binding priority is the same as the order of sections '+ | ||||
|  | ||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user