Provide status messages on splash screen when loading (#1696)
This commit is contained in:
@@ -27,6 +27,9 @@
|
||||
#define ENGINE_H
|
||||
|
||||
#include <QtCore/QMap>
|
||||
#include <QtCore/QString>
|
||||
#include <QtCore/QObject>
|
||||
|
||||
|
||||
#include "export.h"
|
||||
|
||||
@@ -39,8 +42,9 @@ class Song;
|
||||
class Ladspa2LMMS;
|
||||
|
||||
|
||||
class EXPORT Engine
|
||||
class EXPORT Engine : public QObject
|
||||
{
|
||||
Q_OBJECT
|
||||
public:
|
||||
static void init();
|
||||
static void destroy();
|
||||
@@ -94,6 +98,18 @@ public:
|
||||
return s_pluginFileHandling;
|
||||
}
|
||||
|
||||
static inline Engine * inst()
|
||||
{
|
||||
if( s_instanceOfMe == NULL )
|
||||
{
|
||||
s_instanceOfMe = new Engine();
|
||||
}
|
||||
return s_instanceOfMe;
|
||||
}
|
||||
|
||||
signals:
|
||||
void initProgress(const QString &msg);
|
||||
|
||||
|
||||
private:
|
||||
// small helper function which sets the pointer to NULL before actually deleting
|
||||
@@ -120,6 +136,9 @@ private:
|
||||
|
||||
static QMap<QString, QString> s_pluginFileHandling;
|
||||
|
||||
// even though most methods are static, an instance is needed for Qt slots/signals
|
||||
static Engine * s_instanceOfMe;
|
||||
|
||||
static void initPluginFileHandling();
|
||||
|
||||
friend class GuiApplication;
|
||||
|
||||
@@ -25,8 +25,12 @@
|
||||
#ifndef GUIAPPLICATION_H
|
||||
#define GUIAPPLICATION_H
|
||||
|
||||
#include <QtCore/QObject>
|
||||
|
||||
#include "export.h"
|
||||
|
||||
class QLabel;
|
||||
|
||||
class AutomationEditorWindow;
|
||||
class BBEditor;
|
||||
class ControllerRackView;
|
||||
@@ -36,8 +40,9 @@ class PianoRollWindow;
|
||||
class ProjectNotes;
|
||||
class SongEditorWindow;
|
||||
|
||||
class EXPORT GuiApplication
|
||||
class EXPORT GuiApplication : public QObject
|
||||
{
|
||||
Q_OBJECT;
|
||||
public:
|
||||
explicit GuiApplication();
|
||||
~GuiApplication();
|
||||
@@ -53,6 +58,9 @@ public:
|
||||
AutomationEditorWindow* automationEditor() { return m_automationEditor; }
|
||||
ControllerRackView* getControllerRackView() { return m_controllerRackView; }
|
||||
|
||||
public slots:
|
||||
void displayInitProgress(const QString &msg);
|
||||
|
||||
private:
|
||||
static GuiApplication* s_instance;
|
||||
|
||||
@@ -64,6 +72,7 @@ private:
|
||||
PianoRollWindow* m_pianoRoll;
|
||||
ProjectNotes* m_projectNotes;
|
||||
ControllerRackView* m_controllerRackView;
|
||||
QLabel* m_loadingProgressLabel;
|
||||
};
|
||||
|
||||
#define gui GuiApplication::instance()
|
||||
|
||||
@@ -190,6 +190,7 @@ private slots:
|
||||
|
||||
signals:
|
||||
void periodicUpdate();
|
||||
void initProgress(const QString &msg);
|
||||
|
||||
} ;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user