Changeset 9801
- Timestamp:
- 10/29/10 22:52:41 (19 months ago)
- Location:
- trunk/JHotDrawPlugin
- Files:
-
- 5 edited
-
data/System/JHotDrawPlugin.txt (modified) (6 diffs)
-
lib/Foswiki/Plugins/JHotDrawPlugin.pm (modified) (2 diffs)
-
lib/Foswiki/Plugins/JHotDrawPlugin/source.zip (modified) (previous)
-
pub/System/JHotDrawPlugin/jhotdraw.jar (modified) (previous)
-
pub/System/JHotDrawPlugin/jhotdraw_src.js (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
trunk/JHotDrawPlugin/data/System/JHotDrawPlugin.txt
r6027 r9801 1 %META:TOPICINFO{author="ProjectContributor" date="1 144799477" format="1.1" version="1.1"}%1 %META:TOPICINFO{author="ProjectContributor" date="1288389452" format="1.1" version="1"}% 2 2 ---+!! <nop>%TOPIC% 3 3 … … 21 21 22 22 The tools on the left create or manipulate figures. 23 | <img src="%ATTACHURLPATH%/SEL 1.gif" width="24" height="24" alt="Selection"> | selects, moves or resizes a figure; the shift-key toggles the selection. Dragging the selection tool in the background selects the figures within the dragged rectangle. |24 | <img src="%ATTACHURLPATH%/TEXT 1.gif" width="24" height="24" alt="Text"> | creates a new or edits an existing text figure |25 | <img src="%ATTACHURLPATH%/ATEXT 1.gif" width="24" height="24" alt="Connected Text"> | creates a new text figure and attaches it to the clicked figure. Once a text figure is attached it remains connected to the figure. |26 | <img src="%ATTACHURLPATH%/RECT 1.gif" width="24" height="24" alt="Rectangle"> | creates a rectangle figure |27 | <img src="%ATTACHURLPATH%/RRECT 1.gif" width="24" height="24" alt="Round Rectangle"> | creates a round rectangle figure |28 | <img src="%ATTACHURLPATH%/ELLIPSE 1.gif" width="24" height="24" alt="Ellipse"> | creates an ellipse figure |29 | <img src="%ATTACHURLPATH%/LINE 1.gif" width="24" height="24" alt="Line"> | creates a line figure |30 | <img src="%ATTACHURLPATH%/CONN 1.gif" width="24" height="24" alt="Connection Line"> | creates or adjusts connections between figures. A connection is split into segments by dragging a point on the connection. To join two segments click the end point of a segment |31 | <img src="%ATTACHURLPATH%/OCONN 1.gif" width="24" height="24" alt="Elbow Connection Line"> | creates an elbow connection and offers the same features as the ordinary connection tool |32 | <img src="%ATTACHURLPATH%/SCRIBBL 1.gif" width="24" height="24" alt="Scribble"> | creates a scribble figure; dragging the mouse creates a smooth line while successive clicks yields a polyline figure. A two-button click terminates the figure. |33 | <img src="%ATTACHURLPATH%/POLYGON 1.gif" width="24" height="24" alt="Polygon"> | creates a polygon figure; dragging the mouse creates a smooth border while successive clicks yields a polyline border. A two-button click or the ESCAPE key terminates the figure. |34 | <img src="%ATTACHURLPATH%/BORDDEC 1.gif" width="24" height="24" alt="Border"> | decorates the clicked figure with a border |35 | <img src="%ATTACHURLPATH%/URL 1.gif" width="24" height="24" alt="URL"> | adds a sensitive area to the figure that will redirect to a URL. If an image contains any sensitive areas it can only be selected for edit by clicking on the boundary or (if enabled) the attached Edit button. You can use wikiwords and web.topic wiki link expressions as well as full URLs. |23 | <img src="%ATTACHURLPATH%/SEL3.gif" width="24" height="24" alt="Selection"> | selects, moves or resizes a figure; the shift-key toggles the selection. Dragging the selection tool in the background selects the figures within the dragged rectangle. | 24 | <img src="%ATTACHURLPATH%/TEXT3.gif" width="24" height="24" alt="Text"> | creates a new or edits an existing text figure | 25 | <img src="%ATTACHURLPATH%/ATEXT3.gif" width="24" height="24" alt="Connected Text"> | creates a new text figure and attaches it to the clicked figure. Once a text figure is attached it remains connected to the figure. | 26 | <img src="%ATTACHURLPATH%/RECT3.gif" width="24" height="24" alt="Rectangle"> | creates a rectangle figure | 27 | <img src="%ATTACHURLPATH%/RRECT3.gif" width="24" height="24" alt="Round Rectangle"> | creates a round rectangle figure | 28 | <img src="%ATTACHURLPATH%/ELLIPSE3.gif" width="24" height="24" alt="Ellipse"> | creates an ellipse figure | 29 | <img src="%ATTACHURLPATH%/LINE3.gif" width="24" height="24" alt="Line"> | creates a line figure | 30 | <img src="%ATTACHURLPATH%/CONN2.gif" width="24" height="24" alt="Connection Line"> | creates or adjusts connections between figures. A connection is split into segments by dragging a point on the connection. To join two segments click the end point of a segment | 31 | <img src="%ATTACHURLPATH%/OCONN3.gif" width="24" height="24" alt="Elbow Connection Line"> | creates an elbow connection and offers the same features as the ordinary connection tool | 32 | <img src="%ATTACHURLPATH%/SCRIBBL2.gif" width="24" height="24" alt="Scribble"> | creates a scribble figure; dragging the mouse creates a smooth line while successive clicks yields a polyline figure. A two-button click terminates the figure. | 33 | <img src="%ATTACHURLPATH%/POLYGON3.gif" width="24" height="24" alt="Polygon"> | creates a polygon figure; dragging the mouse creates a smooth border while successive clicks yields a polyline border. A two-button click or the ESCAPE key terminates the figure. | 34 | <img src="%ATTACHURLPATH%/BORDDEC3.gif" width="24" height="24" alt="Border"> | decorates the clicked figure with a border | 35 | <img src="%ATTACHURLPATH%/URL3.gif" width="24" height="24" alt="URL"> | adds a sensitive area to the figure that will redirect to a URL. If an image contains any sensitive areas it can only be selected for edit by clicking on the boundary or (if enabled) the attached Edit button. You can use wikiwords and web.topic wiki link expressions as well as full URLs. | 36 36 37 37 ---+++ Handles … … 73 73 %DRAWING{example}% 74 74 75 ---+++ Known Problems76 77 * %X% Versions since 13 Oct 2009 will only work with Foswiki 1.0.7 or later and only with Foswiki having {Validation}{Method} set to the high security setting of 'strikeone' in configure (recommended anyway). Look out for updates of the plugin as this will naturally be fixed in future versions. If you run Foswiki 1.0.6 or older please download the 16 Jun 2009 version of the plugin (which you can download as [[http://foswiki.org/bin/viewfile/Extensions/JHotDrawPlugin?filename=JHotDrawPlugin.zip;rev=6][old zip]] or [[http://foswiki.org/bin/viewfile/Extensions/JHotDrawPlugin?filename=JHotDrawPlugin.tgz;rev=6][old tgz]])78 79 75 * If you add a map to a drawing by setting a URL on any of the figures a map file is created. If you subsequently remove all the URLs from figures in the drawing the map still exists, but is now empty. There is no way to remove the map other than by manually moving the attachment. 80 76 … … 88 84 | Release: | %$RELEASE% | 89 85 | Change History: | | 86 | 29 Oct 2010 | Foswikitask:Item2614: Fix so the plugin will work with all setting of validation methis, strikeone, embedded, and none.<br /> Foswikitask:Item9917: Fix so plugin can save and exit in Foswiki 1.1.X. This also adds a dependency of !JQueryPlugin and !ZonePlugin for the plugin to be used in old 1.0 installations only. <br /> Foswikitask:Item8387: Plugin now works in other skins than Pattern and Nat. <br /> Foswikitask:Item8558: Added all the graphic files used on plugin topic as attachments in meta. Replaced some small icons by the best version | 90 87 | 13 Jan 2010 | Foswikitask:Item2624: Help Foswiki:Extensions.JHotDrawPlugin work correctly under Foswiki:Extensions.NatSkin | 91 88 | 11 Jan 2010 | Foswikitask:Item2620 and Foswikitask:Item2614. Documented that upgraders must delete any old templates/jhotdraw.pattern.tmpl file. Documented that because of a bug the plugin only works with 1.0.7 or later and with {Validation}{Method} = 'strikeone'. Provided links to older versions for those not yet at Foswiki 1.0.7. | … … 121 118 | 01 Oct 2001 | Updated this text | 122 119 | 23 Sep 2001 | Initial version | 123 | 2000 | Peter Thoeny created <nop>TWikiDraw based on JHotDraw (<nop>TWikiDraw applet that allows you to save a drawing as a =.draw= and a =.gif= file. New =%<nop>DRAWING%= variable to insert a drawing into any TWiki topic. New =oopstwikidraw.tmpl= template that contains the <nop>TWikiDraw applet. |124 | Dependencies: | Java 1.1enabled browser<br />%$DEPENDENCIES% |125 | PluginHome: | http://foswiki.org/Extensions/%TOPIC% |126 | Feedback: | http://foswiki.org/Extensions/%TOPIC%Dev |120 | 2000 | Peter Thoeny created <nop>TWikiDraw based on !JHotDraw (<nop>TWikiDraw applet that allows you to save a drawing as a =.draw= and a =.gif= file. New =%<nop>DRAWING%= variable to insert a drawing into any TWiki topic. New =oopstwikidraw.tmpl= template that contains the <nop>TWikiDraw applet. | 121 | Dependencies: | Java enabled browser<br />%$DEPENDENCIES% | 122 | Home: | http://foswiki.org/Extensions/%TOPIC% | 123 | Support: | http://foswiki.org/Support/%TOPIC% | 127 124 128 125 * JHotDraw is Copyright 1996, 1997 by <a href="http://www.ifa.ch/">IFA Informatik</a> and Erich Gamma, erich_gamma@acm.org . _It is hereby granted that this software can be used, copied, modified, and distributed without fee provided that this copyright notice appears in all copies._ … … 132 129 * Copyright © 2001 Motorola. All Rights Reserved. 133 130 * Copyright © 2003-2008 Crawford Currie http://www.c-dot.co.uk 134 * Foswiki version: © 2008 Foswiki Contributors131 * Foswiki version: © 2008-2010 Foswiki Contributors 135 132 136 133 %META:FILEATTACHMENT{name="screenshot.png" attachment="screenshot.png" attr="h" comment="" date="1288389452" path="screenshot.png" size="9794" user="ProjectContributor" version="1"}% 134 %META:FILEATTACHMENT{name="example.draw" attachment="example.draw" attr="h" comment="" date="1288389452" path="example.draw" size="29114" user="ProjectContributor" version="1"}% 135 %META:FILEATTACHMENT{name="ATEXT3.gif" attachment="ATEXT3.gif" attr="h" comment="" date="1288389452" path="ATEXT3.gif" size="191" user="ProjectContributor" version="1"}% 136 %META:FILEATTACHMENT{name="BORDDEC3.gif" attachment="BORDDEC3.gif" attr="h" comment="" date="1288389452" path="BORDDEC3.gif" size="186" user="ProjectContributor" version="1"}% 137 %META:FILEATTACHMENT{name="CONN2.gif" attachment="CONN2.gif" attr="h" comment="" date="1288389452" path="CONN2.gif" size="161" user="ProjectContributor" version="1"}% 138 %META:FILEATTACHMENT{name="ELLIPSE3.gif" attachment="ELLIPSE3.gif" attr="h" comment="" date="1288389452" path="ELLIPSE3.gif" size="202" user="ProjectContributor" version="1"}% 139 %META:FILEATTACHMENT{name="example.gif" attachment="example.gif" attr="h" comment="" date="1288389452" path="example.gif" size="9910" user="ProjectContributor" version="1"}% 140 %META:FILEATTACHMENT{name="LINE3.gif" attachment="LINE3.gif" attr="h" comment="" date="1288389452" path="LINE3.gif" size="164" user="ProjectContributor" version="1"}% 141 %META:FILEATTACHMENT{name="OCONN3.gif" attachment="OCONN3.gif" attr="h" comment="" date="1288389452" path="OCONN3.gif" size="170" user="ProjectContributor" version="1"}% 142 %META:FILEATTACHMENT{name="POLYGON3.gif" attachment="POLYGON3.gif" attr="h" comment="" date="1288389452" path="POLYGON3.gif" size="189" user="ProjectContributor" version="1"}% 143 %META:FILEATTACHMENT{name="RECT3.gif" attachment="RECT3.gif" attr="h" comment="" date="1288389452" path="RECT3.gif" size="190" user="ProjectContributor" version="1"}% 144 %META:FILEATTACHMENT{name="RRECT3.gif" attachment="RRECT3.gif" attr="h" comment="" date="1288389452" path="RRECT3.gif" size="190" user="ProjectContributor" version="1"}% 145 %META:FILEATTACHMENT{name="SCRIBBL2.gif" attachment="SCRIBBL2.gif" attr="h" comment="" date="1288389452" path="SCRIBBL2.gif" size="169" user="ProjectContributor" version="1"}% 146 %META:FILEATTACHMENT{name="SEL3.gif" attachment="SEL3.gif" attr="h" comment="" date="1288389452" path="SEL3.gif" size="192" user="ProjectContributor" version="1"}% 147 %META:FILEATTACHMENT{name="TEXT3.gif" attachment="TEXT3.gif" attr="h" comment="" date="1288389452" path="TEXT3.gif" size="186" user="ProjectContributor" version="1"}% 148 %META:FILEATTACHMENT{name="URL3.gif" attachment="URL3.gif" attr="h" comment="" date="1288389452" path="URL3.gif" size="230" user="ProjectContributor" version="1"}% 149 %META:FILEATTACHMENT{name="example.map" attachment="example.map" attr="h" comment="" date="1288389452" path="example.map" size="3732" user="ProjectContributor" version="1"}% -
trunk/JHotDrawPlugin/lib/Foswiki/Plugins/JHotDrawPlugin.pm
r9797 r9801 31 31 32 32 our $VERSION = '$Rev$'; 33 our $RELEASE = ' 13 Jan2010';33 our $RELEASE = '29 Oct 2010'; 34 34 our $SHORTDESCRIPTION = 'Java Applet based drawing editor'; 35 35 … … 220 220 my $query = Foswiki::Func::getCgiQuery(); 221 221 222 require Foswiki::Validation; 223 my $nonce = $query->param('validation_key'); 224 if ( !defined($nonce) 225 || !Foswiki::Validation::isValidNonce( $session->getCGISession(), 226 $nonce ) ) 227 { 228 returnRESTResult( $response, 403, "Invalid validation key" ); 229 return; 230 } 222 if ( $Foswiki::cfg{Validation}{Method} eq 'strikeone' ) { 223 require Foswiki::Validation; 224 my $nonce = $query->param('validation_key'); 225 if ( !defined($nonce) 226 || !Foswiki::Validation::isValidNonce( $session->getCGISession(), 227 $nonce ) ) 228 { 229 returnRESTResult( $response, 403, "Invalid validation key" ); 230 return; 231 } 232 } 233 231 234 my ($web, $topic) = _getTopic( @_ ); 232 235 -
trunk/JHotDrawPlugin/pub/System/JHotDrawPlugin/jhotdraw_src.js
r9797 r9801 42 42 + drawing); 43 43 44 try { 45 foswikiStrikeOne(document.saveform); 46 form.push( 47 'Content-Disposition: form-data; name="validation_key"\r\n\r\n' 48 + document.saveform.validation_key.value); 49 } catch (e) { 50 alert(e); 44 if (typeof(foswikiStrikeOne) === "function") { 45 try { 46 foswikiStrikeOne(document.saveform); 47 form.push( 48 'Content-Disposition: form-data; name="validation_key"\r\n\r\n' 49 + document.saveform.validation_key.value); 50 } catch (e) { 51 alert(e); 52 } 51 53 } 52 54
Note: See TracChangeset
for help on using the changeset viewer.
