rbutil: Add voice installation to main widget.

Add checkbox for installing the prerendered voice file to the main
install widget. Current limitations:
- only english for now. The available languages are available from the
  build server but are not yet taken into account.
- only for releases. This is the same limitations we had before. We do
  have voices for daily builds, but that requires adding daily builds
  again (those have been removed some time back.)
- Old voice installation dialog still present.

Change-Id: Ia6443b0f15365196df86cc1b64d5e043dff70c4c
This commit is contained in:
Dominik Riebeling 2020-11-21 19:33:29 +01:00
parent ad37655687
commit c2dacf6736
9 changed files with 210 additions and 99 deletions

View file

@ -47,6 +47,7 @@ const static struct {
{ RbSettings::InstallFonts, "install_fonts", "true" }, { RbSettings::InstallFonts, "install_fonts", "true" },
{ RbSettings::InstallThemes, "install_themes", "false" }, { RbSettings::InstallThemes, "install_themes", "false" },
{ RbSettings::InstallGamefiles, "install_gamefiles", "true" }, { RbSettings::InstallGamefiles, "install_gamefiles", "true" },
{ RbSettings::InstallVoice, "install_voice", "false" },
#if defined(Q_OS_WIN32) #if defined(Q_OS_WIN32)
{ RbSettings::Tts, "tts", "sapi" }, { RbSettings::Tts, "tts", "sapi" },
#elif defined(Q_OS_MACX) #elif defined(Q_OS_MACX)

View file

@ -46,6 +46,7 @@ class RbSettings : public QObject
InstallFonts, InstallFonts,
InstallThemes, InstallThemes,
InstallGamefiles, InstallGamefiles,
InstallVoice,
Tts, Tts,
UseTtsCorrections, UseTtsCorrections,
TalkFolders, TalkFolders,

View file

@ -159,7 +159,7 @@ QStringList SystemInfo::platforms(enum SystemInfo::PlatformType type, QString va
return result; return result;
} }
QMap<QString, QStringList> SystemInfo::languages(void) QMap<QString, QStringList> SystemInfo::languages(bool namesOnly)
{ {
ensureSystemInfoExists(); ensureSystemInfoExists();
@ -168,7 +168,11 @@ QMap<QString, QStringList> SystemInfo::languages(void)
QStringList a = systemInfos->childKeys(); QStringList a = systemInfos->childKeys();
for(int i = 0; i < a.size(); i++) for(int i = 0; i < a.size(); i++)
{ {
result.insert(a.at(i), systemInfos->value(a.at(i), "null").toStringList()); QStringList data = systemInfos->value(a.at(i), "null").toStringList();
if(namesOnly)
result.insert(data.at(0), QStringList(data.at(1)));
else
result.insert(a.at(i), data);
} }
systemInfos->endGroup(); systemInfos->endGroup();
return result; return result;

View file

@ -90,8 +90,9 @@ class SystemInfo : public QObject
//! return a list of all platforms (rbutil internal names) //! return a list of all platforms (rbutil internal names)
static QStringList platforms(enum PlatformType type = PlatformAll, static QStringList platforms(enum PlatformType type = PlatformAll,
QString variant=""); QString variant="");
//! returns a map of all languages //! returns a map of all languages.
static QMap<QString, QStringList> languages(void); //! Maps <language code> to (<language name>, <display name>)
static QMap<QString, QStringList> languages(bool namesOnly = false);
//! returns a map of usb-ids and their targets //! returns a map of usb-ids and their targets
static QMap<int, QStringList> usbIdMap(enum MapType type); static QMap<int, QStringList> usbIdMap(enum MapType type);
//! get a value from system settings //! get a value from system settings

View file

@ -39,6 +39,7 @@ SelectiveInstallWidget::SelectiveInstallWidget(QWidget* parent) : QWidget(parent
ui.fontsCheckbox->setChecked(RbSettings::value(RbSettings::InstallFonts).toBool()); ui.fontsCheckbox->setChecked(RbSettings::value(RbSettings::InstallFonts).toBool());
ui.themesCheckbox->setChecked(RbSettings::value(RbSettings::InstallThemes).toBool()); ui.themesCheckbox->setChecked(RbSettings::value(RbSettings::InstallThemes).toBool());
ui.gamefileCheckbox->setChecked(RbSettings::value(RbSettings::InstallGamefiles).toBool()); ui.gamefileCheckbox->setChecked(RbSettings::value(RbSettings::InstallGamefiles).toBool());
ui.voiceCheckbox->setChecked(RbSettings::value(RbSettings::InstallVoice).toBool());
// check if Rockbox is installed by looking after rockbox-info.txt. // check if Rockbox is installed by looking after rockbox-info.txt.
// If installed uncheck bootloader installation. // If installed uncheck bootloader installation.
@ -62,17 +63,27 @@ SelectiveInstallWidget::SelectiveInstallWidget(QWidget* parent) : QWidget(parent
void SelectiveInstallWidget::selectedVersionChanged(int index) void SelectiveInstallWidget::selectedVersionChanged(int index)
{ {
QString current = ui.selectedVersion->itemData(index).toString(); m_buildtype = ui.selectedVersion->itemData(index).toString();
if(current == "release") bool voice = true;
if(m_buildtype == "release") {
ui.selectedDescription->setText(tr("This is the latest stable " ui.selectedDescription->setText(tr("This is the latest stable "
"release available.")); "release available."));
if(current == "development") voice = true;
}
if(m_buildtype == "development") {
ui.selectedDescription->setText(tr("The development version is " ui.selectedDescription->setText(tr("The development version is "
"updated on every code change. Last update was on %1").arg( "updated on every code change. Last update was on %1").arg(
ServerInfo::instance()->platformValue(ServerInfo::BleedingDate).toString())); ServerInfo::instance()->platformValue(ServerInfo::BleedingDate).toString()));
if(current == "rc") voice = false;
}
if(m_buildtype == "rc") {
ui.selectedDescription->setText(tr("This will eventually become the " ui.selectedDescription->setText(tr("This will eventually become the "
"next Rockbox version. Install it to help testing.")); "next Rockbox version. Install it to help testing."));
voice = false;
}
ui.voiceCheckbox->setEnabled(voice);
ui.voiceCombobox->setEnabled(voice);
ui.voiceLabel->setEnabled(voice);
} }
@ -144,7 +155,27 @@ void SelectiveInstallWidget::updateVersion(void)
RockboxInfo info(m_mountpoint); RockboxInfo info(m_mountpoint);
ui.bootloaderCheckbox->setChecked(!info.success()); ui.bootloaderCheckbox->setChecked(!info.success());
} }
// populate languages for voice file.
// FIXME: currently only english. Need to get the available languages from
// build-info later.
QVariant current = ui.voiceCombobox->currentData();
QMap<QString, QStringList> languages = SystemInfo::languages(true);
QStringList voicelangs;
voicelangs << "english";
ui.voiceCombobox->clear();
for(int i = 0; i < voicelangs.size(); i++) {
QString key = voicelangs.at(i);
if(!languages.contains(key)) {
LOG_WARNING() << "trying to add unknown language" << key;
continue;
}
ui.voiceCombobox->addItem(languages.value(key).at(0), key);
}
// try to select the previously selected one again (if still present)
// TODO: Fall back to system language if not found, or english.
int sel = ui.voiceCombobox->findData(current);
if(sel >= 0)
ui.voiceCombobox->setCurrentIndex(sel);
} }
@ -157,6 +188,8 @@ void SelectiveInstallWidget::saveSettings(void)
RbSettings::setValue(RbSettings::InstallFonts, ui.fontsCheckbox->isChecked()); RbSettings::setValue(RbSettings::InstallFonts, ui.fontsCheckbox->isChecked());
RbSettings::setValue(RbSettings::InstallThemes, ui.themesCheckbox->isChecked()); RbSettings::setValue(RbSettings::InstallThemes, ui.themesCheckbox->isChecked());
RbSettings::setValue(RbSettings::InstallGamefiles, ui.gamefileCheckbox->isChecked()); RbSettings::setValue(RbSettings::InstallGamefiles, ui.gamefileCheckbox->isChecked());
RbSettings::setValue(RbSettings::InstallVoice, ui.voiceCheckbox->isChecked());
RbSettings::setValue(RbSettings::VoiceLanguage, ui.voiceCombobox->currentData().toString());
} }
@ -209,7 +242,8 @@ void SelectiveInstallWidget::continueInstall(bool error)
case 3: installFonts(); break; case 3: installFonts(); break;
case 4: installThemes(); break; case 4: installThemes(); break;
case 5: installGamefiles(); break; case 5: installGamefiles(); break;
case 6: installBootloaderPost(); break; case 6: installVoicefile(); break;
case 7: installBootloaderPost(); break;
default: break; default: break;
} }
@ -381,15 +415,14 @@ void SelectiveInstallWidget::installRockbox(void)
LOG_INFO() << "installing Rockbox"; LOG_INFO() << "installing Rockbox";
QString url; QString url;
QString selected = ui.selectedVersion->itemData(ui.selectedVersion->currentIndex()).toString(); RbSettings::setValue(RbSettings::Build, m_buildtype);
RbSettings::setValue(RbSettings::Build, selected);
RbSettings::sync(); RbSettings::sync();
if(selected == "release") url = ServerInfo::instance()->platformValue( if(m_buildtype == "release") url = ServerInfo::instance()->platformValue(
ServerInfo::CurReleaseUrl, m_target).toString(); ServerInfo::CurReleaseUrl, m_target).toString();
else if(selected == "development") url = ServerInfo::instance()->platformValue( else if(m_buildtype == "development") url = ServerInfo::instance()->platformValue(
ServerInfo::CurDevelUrl, m_target).toString(); ServerInfo::CurDevelUrl, m_target).toString();
else if(selected == "rc") url = ServerInfo::instance()->platformValue( else if(m_buildtype == "rc") url = ServerInfo::instance()->platformValue(
ServerInfo::RelCandidateUrl, m_target).toString(); ServerInfo::RelCandidateUrl, m_target).toString();
//! install build //! install build
@ -399,7 +432,7 @@ void SelectiveInstallWidget::installRockbox(void)
m_zipinstaller->setLogSection("Rockbox (Base)"); m_zipinstaller->setLogSection("Rockbox (Base)");
if(!RbSettings::value(RbSettings::CacheDisabled).toBool()) if(!RbSettings::value(RbSettings::CacheDisabled).toBool())
m_zipinstaller->setCache(true); m_zipinstaller->setCache(true);
m_zipinstaller->setLogVersion(m_versions[selected]); m_zipinstaller->setLogVersion(m_versions[m_buildtype]);
m_zipinstaller->setMountPoint(m_mountpoint); m_zipinstaller->setMountPoint(m_mountpoint);
connect(m_zipinstaller, SIGNAL(done(bool)), this, SLOT(continueInstall(bool))); connect(m_zipinstaller, SIGNAL(done(bool)), this, SLOT(continueInstall(bool)));
@ -422,25 +455,71 @@ void SelectiveInstallWidget::installFonts(void)
if(ui.fontsCheckbox->isChecked()) { if(ui.fontsCheckbox->isChecked()) {
LOG_INFO() << "installing Fonts"; LOG_INFO() << "installing Fonts";
RockboxInfo installInfo(m_mountpoint); RockboxInfo installInfo(m_mountpoint);
QString fontsurl; QString fontsurl;
QString logversion; QString logversion;
QString relversion = installInfo.release(); QString relversion = installInfo.release();
if(relversion.isEmpty()) { if(relversion.isEmpty()) {
// release is empty for non-release versions (i.e. daily / current) // release is empty for non-release versions (i.e. daily / current)
fontsurl = SystemInfo::value(SystemInfo::FontUrl, SystemInfo::BuildDaily).toString(); fontsurl = SystemInfo::value(SystemInfo::FontUrl, SystemInfo::BuildDaily).toString();
}
else {
fontsurl = SystemInfo::value(SystemInfo::FontUrl, SystemInfo::BuildRelease).toString();
logversion = installInfo.release();
}
fontsurl.replace("%RELEASEVER%", relversion);
// create new zip installer
if(m_zipinstaller != nullptr) m_zipinstaller->deleteLater();
m_zipinstaller = new ZipInstaller(this);
m_zipinstaller->setUrl(fontsurl);
m_zipinstaller->setLogSection("Fonts");
m_zipinstaller->setLogVersion(logversion);
m_zipinstaller->setMountPoint(m_mountpoint);
if(!RbSettings::value(RbSettings::CacheDisabled).toBool())
m_zipinstaller->setCache(true);
connect(m_zipinstaller, SIGNAL(done(bool)), this, SLOT(continueInstall(bool)));
connect(m_zipinstaller, SIGNAL(logItem(QString, int)), m_logger, SLOT(addItem(QString, int)));
connect(m_zipinstaller, SIGNAL(logProgress(int, int)), m_logger, SLOT(setProgress(int, int)));
connect(m_logger, SIGNAL(aborted()), m_zipinstaller, SLOT(abort()));
m_zipinstaller->install();
} }
else { else {
fontsurl = SystemInfo::value(SystemInfo::FontUrl, SystemInfo::BuildRelease).toString(); LOG_INFO() << "Fonts install disabled.";
emit installSkipped(false);
}
}
void SelectiveInstallWidget::installVoicefile(void)
{
if(ui.voiceCheckbox->isChecked()) {
LOG_INFO() << "installing Voice file";
QString lang = ui.voiceCombobox->currentData().toString();
RockboxInfo installInfo(m_mountpoint);
QString voiceurl;
QString logversion;
QString relversion = installInfo.release();
if(m_buildtype == "release") {
// release is empty for non-release versions (i.e. daily / current)
voiceurl = SystemInfo::value(SystemInfo::VoiceUrl, SystemInfo::BuildRelease).toString();
}
else {
voiceurl = SystemInfo::value(SystemInfo::VoiceUrl, SystemInfo::BuildDaily).toString();
logversion = installInfo.release(); logversion = installInfo.release();
} }
fontsurl.replace("%RELEASEVER%", relversion); voiceurl.replace("%RELVERSION%", m_versions[m_buildtype]);
voiceurl.replace("%MODEL%", m_target);
voiceurl.replace("%LANGUAGE%", lang);
LOG_INFO() << "voicurl" << voiceurl;
// create new zip installer // create new zip installer
if(m_zipinstaller != nullptr) m_zipinstaller->deleteLater(); if(m_zipinstaller != nullptr) m_zipinstaller->deleteLater();
m_zipinstaller = new ZipInstaller(this); m_zipinstaller = new ZipInstaller(this);
m_zipinstaller->setUrl(fontsurl); m_zipinstaller->setUrl(voiceurl);
m_zipinstaller->setLogSection("Fonts"); m_zipinstaller->setLogSection("Voice (" + lang + ")");
m_zipinstaller->setLogVersion(logversion); m_zipinstaller->setLogVersion(logversion);
m_zipinstaller->setMountPoint(m_mountpoint); m_zipinstaller->setMountPoint(m_mountpoint);
if(!RbSettings::value(RbSettings::CacheDisabled).toBool()) if(!RbSettings::value(RbSettings::CacheDisabled).toBool())
@ -453,7 +532,7 @@ void SelectiveInstallWidget::installFonts(void)
m_zipinstaller->install(); m_zipinstaller->install();
} }
else { else {
LOG_INFO() << "Fonts install disabled."; LOG_INFO() << "Voice install disabled.";
emit installSkipped(false); emit installSkipped(false);
} }
} }

