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

svn at pcbsd.org svn at pcbsd.org
Fri Feb 15 17:20:53 PST 2013


Author: kenmoore
Date: 2013-02-16 01:20:53 +0000 (Sat, 16 Feb 2013)
New Revision: 21565

Modified:
   pcbsd-projects/PCDM/pcdm-gui.cpp
   pcbsd-projects/PCDM/pcdm-gui.h
   pcbsd-projects/PCDM/pcdm.theme
Log:
Remove the timing debugs, got it starting up in under a sec on my VM now.



Modified: pcbsd-projects/PCDM/pcdm-gui.cpp
===================================================================
--- pcbsd-projects/PCDM/pcdm-gui.cpp	2013-02-16 01:01:41 UTC (rev 21564)
+++ pcbsd-projects/PCDM/pcdm-gui.cpp	2013-02-16 01:20:53 UTC (rev 21565)
@@ -11,14 +11,12 @@
 
 PCDMgui::PCDMgui() : QMainWindow()
 {
-    timer = new QTime();
-    timer->start();
     //Load the Theme
     loadTheme();
-    qDebug() << "GUI Time: Theme Loaded:" << QString::number(timer->elapsed()) + " ms";
     //Create the GUI based upon the current Theme
     createGUIfromTheme();
-    qDebug() << "GUI Time: GUI Created:" << QString::number(timer->elapsed())+" ms";
+    //Now make sure that the login widget has focus
+    loginW->resetFocus(); 
 }
 
 PCDMgui::~PCDMgui()
@@ -60,12 +58,11 @@
   //Set the application style sheet
   style.append(" "+ currentTheme->styleSheet() );
   this->setStyleSheet( style.simplified() );
-  qDebug() << "GUI Time: StyleSheet Set:" << QString::number(timer->elapsed()) + " ms";
+
   //get the default translation directory
   translationDir = QApplication::applicationDirPath() + "/i18n/";
   //Fill the translator
   m_translator = new QTranslator();
-  qDebug() << "GUI Time: Translator Loaded:" << QString::number(timer->elapsed()) + " ms";
   //Create the Toolbar
   toolbar = new QToolBar();
   //Add the Toolbar to the window
@@ -92,7 +89,6 @@
     else{ toolbar->setToolButtonStyle(Qt::ToolButtonIconOnly); } //default to icon only
     
     toolbar->setIconSize( currentTheme->itemIconSize("toolbar") ); //use theme size
-    qDebug() << "GUI Time: Toolbar Created:" << QString::number(timer->elapsed()) + " ms";
   //Populate the Toolbar with items (starts at leftmost/topmost)
     //----Virtual Keyboard
     tmpIcon = currentTheme->itemIcon("vkeyboard");
@@ -100,7 +96,6 @@
     virtkeyboardButton = new QAction( QIcon(tmpIcon),tr("Virtual Keyboard"),this );
     toolbar->addAction(virtkeyboardButton);
     connect( virtkeyboardButton, SIGNAL(triggered()), this, SLOT(slotPushVirtKeyboard()) );
-    qDebug() << "GUI Time: VKeyboard Created:" << QString::number(timer->elapsed()) + " ms";
 
     //----Locale Switcher
     tmpIcon = currentTheme->itemIcon("locale");
@@ -108,7 +103,6 @@
     localeButton = new QAction( QIcon(tmpIcon),tr("Locale"),this );
     toolbar->addAction(localeButton);
     connect( localeButton, SIGNAL(triggered()), this, SLOT(slotChangeLocale()) );
-    qDebug() << "GUI Time: Locale Created:" << QString::number(timer->elapsed()) + " ms";
     
     //----Keyboard Layout Switcher
     tmpIcon = currentTheme->itemIcon("keyboard");
@@ -116,13 +110,11 @@
     keyboardButton = new QAction( QIcon(tmpIcon),tr("Keyboard Layout"),this );
     toolbar->addAction(keyboardButton);
     connect( keyboardButton, SIGNAL(triggered()), this, SLOT(slotChangeKeyboardLayout()) );
-    qDebug() << "GUI Time: Keyboard Created:" << QString::number(timer->elapsed()) + " ms";
     
     //----Add a spacer
     QWidget* spacer = new QWidget();
     spacer->setSizePolicy(QSizePolicy::Expanding, QSizePolicy::Expanding);
     toolbar->addWidget(spacer);
