From 28705d9edd8aab713ecdb8a7a40723d3cacc91d3 Mon Sep 17 00:00:00 2001 From: Alexander Ebert Date: Wed, 18 Apr 2012 22:43:39 +0200 Subject: [PATCH] Marked items are now properly reset --- wcfsetup/install/files/js/WCF.js | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) diff --git a/wcfsetup/install/files/js/WCF.js b/wcfsetup/install/files/js/WCF.js index d1bf12e34e..3c802b23df 100644 --- a/wcfsetup/install/files/js/WCF.js +++ b/wcfsetup/install/files/js/WCF.js @@ -733,6 +733,12 @@ WCF.Clipboard = { * @param jQuery jqXHR */ _loadMarkedItemsSuccess: function(data, textStatus, jqXHR) { + // unmark all items first + this._containers.each(function(index, container) { + $(container).find('input.jsClipboardItem').removeAttr('checked').end().find('input.jsClipboardMarkAll').removeAttr('checked'); + }); + + this._markedObjectIDs = [ ]; for (var $typeName in data.markedItems) { var $objectData = data.markedItems[$typeName]; for (var $i in $objectData) { @@ -989,7 +995,7 @@ WCF.Clipboard = { * Closes the clipboard editor item list. */ _closeLists: function() { - $('.jsClipboardEditor ul').removeClass('dropdownOpen') + $('.jsClipboardEditor ul').removeClass('dropdownOpen'); }, /** @@ -1036,7 +1042,10 @@ WCF.Clipboard = { data: { actionName: listItem.data('parameters').actionName, className: listItem.data('parameters').className, - objectIDs: objectIDs + objectIDs: objectIDs, + parameters: { + unmarkItems: true + } }, success: $.proxy(this._loadMarkedItems, this) }); -- 2.20.1