mirror of
https://github.com/bancika/diy-layout-creator
synced 2026-11-10 17:22:09 +10:00
selection & multi d&d fix
This commit is contained in:
@@ -12,9 +12,9 @@
|
||||
<classpathentry kind="lib" path="lib/org-openide-awt.jar"/>
|
||||
<classpathentry kind="lib" path="lib/org-openide-util.jar"/>
|
||||
<classpathentry kind="lib" path="lib/org-openide-util-lookup.jar"/>
|
||||
<classpathentry kind="lib" path="lib/app-framework.jar"/>
|
||||
<classpathentry kind="lib" path="lib/swing-framework.jar"/>
|
||||
<classpathentry combineaccessrules="false" kind="src" path="/diylc-core"/>
|
||||
<classpathentry combineaccessrules="false" kind="src" path="/app-framework"/>
|
||||
<classpathentry combineaccessrules="false" kind="src" path="/swing-framework"/>
|
||||
<classpathentry kind="lib" path="lib/xstream-1.4.3.jar"/>
|
||||
<classpathentry kind="output" path="bin"/>
|
||||
</classpath>
|
||||
|
||||
+11
-12
@@ -100,26 +100,15 @@ public class CanvasPlugin implements IPlugIn, ClipboardOwner {
|
||||
canvasPanel = new CanvasPanel(plugInPort);
|
||||
canvasPanel.addMouseListener(new MouseAdapter() {
|
||||
|
||||
private boolean processedPressed = false;
|
||||
|
||||
@Override
|
||||
public void mousePressed(MouseEvent e) {
|
||||
canvasPanel.requestFocus();
|
||||
mouseReleased(e);
|
||||
processedPressed = true;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void mouseReleased(final MouseEvent e) {
|
||||
// Do not send mouseClicked on release if it was already
|
||||
// process on pressed.
|
||||
if (processedPressed) {
|
||||
processedPressed = false;
|
||||
} else {
|
||||
plugInPort.mouseClicked(e.getPoint(), e.getButton(), e
|
||||
.isControlDown(), e.isShiftDown(), e
|
||||
.isAltDown(), e.getClickCount());
|
||||
}
|
||||
|
||||
// Invoke the rest of the code later so we get the chance to
|
||||
// process selection messages.
|
||||
SwingUtilities.invokeLater(new Runnable() {
|
||||
@@ -185,6 +174,16 @@ public class CanvasPlugin implements IPlugIn, ClipboardOwner {
|
||||
.isShiftDown(), e.isAltDown());
|
||||
}
|
||||
});
|
||||
|
||||
canvasPanel.addMouseListener(new MouseAdapter() {
|
||||
|
||||
@Override
|
||||
public void mouseClicked(MouseEvent e) {
|
||||
plugInPort.mouseClicked(e.getPoint(), e.getButton(), e
|
||||
.isControlDown(), e.isShiftDown(), e.isAltDown(), e
|
||||
.getClickCount());
|
||||
}
|
||||
});
|
||||
}
|
||||
return canvasPanel;
|
||||
}
|
||||
|
||||
@@ -1249,5 +1249,25 @@
|
||||
</changes>
|
||||
<url>http://code.google.com/p/diy-layout-creator/downloads/list</url>
|
||||
</org.diylc.appframework.update.Version>
|
||||
<org.diylc.appframework.update.Version>
|
||||
<versionNumber>
|
||||
<major>3</major>
|
||||
<minor>29</minor>
|
||||
<build>0</build>
|
||||
</versionNumber>
|
||||
<releaseDate>2013-08-15 20:00:00.000 CET</releaseDate>
|
||||
<name></name>
|
||||
<changes>
|
||||
<org.diylc.appframework.update.Change>
|
||||
<changeType>BUG_FIX</changeType>
|
||||
<description>Issue with dragging multiple components</description>
|
||||
</org.diylc.appframework.update.Change>
|
||||
<org.diylc.appframework.update.Change>
|
||||
<changeType>BUG_FIX</changeType>
|
||||
<description>Issue with component selection</description>
|
||||
</org.diylc.appframework.update.Change>
|
||||
</changes>
|
||||
<url>http://code.google.com/p/diy-layout-creator/downloads/list</url>
|
||||
</org.diylc.appframework.update.Version>
|
||||
</a>
|
||||
</java.util.Arrays_-ArrayList>
|
||||
Reference in New Issue
Block a user