always enable 'New Edit from Selection' in edit section, use editPanel.getSelectedClips
This commit is contained in:
parent
86cf90fa82
commit
de8c824c2b
3 changed files with 5 additions and 9 deletions
|
@ -94,7 +94,7 @@ pandora.ui.folders = function(section) {
|
||||||
pandora.$ui.personalListsMenu = Ox.MenuButton({
|
pandora.$ui.personalListsMenu = Ox.MenuButton({
|
||||||
items: [
|
items: [
|
||||||
{ id: 'newedit', title: Ox._('New Edit'), keyboard: 'control n' },
|
{ id: 'newedit', title: Ox._('New Edit'), keyboard: 'control n' },
|
||||||
{ id: 'neweditfromselection', title: Ox._('New Edit from Selection'), keyboard: 'shift control n', disabled: !ui.edit || !ui.editSelection.length },
|
{ id: 'neweditfromselection', title: Ox._('New Edit from Selection'), keyboard: 'shift control n', disabled: !ui.edit },
|
||||||
{ id: 'newsmartedit', title: Ox._('New Smart Edit'), keyboard: 'alt control n'},
|
{ id: 'newsmartedit', title: Ox._('New Smart Edit'), keyboard: 'alt control n'},
|
||||||
{},
|
{},
|
||||||
{ id: 'duplicateedit', title: Ox._('Duplicate Selected Edit'), keyboard: 'control d', disabled: !ui.edit },
|
{ id: 'duplicateedit', title: Ox._('Duplicate Selected Edit'), keyboard: 'control d', disabled: !ui.edit },
|
||||||
|
|
|
@ -650,15 +650,12 @@ pandora.ui.mainMenu = function() {
|
||||||
that.uncheckItem(previousEdit == '' ? 'allitems' : 'viewlist' + previousEdit.replace(/_/g, Ox.char(9)));
|
that.uncheckItem(previousEdit == '' ? 'allitems' : 'viewlist' + previousEdit.replace(/_/g, Ox.char(9)));
|
||||||
that.checkItem(edit == '' ? 'allitems' : 'viewlist' + edit.replace(/_/g, '\t'));
|
that.checkItem(edit == '' ? 'allitems' : 'viewlist' + edit.replace(/_/g, '\t'));
|
||||||
}
|
}
|
||||||
that[edit ? 'enableItem' : 'disableItem']('duplicatelist');
|
that[!isGuest && edit ? 'enableItem' : 'disableItem']('duplicatelist');
|
||||||
that[action]('editlist');
|
that[action]('editlist');
|
||||||
that[action]('deletelist');
|
that[action]('deletelist');
|
||||||
that[ui.listSelection.length ? 'enableItem' : 'disableItem']('newlistfromselection');
|
that[!isGuest && edit ? 'enableItem' : 'disableItem']('newlistfromselection');
|
||||||
that.replaceMenu('itemMenu', getItemMenu());
|
that.replaceMenu('itemMenu', getItemMenu());
|
||||||
},
|
},
|
||||||
pandora_editselection: function(data) {
|
|
||||||
that[data.value.length ? 'enableItem' : 'disableItem']('newlistfromselection');
|
|
||||||
},
|
|
||||||
pandora_find: function() {
|
pandora_find: function() {
|
||||||
var action = pandora.getListData().editable ? 'enableItem' : 'disableItem',
|
var action = pandora.getListData().editable ? 'enableItem' : 'disableItem',
|
||||||
list = ui._list,
|
list = ui._list,
|
||||||
|
@ -998,7 +995,7 @@ pandora.ui.mainMenu = function() {
|
||||||
{ id: 'neweditfromselection', title: Ox._('New Edit from Selection'), disabled: isGuest || ui.listSelection.length == 0 },
|
{ id: 'neweditfromselection', title: Ox._('New Edit from Selection'), disabled: isGuest || ui.listSelection.length == 0 },
|
||||||
{ id: 'newsmarteditfromresults', title: Ox._('New Smart Edit from Results'), disabled: isGuest }
|
{ id: 'newsmarteditfromresults', title: Ox._('New Smart Edit from Results'), disabled: isGuest }
|
||||||
] : ui.section == 'edits' ? [
|
] : ui.section == 'edits' ? [
|
||||||
{ id: 'newlistfromselection', title: Ox._('New ' + itemNameSingular + ' from Selection'), disabled: isGuest || !ui.edit || ui.editSelection.length == 0, keyboard: 'shift control n' },
|
{ id: 'newlistfromselection', title: Ox._('New ' + itemNameSingular + ' from Selection'), disabled: isGuest || !ui.edit, keyboard: 'shift control n' },
|
||||||
{ id: 'newsmartlist', title: Ox._('New Smart ' + itemNameSingular), disabled: isGuest, keyboard: 'alt control n' }
|
{ id: 'newsmartlist', title: Ox._('New Smart ' + itemNameSingular), disabled: isGuest, keyboard: 'alt control n' }
|
||||||
] : [
|
] : [
|
||||||
{ id: 'newpdf', title: Ox._('New PDF'), disabled: isGuest, keyboard: 'alt control n' },
|
{ id: 'newpdf', title: Ox._('New PDF'), disabled: isGuest, keyboard: 'alt control n' },
|
||||||
|
|
|
@ -38,7 +38,7 @@ pandora.addFolderItem = function(section) {
|
||||||
if (!isSmart) {
|
if (!isSmart) {
|
||||||
data.items = isItems ? ui.listSelection
|
data.items = isItems ? ui.listSelection
|
||||||
: ui.section == 'items' ? pandora.$ui.clipList.options('selected')
|
: ui.section == 'items' ? pandora.$ui.clipList.options('selected')
|
||||||
: ui.editSelection;
|
: pandora.$ui.editPanel.getSelectedClips();
|
||||||
} else {
|
} else {
|
||||||
data.query = ui.find;
|
data.query = ui.find;
|
||||||
}
|
}
|
||||||
|
@ -446,7 +446,6 @@ pandora.createLinks = function($element) {
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
} else {
|
} else {
|
||||||
|
|
||||||
pandora.api.addClips({
|
pandora.api.addClips({
|
||||||
clips: getClipData(items),
|
clips: getClipData(items),
|
||||||
edit: target,
|
edit: target,
|
||||||
|
|
Loading…
Reference in a new issue