tweak new version dialog

This commit is contained in:
Andrew Dolgov 2010-11-25 14:57:32 +03:00
parent 1bf679a304
commit e91ad1e9ab
2 changed files with 13 additions and 6 deletions

View File

@ -3905,7 +3905,7 @@
if ($version_data && $version_data['version']) { if ($version_data && $version_data['version']) {
if (version_compare(VERSION, $version_data['version']) == -1) { if (version_compare(VERSION, $version_data['version']) == -1) {
return $version_data['version']; return $version_data;
} }
} }
} }

View File

@ -766,18 +766,25 @@
} }
if ($id == "newVersion") { if ($id == "newVersion") {
$version = check_for_update($link); $version_data = check_for_update($link);
$version = $version_data['version'];
$version_link = "<a class=\"visibleLink\" target=\"_blank\" $id = $version_data['version_id'];
href=\"http://tt-rss.org\">http://tt-rss.org</a>";
print "<div class='tagCloudContainer'>"; print "<div class='tagCloudContainer'>";
print T_sprintf("New version of Tiny Tiny RSS is available (%s).<br/>Visit %s for more information.", "<b>$version</b>", $version_link); print T_sprintf("New version of Tiny Tiny RSS is available (%s).",
"<b>$version</b>");
print "</div>"; print "</div>";
$details = "http://tt-rss.org/redmine/versions/show/$id";
$download = "http://tt-rss.org/#Download";
print "<div style='text-align : center'>"; print "<div style='text-align : center'>";
print "<button dojoType=\"dijit.form.Button\"
onclick=\"return window.open('$details')\">".__("Details")."</button>";
print "<button dojoType=\"dijit.form.Button\"
onclick=\"return window.open('$download')\">".__("Download")."</button>";
print "<button dojoType=\"dijit.form.Button\" print "<button dojoType=\"dijit.form.Button\"
onclick=\"return dijit.byId('newVersionDlg').hide()\">". onclick=\"return dijit.byId('newVersionDlg').hide()\">".
__('Close this window')."</button>"; __('Close this window')."</button>";