diff options
author | Dominik Riebeling <Dominik.Riebeling@gmail.com> | 2020-11-14 16:23:56 +0100 |
---|---|---|
committer | Dominik Riebeling <Dominik.Riebeling@gmail.com> | 2020-11-14 16:42:29 +0100 |
commit | 2509def164ee7f4aecbe6a786df57140f19e35f2 (patch) | |
tree | 63a7396e1b94482f9f05c3f3abf6c7cd77e10d26 /rbutil/rbutilqt/gui/manualwidget.cpp | |
parent | 440083af872da43c116c5374d8e1511cef65abf2 (diff) | |
download | rockbox-2509def164ee7f4aecbe6a786df57140f19e35f2.tar.gz rockbox-2509def164ee7f4aecbe6a786df57140f19e35f2.zip |
rbutil: Rework player configuration.
- Split internal configuration into player specific and common parts.
Always require passing the player for player specific data instead of
implicitly assuming the currently selected one; only use the currently
selected one if the player name is explicitly passed as empty.
- Similarly adjust handling of server info data; prepare for splitting
into build type specific values so the naming becomes cleaner.
Change-Id: I894e694f83bd9fe2d22ad46b3f8f7df3e2c68033
Diffstat (limited to 'rbutil/rbutilqt/gui/manualwidget.cpp')
-rw-r--r-- | rbutil/rbutilqt/gui/manualwidget.cpp | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/rbutil/rbutilqt/gui/manualwidget.cpp b/rbutil/rbutilqt/gui/manualwidget.cpp index 0ba3012aea..23adc3cf46 100644 --- a/rbutil/rbutilqt/gui/manualwidget.cpp +++ b/rbutil/rbutilqt/gui/manualwidget.cpp | |||
@@ -42,9 +42,9 @@ void ManualWidget::updateManual() | |||
42 | if(!m_platform.isEmpty()) | 42 | if(!m_platform.isEmpty()) |
43 | { | 43 | { |
44 | ui.labelPdfManual->setText(tr("<a href='%1'>PDF Manual</a>") | 44 | ui.labelPdfManual->setText(tr("<a href='%1'>PDF Manual</a>") |
45 | .arg(ServerInfo::platformValue(m_platform, ServerInfo::ManualPdfUrl).toString())); | 45 | .arg(ServerInfo::platformValue(ServerInfo::ManualPdfUrl, m_platform).toString())); |
46 | ui.labelHtmlManual->setText(tr("<a href='%1'>HTML Manual (opens in browser)</a>") | 46 | ui.labelHtmlManual->setText(tr("<a href='%1'>HTML Manual (opens in browser)</a>") |
47 | .arg(ServerInfo::platformValue(m_platform, ServerInfo::ManualHtmlUrl).toString())); | 47 | .arg(ServerInfo::platformValue(ServerInfo::ManualHtmlUrl, m_platform).toString())); |
48 | } | 48 | } |
49 | else { | 49 | else { |
50 | ui.labelPdfManual->setText(tr("Select a device for a link to the correct manual")); | 50 | ui.labelPdfManual->setText(tr("Select a device for a link to the correct manual")); |
@@ -65,9 +65,9 @@ void ManualWidget::downloadManual(void) | |||
65 | QMessageBox::Yes | QMessageBox::No) != QMessageBox::Yes) { | 65 | QMessageBox::Yes | QMessageBox::No) != QMessageBox::Yes) { |
66 | return; | 66 | return; |
67 | } | 67 | } |
68 | QString manual = SystemInfo::value(SystemInfo::CurManual).toString(); | 68 | QString manual = SystemInfo::platformValue(SystemInfo::CurManual).toString(); |
69 | if(manual.isEmpty()) { | 69 | if(manual.isEmpty()) { |
70 | manual = "rockbox-" + SystemInfo::value(SystemInfo::CurBuildserverModel).toString(); | 70 | manual = "rockbox-" + SystemInfo::platformValue(SystemInfo::CurBuildserverModel).toString(); |
71 | } | 71 | } |
72 | 72 | ||
73 | ProgressLoggerGui* logger = new ProgressLoggerGui(this); | 73 | ProgressLoggerGui* logger = new ProgressLoggerGui(this); |
@@ -78,14 +78,14 @@ void ManualWidget::downloadManual(void) | |||
78 | installer->setCache(true); | 78 | installer->setCache(true); |
79 | 79 | ||
80 | if(ui.radioPdf->isChecked()) { | 80 | if(ui.radioPdf->isChecked()) { |
81 | installer->setUrl(ServerInfo::platformValue(m_platform, | 81 | installer->setUrl(ServerInfo::platformValue( |
82 | ServerInfo::ManualPdfUrl).toString()); | 82 | ServerInfo::ManualPdfUrl, m_platform).toString()); |
83 | installer->setLogSection("Manual (PDF)"); | 83 | installer->setLogSection("Manual (PDF)"); |
84 | installer->setTarget("/" + manual + ".pdf"); | 84 | installer->setTarget("/" + manual + ".pdf"); |
85 | } | 85 | } |
86 | else { | 86 | else { |
87 | installer->setUrl(ServerInfo::platformValue(m_platform, | 87 | installer->setUrl(ServerInfo::platformValue( |
88 | ServerInfo::ManualZipUrl).toString()); | 88 | ServerInfo::ManualZipUrl, m_platform).toString()); |
89 | installer->setLogSection("Manual (HTML)"); | 89 | installer->setLogSection("Manual (HTML)"); |
90 | installer->setTarget("/" + manual + "-" + "-html.zip"); | 90 | installer->setTarget("/" + manual + "-" + "-html.zip"); |
91 | } | 91 | } |