|
From: Chris W. <la...@us...> - 2001-11-20 04:03:50
|
Update of /cvsroot/openinteract/OpenInteract/pkg/base_box/OpenInteract/Handler
In directory usw-pr-cvs1:/tmp/cvs-serv24936/OpenInteract/Handler
Modified Files:
Box.pm
Log Message:
modify the login box and ensure we have adequate debugging for custom
handler and for box removal
Index: Box.pm
===================================================================
RCS file: /cvsroot/openinteract/OpenInteract/pkg/base_box/OpenInteract/Handler/Box.pm,v
retrieving revision 1.14
retrieving revision 1.15
diff -C2 -d -r1.14 -r1.15
*** Box.pm 2001/11/01 05:40:51 1.14
--- Box.pm 2001/11/20 04:03:48 1.15
***************
*** 48,51 ****
--- 48,53 ----
eval "require $custom_box_class";
my $custom_box_method = $BOX_CONFIG->{custom_box_method} || DEFAULT_METHOD;
+ $R->DEBUG && $R->scrib( "Calling custom box handler:",
+ "$custom_box_class\->$custom_box_method" );
eval { $custom_box_class->$custom_box_method() };
if ( $@ ) {
***************
*** 78,82 ****
if ( $box_info->{remove} ) {
push @to_remove, $box_info->{name};
! next;
}
--- 80,84 ----
if ( $box_info->{remove} ) {
push @to_remove, $box_info->{name};
! next BOX;
}
***************
*** 125,128 ****
--- 127,131 ----
$box_info->{weight} ||= DEFAULT_BOX_WEIGHT;
next BOX if ( $box_info->{weight} > MAX_BOX_WEIGHT );
+
$R->DEBUG && $R->scrib( 1, "Putting box ($box_info->{name}) onto the",
"stack with weight $box_info->{weight}" );
***************
*** 133,136 ****
--- 136,140 ----
foreach my $remove_name ( @to_remove ) {
+ $R->DEBUG && $R->scrib( 1, "Trying to remove box: $remove_name" );
delete $good_boxes{ $remove_name } if ( $remove_name );
}
***************
*** 160,164 ****
# Generate content for each box
! my @boxes = ();
$R->DEBUG && $R->scrib( 2, "Sorted boxes currently in the list:\n", Dumper( \@sorted_boxes ) );
foreach my $box_info ( @sorted_boxes ) {
--- 164,168 ----
# Generate content for each box
! my @content = ();
$R->DEBUG && $R->scrib( 2, "Sorted boxes currently in the list:\n", Dumper( \@sorted_boxes ) );
foreach my $box_info ( @sorted_boxes ) {
***************
*** 194,198 ****
{ name => $box_template_fullname } );
}
! push @boxes, $box_content;
}
--- 198,202 ----
{ name => $box_template_fullname } );
}
! push @content, $box_content;
}
***************
*** 200,204 ****
|| $BOX_CONFIG->{default_separator}
|| DEFAULT_SEPARATOR;
! return join( $sep_string, @boxes );
}
--- 204,208 ----
|| $BOX_CONFIG->{default_separator}
|| DEFAULT_SEPARATOR;
! return join( $sep_string, @content );
}
|