Skip to content

Commit

Permalink
Merge pull request #46 from sgiehl/master
Browse files Browse the repository at this point in the history
#3813 jQuery / jQueryUI / jqPlot upgrades to latest versions

Tested it locally with latest Opera, IE7-9, FX and Chrome. Didn't find any issues.
  • Loading branch information
halfdan committed Mar 30, 2013
2 parents 1149f26 + ecb2675 commit b629917
Show file tree
Hide file tree
Showing 54 changed files with 3,004 additions and 1,352 deletions.
5 changes: 3 additions & 2 deletions core/AssetManager.php
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
* JavaScript and CSS files.
*
* It performs the following actions:
* - Identifies required assets
* - Identifies required assets
* - Includes assets in the rendered HTML page
* - Manages asset merging and minifying
* - Manages server-side cache
Expand Down Expand Up @@ -188,9 +188,9 @@ private static function getCssFiles()
private static function sortCssFiles($cssFiles)
{
$priorityCssOrdered = array(
'libs/',
'themes/default/common.css',
'themes/default/',
'libs/',
'plugins/',
);

Expand Down Expand Up @@ -282,6 +282,7 @@ private static function sortJsFiles($jsFiles)
$priorityJsOrdered = array(
'libs/jquery/jquery.js',
'libs/jquery/jquery-ui.js',
'libs/jquery/jquery.browser.js',
'libs/',
'themes/default/common.js',
'themes/default/',
Expand Down
47 changes: 21 additions & 26 deletions libs/jqplot/jqplot-custom.min.js

Large diffs are not rendered by default.

3 changes: 2 additions & 1 deletion libs/jqplot/jqplot.axisLabelRenderer.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,9 @@
* Pure JavaScript plotting plugin using jQuery
*
* Version: @VERSION
* Revision: @REVISION
*
* Copyright (c) 2009-2011 Chris Leonello
* Copyright (c) 2009-2013 Chris Leonello
* jqPlot is currently available for use in all personal or commercial projects
* under both the MIT (http://www.opensource.org/licenses/mit-license.php) and GPL
* version 2.0 (http://www.gnu.org/licenses/gpl-2.0.html) licenses. This means that you can
Expand Down
38 changes: 33 additions & 5 deletions libs/jqplot/jqplot.axisTickRenderer.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,9 @@
* Pure JavaScript plotting plugin using jQuery
*
* Version: @VERSION
* Revision: @REVISION
*
* Copyright (c) 2009-2011 Chris Leonello
* Copyright (c) 2009-2013 Chris Leonello
* jqPlot is currently available for use in all personal or commercial projects
* under both the MIT (http://www.opensource.org/licenses/mit-license.php) and GPL
* version 2.0 (http://www.gnu.org/licenses/gpl-2.0.html) licenses. This means that you can
Expand Down Expand Up @@ -63,7 +64,7 @@
// prop: showLabel
// wether or not to show the label.
this.showLabel = true;
this.label = '';
this.label = null;
this.value = null;
this._styles = {};
// prop: formatter
Expand All @@ -73,6 +74,10 @@
// String to prepend to the tick label.
// Prefix is prepended to the formatted tick label.
this.prefix = '';
// prop: suffix
// String to append to the tick label.
// Suffix is appended to the formatted tick label.
this.suffix = '';
// prop: formatString
// string passed to the formatter.
this.formatString = '';
Expand All @@ -85,6 +90,9 @@
// prop: textColor
// css spec for the color attribute.
this.textColor;
// prop: escapeHTML
// true to escape HTML entities in the label.
this.escapeHTML = false;
this._elem;
this._breakTick = false;

Expand All @@ -108,8 +116,8 @@
};

$.jqplot.AxisTickRenderer.prototype.draw = function() {
if (!this.label) {
this.label = this.prefix + this.formatter(this.formatString, this.value);
if (this.label === null) {
this.label = this.prefix + this.formatter(this.formatString, this.value) + this.suffix;
}
var style = {position: 'absolute'};
if (Number(this.label)) {
Expand All @@ -124,7 +132,14 @@

this._elem = $(document.createElement('div'));
this._elem.addClass("jqplot-"+this.axis+"-tick");
this._elem.text(this.label);

if (!this.escapeHTML) {
this._elem.html(this.label);
}
else {
this._elem.text(this.label);
}

this._elem.css(style);

for (var s in this._styles) {
Expand Down Expand Up @@ -157,6 +172,19 @@
return String(val);
}
};

$.jqplot.PercentTickFormatter = function (format, val) {
if (typeof val == 'number') {
val = 100 * val;
if (!format) {
format = $.jqplot.config.defaultTickFormatString;
}
return $.jqplot.sprintf(format, val);
}
else {
return String(val);
}
};

$.jqplot.AxisTickRenderer.prototype.pack = function() {
};
Expand Down
459 changes: 242 additions & 217 deletions libs/jqplot/jqplot.canvasGridRenderer.js

Large diffs are not rendered by default.

Loading

0 comments on commit b629917

Please sign in to comment.