line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
package HTML::Widgets::NavMenu::Iterator::NavMenu::HeaderRole; |
2
|
|
|
|
|
|
|
$HTML::Widgets::NavMenu::Iterator::NavMenu::HeaderRole::VERSION = '1.1000'; |
3
|
1
|
|
|
1
|
|
5
|
use strict; |
|
1
|
|
|
|
|
2
|
|
|
1
|
|
|
|
|
22
|
|
4
|
1
|
|
|
1
|
|
4
|
use warnings; |
|
1
|
|
|
|
|
2
|
|
|
1
|
|
|
|
|
22
|
|
5
|
|
|
|
|
|
|
|
6
|
1
|
|
|
1
|
|
5
|
use parent qw(HTML::Widgets::NavMenu::Iterator::NavMenu); |
|
1
|
|
|
|
|
1
|
|
|
1
|
|
|
|
|
4
|
|
7
|
|
|
|
|
|
|
|
8
|
|
|
|
|
|
|
__PACKAGE__->mk_acc_ref( |
9
|
|
|
|
|
|
|
[ |
10
|
|
|
|
|
|
|
qw( |
11
|
|
|
|
|
|
|
_was_role |
12
|
|
|
|
|
|
|
) |
13
|
|
|
|
|
|
|
] |
14
|
|
|
|
|
|
|
); |
15
|
|
|
|
|
|
|
|
16
|
|
|
|
|
|
|
|
17
|
|
|
|
|
|
|
sub _start_handle_non_role |
18
|
|
|
|
|
|
|
{ |
19
|
15
|
|
|
15
|
|
30
|
my $self = shift; |
20
|
|
|
|
|
|
|
|
21
|
15
|
100
|
|
|
|
36
|
if ( $self->_was_role() ) |
22
|
|
|
|
|
|
|
{ |
23
|
3
|
|
|
|
|
30
|
$self->_add_tags( |
24
|
|
|
|
|
|
|
$self->gen_ul_tag( { 'depth' => $self->stack->len() - 2 } ) ); |
25
|
|
|
|
|
|
|
} |
26
|
|
|
|
|
|
|
|
27
|
15
|
|
|
|
|
39
|
$self->_was_role(0); |
28
|
|
|
|
|
|
|
|
29
|
15
|
|
|
|
|
37
|
return $self->SUPER::_start_handle_non_role(); |
30
|
|
|
|
|
|
|
} |
31
|
|
|
|
|
|
|
|
32
|
|
|
|
|
|
|
sub _start_handle_role |
33
|
|
|
|
|
|
|
{ |
34
|
7
|
|
|
7
|
|
10
|
my $self = shift; |
35
|
7
|
100
|
|
|
|
15
|
if ( $self->get_role() eq "header" ) |
36
|
|
|
|
|
|
|
{ |
37
|
4
|
100
|
|
|
|
14
|
if ( !$self->_was_role() ) |
38
|
|
|
|
|
|
|
{ |
39
|
3
|
|
|
|
|
7
|
$self->_add_tags(""); |
40
|
|
|
|
|
|
|
} |
41
|
4
|
|
|
|
|
11
|
$self->_add_tags( "", $self->get_link_tag(), "", ); |
42
|
|
|
|
|
|
|
|
43
|
4
|
|
|
|
|
18
|
$self->_was_role(1); |
44
|
|
|
|
|
|
|
} |
45
|
|
|
|
|
|
|
else |
46
|
|
|
|
|
|
|
{ |
47
|
3
|
|
|
|
|
25
|
return $self->SUPER::_start_handle_role(); |
48
|
|
|
|
|
|
|
} |
49
|
|
|
|
|
|
|
} |
50
|
|
|
|
|
|
|
|
51
|
|
|
|
|
|
|
|
52
|
|
|
|
|
|
|
sub _end_handle_role |
53
|
|
|
|
|
|
|
{ |
54
|
7
|
|
|
7
|
|
12
|
my $self = shift; |
55
|
7
|
100
|
|
|
|
12
|
if ( $self->get_role() eq "header" ) |
56
|
|
|
|
|
|
|
{ |
57
|
|
|
|
|
|
|
# Do nothing; |
58
|
|
|
|
|
|
|
} |
59
|
|
|
|
|
|
|
else |
60
|
|
|
|
|
|
|
{ |
61
|
3
|
|
|
|
|
12
|
return $self->SUPER::_end_handle_role(); |
62
|
|
|
|
|
|
|
} |
63
|
|
|
|
|
|
|
} |
64
|
|
|
|
|
|
|
|
65
|
|
|
|
|
|
|
|
66
|
|
|
|
|
|
|
1; |
67
|
|
|
|
|
|
|
|
68
|
|
|
|
|
|
|
__END__ |