This commit is contained in:
kestes%walrus.com 2003-04-13 22:01:17 +00:00
Родитель 7c08afb482
Коммит 4a5ec5ccf1
1 изменённых файлов: 33 добавлений и 9 удалений

Просмотреть файл

@ -30,8 +30,8 @@
# kestes@walrus.com Home. # kestes@walrus.com Home.
# Contributor(s): # Contributor(s):
# $Revision: 1.24 $ # $Revision: 1.25 $
# $Date: 2003-04-13 14:21:42 $ # $Date: 2003-04-13 22:01:17 $
# $Author: kestes%walrus.com $ # $Author: kestes%walrus.com $
# $Source: /home/jrmuizel/cvs-mirror/mozilla/webtools/tinderbox2/src/lib/TinderDB/Notice.pm,v $ # $Source: /home/jrmuizel/cvs-mirror/mozilla/webtools/tinderbox2/src/lib/TinderDB/Notice.pm,v $
# $Name: $ # $Name: $
@ -81,10 +81,11 @@ use File::Basename;
use lib '#tinder_libdir#'; use lib '#tinder_libdir#';
use Utils; use Utils;
use VCDisplay;
use HTMLPopUp; use HTMLPopUp;
use TinderDB::BasicTxtDB; use TinderDB::BasicTxtDB;
$VERSION = ( qw $Revision: 1.24 $ )[1]; $VERSION = ( qw $Revision: 1.25 $ )[1];
@ISA = qw(TinderDB::BasicTxtDB); @ISA = qw(TinderDB::BasicTxtDB);
@ -362,17 +363,31 @@ sub render_notice {
foreach $time (@db_times) { foreach $time (@db_times) {
$localtime = localtime($time); my ($pretty_time) = HTMLPopUp::timeHTML($time);
my $checkin_links;
$checkin_links .= VCDisplay::query(
'tree' => $tree,
'mindate' => $time,
'linktxt' => "Checkins since $pretty_time",
);
$checkin_links .= "<br>\n";
$checkin_links .= VCDisplay::query(
'tree' => $tree,
'maxdate' => $time,
'mindate' => $time-$main::SECONDS_PER_HOUR,
'linktxt' => "Checkins before $pretty_time",
);
$checkin_links .= "<br>\n";
# allow us to reference individual notices in the file
$rendered_notices .= ( $rendered_notices .= (
"\n\n". "\n\n".
# allow us to reference individual
# notices in the file
HTMLPopUp::Link( HTMLPopUp::Link(
"name"=>$time, "name"=>$time,
"href"=>"\#$time", "href"=>"\#$time",
#"linktxt" => $localtime,
). ).
"<!-- $localtime -->". "<!-- $pretty_time -->".
"\n". "\n".
""); "");
@ -417,6 +432,15 @@ sub render_notice {
my $href = (FileStructure::get_filename($tree, 'tree_URL'). my $href = (FileStructure::get_filename($tree, 'tree_URL').
"/all_notices.html\#$first_notice_time"); "/all_notices.html\#$first_notice_time");
my $index_link = (
"\t\t".
HTMLPopUp::Link(
"linktxt" => "All Notices for this tree",
"href" => $href,
).
"<br>\n".
"");
# the popup window software is pretty sensitive to newlines and # the popup window software is pretty sensitive to newlines and
# terminating quotes. Take those out of the message. # terminating quotes. Take those out of the message.
@ -435,7 +459,7 @@ sub render_notice {
"linktxt" => " $NOTICE_AVAILABLE ", "linktxt" => " $NOTICE_AVAILABLE ",
"href" => $href, "href" => $href,
"windowtxt" => $rendered_notices, "windowtxt" => $rendered_notices.$index_link,
"windowtitle" => $title, "windowtitle" => $title,
"windowheight" => (175 * $num_notices)+100, "windowheight" => (175 * $num_notices)+100,
). ).