X-Git-Url: http://sigrok.org/gitweb/?a=blobdiff_plain;f=pv%2Fapplication.hpp;h=61fe46e2480dc855210e586230c2e6960e070101;hb=3d6ff1cd;hp=8d0ebd4d581e9995495d777b9cb2473dcba991a2;hpb=7a01bd3654ed046216308fa64edfd79be7cd525f;p=pulseview.git
diff --git a/pv/application.hpp b/pv/application.hpp
index 8d0ebd4d..61fe46e2 100644
--- a/pv/application.hpp
+++ b/pv/application.hpp
@@ -14,21 +14,60 @@
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
+ * along with this program; if not, see .
*/
#ifndef PULSEVIEW_PV_APPLICATION_HPP
#define PULSEVIEW_PV_APPLICATION_HPP
+#include
+
#include
+#include
+#include
+
+#include
+
+#include "globalsettings.hpp"
-class Application : public QApplication
+using std::shared_ptr;
+using std::pair;
+using std::vector;
+
+class Application : public QApplication, public pv::GlobalSettingsInterface
{
+ Q_OBJECT
+
public:
Application(int &argc, char* argv[]);
+
+ QStringList get_languages();
+ void switch_language(const QString& language);
+ void on_setting_changed(const QString &key, const QVariant &value);
+
+ void collect_version_info(shared_ptr context);
+ void print_version_info();
+
+ vector< pair > get_version_info() const;
+ vector get_fw_path_list() const;
+ vector get_pd_path_list() const;
+ vector< pair > get_driver_list() const;
+ vector< pair > get_input_format_list() const;
+ vector< pair > get_output_format_list() const;
+ vector< pair > get_pd_list() const;
+
private:
bool notify(QObject *receiver, QEvent *event);
+
+ vector< pair > version_info_;
+ vector fw_path_list_;
+ vector pd_path_list_;
+ vector< pair > driver_list_;
+ vector< pair > input_format_list_;
+ vector< pair > output_format_list_;
+ vector< pair > pd_list_;
+
+ QTranslator app_translator_, qt_translator_, qtbase_translator_;
};
#endif // PULSEVIEW_PV_APPLICATION_HPP