aboutsummaryrefslogtreecommitdiffstats
path: root/sonar-server
diff options
context:
space:
mode:
authorSimon Brandhof <simon.brandhof@gmail.com>2013-02-11 15:53:17 +0100
committerSimon Brandhof <simon.brandhof@gmail.com>2013-02-11 15:53:17 +0100
commit584f2a87aa824ba33944428fec6ce7e1c62c5ffb (patch)
tree335b47fae75c1bd98086e9f49e6dd30a74a61261 /sonar-server
parentefd5716474747b6064e3934d5fe3fe35ebca900d (diff)
downloadsonarqube-584f2a87aa824ba33944428fec6ce7e1c62c5ffb.tar.gz
sonarqube-584f2a87aa824ba33944428fec6ce7e1c62c5ffb.zip
SONAR-4129 smaller icons (10x10px)
Diffstat (limited to 'sonar-server')
-rw-r--r--sonar-server/src/main/webapp/WEB-INF/app/helpers/application_helper.rb14
-rwxr-xr-xsonar-server/src/main/webapp/images/trend/-1-black.pngbin1033 -> 1088 bytes
-rwxr-xr-xsonar-server/src/main/webapp/images/trend/-1-green.pngbin1032 -> 1090 bytes
-rwxr-xr-xsonar-server/src/main/webapp/images/trend/-1-red.pngbin1033 -> 1089 bytes
-rwxr-xr-xsonar-server/src/main/webapp/images/trend/-2-black.pngbin1065 -> 1098 bytes
-rwxr-xr-xsonar-server/src/main/webapp/images/trend/-2-green.pngbin1067 -> 1099 bytes
-rwxr-xr-xsonar-server/src/main/webapp/images/trend/-2-red.pngbin1064 -> 1099 bytes
-rw-r--r--sonar-server/src/main/webapp/images/trend/0.pngbin71 -> 805 bytes
-rwxr-xr-xsonar-server/src/main/webapp/images/trend/1-black.pngbin1021 -> 1080 bytes
-rwxr-xr-xsonar-server/src/main/webapp/images/trend/1-green.pngbin1019 -> 1080 bytes
-rwxr-xr-xsonar-server/src/main/webapp/images/trend/1-red.pngbin1025 -> 0 bytes
-rwxr-xr-xsonar-server/src/main/webapp/images/trend/2-black.pngbin1056 -> 1094 bytes
-rwxr-xr-xsonar-server/src/main/webapp/images/trend/2-green.pngbin1055 -> 1094 bytes
-rwxr-xr-xsonar-server/src/main/webapp/images/trend/2-red.pngbin1057 -> 1094 bytes
14 files changed, 11 insertions, 3 deletions
diff --git a/sonar-server/src/main/webapp/WEB-INF/app/helpers/application_helper.rb b/sonar-server/src/main/webapp/WEB-INF/app/helpers/application_helper.rb
index fbb8499555d..06ee266c772 100644
--- a/sonar-server/src/main/webapp/WEB-INF/app/helpers/application_helper.rb
+++ b/sonar-server/src/main/webapp/WEB-INF/app/helpers/application_helper.rb
@@ -356,7 +356,8 @@ module ApplicationHelper
# Display the trend icon :
#
# === Optional parameters
- # * empty: true|false. Show an empty transparent image when no trend or no measure. Default is false.
+ # :empty: true|false. Show an empty transparent image when no trend or no measure. Default is false.
+ # :big : true|false (default is false). Default is 10x10px. Big is 16x16px.
#
# === Examples
# trend_icon('ncloc')
@@ -371,8 +372,15 @@ module ApplicationHelper
m = @snapshot.measure(metric_or_measure)
end
+ if options[:big]
+ size = '-big'
+ pixels = 16
+ else
+ size = ''
+ pixels = 10
+ end
if m.nil? || m.tendency.nil? || m.tendency==0
- return options[:empty] ? image_tag('trend/0.png', :width => '16', :alt => '') : nil
+ return options[:empty] ? image_tag("trend/0#{size}.png", :width => pixels, :height => pixels, :alt => '') : nil
end
filename = m.tendency.to_s
@@ -384,7 +392,7 @@ module ApplicationHelper
when 1
filename+= '-green'
end
- image_tag("trend/#{filename}.png")
+ image_tag("trend/#{filename}#{size}.png", :width => pixels, :height => pixels, :alt => '')
end
#
diff --git a/sonar-server/src/main/webapp/images/trend/-1-black.png b/sonar-server/src/main/webapp/images/trend/-1-black.png
index c2b0b594db2..83f12ed1593 100755
--- a/sonar-server/src/main/webapp/images/trend/-1-black.png
+++ b/sonar-server/src/main/webapp/images/trend/-1-black.png
Binary files differ
diff --git a/sonar-server/src/main/webapp/images/trend/-1-green.png b/sonar-server/src/main/webapp/images/trend/-1-green.png
index 734414d5fdb..2398a8fca58 100755
--- a/sonar-server/src/main/webapp/images/trend/-1-green.png
+++ b/sonar-server/src/main/webapp/images/trend/-1-green.png
Binary files differ
diff --git a/sonar-server/src/main/webapp/images/trend/-1-red.png b/sonar-server/src/main/webapp/images/trend/-1-red.png
index 28eeb6703f1..69978685cd7 100755
--- a/sonar-server/src/main/webapp/images/trend/-1-red.png
+++ b/sonar-server/src/main/webapp/images/trend/-1-red.png
Binary files differ
diff --git a/sonar-server/src/main/webapp/images/trend/-2-black.png b/sonar-server/src/main/webapp/images/trend/-2-black.png
index 4d91b2f10bf..084f3ce81bc 100755
--- a/sonar-server/src/main/webapp/images/trend/-2-black.png
+++ b/sonar-server/src/main/webapp/images/trend/-2-black.png
Binary files differ
diff --git a/sonar-server/src/main/webapp/images/trend/-2-green.png b/sonar-server/src/main/webapp/images/trend/-2-green.png
index 9849178bb7f..96409ac486c 100755
--- a/sonar-server/src/main/webapp/images/trend/-2-green.png
+++ b/sonar-server/src/main/webapp/images/trend/-2-green.png
Binary files differ
diff --git a/sonar-server/src/main/webapp/images/trend/-2-red.png b/sonar-server/src/main/webapp/images/trend/-2-red.png
index 1d63bc36d3e..5275fe5d578 100755
--- a/sonar-server/src/main/webapp/images/trend/-2-red.png
+++ b/sonar-server/src/main/webapp/images/trend/-2-red.png
Binary files differ
diff --git a/sonar-server/src/main/webapp/images/trend/0.png b/sonar-server/src/main/webapp/images/trend/0.png
index 12743e982ba..8cefe92efe7 100644
--- a/sonar-server/src/main/webapp/images/trend/0.png
+++ b/sonar-server/src/main/webapp/images/trend/0.png
Binary files differ
diff --git a/sonar-server/src/main/webapp/images/trend/1-black.png b/sonar-server/src/main/webapp/images/trend/1-black.png
index 7adf22e30c0..439315abf9a 100755
--- a/sonar-server/src/main/webapp/images/trend/1-black.png
+++ b/sonar-server/src/main/webapp/images/trend/1-black.png
Binary files differ
diff --git a/sonar-server/src/main/webapp/images/trend/1-green.png b/sonar-server/src/main/webapp/images/trend/1-green.png
index fae26a1d5ce..af56e02d5f2 100755
--- a/sonar-server/src/main/webapp/images/trend/1-green.png
+++ b/sonar-server/src/main/webapp/images/trend/1-green.png
Binary files differ
diff --git a/sonar-server/src/main/webapp/images/trend/1-red.png b/sonar-server/src/main/webapp/images/trend/1-red.png
deleted file mode 100755
index 8ca7ac3e911..00000000000
--- a/sonar-server/src/main/webapp/images/trend/1-red.png
+++ /dev/null
Binary files differ
diff --git a/sonar-server/src/main/webapp/images/trend/2-black.png b/sonar-server/src/main/webapp/images/trend/2-black.png
index 1e8ad1e15d5..22a3a19b181 100755
--- a/sonar-server/src/main/webapp/images/trend/2-black.png
+++ b/sonar-server/src/main/webapp/images/trend/2-black.png
Binary files differ
diff --git a/sonar-server/src/main/webapp/images/trend/2-green.png b/sonar-server/src/main/webapp/images/trend/2-green.png
index 21e2a7958c4..59030cc5833 100755
--- a/sonar-server/src/main/webapp/images/trend/2-green.png
+++ b/sonar-server/src/main/webapp/images/trend/2-green.png
Binary files differ
diff --git a/sonar-server/src/main/webapp/images/trend/2-red.png b/sonar-server/src/main/webapp/images/trend/2-red.png
index 24dff31c72f..032ee5dd339 100755
--- a/sonar-server/src/main/webapp/images/trend/2-red.png
+++ b/sonar-server/src/main/webapp/images/trend/2-red.png
Binary files differ