Browse files

調整

  • Loading branch information...
1 parent d8037f5 commit aca2bf819c5d170052312299f48479f82a19abaf @kazeburo committed Jul 6, 2010
Showing with 2 additions and 9 deletions.
  1. +1 −6 lib/NoNoPaste.pm
  2. +1 −3 lib/Shirahata.pm
View
7 lib/NoNoPaste.pm
@@ -163,7 +163,6 @@ __DATA__
: }
<h2 class="subheader">List</h2>
-
<: for $entries -> $entry { :>
<div class="entry">
<pre class="prettyprint">
@@ -182,7 +181,6 @@ __DATA__
<a href="<: $req.uri_for('/', [ offset => $offset + 10 ] ) :>">Next</a>
<: } :>
</p>
-
: }
: override javascript -> {
@@ -193,11 +191,9 @@ $(function() {
$.jStorage.set( "nick", $('#nick').val() );
return true;
});
-
if ( $('#nick').val().length == 0 ) {
$('#nick').val( $.jStorage.get("nick") );
}
-
});
</script>
: }
@@ -209,15 +205,14 @@ $(function() {
: override content -> {
<h2 class="subheader"><a href="<: $req.uri_for('/entry/'~$entry.id) :>"><: $req.uri_for('/entry/'~$entry.id) :></a></h2>
-
<div class="entry">
<pre class="prettyprint">
<: $entry.body :>
</pre>
<div class="entry_meta"><a href="<: $req.uri_for('/entry/'~$entry.id) :>" class="date"><: $entry.ctime :></a> / <span class="nick"><: $entry.nick :></span></div>
</div>
-
: }
+
: override javascript -> {
<script type="text/javascript">
$(function() {
View
4 lib/Shirahata.pm
@@ -91,7 +91,6 @@ sub build_template {
if ( !$self->{_templates_dir} ) {
my $reader = Data::Section::Simple->new(ref $self);
my $all = $reader->get_data_section;
-
$self->{_template_dir} = File::Temp::tempdir( CLEANUP => 1 );
for my $section ( keys %$all ) {
my $fh = Path::Class::file( $self->{_template_dir}, $section )->openw;
@@ -107,6 +106,7 @@ sub build_app {
my $tx = Text::Xslate->new(
path => [ $self->build_template ],
cache_dir => File::Temp::tempdir( CLEANUP => 1 ),
+ cache => 2,
input_layer => ':raw',
function => {
fillinform => sub {
@@ -211,8 +211,6 @@ sub post {
$class->_any( ['POST'], $_[0], $_[1] );
}
-
-
1;
package Shirahata::Connection;

0 comments on commit aca2bf8

Please sign in to comment.