diff --git a/src/IDF/Diff.php b/src/IDF/Diff.php
index b1073b5..20f7f33 100644
--- a/src/IDF/Diff.php
+++ b/src/IDF/Diff.php
@@ -115,6 +115,13 @@ class IDF_Diff
{
$out = '';
foreach ($this->files as $filename=>$file) {
+ $openPre = '';
+ $closePre = '';
+ $fileinfo = IDF_Views_Source::getMimeType($filename);
+ if (IDF_Views_Source::isSupportedExtension($fileinfo[2])) {
+ $openPre = '
';
+ $closePre = '
';
+ }
$out .= "\n".''."\n";
$out .= ''.Pluf_esc($filename).' |
'."\n";
$cc = 1;
@@ -128,7 +135,7 @@ class IDF_Diff
$class = 'diff-a';
}
$line_content = self::padLine(Pluf_esc($line[2]));
- $out .= sprintf('%s | %s | %s |
'."\n", $line[0], $line[1], $class, $line_content);
+ $out .= sprintf('%s | %s | %s%s%s |
'."\n", $line[0], $line[1], $class, $openPre, $line_content, $closePre);
}
if (count($file['chunks']) > $cc)
$out .= '... | ... | |
'."\n";
diff --git a/src/IDF/templates/source/commit.html b/src/IDF/templates/source/commit.html
index 1f8c036..2f01d4d 100644
--- a/src/IDF/templates/source/commit.html
+++ b/src/IDF/templates/source/commit.html
@@ -1,4 +1,5 @@
{extends "source/base.html"}
+{block extraheader}{/block}
{block docclass}yui-t1{assign $inCommit=true}{/block}
{block body}
@@ -43,3 +44,9 @@
{/if}
{/block}
+{block javascript}
+
+
+{/block}