mirror of
https://github.com/flynx/ImageGrid.git
synced 2025-10-28 18:00:09 +00:00
starting refactoring of the ui/render/access...
Signed-off-by: Alex A. Naanou <alex.nanou@gmail.com>
This commit is contained in:
parent
edde747468
commit
796bd4d8cb
@ -20,6 +20,11 @@ require('features/history')
|
||||
require('features/app')
|
||||
require('features/peer')
|
||||
require('features/ui')
|
||||
// XXX
|
||||
require('features/ui-ribbons')
|
||||
require('features/ui-virtual-dom')
|
||||
require('features/ui-react')
|
||||
// XXX
|
||||
require('features/ui-partial-ribbons-precache')
|
||||
require('features/ui-partial-ribbons')
|
||||
require('features/ui-partial-ribbons-2')
|
||||
|
||||
@ -629,7 +629,7 @@ var JournalActions = actions.Actions({
|
||||
var handler = function(action){
|
||||
return function(){
|
||||
var cur = this.current
|
||||
var args = args2array(arguments)
|
||||
var args = util.args2array(arguments)
|
||||
|
||||
var data = {
|
||||
type: 'basic',
|
||||
|
||||
@ -1311,7 +1311,7 @@ module.FileSystemSaveHistory = core.ImageGridFeatures.Feature({
|
||||
['saveIndex',
|
||||
function(res){
|
||||
var that = this
|
||||
var comments = this.comments.save
|
||||
var comments = this.comments && this.comments.save
|
||||
|
||||
if(comments && comments.current){
|
||||
res
|
||||
|
||||
@ -66,6 +66,11 @@ core.ImageGridFeatures.Feature('viewer-testing', [
|
||||
'ui',
|
||||
'keyboard',
|
||||
|
||||
// XXX
|
||||
'ui-ribbons-render',
|
||||
'ui-vdom-render',
|
||||
'ui-react-render',
|
||||
|
||||
// features...
|
||||
'ui-cursor',
|
||||
'ui-animation',
|
||||
|
||||
@ -41,7 +41,9 @@ var core = require('features/core')
|
||||
//---------------------------------------------------------------------
|
||||
|
||||
// XXX DEBUG: remove when not needed...
|
||||
window.vdom = vdom
|
||||
if(typeof(window) != 'undefined'){
|
||||
window.vdom = vdom
|
||||
}
|
||||
|
||||
|
||||
//---------------------------------------------------------------------
|
||||
|
||||
42
ui (gen4)/features/ui-react.js
Executable file
42
ui (gen4)/features/ui-react.js
Executable file
@ -0,0 +1,42 @@
|
||||
/**********************************************************************
|
||||
*
|
||||
*
|
||||
*
|
||||
**********************************************************************/
|
||||
((typeof define)[0]=='u'?function(f){module.exports=f(require)}:define)
|
||||
(function(require){ var module={} // make module AMD/node compatible...
|
||||
/*********************************************************************/
|
||||
|
||||
var actions = require('lib/actions')
|
||||
var features = require('lib/features')
|
||||
|
||||
var core = require('features/core')
|
||||
|
||||
|
||||
|
||||
/*********************************************************************/
|
||||
|
||||
var ReactActions = actions.Actions({
|
||||
})
|
||||
|
||||
var React =
|
||||
module.React = core.ImageGridFeatures.Feature({
|
||||
title: '',
|
||||
doc: '',
|
||||
|
||||
tag: 'ui-react-render',
|
||||
exclusive: ['ui-render'],
|
||||
depends: [
|
||||
// XXX
|
||||
],
|
||||
|
||||
actions: ReactActions,
|
||||
|
||||
handlers: [],
|
||||
})
|
||||
|
||||
|
||||
|
||||
|
||||
/**********************************************************************
|
||||
* vim:set ts=4 sw=4 : */ return module })
|
||||
42
ui (gen4)/features/ui-ribbons.js
Executable file
42
ui (gen4)/features/ui-ribbons.js
Executable file
@ -0,0 +1,42 @@
|
||||
/**********************************************************************
|
||||
*
|
||||
*
|
||||
*
|
||||
**********************************************************************/
|
||||
((typeof define)[0]=='u'?function(f){module.exports=f(require)}:define)
|
||||
(function(require){ var module={} // make module AMD/node compatible...
|
||||
/*********************************************************************/
|
||||
|
||||
var actions = require('lib/actions')
|
||||
var features = require('lib/features')
|
||||
|
||||
var core = require('features/core')
|
||||
|
||||
|
||||
|
||||
/*********************************************************************/
|
||||
|
||||
var RibbonsActions = actions.Actions({
|
||||
})
|
||||
|
||||
var Ribbons =
|
||||
module.Ribbons = core.ImageGridFeatures.Feature({
|
||||
title: '',
|
||||
doc: '',
|
||||
|
||||
tag: 'ui-ribbons-render',
|
||||
exclusive: ['ui-render'],
|
||||
depends: [
|
||||
// XXX
|
||||
],
|
||||
|
||||
actions: RibbonsActions,
|
||||
|
||||
handlers: [],
|
||||
})
|
||||
|
||||
|
||||
|
||||
|
||||
/**********************************************************************
|
||||
* vim:set ts=4 sw=4 : */ return module })
|
||||
44
ui (gen4)/features/ui-virtual-dom.js
Executable file
44
ui (gen4)/features/ui-virtual-dom.js
Executable file
@ -0,0 +1,44 @@
|
||||
/**********************************************************************
|
||||
*
|
||||
*
|
||||
*
|
||||
**********************************************************************/
|
||||
((typeof define)[0]=='u'?function(f){module.exports=f(require)}:define)
|
||||
(function(require){ var module={} // make module AMD/node compatible...
|
||||
/*********************************************************************/
|
||||
|
||||
var vdom = require('ext-lib/virtual-dom')
|
||||
|
||||
var actions = require('lib/actions')
|
||||
var features = require('lib/features')
|
||||
|
||||
var core = require('features/core')
|
||||
|
||||
|
||||
|
||||
/*********************************************************************/
|
||||
|
||||
var VirtualDomActions = actions.Actions({
|
||||
})
|
||||
|
||||
var VirtualDom =
|
||||
module.VirtualDom = core.ImageGridFeatures.Feature({
|
||||
title: '',
|
||||
doc: '',
|
||||
|
||||
tag: 'ui-vdom-render',
|
||||
exclusive: ['ui-render'],
|
||||
depends: [
|
||||
// XXX
|
||||
],
|
||||
|
||||
actions: VirtualDomActions,
|
||||
|
||||
handlers: [],
|
||||
})
|
||||
|
||||
|
||||
|
||||
|
||||
/**********************************************************************
|
||||
* vim:set ts=4 sw=4 : */ return module })
|
||||
@ -20,6 +20,9 @@ requirejs.config({
|
||||
//text: 'node_modules/requirejs-plugins/lib/text',
|
||||
//json: 'node_modules/requirejs-plugins/src/json',
|
||||
|
||||
//react: 'node_modules/react/dist/react-with-addons.min.js',
|
||||
//'react-dom': 'node_modules/react-dom/dist/react-dom.min.js',
|
||||
|
||||
'lib/object': 'node_modules/ig-object/object',
|
||||
'lib/actions': 'node_modules/ig-actions/actions',
|
||||
'lib/features': 'node_modules/ig-features/features',
|
||||
|
||||
@ -26,6 +26,8 @@
|
||||
"ig-features": "^2.0.0",
|
||||
"ig-object": "^1.0.1",
|
||||
"openseadragon": "^2.1.0",
|
||||
"react": "^15.5.4",
|
||||
"react-dom": "^15.5.4",
|
||||
"requirejs": "^2.1.23",
|
||||
"requirejs-plugins": "^1.0.2",
|
||||
"sharp": "^0.17.0",
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user