mirror of
https://github.com/bancika/diy-layout-creator
synced 2026-11-10 17:22:09 +10:00
select all works now
This commit is contained in:
+7
@@ -168,6 +168,13 @@ public interface IPlugInPort {
|
|||||||
*/
|
*/
|
||||||
ComponentSelection getSelectedComponents();
|
ComponentSelection getSelectedComponents();
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Changes component selection.
|
||||||
|
*
|
||||||
|
* @param selection
|
||||||
|
*/
|
||||||
|
void setSelectedComponents(ComponentSelection selection);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Returns the {@link Area} occupied by the component.
|
* Returns the {@link Area} occupied by the component.
|
||||||
*
|
*
|
||||||
|
|||||||
+2
@@ -187,6 +187,8 @@ public class ClipboardManager implements IPlugIn, ClipboardOwner {
|
|||||||
@Override
|
@Override
|
||||||
public void actionPerformed(ActionEvent e) {
|
public void actionPerformed(ActionEvent e) {
|
||||||
LOG.info("Select All triggered");
|
LOG.info("Select All triggered");
|
||||||
|
plugInPort.setSelectedComponents(new ComponentSelection(plugInPort.getCurrentProject()
|
||||||
|
.getComponents()));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
+9
@@ -453,6 +453,15 @@ public class Presenter implements IPlugInPort {
|
|||||||
return new ComponentSelection(selectedComponents);
|
return new ComponentSelection(selectedComponents);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void setSelectedComponents(ComponentSelection selection) {
|
||||||
|
this.selectedComponents = new ComponentSelection(selection);
|
||||||
|
messageDispatcher.dispatchMessage(EventType.SELECTION_CHANGED, selectedComponents);
|
||||||
|
messageDispatcher.dispatchMessage(EventType.SELECTION_SIZE_CHANGED,
|
||||||
|
calculateSelectionDimension());
|
||||||
|
messageDispatcher.dispatchMessage(EventType.REPAINT);
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public Area getComponentArea(IDIYComponent<?> component) {
|
public Area getComponentArea(IDIYComponent<?> component) {
|
||||||
return componentAreaMap.get(component);
|
return componentAreaMap.get(component);
|
||||||
|
|||||||
Reference in New Issue
Block a user