Tweaks to fix up my optimizatinos

* Fixed a rendering glitch with empty shows in the Now Playing screen
* Changed drag and drop placeholder to show the track name. Reverted it
  from the default DataTables placeholder, which unfortunately gets the
  column widths wrong.
This commit is contained in:
Albert Santoni 2015-04-14 17:39:52 -04:00
parent b1ea1f27a3
commit f3c8f40183
2 changed files with 14 additions and 5 deletions

View File

@ -590,8 +590,7 @@ var AIRTIME = (function(AIRTIME){
//remove the column classes from all tds. //remove the column classes from all tds.
$nRow.find('td').removeClass(); $nRow.find('td').removeClass();
//$node = $(nRow.children[0]).replaceWith(emptyNode);; $node = $(nRow.children[0]);
//$node.html('');
if ($node) { if ($node) {
$node.empty(); $node.empty();
} }
@ -1014,8 +1013,18 @@ var AIRTIME = (function(AIRTIME){
} }
if (selected.length === 1) { if (selected.length === 1) {
//message = $.i18n._("Moving 1 Item"); message = sprintf($.i18n._("Moving %s"), selected[0].title);
draggingContainer = item; //draggingContainer = item; //Default DataTables drag and drop
draggingContainer = $('<tr/>')
.addClass('sb-helper')
.append('<td/>')
.find("td")
.attr("colspan", colspan)
.width(width)
.height(height)
.addClass("ui-state-highlight")
.append(message)
.end();
} }
else { else {
message = sprintf($.i18n._("Moving %s Items"), selected.length); message = sprintf($.i18n._("Moving %s Items"), selected.length);

View File

@ -168,7 +168,7 @@ AIRTIME = (function(AIRTIME) {
$builder.find(dateStartId) $builder.find(dateStartId)
.datepicker(oBaseDatePickerSettings) .datepicker(oBaseDatePickerSettings)
.blur(validateTimeRange); .blur(validateTimeRange);
$builder.find(timeStartId) $builder.find(timeStartId)
.timepicker(oBaseTimePickerSettings) .timepicker(oBaseTimePickerSettings)
.blur(validateTimeRange); .blur(validateTimeRange);