Author: Lars Michelsen <[email protected]>
Date: Thu Nov 24 18:40:13 2011 +0100
Committer: Lars Michelsen <[email protected]>
Commit-Date: Thu Nov 24 18:40:13 2011 +0100
Bugfix: Removing just dragged new lines before opening the add/modify dialog
---
ChangeLog | 1 +
TODO | 1 -
share/frontend/nagvis-js/js/edit.js | 10 +++++++++-
3 files changed, 10 insertions(+), 2 deletions(-)
diff --git a/ChangeLog b/ChangeLog
index 565a824..905aa3b 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -23,6 +23,7 @@ Frontend
* Only show the edit links in context menu when permitted to edit the map
* Bugfix: Don't enable map_image when not set when editing the global
sections of maps
+ * Bugfix: Removing just dragged new lines before opening the add/modify
dialog
1.6rc4
Core
diff --git a/TODO b/TODO
index e929be5..042821b 100644
--- a/TODO
+++ b/TODO
@@ -10,7 +10,6 @@ Relative Koordinaten:
- Beim Config Parsen Fehlermeldung erzeugen
- Sidebar Folder auf/zu klappbar
- In Sidebar/Dropdown die aktuelle Map highlighten
-- Abgebrochene Linie wieder aus Ansicht entfernen
- line_weather_color umbrechen wenn als Text dargestellt
- line_label_y_offset wird noch nicht sauber berechnet
diff --git a/share/frontend/nagvis-js/js/edit.js
b/share/frontend/nagvis-js/js/edit.js
index 569fb84..ac6ae4b 100644
--- a/share/frontend/nagvis-js/js/edit.js
+++ b/share/frontend/nagvis-js/js/edit.js
@@ -436,8 +436,10 @@ function addClick(e) {
pos = null;
// Draw a line to illustrate the progress of drawing the current line
- if(addViewType === 'line' || addObjType === 'textbox' || addObjType ===
'line') {
+ if((addViewType === 'line' || addObjType === 'textbox' || addObjType ===
'line')
+ && addShape === null) {
addShape = new jsGraphics('map');
+ addShape.cnv.setAttribute('id', 'drawing');
addShape.setColor('#06B606');
addShape.setStroke(1);
@@ -480,6 +482,12 @@ function addClick(e) {
if(sUrl === '')
return false;
+ // remove the drawing area. Once reached this it is not needed anymore
+ if(addShape !== null) {
+ addShape.clear();
+ document.getElementById('map').removeChild(addShape.cnv);
+ }
+
// FIXME: Language string
showFrontendDialog(sUrl, 'Properties');
sUrl = '';
------------------------------------------------------------------------------
All the data continuously generated in your IT infrastructure
contains a definitive record of customers, application performance,
security threats, fraudulent activity, and more. Splunk takes this
data and makes sense of it. IT sense. And common sense.
http://p.sf.net/sfu/splunk-novd2d
_______________________________________________
Nagvis-checkins mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/nagvis-checkins