Add option for loading voltage presets on power kernels
[qcpufreq] / src / mainwindow.h
old mode 100755 (executable)
new mode 100644 (file)
index 13eae27..920f6a5
@@ -1,6 +1,6 @@
 /*
  * QCPUFreq - a simple cpufreq GUI
- * Copyright (C) 2010 Daniel Klaffenbach <daniel.klaffenbach@cs.tu-chemnitz.de>
+ * Copyright (C) 2010 Daniel Klaffenbach <danielklaffenbach@gmail.com>
  *
  * This program is free software: you can redistribute it and/or modify
  * it under the terms of the GNU General Public License as published by
 #include <QMainWindow>
 #include <QGraphicsScene>
 #include <QTimer>
+#include <QProcess>
+#include <QStringList>
+
+#include "helpwindow.h"
+#include "settings.h"
 
 namespace Ui {
     class MainWindow;
@@ -38,10 +43,16 @@ public:
 public slots:
     void about();
     void adjustFreq();
+    void applySettings();
+    void loadPreset();
     void orientationChanged();
     void refresh();
-    void setAutoRotaion();
+    void save();
+    void setAdvancedTemperature();
+    void setAutoRotation();
     void setSmartReflex();
+    void showHelp();
+    void showSettings();
 
 
 private:
@@ -55,11 +66,24 @@ private:
     int getScalingStep( int freq );
     int getScalingSteps();
     int getSmartReflexState();
+    //! The helper process
+    QProcess helperProcess;
+    //! The help window
+    HelpWindow helpWindow;
+    //! Initializes the application
+    void init();
+    int minFreq;
     QString readSysFile( QString sys_file );
     //! the timer for refreshing the UI
-    QTimer *refreshTimer;
+    QTimer refreshTimer;
+    //! The amount of scaling steps
+    int scalingSteps;
+    //! The available scaling frequencies
+    QStringList scalingFrequencies;
     //! the QGraphicsScene will contain the large chip icon displayed in the UI
-    QGraphicsScene *scene;
+    QGraphicsScene scene;
+    bool showSudoError;
+    Settings *settings;
     bool usePortrait();
 };