some refactoring...

Signed-off-by: Alex A. Naanou <alex.nanou@gmail.com>
This commit is contained in:
Alex A. Naanou 2017-01-16 18:16:07 +03:00
parent d5ef01b144
commit ae2cb9af7b
2 changed files with 19 additions and 7 deletions

View File

@ -154,18 +154,18 @@ module.GLOBAL_KEYBOARD2 = {
meta_Q: 'close', meta_Q: 'close',
// XXX // XXX
F5: keyboard.doc('Reload viewer (full)', F5: 'reload!: "full"',
/*F5: keyboard.doc('Reload viewer (full)',
function(){ function(){
//a.stop() //a.stop()
/* //killAllWorkers()
killAllWorkers() // .done(function(){
.done(function(){ // reload()
reload() // })
})
*/
location.reload() location.reload()
return false return false
}), }),
//*/
F12: 'showDevTools', F12: 'showDevTools',
// NOTE: these are for systems where F** keys are not available // NOTE: these are for systems where F** keys are not available

View File

@ -331,6 +331,18 @@ module.ViewerActions = actions.Actions({
// - we depend on the internals of a custom add-on feature // - we depend on the internals of a custom add-on feature
reload: ['Interface/Reload viewer', reload: ['Interface/Reload viewer',
function(force){ function(force){
// full reload...
if(force == 'full'){
//this.stop()
/*
killAllWorkers()
.done(function(){
reload()
})
*/
location.reload()
}
this.ribbons.preventTransitions() this.ribbons.preventTransitions()
// NOTE: this essentially sets the update threshold to 0... // NOTE: this essentially sets the update threshold to 0...