From 02b9fa83ab23f02c803c57cd416ace4eeba3d06a Mon Sep 17 00:00:00 2001 From: Ezequiel Bergamaschi Date: Thu, 2 Apr 2015 17:50:16 -0300 Subject: [PATCH 1/3] Bug WISE-435 #resolve --- mindplot/src/main/javascript/Designer.js | 2 ++ .../main/javascript/libraries/bootstrap/BootstrapDialog.js | 3 --- mindplot/src/main/javascript/widget/Menu.js | 4 ++++ wise-webapp/src/main/webapp/jsp/mindmapShare.jsp | 2 +- 4 files changed, 7 insertions(+), 4 deletions(-) diff --git a/mindplot/src/main/javascript/Designer.js b/mindplot/src/main/javascript/Designer.js index 8b20fa85..947c9ce8 100644 --- a/mindplot/src/main/javascript/Designer.js +++ b/mindplot/src/main/javascript/Designer.js @@ -1036,6 +1036,7 @@ mindplot.Designer = new Class(/** @lends Designer */{ var topic = model.selectedTopic(); if (topic) { topic.showLinkEditor(); + this.onObjectFocusEvent(); } }, @@ -1045,6 +1046,7 @@ mindplot.Designer = new Class(/** @lends Designer */{ var topic = model.selectedTopic(); if (topic) { topic.showNoteEditor(); + this.onObjectFocusEvent(); } }, diff --git a/mindplot/src/main/javascript/libraries/bootstrap/BootstrapDialog.js b/mindplot/src/main/javascript/libraries/bootstrap/BootstrapDialog.js index 62ecc3de..83f37aef 100644 --- a/mindplot/src/main/javascript/libraries/bootstrap/BootstrapDialog.js +++ b/mindplot/src/main/javascript/libraries/bootstrap/BootstrapDialog.js @@ -15,9 +15,6 @@ var BootstrapDialog = new Class({ this.options.onEventData.dialog = this; this._native = $('').append(''); var content = $(''); - content.on('keydown', function(event) { - event.stopPropagation(); - }); var header = this._buildHeader(title); if (header) { content.append(header); diff --git a/mindplot/src/main/javascript/widget/Menu.js b/mindplot/src/main/javascript/widget/Menu.js index d513d2e6..313c14a8 100644 --- a/mindplot/src/main/javascript/widget/Menu.js +++ b/mindplot/src/main/javascript/widget/Menu.js @@ -353,6 +353,7 @@ mindplot.widget.Menu = new Class({ closeButton: true, cancelButton: true }); + designer.onObjectFocusEvent(); }); this._registerTooltip('shareIt', $msg('COLLABORATE')); @@ -365,6 +366,7 @@ mindplot.widget.Menu = new Class({ closeButton: true, cancelButton: true }); + designer.onObjectFocusEvent(); }); this._registerTooltip('publishIt', $msg('PUBLISH')); } @@ -377,6 +379,7 @@ mindplot.widget.Menu = new Class({ closeButton: true, cancelButton: true }); + designer.onObjectFocusEvent(); }); this._registerTooltip('history', $msg('HISTORY')); } @@ -392,6 +395,7 @@ mindplot.widget.Menu = new Class({ closeButton: true, cancelButton: true }); + designer.onObjectFocusEvent(); event.preventDefault(); }); } diff --git a/wise-webapp/src/main/webapp/jsp/mindmapShare.jsp b/wise-webapp/src/main/webapp/jsp/mindmapShare.jsp index d3fa1a7d..0148b725 100644 --- a/wise-webapp/src/main/webapp/jsp/mindmapShare.jsp +++ b/wise-webapp/src/main/webapp/jsp/mindmapShare.jsp @@ -65,7 +65,7 @@

:

