diff options
author | Bruce Zu <bruce.zu@sonymobile.com> | 2013-04-21 22:56:17 +0800 |
---|---|---|
committer | Shawn Pearce <sop@google.com> | 2013-04-22 10:28:15 -0700 |
commit | dbc2f75dc9ae2a832087bf8ce4d50564573fdc0a (patch) | |
tree | 954c1ca056f8732f1f07c32511425b3b36e6e204 /gerrit-httpd | |
parent | c46e3f255ef15b9bb15321127864ec0093266089 (diff) |
Enable expanding skipped lines even if 'Syntax Coloring' is off
On SideBySide diff UI if 'Syntax Coloring' is disabled attempting
to expand 'skipped common xx lines' will result in only one line
displaying on the left side. Enabling 'Syntax Coloring' makes the
expand work correctly on both sides.
This issue has existed since v2.3, as the server was not including
enough file content to support expanding the skipped regions.
Change-Id: I6f33b21415746a54c0cdc507246c139b49cd045d
Diffstat (limited to 'gerrit-httpd')
-rw-r--r-- | gerrit-httpd/src/main/java/com/google/gerrit/httpd/rpc/patch/PatchScriptBuilder.java | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/gerrit-httpd/src/main/java/com/google/gerrit/httpd/rpc/patch/PatchScriptBuilder.java b/gerrit-httpd/src/main/java/com/google/gerrit/httpd/rpc/patch/PatchScriptBuilder.java index 816bbef6eb..502c9a39d0 100644 --- a/gerrit-httpd/src/main/java/com/google/gerrit/httpd/rpc/patch/PatchScriptBuilder.java +++ b/gerrit-httpd/src/main/java/com/google/gerrit/httpd/rpc/patch/PatchScriptBuilder.java @@ -198,10 +198,10 @@ class PatchScriptBuilder { context = diffPrefs.getContext(); hugeFile = true; - } else if (diffPrefs.isSyntaxHighlighting()) { - // In order to syntax highlight the file properly we need to - // give the client the complete file contents. So force our - // context temporarily to the complete file size. + } else { + // In order to expand the skipped common lines or syntax highlight the + // file properly we need to give the client the complete file contents. + // So force our context temporarily to the complete file size. // context = MAX_CONTEXT; } |