[PC-BSD Commits] r21569 - pcbsd-projects/PCDM

svn at pcbsd.org svn at pcbsd.org
Fri Feb 15 17:46:33 PST 2013


Author: kenmoore
Date: 2013-02-16 01:46:33 +0000 (Sat, 16 Feb 2013)
New Revision: 21569

Modified:
   pcbsd-projects/PCDM/fancySwitcher.cpp
   pcbsd-projects/PCDM/pcdm-backend.cpp
Log:
Now the DE switcher should be fixed, was caused by an xsession entry not listing an icon at all.



Modified: pcbsd-projects/PCDM/fancySwitcher.cpp
===================================================================
--- pcbsd-projects/PCDM/fancySwitcher.cpp	2013-02-16 01:36:38 UTC (rev 21568)
+++ pcbsd-projects/PCDM/fancySwitcher.cpp	2013-02-16 01:46:33 UTC (rev 21569)
@@ -193,7 +193,6 @@
     qDebug() << "FancySwitcher: invalid icon file" << icon;
     return;
   }
-  qDebug() << "FancySwitcher: Add Item:" << id << icon;
   if(idL.indexOf(id)==-1){
     idL << id;
     icL << new QGraphicsPixmapItem(QPixmap(icon).scaled(iconSize,iconSize));

Modified: pcbsd-projects/PCDM/pcdm-backend.cpp
===================================================================
--- pcbsd-projects/PCDM/pcdm-backend.cpp	2013-02-16 01:36:38 UTC (rev 21568)
+++ pcbsd-projects/PCDM/pcdm-backend.cpp	2013-02-16 01:46:33 UTC (rev 21569)
@@ -363,7 +363,7 @@
     if(!tmp.isEmpty()){
       //Complete file paths if necessary
       if(!tmp[0].startsWith("/")){ tmp[0] = "/usr/local/bin/"+tmp[0]; }
-      if(!tmp[3].startsWith("/")&&!tmp[3].startsWith(":")){ tmp[3] = xIconDir+tmp[3]; }
+      if(!tmp[3].startsWith("/")&&!tmp[3].startsWith(":")&&!tmp[3].isEmpty()){ tmp[3] = xIconDir+tmp[3]; }
       if(!tmp[4].startsWith("/")){ tmp[4] = "/usr/local/bin/"+tmp[4]; }
       //Check for valid DE
       if(QFile::exists(tmp[0]) && QFile::exists(tmp[4])){
@@ -372,7 +372,7 @@
 	instXNameList << tmp[1];
 	instXCommentList << tmp[2];
 	//Check to make sure we have a valid icon
-	if( !QFile::exists(tmp[3]) ){ tmp[3] = ""; }
+	if(!tmp[3].isEmpty() && !QFile::exists(tmp[3]) ){ tmp[3] = ""; }
 	instXIconList << tmp[3];
 	Backend::log( "PCDM: Found xsession: " + tmp.join(" ") );
       }



More information about the Commits mailing list