Module: nagvis
Branch: master
Commit: f4c4aecf07e8a8eafabf422b94eaef87e4f43165
URL:    
http://nagvis.git.sourceforge.net/git/gitweb.cgi?p=nagvis/nagvis;a=commit;h=f4c4aecf07e8a8eafabf422b94eaef87e4f43165

Author: LaMi <[email protected]>
Date:   Sat Feb 13 19:09:30 2010 +0100

#188 The default background color is now transparent; Automaps can handle the 
background_color attribute now

---

 docs/en_US/nagvis_config_format_description.html |    2 +-
 share/server/core/classes/GlobalMainCfg.php      |    4 ++--
 share/server/core/classes/NagVisAutoMap.php      |    1 +
 3 files changed, 4 insertions(+), 3 deletions(-)

diff --git a/docs/en_US/nagvis_config_format_description.html 
b/docs/en_US/nagvis_config_format_description.html
index e7ef679..2573741 100644
--- a/docs/en_US/nagvis_config_format_description.html
+++ b/docs/en_US/nagvis_config_format_description.html
@@ -131,7 +131,7 @@
                <td> backend </td><td> ndomy_1 </td><td> Default backend (ID of 
the backend - copy the text from which <code>&lt;backend-id></code> stands for 
in <code>[backend_&lt;backend-id>]</code> ) </td>
                </tr>
                <tr>
-               <td> backgroundcolor </td><td> #fff </td><td> Default 
background color of maps </td>
+               <td>backgroundcolor</td><td>transparent</td><td>Default 
background color of maps </td>
                </tr>
                <tr>
                <td>contextmenu</td><td>0</td><td>Enable/Disable the context 
menu on your map objects. (<font color="#ff0000">New in 1.4</font>)</td>
diff --git a/share/server/core/classes/GlobalMainCfg.php 
b/share/server/core/classes/GlobalMainCfg.php
index 57ef66a..4c29866 100644
--- a/share/server/core/classes/GlobalMainCfg.php
+++ b/share/server/core/classes/GlobalMainCfg.php
@@ -129,7 +129,7 @@ class GlobalMainCfg {
                                        'match' => MATCH_STRING_NO_SPACE),
                                'backgroundcolor' => Array('must' => 0,
                                        'editable' => 1,
-                                       'default' => '#fff',
+                                       'default' => 'transparent',
                                        'match' => MATCH_COLOR),
                                'contextmenu' => Array('must' => 0,
                                        'editable' => 1,
@@ -582,7 +582,7 @@ class GlobalMainCfg {
                                        'match' => MATCH_BOOLEAN),
                                'backgroundcolor' => Array('must' => 0,
                                        'editable' => 1,
-                                       'default' => '#fff',
+                                       'default' => '#ffffff',
                                        'match' => MATCH_COLOR)),
                        'worker' => Array(
                                'interval' => Array('must' => 0,
diff --git a/share/server/core/classes/NagVisAutoMap.php 
b/share/server/core/classes/NagVisAutoMap.php
index 5bc2831..8c44cac 100644
--- a/share/server/core/classes/NagVisAutoMap.php
+++ b/share/server/core/classes/NagVisAutoMap.php
@@ -217,6 +217,7 @@ class NagVisAutoMap extends GlobalMap {
                $str .= 'dpi="72", ';
                //ratio: expand, auto, fill, compress
                $str .= 'ratio="fill", ';
+               $str .= 'bgcolor="'.$this->MAPCFG->getValue('global', 0, 
'background_color').'", ';
                $str .= 
'root="'.$this->rootObject->getType().'_'.$this->rootObject->getObjectId().'", 
';
                
                /* Directed (dot) only */


------------------------------------------------------------------------------
SOLARIS 10 is the OS for Data Centers - provides features such as DTrace,
Predictive Self Healing and Award Winning ZFS. Get Solaris 10 NOW
http://p.sf.net/sfu/solaris-dev2dev
_______________________________________________
Nagvis-checkins mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/nagvis-checkins

Reply via email to