remove require, Time::Simple
@@ -28,10 +28,10 @@ | ||
28 | 28 | use SVG; |
29 | 29 | use Time::Piece; |
30 | 30 | use Time::Seconds; |
31 | -use Time::Simple; | |
32 | 31 | use Time::HiRes; |
33 | 32 | use Tie::IxHash; |
34 | -use XML::Atom; | |
33 | +use XML::Atom::Feed; | |
34 | +use XML::Atom::Entry; | |
35 | 35 | use XML::Generator::DBI; |
36 | 36 | use XML::SAX::Writer; |
37 | 37 | #%DB::packages = ( 'main' => 1 ); |
@@ -460,7 +460,6 @@ | ||
460 | 460 | { |
461 | 461 | print "Content-Type: image/svg+xml\n\n"; |
462 | 462 | |
463 | - require SVG; | |
464 | 463 | $date = Date::Simple->new( split /-/, $date ); |
465 | 464 | $graph_bgn = $date->format('%Y-%m-%d'); |
466 | 465 | $graph_end = $date->next->format('%Y-%m-%d'); |
@@ -502,9 +501,8 @@ | ||
502 | 501 | $svg->rectangle( 'x' => 50, 'y' => $_ * 20 + 14, width => $width, height => 2 ); |
503 | 502 | } |
504 | 503 | if ( $today ) { |
505 | - require Time::Simple; | |
506 | - my $time = Time::Simple->new(); | |
507 | - my $x = ( $time->hours * 60 + $time->minutes ) * 0.5 + 50; | |
504 | + my $time = Time::Piece->localtime; | |
505 | + my $x = ( $time->hour * 60 + $time->minute ) * 0.5 + 50; | |
508 | 506 | $svg->tag( 'line', x1 => $x, x2 => $x, y1 => 30, y2 => $tuner{all} * 20 + 20, |
509 | 507 | style => { stroke => 'red', 'fill-opacity' => '1.0' } ); |
510 | 508 | } |
@@ -634,9 +632,6 @@ | ||
634 | 632 | ################ mode=atom ################ |
635 | 633 | |
636 | 634 | if ( $mode eq 'atom' ) { |
637 | - require XML::Atom::Feed; | |
638 | - require XML::Atom::Entry; | |
639 | - | |
640 | 635 | my $recording_count = $encoding_count = $jbk_count = 0; |
641 | 636 | my $ary_ref = $dbh->selectall_arrayref( |
642 | 637 | "SELECT chtxt, title, btime, etime, opt |
@@ -1725,8 +1720,6 @@ | ||
1725 | 1720 | ################ mode=expert ################ |
1726 | 1721 | |
1727 | 1722 | if ( $mode eq 'expert' ) { |
1728 | - require List::Compare; | |
1729 | - | |
1730 | 1723 | my $ary_ref; |
1731 | 1724 | |
1732 | 1725 | $HTML =~ s/%HTML_TITLE_OPT%/ - Expert/; |
@@ -1955,7 +1948,6 @@ | ||
1955 | 1948 | $HTML =~ s|%REFRESH%|<meta http-equiv="refresh" content="300">|; |
1956 | 1949 | $HTML .= qq {<div>\n}; |
1957 | 1950 | |
1958 | - require Data::Dumper::Concise; | |
1959 | 1951 | $tmp = read_file( '/etc/rec10.conf' ); |
1960 | 1952 | $tmp =~ s/\n/<br>\n/gs; |
1961 | 1953 | $HTML .= $tmp; |
@@ -2281,8 +2273,6 @@ | ||
2281 | 2273 | } |
2282 | 2274 | |
2283 | 2275 | sub get_overlap { |
2284 | - require List::Util; | |
2285 | - | |
2286 | 2276 | my $ary_ref = $dbh->selectall_arrayref( |
2287 | 2277 | "SELECT btime, etime, title |
2288 | 2278 | FROM timeline |