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

svn at pcbsd.org svn at pcbsd.org
Fri Feb 15 15:32:06 PST 2013


Author: kenmoore
Date: 2013-02-15 23:32:06 +0000 (Fri, 15 Feb 2013)
New Revision: 21558

Modified:
   pcbsd-projects/PCDM/main.cpp
   pcbsd-projects/PCDM/pcdm-gui.cpp
   pcbsd-projects/PCDM/pcdm-gui.h
Log:
Try disabling the splashscreen entirely to see how much startup time is saved



Modified: pcbsd-projects/PCDM/main.cpp
===================================================================
--- pcbsd-projects/PCDM/main.cpp	2013-02-15 23:20:00 UTC (rev 21557)
+++ pcbsd-projects/PCDM/main.cpp	2013-02-15 23:32:06 UTC (rev 21558)
@@ -36,12 +36,12 @@
   QApplication a(argc,argv); 
   
   // Show our splash screen, so the user doesn't freak that that it takes a few seconds to show up
-  QSplashScreen splash;
+  /*QSplashScreen splash;
   if(!Config::splashscreen().isEmpty()){
     splash.setPixmap( QPixmap(Config::splashscreen()) ); //load the splashscreen file
   }
-  splash.show();
-  qDebug() << "SplashScreen Started:" << QString::number(clock.elapsed())+" ms";
+  splash.show();*/
+  qDebug() << "No SplashScreen Started:" << QString::number(clock.elapsed())+" ms";
   //Initialize the xprocess
   XProcess desktop;
   
@@ -60,7 +60,7 @@
 	desktop.setXCommand(dcmd);
 	desktop.setXHomeDir( Backend::getUserHomeDir(user) );
 	desktop.startXSession();
-	splash.close();
+	//splash.close();
 	goodAL=TRUE; //flag this as a good login to skip the GUI
     }
   }
@@ -91,6 +91,7 @@
     Backend::log("Starting up PCDM interface");
     PCDMgui w;
     qDebug() << "Main GUI Created:" << QString::number(clock.elapsed())+" ms";
+    //splash.finish(&w); //close the splash when the GUI starts up
     //Set the proper size on the Application
     //if(Theme::isFullScreen() ){
       w.setWindowFlags(w.windowFlags() ^Qt::WindowSoftkeysVisibleHint);
@@ -114,9 +115,8 @@
     QObject::connect( &w,SIGNAL(xHomeFound(QString)), &desktop,SLOT(setXHomeDir(QString)) );
     QObject::connect( &w,SIGNAL(xSessionStart()), &desktop,SLOT(startXSession()) );
     
-    
+    qDebug() << "Showing GUI:" << QString::number(clock.elapsed())+" ms";
     w.show();
-    splash.finish(&w);
     qDebug() << "Starting GUI:" << QString::number(clock.elapsed())+" ms";
     returnCode = a.exec();
     Backend::startXSession();

Modified: pcbsd-projects/PCDM/pcdm-gui.cpp
===================================================================
--- pcbsd-projects/PCDM/pcdm-gui.cpp	2013-02-15 23:20:00 UTC (rev 21557)
+++ pcbsd-projects/PCDM/pcdm-gui.cpp	2013-02-15 23:32:06 UTC (rev 21558)
@@ -11,6 +11,8 @@
 
 PCDMgui::PCDMgui() : QMainWindow()
 {
+    //timer = new QTime();
+    //timer->start();
     //Load the Theme
     loadTheme();
 

Modified: pcbsd-projects/PCDM/pcdm-gui.h
===================================================================
--- pcbsd-projects/PCDM/pcdm-gui.h	2013-02-15 23:20:00 UTC (rev 21557)
+++ pcbsd-projects/PCDM/pcdm-gui.h	2013-02-15 23:32:06 UTC (rev 21558)
@@ -63,6 +63,7 @@
     QProcess* vkbd;
     QStringList kModels, kLayouts;
     ThemeStruct* currentTheme;
+    QTime* timer;
 
     QTranslator* m_translator;
     QString translationDir;



More information about the Commits mailing list