tweaks...

Signed-off-by: Alex A. Naanou <alex.nanou@gmail.com>
This commit is contained in:
Alex A. Naanou 2014-11-26 04:15:02 +03:00
parent a602cf122e
commit 76992ea5fa
3 changed files with 9 additions and 10 deletions

View File

@ -563,6 +563,7 @@ var DataPrototype = {
}
// first/last special case...
// XXX need to get first loaded...
if(target == 'first'){
list = this.ribbons[this.getRibbon(mode)]
for(var res in list){

View File

@ -206,22 +206,19 @@ $(function(){
})
// XXX for some reason this does not happen right away...
// XXX for some reason this is not visible when loading...
a.setEmptyMsg('Loading...')
viewer.Features.setup(a, [
// XXX I do not fully understand it yet, but PartialRibbons must be
// setup BEFORE AlignRibbonsTo*, otherwise the later will break
// on shifting an image to a new ribbon...
// To reproduce:
// - setupe RibbonAlignToFirst first
// - go to top ribbon
// - shift image up
// features...
// NOTE: partial ribbons needs to be setup first...
// ...the reasons why things break otherwise is not too clear.
'ui-partial-ribbons',
'ui-ribbon-align-to-order',
'ui-single-image-view',
// ui elements...
'image-marks',
'image-bookmarks',
@ -229,7 +226,6 @@ $(function(){
'ui-animation',
'ui-bounds-indicators',
'ui-current-image-indicator',
])
// this publishes all the actions...

View File

@ -240,7 +240,7 @@ actions.Actions({
// adding new items to the resulting structure...
// XXX is this the correct way to go???
// ...can we save simple attribute values???
dump: ['Dump state as JSOM object',
json: ['Dump state as JSOM object',
'This will collect JSON data from every afailable attribute '
+'supporting the .dumpJSON() method.',
function(){
@ -291,6 +291,8 @@ actions.Actions({
function(all){ this.focusImage(all == null ? 'first' : 0) }],
lastImage: ['Focus last image in current ribbon',
function(all){ this.focusImage(all == null ? 'last' : -1) }],
// XXX these break if image at first/last position are not loaded (crop, group, ...)
// XXX do we actually need these???
firstGlobalImage: ['Get first globally image',
function(){ this.firstImage(true) }],
lastGlobalImage: ['Get last globally image',