From 77fe73799af9e3638528d79e2c72443c884fcde0 Mon Sep 17 00:00:00 2001 From: pvdk Date: Sun, 15 Dec 2013 13:12:48 +0100 Subject: [PATCH] Enabled language setting to be accessable from different pages --- apps/wizard/componentselectionpage.cpp | 2 -- apps/wizard/installationpage.cpp | 2 ++ apps/wizard/installationtargetpage.cpp | 2 ++ apps/wizard/mainwizard.cpp | 4 ++++ 4 files changed, 8 insertions(+), 2 deletions(-) diff --git a/apps/wizard/componentselectionpage.cpp b/apps/wizard/componentselectionpage.cpp index 046f340765..b5618c6771 100644 --- a/apps/wizard/componentselectionpage.cpp +++ b/apps/wizard/componentselectionpage.cpp @@ -28,8 +28,6 @@ void Wizard::ComponentSelectionPage::updateButton(QListWidgetItem *item) for (int i =0; i < componentsList->count(); ++i) { QListWidgetItem *item = componentsList->item(i); - qDebug() << "item is " << item->text(); - if (!item) continue; diff --git a/apps/wizard/installationpage.cpp b/apps/wizard/installationpage.cpp index de0720ecbd..1053c32401 100644 --- a/apps/wizard/installationpage.cpp +++ b/apps/wizard/installationpage.cpp @@ -13,6 +13,8 @@ Wizard::InstallationPage::InstallationPage(MainWizard *wizard) : void Wizard::InstallationPage::initializePage() { + QString path = field("installation.path").toString(); + qDebug() << "installing to: " << field("installation.path").toString(); logTextEdit->setText(QString("Installing to %1").arg(field("installation.path").toString())); } diff --git a/apps/wizard/installationtargetpage.cpp b/apps/wizard/installationtargetpage.cpp index 0952abdcb5..60acfd5f78 100644 --- a/apps/wizard/installationtargetpage.cpp +++ b/apps/wizard/installationtargetpage.cpp @@ -17,6 +17,8 @@ Wizard::InstallationTargetPage::InstallationTargetPage(MainWizard *wizard) : void Wizard::InstallationTargetPage::initializePage() { + qDebug() << mWizard->field("installation.language"); + #ifdef Q_OS_WIN QString path = QDesktopServices::storageLocation(QDesktopServices::DocumentsLocation); #endif diff --git a/apps/wizard/mainwizard.cpp b/apps/wizard/mainwizard.cpp index e6cb140d08..58ef2e0611 100644 --- a/apps/wizard/mainwizard.cpp +++ b/apps/wizard/mainwizard.cpp @@ -24,6 +24,10 @@ Wizard::MainWizard::MainWizard(QWidget *parent) : #endif setWindowTitle(tr("OpenMW Wizard")); + + // Set the property for comboboxes to the text instead of index + setDefaultProperty("QComboBox", "currentText", "currentIndexChanged"); + setupInstallations(); setupPages(); }