[PC-BSD Commits] r17969 - in pcbsd/current/src-qt4/pc-controlpanel: . items/hardware

svn at pcbsd.org svn at pcbsd.org
Fri Jul 27 08:16:45 PDT 2012


Author: kris
Date: 2012-07-27 15:16:44 +0000 (Fri, 27 Jul 2012)
New Revision: 17969

Modified:
   pcbsd/current/src-qt4/pc-controlpanel/items/hardware/pc-xgui.desktop
   pcbsd/current/src-qt4/pc-controlpanel/pbiinfo.cpp
Log:

Fix a potential issue causing the UI to hang in Control Panel



Modified: pcbsd/current/src-qt4/pc-controlpanel/items/hardware/pc-xgui.desktop
===================================================================
--- pcbsd/current/src-qt4/pc-controlpanel/items/hardware/pc-xgui.desktop	2012-07-27 14:47:26 UTC (rev 17968)
+++ pcbsd/current/src-qt4/pc-controlpanel/items/hardware/pc-xgui.desktop	2012-07-27 15:16:44 UTC (rev 17969)
@@ -5,7 +5,7 @@
 Exec=pc-su pc-runxgui
 Type=Application
 Icon=video-display
-PC-TryMessage=Are you sure you want to run the display setup wizard? Doing so will exit the current desktop session and any unsaved files will be lost.
+PC-TryMessage=Schedule the display wizard to run after the next reboot?
 Keywords="screen,monitor,resolution,screen resolution,video,video adapter,video card"
 Categories=Settings;System;
 Name=Display

Modified: pcbsd/current/src-qt4/pc-controlpanel/pbiinfo.cpp
===================================================================
--- pcbsd/current/src-qt4/pc-controlpanel/pbiinfo.cpp	2012-07-27 14:47:26 UTC (rev 17968)
+++ pcbsd/current/src-qt4/pc-controlpanel/pbiinfo.cpp	2012-07-27 15:16:44 UTC (rev 17969)
@@ -26,6 +26,7 @@
 
 #include <QProcess>
 #include <QFile>
+#include <QCoreApplication>
 #include <QTextStream>
 
 static const char* const GENERIC_NAME_FIELD = "PBI Information for:";
@@ -68,7 +69,10 @@
     QProcess* loadPBIs = new QProcess();
     loadPBIs->setProcessChannelMode(QProcess::MergedChannels);
     loadPBIs->start(QString("pbi_info"), QStringList() << "-v");
-    loadPBIs->waitForFinished(-1);
+    while(loadPBIs->state() == QProcess::Starting || loadPBIs->state() == QProcess::Running) {
+      loadPBIs->waitForFinished(200);
+      QCoreApplication::processEvents();
+    }
     QString line;
     while ( loadPBIs->canReadLine() )
     {



More information about the Commits mailing list