summaryrefslogtreecommitdiff
path: root/raveos-calamares-module/welcome
diff options
context:
space:
mode:
authorNippy <nippy@Nippy-Mac-mini.local>2026-10-09 10:49:26 +0200
committerNippy <nippy@Nippy-Mac-mini.local>2026-10-09 10:49:26 +0200
commit91978706279a19a3ac96393630876f3e50cbc518 (patch)
tree1355da60486a305aefeea4e55543bbf1008715b3 /raveos-calamares-module/welcome
parent17a23f8a0cec5439d674d90c593497e4ceed2c68 (diff)
downloadRaveOS-PKGBUILD-91978706279a19a3ac96393630876f3e50cbc518.tar.gz
RaveOS-PKGBUILD-91978706279a19a3ac96393630876f3e50cbc518.zip
fix
Diffstat (limited to 'raveos-calamares-module/welcome')
-rw-r--r--raveos-calamares-module/welcome/RaveWelcomeViewStep.cpp20
1 files changed, 0 insertions, 20 deletions
diff --git a/raveos-calamares-module/welcome/RaveWelcomeViewStep.cpp b/raveos-calamares-module/welcome/RaveWelcomeViewStep.cpp
index 86ab549..c2d58c7 100644
--- a/raveos-calamares-module/welcome/RaveWelcomeViewStep.cpp
+++ b/raveos-calamares-module/welcome/RaveWelcomeViewStep.cpp
@@ -20,7 +20,6 @@
CALAMARES_PLUGIN_FACTORY_DEFINITION(RaveWelcomeViewStepFactory, registerPlugin<RaveWelcomeViewStep>();)
-// Widget that paints the background image scaled to fill (like Image.Stretch)
class BgWidget : public QWidget
{
public:
@@ -43,7 +42,6 @@ private:
RaveWelcomeViewStep::RaveWelcomeViewStep(QObject* parent)
: Calamares::ViewStep(parent)
{
- // Default languages if not set via config
m_localeIds = { "de", "en", "en_GB", "hu" };
}
@@ -98,7 +96,6 @@ void RaveWelcomeViewStep::buildWidget()
auto* bg = new BgWidget();
bg->setSizePolicy(QSizePolicy::Expanding, QSizePolicy::Expanding);
- // Load welcome image from branding
QString imgPath;
if (Calamares::Branding::instance())
imgPath = Calamares::Branding::instance()->imagePath(Calamares::Branding::ProductWelcome);
@@ -106,7 +103,6 @@ void RaveWelcomeViewStep::buildWidget()
if (!imgPath.isEmpty())
bg->setPixmap(QPixmap(imgPath));
- // Bottom language bar
auto* bar = new QFrame();
bar->setObjectName("ravewelcomeBar");
bar->setFixedHeight(58);
@@ -116,11 +112,9 @@ void RaveWelcomeViewStep::buildWidget()
m_langCombo->setFixedHeight(40);
m_langCombo->setMinimumWidth(300);
- // Populate language model
auto* model = new Calamares::Locale::TranslationsModel(m_localeIds, m_langCombo);
m_langCombo->setModel(model);
- // Select current locale
QLocale sys = QLocale::system();
QString sysName = sys.name();
m_currentLocaleIndex = 0;
@@ -132,15 +126,12 @@ void RaveWelcomeViewStep::buildWidget()
break;
}
}
- // Default to "en"
int enIdx = m_localeIds.indexOf("en");
if (enIdx >= 0 && m_currentLocaleIndex == 0 && m_localeIds[0] != "en")
m_currentLocaleIndex = enIdx;
m_langCombo->setCurrentIndex(m_currentLocaleIndex);
- // Make the live keyboard layout match the initial language right away,
- // so the WiFi password input is not stuck on the boot default (US).
applyLiveKeyboardLayout(m_localeIds.value(m_currentLocaleIndex));
connect(m_langCombo, QOverload<int>::of(&QComboBox::activated),
@@ -176,9 +167,6 @@ void RaveWelcomeViewStep::onLanguageChanged(int index)
m_currentLocaleIndex = index;
QString localeId = m_localeIds[index];
- // Store locale in GlobalStorage for the installed system.
- // A localecfg a teljes localeConf-ot olvassa, ezért minden LC_* kulcsot
- // beírunk, ne csak a LANG-ot.
if (Calamares::JobQueue::instance())
{
Calamares::GlobalStorage* gs = Calamares::JobQueue::instance()->globalStorage();
@@ -199,18 +187,13 @@ void RaveWelcomeViewStep::onLanguageChanged(int index)
localeConf.insert(QLatin1String(k), fullLocale);
gs->insert("localeConf", localeConf);
- // A 'locale' kulcs is kell (nyelv, kódolás nélkül), ha a standard
- // locale modul mégis olvasná.
gs->insert("locale", lang);
}
}
- // Install new translator - this changes the entire Calamares UI language
Calamares::Locale::Translation::Id tid { localeId };
Calamares::installTranslator(tid, brandingTranslationsPrefix());
- // Apply the matching live keyboard layout immediately, so the WiFi
- // password input follows the selected language (before the keyboard page).
applyLiveKeyboardLayout(localeId);
}
@@ -237,9 +220,6 @@ void RaveWelcomeViewStep::applyLiveKeyboardLayout(const QString& localeId)
layout = QStringLiteral("gb");
}
- // Best effort: apply the layout to the running X11 session so the WiFi
- // password input matches the selected language immediately. A missing
- // setxkbmap or non-X11 session must not break the installer.
const QStringList args { QStringLiteral("-layout"), layout };
QProcess::startDetached(QStringLiteral("setxkbmap"), args);
}