View file

@ -41,6 +41,7 @@ class SelectiveInstallWidget : public QWidget
void installBootloader(void); void installBootloader(void);
void installRockbox(void); void installRockbox(void);
void installFonts(void); void installFonts(void);
void installVoicefile(void);
void installThemes(void); void installThemes(void);
void installGamefiles(void); void installGamefiles(void);
void installBootloaderPost(void); void installBootloaderPost(void);
@ -62,6 +63,7 @@ class SelectiveInstallWidget : public QWidget
ZipInstaller *m_zipinstaller; ZipInstaller *m_zipinstaller;
QMap<QString, QString> m_versions; QMap<QString, QString> m_versions;
ThemesInstallWindow *m_themesinstaller; ThemesInstallWindow *m_themesinstaller;
QString m_buildtype;
}; };
#endif #endif

View file

@ -7,7 +7,7 @@
<x>0</x> <x>0</x>
<y>0</y> <y>0</y>
<width>663</width> <width>663</width>
<height>369</height> <height>399</height>
</rect> </rect>
</property> </property>
<property name="sizePolicy"> <property name="sizePolicy">
@ -54,22 +54,22 @@
<string>Rockbox components to install</string> <string>Rockbox components to install</string>
</property> </property>
<layout class="QGridLayout" name="gridLayout_2"> <layout class="QGridLayout" name="gridLayout_2">
<item row="0" column="0"> <item row="1" column="0">
<widget class="QCheckBox" name="bootloaderCheckbox"> <widget class="QCheckBox" name="rockboxCheckbox">
<property name="text"> <property name="text">
<string>&amp;Bootloader</string> <string>&amp;Rockbox</string>
</property> </property>
<property name="icon"> <property name="icon">
<iconset resource="../rbutilqt.qrc"> <iconset resource="../rbutilqt.qrc">
<normaloff>:/icons/preferences-system.svg</normaloff>:/icons/preferences-system.svg</iconset> <normaloff>:/icons/multimedia-player.svg</normaloff>:/icons/multimedia-player.svg</iconset>
</property> </property>
<property name="checked"> <property name="checked">
<bool>true</bool> <bool>true</bool>
</property> </property>
</widget> </widget>
</item> </item>
<item row="1" column="1"> <item row="0" column="1">
<widget class="QLabel" name="rockboxLabel"> <widget class="QLabel" name="bootloaderLabel">
<property name="sizePolicy"> <property name="sizePolicy">
<sizepolicy hsizetype="MinimumExpanding" vsizetype="Preferred"> <sizepolicy hsizetype="MinimumExpanding" vsizetype="Preferred">
<horstretch>0</horstretch> <horstretch>0</horstretch>
@ -77,13 +77,51 @@
</sizepolicy> </sizepolicy>
</property> </property>
<property name="text"> <property name="text">
<string>The main Rockbox firmware.</string> <string>The bootloader is required for starting Rockbox. Only necessary for first time install.</string>
</property> </property>
<property name="wordWrap"> <property name="wordWrap">
<bool>true</bool> <bool>true</bool>
</property> </property>
</widget> </widget>
</item> </item>
<item row="3" column="0">
<widget class="QCheckBox" name="themesCheckbox">
<property name="text">
<string>Themes</string>
</property>
<property name="icon">
<iconset resource="../rbutilqt.qrc">
<normaloff>:/icons/preferences-desktop-theme.svg</normaloff>:/icons/preferences-desktop-theme.svg</iconset>
</property>
</widget>
</item>
<item row="3" column="3">
<widget class="QPushButton" name="themesCustomize">
<property name="text">
<string>Customize</string>
</property>
<property name="icon">
<iconset resource="../rbutilqt.qrc">
<normaloff>:/icons/preferences-system.svg</normaloff>:/icons/preferences-system.svg</iconset>
</property>
</widget>
</item>
<item row="1" column="2">
<spacer name="horizontalSpacer">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeType">
<enum>QSizePolicy::Minimum</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>1</width>
<height>1</height>
</size>
</property>
</spacer>
</item>
<item row="2" column="0"> <item row="2" column="0">
<widget class="QCheckBox" name="fontsCheckbox"> <widget class="QCheckBox" name="fontsCheckbox">
<property name="text"> <property name="text">
@ -98,22 +136,19 @@
</property> </property>
</widget> </widget>
</item> </item>
<item row="1" column="0"> <item row="6" column="0">
<widget class="QCheckBox" name="rockboxCheckbox"> <widget class="QCheckBox" name="gamefileCheckbox">
<property name="text"> <property name="text">
<string>&amp;Rockbox</string> <string>Game Files</string>
</property> </property>
<property name="icon"> <property name="icon">
<iconset resource="../rbutilqt.qrc"> <iconset resource="../rbutilqt.qrc">
<normaloff>:/icons/multimedia-player.svg</normaloff>:/icons/multimedia-player.svg</iconset> <normaloff>:/icons/input-gaming.svg</normaloff>:/icons/input-gaming.svg</iconset>
</property>
<property name="checked">
<bool>true</bool>
</property> </property>
</widget> </widget>
</item> </item>
<item row="6" column="1"> <item row="3" column="1">
<widget class="QLabel" name="gameLabel"> <widget class="QLabel" name="themesLabel">
<property name="sizePolicy"> <property name="sizePolicy">
<sizepolicy hsizetype="MinimumExpanding" vsizetype="Preferred"> <sizepolicy hsizetype="MinimumExpanding" vsizetype="Preferred">
<horstretch>0</horstretch> <horstretch>0</horstretch>
@ -121,7 +156,7 @@
</sizepolicy> </sizepolicy>
</property> </property>
<property name="text"> <property name="text">
<string>Some game plugins require additional files.</string> <string>Themes allow adjusting the user interface of Rockbox. Use &quot;Customize&quot; to select themes.</string>
</property> </property>
<property name="wordWrap"> <property name="wordWrap">
<bool>true</bool> <bool>true</bool>
@ -144,8 +179,8 @@
</property> </property>
</widget> </widget>
</item> </item>
<item row="0" column="1"> <item row="6" column="1">
<widget class="QLabel" name="bootloaderLabel"> <widget class="QLabel" name="gameLabel">
<property name="sizePolicy"> <property name="sizePolicy">
<sizepolicy hsizetype="MinimumExpanding" vsizetype="Preferred"> <sizepolicy hsizetype="MinimumExpanding" vsizetype="Preferred">
<horstretch>0</horstretch> <horstretch>0</horstretch>
@ -153,77 +188,63 @@
</sizepolicy> </sizepolicy>
</property> </property>
<property name="text"> <property name="text">
<string>The bootloader is required for starting Rockbox. Only necessary for first time install.</string> <string>Some game plugins require additional files.</string>
</property> </property>
<property name="wordWrap"> <property name="wordWrap">
<bool>true</bool> <bool>true</bool>
</property> </property>
</widget> </widget>
</item> </item>
<item row="6" column="0"> <item row="1" column="1">
<widget class="QCheckBox" name="gamefileCheckbox"> <widget class="QLabel" name="rockboxLabel">
<property name="text"> <property name="sizePolicy">
<string>Game Files</string> <sizepolicy hsizetype="MinimumExpanding" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property> </property>
<property name="icon"> <property name="text">
<iconset resource="../rbutilqt.qrc"> <string>The main Rockbox firmware.</string>
<normaloff>:/icons/input-gaming.svg</normaloff>:/icons/input-gaming.svg</iconset> </property>
<property name="wordWrap">
<bool>true</bool>
</property> </property>
</widget> </widget>
</item> </item>
<item row="3" column="3"> <item row="0" column="0">
<widget class="QPushButton" name="themesCustomize"> <widget class="QCheckBox" name="bootloaderCheckbox">
<property name="text"> <property name="text">
<string>Customize</string> <string>&amp;Bootloader</string>
</property> </property>
<property name="icon"> <property name="icon">
<iconset resource="../rbutilqt.qrc"> <iconset resource="../rbutilqt.qrc">
<normaloff>:/icons/preferences-system.svg</normaloff>:/icons/preferences-system.svg</iconset> <normaloff>:/icons/preferences-system.svg</normaloff>:/icons/preferences-system.svg</iconset>
</property> </property>
</widget> <property name="checked">
</item>
<item row="3" column="0">
<widget class="QCheckBox" name="themesCheckbox">
<property name="text">
<string>Themes</string>
</property>
<property name="icon">
<iconset resource="../rbutilqt.qrc">
<normaloff>:/icons/preferences-desktop-theme.svg</normaloff>:/icons/preferences-desktop-theme.svg</iconset>
</property>
</widget>
</item>
<item row="3" column="1">
<widget class="QLabel" name="themesLabel">
<property name="sizePolicy">
<sizepolicy hsizetype="MinimumExpanding" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="text">
<string>Themes allow adjusting the user interface of Rockbox. Use &quot;Customize&quot; to select themes.</string>
</property>
<property name="wordWrap">
<bool>true</bool> <bool>true</bool>
</property> </property>
</widget> </widget>
</item> </item>
<item row="1" column="2"> <item row="7" column="0">
<spacer name="horizontalSpacer"> <widget class="QCheckBox" name="voiceCheckbox">
<property name="orientation"> <property name="text">
<enum>Qt::Horizontal</enum> <string>&amp;Voice File</string>
</property> </property>
<property name="sizeType"> <property name="icon">
<enum>QSizePolicy::Minimum</enum> <iconset resource="../rbutilqt.qrc">
<normaloff>:/icons/audio-volume-high.svg</normaloff>:/icons/audio-volume-high.svg</iconset>
</property> </property>
<property name="sizeHint" stdset="0"> </widget>
<size> </item>
<width>1</width> <item row="7" column="1">
<height>1</height> <widget class="QLabel" name="voiceLabel">
</size> <property name="text">
<string>Install prerendered voice file.</string>
</property> </property>
</spacer> </widget>
</item>
<item row="7" column="3">
<widget class="QComboBox" name="voiceCombobox"/>
</item> </item>
</layout> </layout>
</widget> </widget>