- "/>
From 4822267970c7d2b13fe23ed7b24596ad3b0a40fa Mon Sep 17 00:00:00 2001 From: Ezequiel Bergamaschi Date: Fri, 3 Apr 2015 00:53:53 -0300 Subject: [PATCH 2/3] fixing freemind tests --- .../test/resources/data/freemind/basic.wxml | 18 +- .../src/test/resources/data/freemind/bug.wxml | 105 ++++++------ .../test/resources/data/freemind/fonts.wxml | 28 ++-- .../test/resources/data/freemind/i18n.wxml | 8 +- .../test/resources/data/freemind/i18n2.wxml | 6 +- .../test/resources/data/freemind/icons.wxml | 148 ++++++++--------- .../test/resources/data/freemind/links.wxml | 4 +- .../resources/data/freemind/longnodes.wxml | 4 +- .../resources/data/freemind/node-styles.wxml | 38 +++-- .../test/resources/data/freemind/note.wxml | 4 +- .../resources/data/freemind/numerosity.wxml | 136 ++++++++------- .../test/resources/data/freemind/process.wxml | 156 ++++++++++-------- .../resources/data/freemind/richtextnode.wxml | 99 ++++++----- 13 files changed, 412 insertions(+), 342 deletions(-) diff --git a/wise-webapp/src/test/resources/data/freemind/basic.wxml b/wise-webapp/src/test/resources/data/freemind/basic.wxml index 4a356961..6575307e 100644 --- a/wise-webapp/src/test/resources/data/freemind/basic.wxml +++ b/wise-webapp/src/test/resources/data/freemind/basic.wxml @@ -1,28 +1,28 @@ - + - + - + - + - + - + - + - + - + diff --git a/wise-webapp/src/test/resources/data/freemind/bug.wxml b/wise-webapp/src/test/resources/data/freemind/bug.wxml index d0df12ee..776d7a8f 100644 --- a/wise-webapp/src/test/resources/data/freemind/bug.wxml +++ b/wise-webapp/src/test/resources/data/freemind/bug.wxml @@ -1,142 +1,153 @@ - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + diff --git a/wise-webapp/src/test/resources/data/freemind/fonts.wxml b/wise-webapp/src/test/resources/data/freemind/fonts.wxml index ff9703dc..6fb12947 100644 --- a/wise-webapp/src/test/resources/data/freemind/fonts.wxml +++ b/wise-webapp/src/test/resources/data/freemind/fonts.wxml @@ -1,53 +1,53 @@ - + - + + position="290,-25" shape="line" shrink="false"> + position="290,0" shape="line" shrink="false"> - + + position="-290,-100" shape="line" shrink="false"> + position="-290,-75" shape="line" shrink="false"> + position="-290,-50" shape="line" shrink="false"> + position="-290,-25" shape="line" shrink="false"> - + + position="-290,25" shape="line" shrink="false"> + position="-290,50" shape="line" shrink="false"> + position="-290,75" shape="line" shrink="false"> + position="-290,100" shape="line" shrink="false"> diff --git a/wise-webapp/src/test/resources/data/freemind/i18n.wxml b/wise-webapp/src/test/resources/data/freemind/i18n.wxml index 36d3d2a7..4502643d 100644 --- a/wise-webapp/src/test/resources/data/freemind/i18n.wxml +++ b/wise-webapp/src/test/resources/data/freemind/i18n.wxml @@ -1,14 +1,14 @@ - + - + - + - + diff --git a/wise-webapp/src/test/resources/data/freemind/i18n2.wxml b/wise-webapp/src/test/resources/data/freemind/i18n2.wxml index f35b6a75..e5feedcb 100644 --- a/wise-webapp/src/test/resources/data/freemind/i18n2.wxml +++ b/wise-webapp/src/test/resources/data/freemind/i18n2.wxml @@ -1,12 +1,12 @@ - + - + - + diff --git a/wise-webapp/src/test/resources/data/freemind/icons.wxml b/wise-webapp/src/test/resources/data/freemind/icons.wxml index 662aa487..bb813e20 100644 --- a/wise-webapp/src/test/resources/data/freemind/icons.wxml +++ b/wise-webapp/src/test/resources/data/freemind/icons.wxml @@ -1,292 +1,292 @@ - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + diff --git a/wise-webapp/src/test/resources/data/freemind/links.wxml b/wise-webapp/src/test/resources/data/freemind/links.wxml index 3749d9d4..89edba7d 100644 --- a/wise-webapp/src/test/resources/data/freemind/links.wxml +++ b/wise-webapp/src/test/resources/data/freemind/links.wxml @@ -1,6 +1,6 @@ - + @@ -8,7 +8,7 @@ - + diff --git a/wise-webapp/src/test/resources/data/freemind/longnodes.wxml b/wise-webapp/src/test/resources/data/freemind/longnodes.wxml index 6e8f1d20..0ced37a5 100644 --- a/wise-webapp/src/test/resources/data/freemind/longnodes.wxml +++ b/wise-webapp/src/test/resources/data/freemind/longnodes.wxml @@ -1,8 +1,8 @@ - + - + - + - + - + - + - + - + - + + position="-290,-100" shape="rectagle" shrink="false"> + position="-290,-75" shape="rounded rectagle" shrink="false"> + position="-290,-50" shape="rectagle" shrink="false"> + position="-290,-25" shape="rectagle" shrink="false"> - + + position="-290,0" shape="rectagle" shrink="false"> + position="-290,25" shape="rounded rectagle" shrink="false"> + position="-290,50" shape="rectagle" shrink="false"> + position="-290,75" shape="rectagle" shrink="false"> diff --git a/wise-webapp/src/test/resources/data/freemind/note.wxml b/wise-webapp/src/test/resources/data/freemind/note.wxml index 50b99a56..2783a049 100644 --- a/wise-webapp/src/test/resources/data/freemind/note.wxml +++ b/wise-webapp/src/test/resources/data/freemind/note.wxml @@ -1,10 +1,10 @@ - + - + diff --git a/wise-webapp/src/test/resources/data/freemind/numerosity.wxml b/wise-webapp/src/test/resources/data/freemind/numerosity.wxml index 89575035..89b2993c 100644 --- a/wise-webapp/src/test/resources/data/freemind/numerosity.wxml +++ b/wise-webapp/src/test/resources/data/freemind/numerosity.wxml @@ -1,109 +1,121 @@ - + - + - + - + - + - + - + + position="-740,-150" shape="line" shrink="false"> + position="-830,-175" + shape="line" shrink="false"> + position="-920,-200" + shape="line" shrink="false"> + position="-920,-175" + shape="line" shrink="false"> + position="-830,-150" + shape="line" shrink="false"> + position="-920,-150" + shape="line" shrink="false"> + position="-740,-125" shape="line" shrink="false"> + position="-740,-100" shape="line" shrink="false"> + position="-740,-75" shape="line" shrink="false"> - + + position="-740,-75" shape="line" shrink="false"> + position="-830,-75" shape="line" shrink="false"> - + + position="-740,-75" shape="line" shrink="false"> + position="-740,-50" shape="line" shrink="false"> + position="-740,-25" shape="line" shrink="false"> - + + position="-740,-25" shape="line" shrink="false"> + position="-830,-100" + shape="line" shrink="false"> + position="-830,-75" shape="line" shrink="false"> + position="-830,-50" shape="line" shrink="false"> + position="-830,-25" shape="line" shrink="false"> + position="-830,0" shape="line" shrink="false"> + position="-830,25" shape="line" shrink="false"> @@ -111,78 +123,90 @@ - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + diff --git a/wise-webapp/src/test/resources/data/freemind/process.wxml b/wise-webapp/src/test/resources/data/freemind/process.wxml index c144d009..18f3f410 100644 --- a/wise-webapp/src/test/resources/data/freemind/process.wxml +++ b/wise-webapp/src/test/resources/data/freemind/process.wxml @@ -1,220 +1,234 @@ - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + + position="380,-250" shape="rounded rectagle" shrink="false"> - + + position="380,-225" shape="rounded rectagle" shrink="false"> + position="290,-225" shape="rounded rectagle" shrink="false"> - + + position="290,-200" shape="rounded rectagle" shrink="false"> - + - + - + - + - + - + + position="380,-100" shape="rounded rectagle" shrink="false"> - + + position="290,-75" shape="rounded rectagle" shrink="false"> - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + diff --git a/wise-webapp/src/test/resources/data/freemind/richtextnode.wxml b/wise-webapp/src/test/resources/data/freemind/richtextnode.wxml index c9d1a4f0..01fabaef 100644 --- a/wise-webapp/src/test/resources/data/freemind/richtextnode.wxml +++ b/wise-webapp/src/test/resources/data/freemind/richtextnode.wxml @@ -1,63 +1,65 @@ + fontStyle="Arial;10;#ff3300;bold;;" id="0" position="0,0" + shape="rounded rectagle" shrink="false"> + position="200,0" shape="rounded rectagle" shrink="false"> + position="290,-50" shape="line" shrink="false"> - + + position="380,-75" shape="line" shrink="false"> + position="380,-50" shape="line" shrink="false"> + position="380,-25" shape="line" shrink="false"> + position="290,-25" shape="rounded rectagle" shrink="false"> + position="380,-100" shape="rectagle" shrink="false"> + position="470,-150" shape="rectagle" shrink="false"> + position="470,-125" shape="rectagle" shrink="false"> + position="470,-100" shape="rectagle" shrink="false"> + position="470,-75" shape="rectagle" shrink="false"> + position="470,-50" shape="rectagle" shrink="false"> - + @@ -67,128 +69,141 @@ du plan d'actions]]> position="380,-75" shape="rectagle" shrink="true"> - + + position="380,-50" shape="rectagle" shrink="false"> - + + position="380,-25" shape="rectagle" shrink="false"> - + + position="380,0" shape="rectagle" shrink="false"> - + + position="380,25" shape="rectagle" shrink="false"> - + + position="380,50" shape="rectagle" shrink="false"> - + + position="290,0" shape="rounded rectagle" shrink="false"> + position="380,-25" shape="rectagle" shrink="false"> - + + position="380,0" shape="rectagle" shrink="false"> - + + position="380,25" shape="rectagle" shrink="false"> - + + position="290,25" shape="rounded rectagle" shrink="false"> + position="380,-25" shape="rectagle" shrink="false"> - + + position="380,0" shape="rectagle" shrink="false"> - + + position="380,25" shape="rectagle" shrink="false"> - + + position="380,50" shape="rectagle" shrink="false"> - + From 2316459cf1f243be23e06adf7ab565ff017790f1 Mon Sep 17 00:00:00 2001 From: Ezequiel Bergamaschi Date: Fri, 3 Apr 2015 01:23:50 -0300 Subject: [PATCH 3/3] Bug WISE-421 #resolve --- .../com/wisemapping/model/Collaboration.java | 24 +++++++++++++++++++ 1 file changed, 24 insertions(+) diff --git a/wise-webapp/src/main/java/com/wisemapping/model/Collaboration.java b/wise-webapp/src/main/java/com/wisemapping/model/Collaboration.java index e9c5b982..6180248f 100644 --- a/wise-webapp/src/main/java/com/wisemapping/model/Collaboration.java +++ b/wise-webapp/src/main/java/com/wisemapping/model/Collaboration.java @@ -100,4 +100,28 @@ public class Collaboration { return this.getRole().ordinal() <= role.ordinal(); } + + @Override + public boolean equals(Object o) { + if (this == o) return true; + if (o == null || getClass() != o.getClass()) return false; + + Collaboration that = (Collaboration) o; + + if (id != that.id) return false; + if (collaborator != null ? !collaborator.equals(that.collaborator) : that.collaborator != null) return false; + if (mindMap != null ? !mindMap.equals(that.mindMap) : that.mindMap != null) return false; + if (role != that.role) return false; + + return true; + } + + @Override + public int hashCode() { + int result = (int) (id ^ (id >>> 32)); + result = 31 * result + (role != null ? role.hashCode() : 0); + result = 31 * result + (mindMap != null ? mindMap.hashCode() : 0); + result = 31 * result + (collaborator != null ? collaborator.hashCode() : 0); + return result; + } }