-    qDebug() << "GUI Time: Tool Spacer Created:" << QString::number(timer->elapsed()) + " ms";
     
     //----System Shutdown/Restart
     tmpIcon = currentTheme->itemIcon("system");
@@ -133,7 +125,6 @@
     systemMenu = new QMenu();
     toolbar->addWidget(systemButton);
     systemButton->setPopupMode( QToolButton::InstantPopup );
-    qDebug() << "GUI Time: System Created:" << QString::number(timer->elapsed()) + " ms";
     
   //Create the grid layout
   QGridLayout* grid = new QGridLayout;
@@ -150,7 +141,6 @@
                       currentTheme->itemLocation("header","rowspan"), \
                       currentTheme->itemLocation("header","colspan"), Qt::AlignCenter);
     }
-    qDebug() << "GUI Time: Header Created:" << QString::number(timer->elapsed()) + " ms";
     
     //Username/Password/Login widget
     loginW = new LoginWidget;
@@ -177,7 +167,6 @@
     //Connect the signals/slots
     connect(loginW,SIGNAL(loginRequested(QString,QString)),this,SLOT(slotStartLogin(QString,QString)));
     connect(loginW,SIGNAL(escapePressed()),this,SLOT(slotShutdownComputer()));
-    qDebug() << "GUI Time: LoginW Created:" << QString::number(timer->elapsed()) + " ms";
     
     //----Desktop Environment Switcher
     //Create the switcher
@@ -192,7 +181,6 @@
                       currentTheme->itemLocation("desktop","col"), \
                       currentTheme->itemLocation("desktop","rowspan"), \
                       currentTheme->itemLocation("desktop","colspan"), Qt::AlignCenter);
-    qDebug() << "GUI Time: DEswitch Created:" << QString::number(timer->elapsed()) + " ms";
 
     //----WINDOW SPACERS
     QStringList spacers = currentTheme->getSpacers();
@@ -207,7 +195,6 @@
         grid->setColumnStretch(col,1);
       }
     }
-    qDebug() << "GUI Time: Spacers Created:" << QString::number(timer->elapsed()) + " ms";
 
   //Connect the grid to the Window
     QWidget* widget = new QWidget;
@@ -215,11 +202,7 @@
     this->setCentralWidget(widget);
     
   //Now translate the UI and set all the text
-  qDebug() << "GUI Time: Widget all Set:" << QString::number(timer->elapsed()) + " ms";
   retranslateUi();
-  qDebug() << "GUI Time: Translation Finished:" << QString::number(timer->elapsed()) + " ms";
-  //Now make sure that the login widget has focus
-  loginW->resetFocus();  
 
 }
 

Modified: pcbsd-projects/PCDM/pcdm-gui.h
===================================================================
--- pcbsd-projects/PCDM/pcdm-gui.h	2013-02-16 01:01:41 UTC (rev 21564)
+++ pcbsd-projects/PCDM/pcdm-gui.h	2013-02-16 01:20:53 UTC (rev 21565)
@@ -17,7 +17,6 @@
 #include <QX11EmbedContainer>
 #include <QSpacerItem>
 #include <QProcessEnvironment>
-#include <QTime>
 
 #include "pcdm-backend.h"
 #include "themeStruct.h"
@@ -63,7 +62,6 @@
     //QX11EmbedContainer* container;
     QProcess* vkbd;
     ThemeStruct* currentTheme;
-    QTime* timer;
 
     QTranslator* m_translator;
     QString translationDir;

Modified: pcbsd-projects/PCDM/pcdm.theme
===================================================================
--- pcbsd-projects/PCDM/pcdm.theme	2013-02-16 01:01:41 UTC (rev 21564)
+++ pcbsd-projects/PCDM/pcdm.theme	2013-02-16 01:20:53 UTC (rev 21565)
@@ -73,7 +73,7 @@
 APP_STYLESHEET_START
 QToolBar{ background-color: rgba(253,253,255,120); }
 QWindow{ background-color: white; color: black; }
-QComboBox{font-size: 32px}
+QComboBox{font-size: 28px}
 QToolButton{ background-color: transparent; border: none; }
 QToolButton:hover{ background-color: transparent; border: 1px solid grey; border-radius: 5px; }
 QGroupBox{ 



More information about the Commits mailing list