View file

@ -22,7 +22,7 @@ download_url=http://download.rockbox.org/bootloader
[release] [release]
build_url=https://download.rockbox.org/release/%RELVERSION%/rockbox-%MODEL%-%RELVERSION%.zip build_url=https://download.rockbox.org/release/%RELVERSION%/rockbox-%MODEL%-%RELVERSION%.zip
voice_url=https://download.rockbox.org/release/%RELVERSION%/%MODEL%-%RELVERSION%-english.zip voice_url=https://download.rockbox.org/release/%RELVERSION%/%MODEL%-%RELVERSION%-%LANGUAGE%.zip
font_url=https://download.rockbox.org/release/%RELEASEVER%/rockbox-fonts-%RELEASEVER%.zip font_url=https://download.rockbox.org/release/%RELEASEVER%/rockbox-fonts-%RELEASEVER%.zip
manual_url=https://download.rockbox.org/release/%RELEASEVER%/rockbox-%MODEL%%FORMAT% manual_url=https://download.rockbox.org/release/%RELEASEVER%/rockbox-%MODEL%%FORMAT%
@ -34,14 +34,15 @@ manual_url=https://download.rockbox.org/release-candidate/%RELEASEVER%/rockbox-%
[development] [development]
build_url=http://build.rockbox.org/data/rockbox-%MODEL%.zip build_url=http://build.rockbox.org/data/rockbox-%MODEL%.zip
voice_url=https://download.rockbox.org/release/%RELVERSION%/%MODEL%-%RELVERSION%-english.zip ; we don't have voices for dev builds.
voice_url=https://download.rockbox.org/daily/voices/%MODEL%-%LANGUAGE%.zip
font_url=https://download.rockbox.org/daily/fonts/rockbox-fonts.zip font_url=https://download.rockbox.org/daily/fonts/rockbox-fonts.zip
; manual is only built daily, use that one instead. ; manual is only built daily, use that one instead.
manual_url=https://download.rockbox.org/daily/manual/rockbox-%MODEL%%FORMAT% manual_url=https://download.rockbox.org/daily/manual/rockbox-%MODEL%%FORMAT%
[daily] [daily]
build_url=https://download.rockbox.org/daily/%MODEL%/rockbox-%MODEL%.zip build_url=https://download.rockbox.org/daily/%MODEL%/rockbox-%MODEL%.zip
voice_url=https://download.rockbox.org/daily/voices/%MODEL%-%VERSION%-%LANGUAGE%.zip voice_url=https://download.rockbox.org/daily/voices/%MODEL%-%LANGUAGE%.zip
font_url=https://download.rockbox.org/daily/fonts/rockbox-fonts.zip font_url=https://download.rockbox.org/daily/fonts/rockbox-fonts.zip
manual_url=https://download.rockbox.org/daily/manual/rockbox-%MODEL%%FORMAT% manual_url=https://download.rockbox.org/daily/manual/rockbox-%MODEL%%FORMAT%

View file

@ -496,6 +496,7 @@ void RbUtilQt::installVoice()
// replace placeholder in voice url // replace placeholder in voice url
voiceurl.replace("%MODEL%", model); voiceurl.replace("%MODEL%", model);
voiceurl.replace("%RELVERSION%", relversion); voiceurl.replace("%RELVERSION%", relversion);
voiceurl.replace("%LANGUAGE%", "english");
LOG_INFO() << "voicefile URL:" << voiceurl; LOG_INFO() << "voicefile URL:" << voiceurl;