diff options
Diffstat (limited to 'documentation/sphinx-static')
-rw-r--r-- | documentation/sphinx-static/switchers.js.in | 19 |
1 files changed, 12 insertions, 7 deletions
diff --git a/documentation/sphinx-static/switchers.js.in b/documentation/sphinx-static/switchers.js.in index 5ae0325e6d..408e23a71c 100644 --- a/documentation/sphinx-static/switchers.js.in +++ b/documentation/sphinx-static/switchers.js.in | |||
@@ -219,15 +219,20 @@ by https://git.yoctoproject.org/yocto-autobuilder-helper/tree/scripts/run-docs-b | |||
219 | $('.doctype_switcher_placeholder').html(doctype_select); | 219 | $('.doctype_switcher_placeholder').html(doctype_select); |
220 | $('.doctype_switcher_placeholder select').bind('change', on_doctype_switch); | 220 | $('.doctype_switcher_placeholder select').bind('change', on_doctype_switch); |
221 | 221 | ||
222 | if (ver_compare(release, "3.1") < 0) { | 222 | if (release != "dev") { |
223 | $('#outdated-warning').html('Version ' + release + ' of the project is now considered obsolete, please select and use a more recent version'); | ||
224 | $('#outdated-warning').css('padding', '.5em'); | ||
225 | } else if (release != "dev") { | ||
226 | $.each(all_versions, function(version, vers_data) { | 223 | $.each(all_versions, function(version, vers_data) { |
227 | var series = version.substr(0, 3); | 224 | var series = version.substr(0, 3); |
228 | if (series == current_series && version != release) { | 225 | if (series == current_series) { |
229 | $('#outdated-warning').html('This document is for outdated version ' + release + ', you should select the latest release version in this series, ' + version + '.'); | 226 | if (version != release) { |
230 | $('#outdated-warning').css('padding', '.5em'); | 227 | $('#outdated-warning').html('This document is for outdated version ' + release + ', you should select the latest release version in this series, ' + version + '.'); |
228 | $('#outdated-warning').css('padding', '.5em'); | ||
229 | return false; | ||
230 | } | ||
231 | if (vers_data["obsolete"]) { | ||
232 | $('#outdated-warning').html('Version ' + release + ' of the project is now considered obsolete, please select and use a more recent version'); | ||
233 | $('#outdated-warning').css('padding', '.5em'); | ||
234 | return false; | ||
235 | } | ||
231 | } | 236 | } |
232 | }); | 237 | }); |
233 | } | 238 | } |