Author: [email protected]
Date: Mon Jan 16 09:57:12 2012
New Revision: 1914
Log:
[AMDATUOPENSOCIAL-95] Fixed content vanishing when dragging slightly
Modified:
trunk/amdatu-opensocial/dashboard-plugin/src/main/resources/static/js/jquery.dashboard.js
Modified:
trunk/amdatu-opensocial/dashboard-plugin/src/main/resources/static/js/jquery.dashboard.js
==============================================================================
---
trunk/amdatu-opensocial/dashboard-plugin/src/main/resources/static/js/jquery.dashboard.js
(original)
+++
trunk/amdatu-opensocial/dashboard-plugin/src/main/resources/static/js/jquery.dashboard.js
Mon Jan 16 09:57:12 2012
@@ -129,6 +129,18 @@
}
},
deactivate: function(event, ui) {
+ // refresh the content of the widget if the event is received by the
+ // column in which the widget is displayed
+
+ var found = false;
+ $(this).find('.' + opts.widgetClass).each(function() {
+ found = found || ($(this).attr("id") == ui.item.attr("id"));
+ });
+
+ if (found) {
+ dashboard.getWidget(ui.item.attr("id")).refreshContent();
+ }
+
// This event is called for each column
dashboard.log('Widget is dropped: check if the column is now
empty.',1);
var childLength = $(this).children().length;
@@ -141,6 +153,7 @@
$(this).find('.emptycolumn').remove();
}
}
+
},
start: function(event, ui) {
ui.item.find('.' + opts.widgetTitleClass).addClass('noclick');
_______________________________________________
Amdatu-commits mailing list
[email protected]
http://lists.amdatu.org/mailman/listinfo/amdatu-commits