mirror of
https://github.com/juce-framework/JUCE.git
synced 2026-01-13 00:04:19 +00:00
Added multi-select to the PluginListComponent.
This commit is contained in:
parent
28c281c6d3
commit
874814eaa0
1 changed files with 4 additions and 3 deletions
|
|
@ -83,9 +83,9 @@ public:
|
|||
}
|
||||
}
|
||||
|
||||
void deleteKeyPressed (int lastRowSelected) override
|
||||
void deleteKeyPressed (int) override
|
||||
{
|
||||
removePluginItem (list, lastRowSelected);
|
||||
owner.removeSelected();
|
||||
}
|
||||
|
||||
void sortOrderChanged (int newSortColumnId, bool isForwards) override
|
||||
|
|
@ -152,6 +152,7 @@ PluginListComponent::PluginListComponent (AudioPluginFormatManager& manager, Kno
|
|||
table.setHeaderHeight (22);
|
||||
table.setRowHeight (20);
|
||||
table.setModel (tableModel);
|
||||
table.setMultipleSelectionEnabled (true);
|
||||
addAndMakeVisible (table);
|
||||
|
||||
addAndMakeVisible (optionsButton);
|
||||
|
|
@ -208,7 +209,7 @@ void PluginListComponent::removeSelected()
|
|||
{
|
||||
const SparseSet<int> selected (table.getSelectedRows());
|
||||
|
||||
for (int i = list.getNumTypes(); --i >= 0;)
|
||||
for (int i = table.getNumRows(); --i >= 0;)
|
||||
if (selected.contains (i))
|
||||
TableModel::removePluginItem (list, i);
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue