Commit 48bfd1c9 authored by Kai Koehne's avatar Kai Koehne

Qt4ProjectManager: Revamp of Qt Versions dialog

The versions dialog now uses Utils::DetailsWidget to show the
general version information and (debugging) helper information.

The 'Helper Tools' can now be expanded to see each tools status
& recompile them selectively.
parent 33703a46
<?xml version="1.0" encoding="UTF-8"?>
<ui version="4.0">
<class>Qt4ProjectManager::Internal::DebuggingHelper</class>
<widget class="QWidget" name="Qt4ProjectManager::Internal::DebuggingHelper">
<property name="geometry">
<rect>
<x>0</x>
<y>0</y>
<width>217</width>
<height>128</height>
</rect>
</property>
<layout class="QVBoxLayout" name="verticalLayout">
<property name="margin">
<number>0</number>
</property>
<item>
<layout class="QGridLayout" name="gridLayout">
<item row="0" column="0">
<widget class="QLabel" name="gdbHelperLabel">
<property name="toolTip">
<string>Helps showing content of Qt types. Only used in older versions of gdb.</string>
</property>
<property name="text">
<string>Gdb Helper:</string>
</property>
</widget>
</item>
<item row="0" column="1">
<widget class="QLabel" name="gdbHelperStatus">
<property name="text">
<string>TextLabel</string>
</property>
</widget>
</item>
<item row="0" column="2">
<spacer name="horizontalSpacer">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>40</width>
<height>20</height>
</size>
</property>
</spacer>
</item>
<item row="1" column="0">
<widget class="QLabel" name="qmlDumpLabel">
<property name="toolTip">
<string>Used to extract QML type information from library-based plugins.</string>
</property>
<property name="text">
<string>Qml Dump:</string>
</property>
</widget>
</item>
<item row="1" column="1">
<widget class="QLabel" name="qmlDumpStatus">
<property name="text">
<string>TextLabel</string>
</property>
</widget>
</item>
<item row="1" column="2">
<spacer name="horizontalSpacer_2">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>40</width>
<height>20</height>
</size>
</property>
</spacer>
</item>
<item row="2" column="0">
<widget class="QLabel" name="qmlObserverLabel">
<property name="toolTip">
<string>Version of qmlviewer with support for Qml/JS debugging.</string>
</property>
<property name="text">
<string>Qml Observer:</string>
</property>
</widget>
</item>
<item row="2" column="1">
<widget class="QLabel" name="qmlObserverStatus">
<property name="text">
<string>TextLabel</string>
</property>
</widget>
</item>
<item row="2" column="2">
<spacer name="horizontalSpacer_3">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>40</width>
<height>20</height>
</size>
</property>
</spacer>
</item>
<item row="0" column="4">
<widget class="QPushButton" name="gdbHelperBuildButton">
<property name="text">
<string>Build</string>
</property>
</widget>
</item>
<item row="1" column="4">
<widget class="QPushButton" name="qmlDumpBuildButton">
<property name="text">
<string>Build</string>
</property>
</widget>
</item>
<item row="2" column="4">
<widget class="QPushButton" name="qmlObserverBuildButton">
<property name="text">
<string>Build</string>
</property>
</widget>
</item>
</layout>
</item>
<item>
<layout class="QHBoxLayout" name="horizontalLayout">
<item>
<spacer name="horizontalSpacer_4">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>40</width>
<height>20</height>
</size>
</property>
</spacer>
</item>
<item>
<widget class="QPushButton" name="showLogButton">
<property name="toolTip">
<string>Show compiler output of last build.</string>
</property>
<property name="text">
<string>Show Log</string>
</property>
</widget>
</item>
<item>
<widget class="QPushButton" name="rebuildButton">
<property name="toolTip">
<string>Compile debugging helpers that are checked.</string>
</property>
<property name="text">
<string>Build All</string>
</property>
</widget>
</item>
</layout>
</item>
</layout>
</widget>
<resources/>
<connections/>
</ui>
......@@ -42,7 +42,7 @@ using namespace Qt4ProjectManager::Internal;
using ProjectExplorer::DebuggingHelperLibrary;
DebuggingHelperBuildTask::DebuggingHelperBuildTask(QtVersion *version, DebuggingHelperTools tools)
DebuggingHelperBuildTask::DebuggingHelperBuildTask(QtVersion *version, Tools tools)
{
//
// Extract all information we need from version, such that we don't depend on the existence
......
......@@ -51,9 +51,9 @@ public:
QmlDump = 0x04,
AllTools = GdbDebugging | QmlObserver | QmlDump
};
Q_DECLARE_FLAGS(DebuggingHelperTools, DebuggingHelper)
Q_DECLARE_FLAGS(Tools, DebuggingHelper)
explicit DebuggingHelperBuildTask(QtVersion *version, DebuggingHelperTools tools = AllTools);
explicit DebuggingHelperBuildTask(QtVersion *version, Tools tools = AllTools);
virtual ~DebuggingHelperBuildTask();
void run(QFutureInterface<void> &future);
......@@ -64,7 +64,7 @@ signals:
private:
bool buildDebuggingHelper(QFutureInterface<void> &future, QString *output);
DebuggingHelperTools m_tools;
Tools m_tools;
int m_qtId;
QString m_qtInstallData;
......
......@@ -142,7 +142,10 @@ FORMS += makestep.ui \
wizards/mobileappwizardgenericoptionspage.ui \
wizards/mobileappwizardsymbianoptionspage.ui \
wizards/mobileappwizardmaemooptionspage.ui \
librarydetailswidget.ui
librarydetailswidget.ui \
qtversioninfo.ui \
debugginghelper.ui \
debugginghelper.ui
RESOURCES += qt4projectmanager.qrc \
wizards/wizards.qrc
......
......@@ -41,6 +41,8 @@
#include <QtGui/QWidget>
#include "debugginghelperbuildtask.h"
QT_BEGIN_NAMESPACE
class QTreeWidgetItem;
QT_END_NAMESPACE
......@@ -53,6 +55,8 @@ typedef QSharedPointer<QtVersion> QSharedPointerQtVersion;
namespace Internal {
namespace Ui {
class QtVersionManager;
class QtVersionInfo;
class DebuggingHelper;
}
class QtOptionsPageWidget : public QWidget
......@@ -75,20 +79,13 @@ private:
QTreeWidgetItem *treeItemForIndex(int index) const;
QtVersion *currentVersion() const;
int currentIndex() const;
void updateDebuggingHelperStateLabel(const QtVersion *version = 0);
QIcon debuggerHelperIconForQtVersion(const QtVersion *version);
QPixmap debuggerHelperPixmapForQtVersion(const QtVersion *version);
const QPixmap m_debuggingHelperOkPixmap;
const QPixmap m_debuggingHelperErrorPixmap;
const QPixmap m_debuggingHelperIntermediatePixmap;
const QIcon m_debuggingHelperOkIcon;
const QIcon m_debuggingHelperErrorIcon;
const QIcon m_debuggingHelperIntermediateIcon;
const QString m_specifyNameString;
const QString m_specifyPathString;
Internal::Ui::QtVersionManager *m_ui;
Internal::Ui::QtVersionInfo *m_versionUi;
Internal::Ui::DebuggingHelper *m_debuggingHelperUi;
QList<QSharedPointerQtVersion> m_versions; // Passed on to the helper build task, so, use QSharedPointerQtVersion
int m_defaultVersion;
......@@ -100,7 +97,6 @@ private slots:
void makeMingwVisible(bool visible);
void makeMSVCVisible(bool visible);
void makeS60Visible(bool visible);
void makeDebuggingHelperVisible(bool visible);
void onQtBrowsed();
void onMingwBrowsed();
void updateCurrentQtName();
......@@ -110,8 +106,13 @@ private slots:
void updateCurrentS60SDKDirectory();
void updateCurrentGcceDirectory();
void updateCurrentSbsV2Directory();
void updateDebuggingHelperInfo(const QtVersion *version = 0);
void msvcVersionChanged();
void buildDebuggingHelper();
void buildDebuggingHelper(DebuggingHelperBuildTask::Tools tools
= DebuggingHelperBuildTask::AllTools);
void buildGdbHelper();
void buildQmlDump();
void buildQmlObserver();
void slotShowDebuggingBuildLog();
void debuggingHelperBuildFinished(int qtVersionId, const QString &output);
......
<?xml version="1.0" encoding="UTF-8"?>
<ui version="4.0">
<class>Qt4ProjectManager::Internal::QtVersionInfo</class>
<widget class="QWidget" name="Qt4ProjectManager::Internal::QtVersionInfo">
<property name="geometry">
<rect>
<x>0</x>
<y>0</y>
<width>404</width>
<height>197</height>
</rect>
</property>
<layout class="QGridLayout">
<property name="margin">
<number>0</number>
</property>
<item row="1" column="0">
<widget class="QLabel" name="versionNameLabel">
<property name="text">
<string>Version name:</string>
</property>
</widget>
</item>
<item row="1" column="1">
<widget class="QLineEdit" name="nameEdit"/>
</item>
<item row="2" column="0">
<widget class="QLabel" name="pathLabel">
<property name="text">
<string>qmake location:</string>
</property>
</widget>
</item>
<item row="2" column="1">
<widget class="Utils::PathChooser" name="qmakePath" native="true"/>
</item>
<item row="3" column="0">
<widget class="QLabel" name="mingwLabel">
<property name="text">
<string>MinGW directory:</string>
</property>
</widget>
</item>
<item row="3" column="1">
<widget class="Utils::PathChooser" name="mingwPath" native="true"/>
</item>
<item row="4" column="0">
<widget class="QLabel" name="msvcLabel">
<property name="text">
<string>Toolchain:</string>
</property>
</widget>
</item>
<item row="6" column="0">
<widget class="QLabel" name="s60SDKLabel">
<property name="text">
<string>S60 SDK:</string>
</property>
</widget>
</item>
<item row="6" column="1">
<widget class="Utils::PathChooser" name="s60SDKPath" native="true"/>
</item>
<item row="7" column="0">
<widget class="QLabel" name="gcceLabel">
<property name="text">
<string>CSL/GCCE directory:</string>
</property>
</widget>
</item>
<item row="7" column="1">
<widget class="Utils::PathChooser" name="gccePath" native="true"/>
</item>
<item row="8" column="0">
<widget class="QLabel" name="mwcLabel">
<property name="text">
<string>Carbide directory:</string>
</property>
</widget>
</item>
<item row="8" column="1">
<widget class="Utils::PathChooser" name="mwcPath" native="true"/>
</item>
<item row="9" column="0">
<widget class="QLabel" name="sbsV2Label">
<property name="text">
<string>SBS v2 directory:</string>
</property>
</widget>
</item>
<item row="9" column="1">
<widget class="Utils::PathChooser" name="sbsV2Path" native="true"/>
</item>
<item row="10" column="0" colspan="2">
<widget class="QLabel" name="errorLabel">
<property name="text">
<string/>
</property>
</widget>
</item>
<item row="4" column="1">
<layout class="QHBoxLayout" name="msvcHorizontalLayout">
<item>
<widget class="QComboBox" name="msvcComboBox">
<property name="sizePolicy">
<sizepolicy hsizetype="MinimumExpanding" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
</widget>
</item>
<item>
<widget class="QLabel" name="msvcNotFoundLabel">
<property name="sizePolicy">
<sizepolicy hsizetype="MinimumExpanding" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="text">
<string>Unable to detect MSVC version.</string>
</property>
</widget>
</item>
</layout>
</item>
</layout>
</widget>
<customwidgets>
<customwidget>
<class>Utils::PathChooser</class>
<extends>QWidget</extends>
<header location="global">utils/pathchooser.h</header>
<container>1</container>
<slots>
<signal>editingFinished()</signal>
<signal>browsingFinished()</signal>
</slots>
</customwidget>
</customwidgets>
<resources/>
<connections/>
</ui>
......@@ -6,12 +6,12 @@
<rect>
<x>0</x>
<y>0</y>
<width>427</width>
<height>424</height>
<width>446</width>
<height>450</height>
</rect>
</property>
<layout class="QGridLayout" name="gridLayout">
<item row="0" column="0" colspan="2">
<item row="0" column="0">
<layout class="QHBoxLayout" name="horizontalLayout">
<item>
<widget class="QTreeWidget" name="qtdirList">
......@@ -19,7 +19,7 @@
<bool>true</bool>
</property>
<property name="columnCount">
<number>3</number>
<number>2</number>
</property>
<column>
<property name="text">
......@@ -31,11 +31,6 @@
<string>qmake Location</string>
</property>
</column>
<column>
<property name="text">
<string>Debugging Helper</string>
</property>
</column>
</widget>
</item>
<item>
......@@ -90,177 +85,25 @@
</layout>
</item>
<item row="1" column="0">
<widget class="QLabel" name="versionNameLabel">
<property name="text">
<string>Version name:</string>
</property>
</widget>
</item>
<item row="1" column="1">
<widget class="QLineEdit" name="nameEdit"/>
<widget class="Utils::DetailsWidget" name="versionInfoWidget" native="true"/>
</item>
<item row="2" column="0">
<widget class="QLabel" name="pathLabel">
<property name="text">
<string>qmake location:</string>
</property>
</widget>
</item>
<item row="2" column="1">
<widget class="Utils::PathChooser" name="qmakePath" native="true"/>
</item>
<item row="3" column="0">
<widget class="QLabel" name="mingwLabel">
<property name="text">
<string>MinGW directory:</string>
</property>
</widget>
</item>
<item row="3" column="1">
<widget class="Utils::PathChooser" name="mingwPath" native="true"/>
</item>
<item row="4" column="0">
<widget class="QLabel" name="msvcLabel">
<property name="text">
<string>Toolchain:</string>
</property>
</widget>
</item>
<item row="4" column="1">
<layout class="QHBoxLayout" name="msvcHorizontalLayout">
<item>
<widget class="QComboBox" name="msvcComboBox">
<property name="sizePolicy">
<sizepolicy hsizetype="MinimumExpanding" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
</widget>
</item>
<item>
<widget class="QLabel" name="msvcNotFoundLabel">
<property name="sizePolicy">
<sizepolicy hsizetype="MinimumExpanding" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="text">
<string>Unable to detect MSVC version.</string>
</property>
</widget>
</item>
</layout>
</item>
<item row="5" column="0">
<widget class="QLabel" name="s60SDKLabel">
<property name="text">
<string>S60 SDK:</string>
</property>
</widget>
</item>
<item row="5" column="1">
<widget class="Utils::PathChooser" name="s60SDKPath" native="true"/>
</item>
<item row="6" column="0">
<widget class="QLabel" name="gcceLabel">
<property name="text">
<string>CSL/GCCE directory:</string>
</property>
</widget>
</item>
<item row="6" column="1">
<widget class="Utils::PathChooser" name="gccePath" native="true"/>
</item>
<item row="7" column="0">
<widget class="QLabel" name="mwcLabel">
<property name="text">
<string>Carbide directory:</string>
</property>
</widget>
</item>
<item row="7" column="1">
<widget class="Utils::PathChooser" name="mwcPath" native="true"/>
</item>
<item row="8" column="0">
<widget class="QLabel" name="sbsV2Label">
<property name="text">
<string>SBS v2 directory:</string>
</property>
</widget>
</item>
<item row="8" column="1">
<widget class="Utils::PathChooser" name="sbsV2Path" native="true"/>
</item>
<item row="9" column="0">
<widget class="QLabel" name="debuggingHelperLabel">
<property name="text">
<string>Debugging helpers:</string>
</property>
</widget>
</item>
<item row="9" column="1">
<layout class="QHBoxLayout" name="debuggingHelperHorizontalLayout">
<item>
<widget class="QLabel" name="debuggingHelperStateLabel">
<property name="sizePolicy">
<sizepolicy hsizetype="MinimumExpanding" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="text">
<string/>
</property>
</widget>
</item>
<item>
<widget class="QPushButton" name="showLogButton">
<property name="text">
<string>Show &amp;Log</string>
</property>
</widget>
</item>
<item>
<widget class="QPushButton" name="rebuildButton">
<property name="text">
<string>&amp;Rebuild</string>
</property>
</widget>
</item>
</layout>
</item>
<item row="10" column="0" colspan="2">
<widget class="QLabel" name="errorLabel">
<property name="text">
<string/>
</property>
</widget>
<widget class="Utils::DetailsWidget" name="debuggingHelperWidget" native="true"/>
</item>
</layout>
</widget>
<customwidgets>
<customwidget>
<class>Utils::PathChooser</class>
<class>Utils::DetailsWidget</class>
<extends>QWidget</extends>
<header location="global">utils/pathchooser.h</header>
<header location="global">utils/detailswidget.h</header>
<container>1</container>
<slots>
<signal>editingFinished()</signal>
<signal>browsingFinished()</signal>
</slots>
</customwidget>
</customwidgets>
<tabstops>