From e4fa987e3d3426c01f0b8e3c34cb6c4acfbe85bd Mon Sep 17 00:00:00 2001 From: Fabrice Bellingard Date: Tue, 27 Mar 2012 10:54:49 +0200 Subject: [PATCH] SONAR-3357 Improve the "Violations" widget - replace "On new code" label by "Added" - replace "On old code" label by "Removed" --- .../org/sonar/plugins/core/widgets/rules.html.erb | 8 ++++---- .../src/main/resources/org/sonar/l10n/core.properties | 2 ++ 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/plugins/sonar-core-plugin/src/main/resources/org/sonar/plugins/core/widgets/rules.html.erb b/plugins/sonar-core-plugin/src/main/resources/org/sonar/plugins/core/widgets/rules.html.erb index 21abde5f3cb..d62971a097c 100644 --- a/plugins/sonar-core-plugin/src/main/resources/org/sonar/plugins/core/widgets/rules.html.erb +++ b/plugins/sonar-core-plugin/src/main/resources/org/sonar/plugins/core/widgets/rules.html.erb @@ -22,19 +22,19 @@ if @dashboard_configuration.selected_period? violations_variation = variation_value(violations) new_violations_variation = variation_value(new_violations) - estimated_cleared_violations = (violations_variation - new_violations_variation).to_i if violations_variation && new_violations_variation + estimated_cleared_violations = (new_violations_variation - violations_variation).to_i if violations_variation && new_violations_variation %> <% if new_violations_variation && new_violations_variation > 0 %>
- <%= message('widget.rules.on_new_code') -%>  + <%= message('widget.rules.added') -%>  <%= format_variation(new_violations, :style => 'none', :default => '-') -%> <% end %> - <% if estimated_cleared_violations && estimated_cleared_violations < 0 %> + <% if estimated_cleared_violations && estimated_cleared_violations > 0 %>
- <%= message('widget.rules.on_old_code') -%>  + <%= message('widget.rules.removed') -%>  <%= estimated_cleared_violations -%> <% end %> diff --git a/plugins/sonar-l10n-en-plugin/src/main/resources/org/sonar/l10n/core.properties b/plugins/sonar-l10n-en-plugin/src/main/resources/org/sonar/l10n/core.properties index d41cd3320c9..21c9bcb712f 100644 --- a/plugins/sonar-l10n-en-plugin/src/main/resources/org/sonar/l10n/core.properties +++ b/plugins/sonar-l10n-en-plugin/src/main/resources/org/sonar/l10n/core.properties @@ -654,6 +654,8 @@ widget.rules.violations=Violations widget.rules.rules_compliance=Rules compliance widget.rules.on_new_code=On new code: widget.rules.on_old_code=On old code: +widget.rules.added=Added: +widget.rules.removed=Removed: widget.size.name=Size metrics widget.size.description=Reports general metrics on the size of the project. -- 2.39.5