aboutsummaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
authormatthewt <matthewt@03d0b0b2-0e1a-0410-a411-fdb2f4bd65d7>2008-01-30 18:17:34 +0000
committermatthewt <matthewt@03d0b0b2-0e1a-0410-a411-fdb2f4bd65d7>2008-01-30 18:17:34 +0000
commit68404faadbc484a8ec707d795734ec51fba7c154 (patch)
treebf8306a321ba17acfdaef9ec9b23507de2457d01 /lib
parent7c2bcb55574ebbea6c51b67b5994149400da4895 (diff)
downloadreaction-68404faadbc484a8ec707d795734ec51fba7c154.tar.gz
reaction-68404faadbc484a8ec707d795734ec51fba7c154.zip
=extends NEXT in widgets works
Diffstat (limited to 'lib')
-rw-r--r--lib/ComponentUI/Controller/Root.pm2
-rw-r--r--lib/Reaction/UI/LayoutSet.pm11
2 files changed, 11 insertions, 2 deletions
diff --git a/lib/ComponentUI/Controller/Root.pm b/lib/ComponentUI/Controller/Root.pm
index 2e2a181..4113a73 100644
--- a/lib/ComponentUI/Controller/Root.pm
+++ b/lib/ComponentUI/Controller/Root.pm
@@ -22,7 +22,7 @@ sub base :Chained('/') :PathPart('') :CaptureArgs(0) {
my ($self, $c) = @_;
$self->push_viewport(SiteLayout,
title => 'ComponentUI test title',
- static_base_uri => "${\$c->uri_for('static')}",
+ static_base_uri => "${\$c->uri_for('/static')}",
);
}
diff --git a/lib/Reaction/UI/LayoutSet.pm b/lib/Reaction/UI/LayoutSet.pm
index 44a137c..4185033 100644
--- a/lib/Reaction/UI/LayoutSet.pm
+++ b/lib/Reaction/UI/LayoutSet.pm
@@ -73,7 +73,16 @@ class LayoutSet which {
$layouts->{$fname} = $text;
} elsif ($data =~ /^extends (\S+)/) {
my $super_name = $1;
- $self->super($build_args->{skin}->create_layout_set($super_name))
+ my $skin;
+ if ($super_name eq 'NEXT') {
+ confess "No next skin and layout extends NEXT"
+ unless $build_args->{next_skin};
+ $skin = $build_args->{next_skin};
+ $super_name = $self->name;
+ } else {
+ $skin = $build_args->{skin};
+ }
+ $self->super($skin->create_layout_set($super_name));
} elsif ($data =~ /^widget (\S+)/) {
my $widget_type = $1;
$self->widget_type($1);