From 4b56bfb1fa9b5278c030341a5f0770c0cc3fae68 Mon Sep 17 00:00:00 2001 From: Stas Vilchik Date: Fri, 14 Nov 2014 13:27:15 +0100 Subject: SONAR-5718 Fix clipping effect of the black header --- .../sonar-web/src/main/coffee/issues/component-viewer/main.coffee | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'server/sonar-web/src/main/coffee') diff --git a/server/sonar-web/src/main/coffee/issues/component-viewer/main.coffee b/server/sonar-web/src/main/coffee/issues/component-viewer/main.coffee index 33339dbb453..47ff206ae9e 100644 --- a/server/sonar-web/src/main/coffee/issues/component-viewer/main.coffee +++ b/server/sonar-web/src/main/coffee/issues/component-viewer/main.coffee @@ -223,6 +223,9 @@ define [ line = issue.get('line') || 0 @model.set key: componentKey, issueLine: line + # disable clipping effect of the black header + @$el.addClass 'full-height' + @requestSources(line - LINES_AROUND, line + LINES_AROUND) .done (data) => formattedSource = _.map data.sources, (item) => lineNumber: item[0], code: item[1] @@ -235,7 +238,6 @@ define [ hasSourceBefore: firstLine > 1 hasSourceAfter: lastLine == line + LINES_AROUND @render() - @scrollToLine issue.get 'line' @bindScrollEvents() @requestIssues() .fail => @@ -244,6 +246,9 @@ define [ formattedSource: [] @model.set hasSourceBefore: false, hasSourceAfter: false @render() + .always => + @$el.removeClass 'full-height' + @scrollToLine issue.get 'line' requestSources: (lineFrom, lineTo) -> -- cgit v1.2.3