[Mapbender-commits] r9048 - trunk/mapbender/http/plugins
svn_mapbender at osgeo.org
svn_mapbender at osgeo.org
Wed Aug 13 02:13:58 PDT 2014
Author: hwbllmnn
Date: 2014-08-13 02:13:58 -0700 (Wed, 13 Aug 2014)
New Revision: 9048
Modified:
trunk/mapbender/http/plugins/mb_digitize_widget.php
Log:
added reset button
Modified: trunk/mapbender/http/plugins/mb_digitize_widget.php
===================================================================
--- trunk/mapbender/http/plugins/mb_digitize_widget.php 2014-08-13 08:43:01 UTC (rev 9047)
+++ trunk/mapbender/http/plugins/mb_digitize_widget.php 2014-08-13 09:13:58 UTC (rev 9048)
@@ -120,6 +120,7 @@
'<tr><td>Flächendeckkraft:</td><td><div class="opacity-slider" data-name="fill-opacity"></div></td></tr>' +
'</table><br></br>' +
'<div class="digitize-image digitize-save"></div>' +
+ '<button name="digitize-reset-style">Reset</button>' +
'</div>';
var folderMenu = '<ul class="digitize-contextmenu">' +
@@ -438,6 +439,23 @@
editStyleDialog.find('.digitize-style-' + $(this).val()).css('display', 'block').siblings('table').css('display', 'none');
});
+ editStyleDialog.find('button[name="digitize-reset-style"]').bind('click', function() {
+ if(ispoint) {
+ editStyleDialog.find('.digitize-style-custom,form').css('display', 'block');
+ editStyleDialog.find('.digitize-style-predefined').css('display', 'none');
+ editStyleDialog.find('input[value="custom"]').attr('checked', 'checked');
+ editStyleDialog.find('.digitize-style-custom input[name="marker-symbol"]').val('../img/marker/red.png');
+ editStyleDialog.find('.digitize-style-custom input[name="marker-size"]').val(20);
+ editStyleDialog.find('.digitize-style-predefined input[name="marker-symbol"]').val('icon-airfield-24');
+ editStyleDialog.find('.digitize-style-predefined input[name="marker-size"]').val('medium');
+ editStyleDialog.find('.digitize-style-predefined input[name="marker-color"]').spectrum('set', 'white');
+ }
+ editStyleDialog.find('input[name="stroke"]').spectrum('set', '#555555');
+ editStyleDialog.find('.opacity-slider').slider('value', 100);
+ editStyleDialog.find('input[name="stroke-width"]').val(1);
+ editStyleDialog.find('input[name="fill"]').spectrum('set', '#555555');
+ });
+
editStyleDialog.find('input,select').bind('change', function() {
if(isline && $(this).attr('name').match(/fill/)) {
return;
More information about the Mapbender_commits
mailing list