summaryrefslogtreecommitdiffstats
path: root/kdm/kfrontend
diff options
context:
space:
mode:
authortpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2010-09-09 19:37:03 +0000
committertpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2010-09-09 19:37:03 +0000
commit9d2894b68e0a4d12c64522a06387866518b64681 (patch)
treeefa33161bde9e31a4d1606b0295dc38907393a53 /kdm/kfrontend
parent694e4310ef69e1a9a4287c38926273f7d482c4e8 (diff)
downloadtdebase-9d2894b68e0a4d12c64522a06387866518b64681.tar.gz
tdebase-9d2894b68e0a4d12c64522a06387866518b64681.zip
* Added support for using existing KDM background to KDM themer
* Fixed O2 Enterprise KDM theme git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdebase@1173589 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'kdm/kfrontend')
-rw-r--r--kdm/kfrontend/themer/kdmpixmap.cpp15
-rw-r--r--kdm/kfrontend/themes/o2_enterprise/Dialog.pngbin5099 -> 5098 bytes
-rw-r--r--kdm/kfrontend/themes/o2_enterprise/background.jpgbin965444 -> 0 bytes
-rw-r--r--kdm/kfrontend/themes/o2_enterprise/enterprise.xml2
4 files changed, 14 insertions, 3 deletions
diff --git a/kdm/kfrontend/themer/kdmpixmap.cpp b/kdm/kfrontend/themer/kdmpixmap.cpp
index f18194f53..02ee5626e 100644
--- a/kdm/kfrontend/themer/kdmpixmap.cpp
+++ b/kdm/kfrontend/themer/kdmpixmap.cpp
@@ -42,8 +42,8 @@ KdmPixmap::KdmPixmap( KdmItem *parent, const TQDomNode &node, const char *name )
itemType = "pixmap";
// Set default values for pixmap (note: strings are already Null)
- pixmap.normal.tint.setRgb( 0xFFFFFF );
- pixmap.normal.alpha = 1.0;
+ pixmap.normal.tint.setRgb( 0x800000 );
+ pixmap.normal.alpha = 0.0;
pixmap.active.present = false;
pixmap.prelight.present = false;
@@ -63,6 +63,17 @@ KdmPixmap::KdmPixmap( KdmItem *parent, const TQDomNode &node, const char *name )
pixmap.normal.fullpath = fullPath( el.attribute( "file", "" ) );
parseColor( el.attribute( "tint", "#ffffff" ), pixmap.normal.tint );
pixmap.normal.alpha = el.attribute( "alpha", "1.0" ).toFloat();
+
+ if (el.attribute( "file", "" ) == "@@@KDMBACKGROUND@@@") {
+ // Use the preset KDM background...
+ KStandardDirs *m_pDirs = KGlobal::dirs();
+ KSimpleConfig *config = new KSimpleConfig( TQFile::decodeName( _backgroundCfg ) );
+ config->setGroup("Desktop0");
+ pixmap.normal.fullpath = m_pDirs->findResource("wallpaper", config->readPathEntry("Wallpaper"));
+ // TODO: Detect when there is no wallpaper and use the background settings instead
+ delete config;
+ }
+
} else if (tagName == "active") {
pixmap.active.present = true;
pixmap.active.fullpath = fullPath( el.attribute( "file", "" ) );
diff --git a/kdm/kfrontend/themes/o2_enterprise/Dialog.png b/kdm/kfrontend/themes/o2_enterprise/Dialog.png
index 47d4db8af..440bf6f43 100644
--- a/kdm/kfrontend/themes/o2_enterprise/Dialog.png
+++ b/kdm/kfrontend/themes/o2_enterprise/Dialog.png
Binary files differ
diff --git a/kdm/kfrontend/themes/o2_enterprise/background.jpg b/kdm/kfrontend/themes/o2_enterprise/background.jpg
deleted file mode 100644
index 7a3f643f8..000000000
--- a/kdm/kfrontend/themes/o2_enterprise/background.jpg
+++ /dev/null
Binary files differ
diff --git a/kdm/kfrontend/themes/o2_enterprise/enterprise.xml b/kdm/kfrontend/themes/o2_enterprise/enterprise.xml
index 11849cc62..42e37f890 100644
--- a/kdm/kfrontend/themes/o2_enterprise/enterprise.xml
+++ b/kdm/kfrontend/themes/o2_enterprise/enterprise.xml
@@ -2,7 +2,7 @@
<!DOCTYPE greeter SYSTEM "greeter.dtd">
<greeter>
<item type="pixmap" >
- <normal file="background.jpg" />
+ <normal file="@@@KDMBACKGROUND@@@" />
<pos width="100%" x="0" y="0" height="100%" />
</item>
<item type="pixmap" >