Skip to content
Extraits de code Groupes Projets
Valider 11254054 rédigé par BeezyT's avatar BeezyT
Parcourir les fichiers

refs #2431 show loading feedback when clicking on sparklines

git-svn-id: http://dev.piwik.org/svn/trunk@4790 59fd770c-687e-43c8-a1e3-f5a4ff64c105
parent 348c1adf
Aucune branche associée trouvée
Aucune étiquette associée trouvée
Aucune requête de fusion associée trouvée
.jqplot-loading {
background: url(../../../themes/default/images/loading-blue.gif) no-repeat center center white;
position: absolute;
z-index: 10;
}
.jqplot-tooltip { .jqplot-tooltip {
position: absolute; position: absolute;
z-index: 2000; z-index: 2000;
......
...@@ -28,8 +28,17 @@ function initializeSparklines () { ...@@ -28,8 +28,17 @@ function initializeSparklines () {
if (typeof $.jqplot == 'undefined') { if (typeof $.jqplot == 'undefined') {
piwikHelper.findSWFGraph(idDataTable + "Chart_swf").reload(url); piwikHelper.findSWFGraph(idDataTable + "Chart_swf").reload(url);
} else { } else {
var chart = $('#'+idDataTable+"Chart_swf");
var loading = $(document.createElement('div')).addClass('jqplot-loading');
loading.css({
width: chart.innerWidth()+'px',
height: chart.innerHeight()+'px',
opacity: 0
});
chart.prepend(loading);
loading.css({opacity: .7});
$.get(url, {}, function(data) { $.get(url, {}, function(data) {
$('#'+idDataTable+"Chart_swf").trigger('replot', data).size(); chart.trigger('replot', data).size();
}, 'json'); }, 'json');
} }
piwikHelper.lazyScrollTo(graph[0], 400); piwikHelper.lazyScrollTo(graph[0], 400);
......
0% Chargement en cours ou .
You are about to add 0 people to the discussion. Proceed with caution.
Terminez d'abord l'édition de ce message.
Veuillez vous inscrire ou vous pour commenter