forked from qt-creator/qt-creator
StudioWelcome: Always initialize new project dialog
If the SplashScreen was disabled the new factory was not registered. Change-Id: I3ab04510c33cb4ccfd2d85d3059ecafcc41fa654 Reviewed-by: Samuel Ghinet <samuel.ghinet@qt.io> Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
This commit is contained in:
committed by
Tim Jenssen
parent
2d1e4bcc5f
commit
5cc183e0f7
@@ -353,6 +353,10 @@ bool StudioWelcomePlugin::initialize(const QStringList &arguments, QString *erro
|
|||||||
void StudioWelcomePlugin::extensionsInitialized()
|
void StudioWelcomePlugin::extensionsInitialized()
|
||||||
{
|
{
|
||||||
Core::ModeManager::activateMode(m_welcomeMode->id());
|
Core::ModeManager::activateMode(m_welcomeMode->id());
|
||||||
|
|
||||||
|
// Enable QDS new project dialog
|
||||||
|
Core::ICore::setNewDialogFactory([](QWidget *parent) { return new QdsNewDialog(parent); });
|
||||||
|
|
||||||
if (Utils::CheckableMessageBox::shouldAskAgain(Core::ICore::settings(),
|
if (Utils::CheckableMessageBox::shouldAskAgain(Core::ICore::settings(),
|
||||||
DO_NOT_SHOW_SPLASHSCREEN_AGAIN_KEY)) {
|
DO_NOT_SHOW_SPLASHSCREEN_AGAIN_KEY)) {
|
||||||
connect(Core::ICore::instance(), &Core::ICore::coreOpened, this, [this] {
|
connect(Core::ICore::instance(), &Core::ICore::coreOpened, this, [this] {
|
||||||
@@ -370,8 +374,6 @@ void StudioWelcomePlugin::extensionsInitialized()
|
|||||||
s_view->setSource(QUrl("qrc:/qml/splashscreen/main.qml"));
|
s_view->setSource(QUrl("qrc:/qml/splashscreen/main.qml"));
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
// disabled by default
|
|
||||||
Core::ICore::setNewDialogFactory([](QWidget *parent) { return new QdsNewDialog(parent); });
|
|
||||||
|
|
||||||
QTC_ASSERT(s_view->rootObject(),
|
QTC_ASSERT(s_view->rootObject(),
|
||||||
qWarning() << "The StudioWelcomePlugin has a runtime depdendency on "
|
qWarning() << "The StudioWelcomePlugin has a runtime depdendency on "
|
||||||
|
Reference in New Issue
Block a user