Author:   Lars Michelsen <[email protected]>
Date:     Thu Nov 24 18:52:13 2011 +0100
Committer:   Lars Michelsen <[email protected]>
Commit-Date: Thu Nov 24 18:52:13 2011 +0100

long text values with no spaces do not stretch the add/modify dialog anymore

---

 ChangeLog                                         |    5 +++--
 share/server/core/classes/WuiViewMapAddModify.php |   10 ++++++++++
 2 files changed, 13 insertions(+), 2 deletions(-)

diff --git a/ChangeLog b/ChangeLog
index 905aa3b..2a69f21 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -14,13 +14,14 @@ Core
 
 Frontend
   * Sorting maps by alias in header menu now
-  * Bugfix: Not adding default_params parameter to all maps after editing the
-    global map configuration using the web frontend
   * Added map name dropdown to parent_map option when editing global map
     configuration
   * iconset option is now optional when creating maps using the GUI
   * Reimplemented the "clone object" functionality in edit mode
   * Only show the edit links in context menu when permitted to edit the map
+  * long text values with no spaces do not stretch the add/modify dialog 
anymore
+  * Bugfix: Not adding default_params parameter to all maps after editing the
+    global map configuration using the web frontend
   * 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
diff --git a/share/server/core/classes/WuiViewMapAddModify.php 
b/share/server/core/classes/WuiViewMapAddModify.php
index bb6a5dc..f2497a5 100644
--- a/share/server/core/classes/WuiViewMapAddModify.php
+++ b/share/server/core/classes/WuiViewMapAddModify.php
@@ -281,6 +281,16 @@ class WuiViewMapAddModify {
                     $ret .= $this->inputField($propname, $value, $hideField);
                 break;
             }
+            
+            // Try to split too long values in chunks
+            // At the moment the only way is to try to add a space after each 
",".
+            // The browsers do break automatically at & and spaces - so no 
need to
+            // do anything there. Seems to be enough for now
+            if(strlen($valueTxt) > 36 && strpos($valueTxt, ' ') === false) {
+                if(strpos($valueTxt, ',') !== false) {
+                    $valueTxt = str_replace(',', ', ', $valueTxt);
+                }
+            }
 
             $ret .= '<span 
id="_txt_'.$propname.'"'.$hideTxt.'>'.$valueTxt.'</span>';
 


------------------------------------------------------------------------------
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

Reply via email to