aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorsimonbrandhof <simon.brandhof@gmail.com>2011-08-04 01:15:04 +0200
committersimonbrandhof <simon.brandhof@gmail.com>2011-08-04 01:15:04 +0200
commit0d2522a308bbee1d35aed6303d7ce9e4bcfea13b (patch)
treeb45445c451649c411b34858a704d8701022902b6
parenta9b2318ce220e5abf97ade9123233fbf1e59e900 (diff)
downloadsonarqube-0d2522a308bbee1d35aed6303d7ce9e4bcfea13b.tar.gz
sonarqube-0d2522a308bbee1d35aed6303d7ce9e4bcfea13b.zip
SONAR-75 fix naming convention of widget name and properties
-rw-r--r--plugins/sonar-core-plugin/src/main/java/org/sonar/plugins/core/widgets/CustomMeasuresWidget.java1
-rw-r--r--plugins/sonar-l10n-en-plugin/src/main/resources/org/sonar/l10n/core.properties24
-rw-r--r--sonar-server/src/main/webapp/WEB-INF/app/views/dashboard/_configure_widget.html.erb2
-rw-r--r--sonar-server/src/main/webapp/WEB-INF/app/views/dashboard/_widget_definition.html.erb2
-rw-r--r--sonar-server/src/main/webapp/WEB-INF/app/views/dashboard/_widget_properties.html.erb4
5 files changed, 17 insertions, 16 deletions
diff --git a/plugins/sonar-core-plugin/src/main/java/org/sonar/plugins/core/widgets/CustomMeasuresWidget.java b/plugins/sonar-core-plugin/src/main/java/org/sonar/plugins/core/widgets/CustomMeasuresWidget.java
index 6410d64e60b..c2eafda41fb 100644
--- a/plugins/sonar-core-plugin/src/main/java/org/sonar/plugins/core/widgets/CustomMeasuresWidget.java
+++ b/plugins/sonar-core-plugin/src/main/java/org/sonar/plugins/core/widgets/CustomMeasuresWidget.java
@@ -21,7 +21,6 @@ package org.sonar.plugins.core.widgets;
import org.sonar.api.web.*;
-@WidgetCategory({"Measures"})
@WidgetProperties(
{
@WidgetProperty(key = "metric1", type = WidgetPropertyType.METRIC),
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 bd3e5eb18ae..7e60f08f1c5 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
@@ -409,12 +409,12 @@ dashboard.update_dashboard=Update dashboard
#
#------------------------------------------------------------------------------
-widget.alerts.title=Alerts
+widget.alerts.name=Alerts
widget.alerts.description=Display current alerts on the project.
widget.alerts.no_alert=No alerts
widget.alerts.alerts=Alerts
-widget.code_coverage.title=Code coverage
+widget.code_coverage.name=Code coverage
widget.code_coverage.description=Reports on units tests and code coverage by unit tests.
widget.code_coverage.line_coverage.suffix=\ line coverage
widget.code_coverage.branch_coverage.suffix=\ branch coverage
@@ -427,7 +427,7 @@ widget.code_coverage.errors.suffix=\ errors
widget.code_coverage.tests.suffix=\ tests
widget.code_coverage.skipped.suffix=\ skipped
-widget.comments_duplications.title=Comments & Duplications
+widget.comments_duplications.name=Comments & Duplications
widget.comments_duplications.description=Reports on copy/paste and documentation
widget.comments_duplications.comments=Comments
widget.comments_duplications.lines.suffix=\ lines
@@ -439,7 +439,7 @@ widget.comments_duplications.duplications=Duplications
widget.comments_duplications.blocks.suffix=\ blocs
widget.comments_duplications.files.suffix=\ files
-widget.complexity.title=Complexity
+widget.complexity.name=Complexity
widget.complexity.description=Reports on complexity, average complexity and complexity distribution.
widget.complexity.per_method.suffix=\ /method
widget.complexity.per_paragraph.suffix=\ /paragraph
@@ -447,10 +447,10 @@ widget.complexity.per_class.suffix=\ /class
widget.complexity.per_file.suffix=\ /file
widget.complexity.total=Total
-widget.custom_measures.title=Custom Measures
+widget.custom_measures.name=Custom Measures
widget.custom_measures.description=Display a list of selected measures.
-widget.description.title=Description
+widget.description.name=Description
widget.description.description=Displays general project information
widget.description.key=Key
widget.description.language=Language
@@ -460,15 +460,15 @@ widget.description.alerts=Alerts
widget.description.alerts_rss_feed=RSS Feed
widget.description.links=Links
-widget.events.title=Events
+widget.events.name=Events
widget.events.description=Reports events on the project life cycle such as versions and alerts.
-widget.rules.title=Rules Compliance
+widget.rules.name=Rules Compliance
widget.rules.description=Reports violations and compliance index on coding standards.
widget.rules.violations=Violations
widget.rules.rules_compliance=Rules compliance
-widget.size.title=Size metrics
+widget.size.name=Size metrics
widget.size.description=Reports general metrics on the size of the project.
widget.size.lines_of_code=Lines of code
widget.size.generated.suffix=\ generated
@@ -483,20 +483,20 @@ widget.size.methods.suffix=\ methods
widget.size.accessors.suffix=\ accessors
widget.size.paragraphs.suffix=\ paragraphs
-widget.ckjm.title=Chidamber & Kemerer
+widget.ckjm.name=Chidamber & Kemerer
widget.ckjm.description=Reports on LCOM4 and RFC average and distribution.
widget.ckjm.lcom4=LCOM4
widget.ckjm.per_class.suffix=\ /class
widget.ckjm.files_having_lcom_greater_than_one=\ files having LCOM4>1
widget.ckjm.rfc=RFC
-widget.file_design.title=File design
+widget.file_design.name=File design
widget.file_design.description=Reports on files dependency cycles and tangle index.
widget.file_design.file_tangle_index=File tangle index
widget.file_design.cycles.suffix=\ cycles
widget.file_design.suspect_file_dependencies=Suspect file dependencies
-widget.package_design.title=Package design
+widget.package_design.name=Package design
widget.package_design.description=Reports on package dependency cycles and tangle index.
widget.package_design.package_tangle_index=Package tangle index
widget.package_design.cycles.suffix=\ cycles
diff --git a/sonar-server/src/main/webapp/WEB-INF/app/views/dashboard/_configure_widget.html.erb b/sonar-server/src/main/webapp/WEB-INF/app/views/dashboard/_configure_widget.html.erb
index 08096680906..92d817dae95 100644
--- a/sonar-server/src/main/webapp/WEB-INF/app/views/dashboard/_configure_widget.html.erb
+++ b/sonar-server/src/main/webapp/WEB-INF/app/views/dashboard/_configure_widget.html.erb
@@ -13,7 +13,7 @@
<% if definition.isEditable() %>
<a class="block-view-toggle" onclick="portal.editWidget(<%= widget.id -%>);return false;"><%= message('edit') -%></a>
<% end %>
- <%= definition.getTitle() -%>
+ <%= h message('widget.' + definition.getId() + '.name', :default => definition.getTitle()) -%>
</div>
diff --git a/sonar-server/src/main/webapp/WEB-INF/app/views/dashboard/_widget_definition.html.erb b/sonar-server/src/main/webapp/WEB-INF/app/views/dashboard/_widget_definition.html.erb
index c911a8c0e35..6126d0999db 100644
--- a/sonar-server/src/main/webapp/WEB-INF/app/views/dashboard/_widget_definition.html.erb
+++ b/sonar-server/src/main/webapp/WEB-INF/app/views/dashboard/_widget_definition.html.erb
@@ -1,6 +1,6 @@
<td>
<div class="widget_def" id="def_<%= definition.getId().tr('_', '') -%>">
-<p><b><%= h message('widget.' + definition.getId() + '.title', :default => definition.getTitle()) -%></b></p>
+<p><b><%= h message('widget.' + definition.getId() + '.name', :default => definition.getTitle()) -%></b></p>
<p><%= h message('widget.' + definition.getId() + '.description', :default => definition.getDescription()) -%></p>
<%= form_tag :action => 'add_widget', :did => dashboard_id, :id => resource_id, :widget => definition.getId() %>
<input type="submit" value="<%= message('dashboard.add_widget') -%>" >
diff --git a/sonar-server/src/main/webapp/WEB-INF/app/views/dashboard/_widget_properties.html.erb b/sonar-server/src/main/webapp/WEB-INF/app/views/dashboard/_widget_properties.html.erb
index 5e61afa5646..949fda10184 100644
--- a/sonar-server/src/main/webapp/WEB-INF/app/views/dashboard/_widget_properties.html.erb
+++ b/sonar-server/src/main/webapp/WEB-INF/app/views/dashboard/_widget_properties.html.erb
@@ -15,7 +15,9 @@
<td valign="top" class="thin nowrap"><b><%= property_def.key() -%></b><%= "*" unless property_def.optional()==true -%>: </td>
<td id="row_<%= property_def.key() -%>">
<%= property_value_field(property_def, value) -%>
- <span class="note"><%= property_def.description() -%></span>
+ <span class="note">
+ <%= message("widget." + widget.key + ".param." + property_def.key(), :default => property_def.description()) -%>
+ </span>
</td>
</tr>
<% end %>