osc: add /TABS command to enable a list of tabs (selected by ids)
This commit is contained in:
parent
ff89305e3a
commit
e0b1a27255
2 changed files with 8 additions and 2 deletions
|
|
@ -158,7 +158,11 @@ module.exports = {
|
|||
$('#grid-width-input').remove()
|
||||
EDITING = false
|
||||
},
|
||||
|
||||
tabsEnable: function(tabs){
|
||||
for (i in tabs) {
|
||||
$(`[data-id="${tabs[i]}"]`).trigger('fake-click')
|
||||
}
|
||||
},
|
||||
traversingDisable: function(){
|
||||
$('.traversingEnable, .traversingDisable').toggleClass('on')
|
||||
$('#container').trigger('disableTraversingGestures')
|
||||
|
|
|
|||
|
|
@ -1,5 +1,6 @@
|
|||
var {widgetManager} = require('./managers'),
|
||||
ipc = require('./ipc')
|
||||
ipc = require('./ipc'),
|
||||
actions = require('./actions')
|
||||
|
||||
var Osc = function(){
|
||||
|
||||
|
|
@ -29,6 +30,7 @@ Osc.prototype.send = function(data) {
|
|||
Osc.prototype.receive = function(data){
|
||||
|
||||
if (data.address == '/EXEC') return this.remoteExec(data.args)
|
||||
if (data.address == '/TABS') return actions.tabsEnable(data.args)
|
||||
|
||||
// fetch ids corresponding to the osc address
|
||||
var address = data.address,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue