forked from qt-creator/qt-creator
Debugger: Move main splitter creation to DebugMainWindow setup
To allow other mode main windows to re-use the perspective concept. Change-Id: Icf00b4f0e4bd73a09ebec131ef9c578154f25eec Reviewed-by: Christian Stenger <christian.stenger@theqtcompany.com>
This commit is contained in:
@@ -41,6 +41,8 @@ class QComboBox;
|
||||
class QStackedWidget;
|
||||
QT_END_NAMESPACE
|
||||
|
||||
namespace Core { class IMode; }
|
||||
|
||||
namespace Utils {
|
||||
|
||||
class DEBUGGER_EXPORT Perspective
|
||||
@@ -98,7 +100,7 @@ private:
|
||||
QList<QWidget *> m_widgets;
|
||||
};
|
||||
|
||||
class DebuggerMainWindow : public FancyMainWindow
|
||||
class DEBUGGER_EXPORT DebuggerMainWindow : public FancyMainWindow
|
||||
{
|
||||
Q_OBJECT
|
||||
|
||||
@@ -113,12 +115,14 @@ public:
|
||||
void resetCurrentPerspective();
|
||||
void restorePerspective(const QByteArray &perspectiveId);
|
||||
|
||||
void finalizeSetup();
|
||||
void finalizeSetup(Core::IMode *mode, QWidget *central = 0);
|
||||
|
||||
void showStatusMessage(const QString &message, int timeoutMS);
|
||||
QDockWidget *dockWidget(const QByteArray &dockId) const;
|
||||
QByteArray currentPerspective() const { return m_currentPerspectiveId; }
|
||||
|
||||
QWidget *modeWindow();
|
||||
|
||||
private:
|
||||
QDockWidget *registerDockWidget(const QByteArray &dockId, QWidget *widget);
|
||||
void loadPerspectiveHelper(const QByteArray &perspectiveId, bool fromStoredSettings = true);
|
||||
@@ -136,6 +140,8 @@ private:
|
||||
// list of dock widgets to prevent memory leak
|
||||
typedef QPointer<QDockWidget> DockPtr;
|
||||
QList<DockPtr> m_dockWidgets;
|
||||
|
||||
QWidget *m_modeWindow = 0;
|
||||
};
|
||||
|
||||
} // Utils
|
||||
|
||||
Reference in New Issue
Block a user