Merge tag 'upstream/1.44'
Upstream version 1.44
gregor herrmann
11 years ago
26 | 26 | "Olaf Alders <olaf\@wundercounter.com> (current maintainer)" |
27 | 27 | ], |
28 | 28 | "dist_name" => "HTTP-BrowserDetect", |
29 | "dist_version" => "1.42", | |
29 | "dist_version" => "1.44", | |
30 | 30 | "license" => "perl", |
31 | 31 | "module_name" => "HTTP::BrowserDetect", |
32 | 32 | "recommends" => {}, |
0 | 0 | Revision history for Perl extension HTTP::BrowserDetect. |
1 | ||
2 | 1.44 2012-05-03 | |
3 | - Fixes "sort (...) interpreted as function" introduced in 1.43, which was | |
4 | causing tests to fail | |
5 | ||
6 | 1.43 2012-05-02 | |
7 | - Sorts keys when iterating for consistency across Perl implementations (Thom Blake) | |
1 | 8 | |
2 | 9 | 1.42 2012-03-01 |
3 | 10 | - Adds bot detection for askjeeves, baidu and googleadsbot (Bill Rhodes) |
5 | 5 | "Olaf Alders <olaf@wundercounter.com> (current maintainer)" |
6 | 6 | ], |
7 | 7 | "dynamic_config" : 0, |
8 | "generated_by" : "Dist::Zilla version 4.300003, CPAN::Meta::Converter version 2.112621", | |
8 | "generated_by" : "Dist::Zilla version 4.300010, CPAN::Meta::Converter version 2.120630", | |
9 | 9 | "license" : [ |
10 | 10 | "perl_5" |
11 | 11 | ], |
28 | 28 | }, |
29 | 29 | "runtime" : { |
30 | 30 | "requires" : { |
31 | "Exporter" : 0, | |
32 | "strict" : 0, | |
33 | "vars" : 0 | |
31 | "Exporter" : "0", | |
32 | "strict" : "0", | |
33 | "vars" : "0" | |
34 | 34 | } |
35 | 35 | }, |
36 | 36 | "test" : { |
37 | 37 | "requires" : { |
38 | "Data::Dump" : 0, | |
39 | "English" : 0, | |
40 | "File::Slurp" : 0, | |
41 | "FindBin" : 0, | |
42 | "JSON::PP" : 0, | |
43 | "Test::More" : 0, | |
44 | "warnings" : 0 | |
38 | "Data::Dump" : "0", | |
39 | "English" : "0", | |
40 | "File::Slurp" : "0", | |
41 | "FindBin" : "0", | |
42 | "JSON::PP" : "0", | |
43 | "Test::More" : "0", | |
44 | "warnings" : "0" | |
45 | 45 | } |
46 | 46 | } |
47 | 47 | }, |
57 | 57 | "web" : "https://github.com/oalders/http-browserdetect" |
58 | 58 | } |
59 | 59 | }, |
60 | "version" : "1.42" | |
60 | "version" : "1.44" | |
61 | 61 | } |
62 | 62 |
33 | 33 | "strict" => 0, |
34 | 34 | "vars" => 0 |
35 | 35 | }, |
36 | "VERSION" => "1.42", | |
36 | "VERSION" => "1.44", | |
37 | 37 | "test" => { |
38 | 38 | "TESTS" => "t/*.t" |
39 | 39 | } |
2 | 2 | an HTTP user agent string |
3 | 3 | |
4 | 4 | VERSION |
5 | version 1.42 | |
5 | version 1.44 | |
6 | 6 | |
7 | 7 | SYNOPSIS |
8 | 8 | use HTTP::BrowserDetect; |
395 | 395 | |
396 | 396 | Bill Rhodes |
397 | 397 | |
398 | Thom Blake | |
399 | ||
398 | 400 | TO DO |
399 | 401 | The "_engine()" method currently only handles Gecko and Trident. It |
400 | 402 | needs to be expanded to handle other rendering engines. |
4 | 4 | license = Perl_5 |
5 | 5 | copyright_holder = Lee Semel |
6 | 6 | copyright_year = 2012 |
7 | version = 1.42 | |
7 | version = 1.44 | |
8 | 8 | main_module = lib/HTTP/BrowserDetect.pm |
9 | 9 | |
10 | 10 | [GatherDir] |
1 | 1 | |
2 | 2 | package HTTP::BrowserDetect; |
3 | 3 | { |
4 | $HTTP::BrowserDetect::VERSION = '1.42'; | |
4 | $HTTP::BrowserDetect::VERSION = '1.44'; | |
5 | 5 | } |
6 | 6 | |
7 | 7 | use vars qw(@ISA @EXPORT @EXPORT_OK @ALL_TESTS); |
138 | 138 | ( |
139 | 139 | @OS_TESTS, @WINDOWS_TESTS, @MAC_TESTS, |
140 | 140 | @UNIX_TESTS, @BSD_TESTS, @GAMING_TESTS, |
141 | keys %DEVICE_TESTS, @BROWSER_TESTS, @IE_TESTS, | |
141 | ( sort ( keys %DEVICE_TESTS ) ), @BROWSER_TESTS, @IE_TESTS, | |
142 | 142 | @OPERA_TESTS, @AOL_TESTS, @NETSCAPE_TESTS, |
143 | 143 | @FIREFOX_TESTS, @ENGINE_TESTS, @ROBOT_TESTS, |
144 | 144 | @MISC_TESTS, |
1136 | 1136 | |
1137 | 1137 | my ( $self, $check ) = _self_or_default( @_ ); |
1138 | 1138 | |
1139 | foreach my $device ( keys %DEVICE_TESTS ) { | |
1139 | foreach my $device ( sort keys %DEVICE_TESTS ) { | |
1140 | 1140 | return $device if ( $self->$device ); |
1141 | 1141 | } |
1142 | 1142 | |
1208 | 1208 | my ( $self, $check ) = _self_or_default( @_ ); |
1209 | 1209 | |
1210 | 1210 | my @browser_properties; |
1211 | foreach my $property ( keys %{ $self->{tests} } ) { | |
1211 | foreach my $property ( sort keys %{ $self->{tests} } ) { | |
1212 | 1212 | push @browser_properties, lc( $property ) |
1213 | 1213 | if ( ${ $self->{tests} }{$property} ); |
1214 | 1214 | } |
1233 | 1233 | |
1234 | 1234 | =head1 VERSION |
1235 | 1235 | |
1236 | version 1.42 | |
1236 | version 1.44 | |
1237 | 1237 | |
1238 | 1238 | =head1 SYNOPSIS |
1239 | 1239 | |
1716 | 1716 | |
1717 | 1717 | Bill Rhodes |
1718 | 1718 | |
1719 | Thom Blake | |
1720 | ||
1719 | 1721 | =head1 TO DO |
1720 | 1722 | |
1721 | 1723 | The C<_engine()> method currently only handles Gecko and Trident. It needs to |