diff options
author | mattab <matthieu.aubry@gmail.com> | 2013-09-19 07:31:40 +0400 |
---|---|---|
committer | mattab <matthieu.aubry@gmail.com> | 2013-09-19 07:31:40 +0400 |
commit | d971dacae0c12e1784cdaf5be55402ab0d8c6c2b (patch) | |
tree | 637b9868b0ea4f26c316534aad23527fbb489b6e | |
parent | 64615b167487e55757be99e0e052cadd8b08bf08 (diff) | |
parent | 1909ba397c7a26c64408a646113d7175fc6f0234 (diff) |
Merge branch 'master' of https://github.com/piwik/piwik
-rw-r--r-- | core/Visualization/Sparkline.php | 6 | ||||
-rw-r--r-- | tests/PHPUnit/TestingEnvironment.php | 2 | ||||
m--------- | tests/PHPUnit/UI | 0 |
3 files changed, 7 insertions, 1 deletions
diff --git a/core/Visualization/Sparkline.php b/core/Visualization/Sparkline.php index f946fa629e..c029d91ab7 100644 --- a/core/Visualization/Sparkline.php +++ b/core/Visualization/Sparkline.php @@ -33,6 +33,8 @@ class Sparkline implements ViewInterface const DEFAULT_WIDTH = 100; const DEFAULT_HEIGHT = 25; + public static $enableSparklineImages = true; + private static $colorNames = array('backgroundColor', 'lineColor', 'minPointColor', 'lastPointColor', 'maxPointColor'); /** @@ -147,7 +149,9 @@ class Sparkline implements ViewInterface public function render() { - $this->sparkline->Output(); + if (self::$enableSparklineImages) { + $this->sparkline->Output(); + } } /** diff --git a/tests/PHPUnit/TestingEnvironment.php b/tests/PHPUnit/TestingEnvironment.php index 6e929a933a..0b86b85d9e 100644 --- a/tests/PHPUnit/TestingEnvironment.php +++ b/tests/PHPUnit/TestingEnvironment.php @@ -43,5 +43,7 @@ class Piwik_TestingEnvironment $jsFiles[] = 'tests/resources/screenshot-override/jquery.waitforimages.js'; $jsFiles[] = 'tests/resources/screenshot-override/override.js'; }); + + \Piwik\Visualization\Sparkline::$enableSparklineImages = false; } }
\ No newline at end of file diff --git a/tests/PHPUnit/UI b/tests/PHPUnit/UI -Subproject 2a376b54e55c5955bc31adf2a2fb7eb58bd7ba5 +Subproject 91c3b61f5230770f90ac837aa097d15042be7c7 |