[Jifty-commit] r5765 - in Template-Declare: lib/Template/Declare t

Jifty commits jifty-commit at lists.jifty.org
Fri Aug 22 03:49:36 EDT 2008


Author: sartak
Date: Fri Aug 22 03:49:35 2008
New Revision: 5765

Modified:
   Template-Declare/   (props changed)
   Template-Declare/lib/Template/Declare/Tags.pm
   Template-Declare/t/wrappers.t

Log:
 r70189 at onn:  sartak | 2008-08-22 03:49:29 -0400
 Sadly, a few places (notably Jifty) already use the name "wrapper". Rename our wrapper feature to "create_wrapper".. for now.


Modified: Template-Declare/lib/Template/Declare/Tags.pm
==============================================================================
--- Template-Declare/lib/Template/Declare/Tags.pm	(original)
+++ Template-Declare/lib/Template/Declare/Tags.pm	Fri Aug 22 03:49:35 2008
@@ -18,7 +18,7 @@
     = qw( with template private show show_page attr outs
           outs_raw in_isolation $self under
           get_current_attr xml_decl
-          smart_tag_wrapper current_template wrapper );
+          smart_tag_wrapper current_template create_wrapper );
 our @TAG_SUB_LIST;
 *TagSubs = \@TAG_SUB_LIST;  # For backward compatibility only
 
@@ -273,10 +273,10 @@
 
 }
 
-=head2 wrapper WRAPPERNAME => sub { 'Implementation' };
+=head2 create_wrapper WRAPPERNAME => sub { 'Implementation' };
 
-C<wrapper> declares a wrapper subroutine that can be called like a tag sub,
-but can optionally take arguments to be passed to the wrapper sub. For
+C<create_wrapper> declares a wrapper subroutine that can be called like a tag
+sub, but can optionally take arguments to be passed to the wrapper sub. For
 example, if you wanted to wrap all of the output of a template in the usual
 HTML headers and footers, you can do something like this:
 
@@ -285,7 +285,7 @@
   use base 'Template::Declare';
 
   BEGIN {
-      wrapper wrap => sub {
+      create_wrapper wrap => sub {
           my $code = shift;
           my %params = @_;
           html {
@@ -322,7 +322,7 @@
 
 =cut
 
-sub wrapper ($$) {
+sub create_wrapper ($$) {
     my $wrapper_name   = shift;
     my $coderef        = shift;
     my $template_class = caller;

Modified: Template-Declare/t/wrappers.t
==============================================================================
--- Template-Declare/t/wrappers.t	(original)
+++ Template-Declare/t/wrappers.t	Fri Aug 22 03:49:35 2008
@@ -6,7 +6,7 @@
 use base 'Template::Declare';
 
 BEGIN {
-    wrapper wrap => sub {
+    create_wrapper wrap => sub {
         my $code = shift;
         my %params = @_;
         html {


More information about the Jifty-commit mailing list