From: Matthias Schmidt Date: Sun, 6 Dec 2020 14:11:50 +0000 (+0100) Subject: Fix merge conflict X-Git-Tag: 5.4.0_Alpha_1~561 X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=f247e6f10c02b18a9d32c9d6064c36eb2867d37c;p=GitHub%2FWoltLab%2FWCF.git Fix merge conflict --- diff --git a/wcfsetup/install/files/js/WoltLabSuite/Core/Media/Manager/Select.js b/wcfsetup/install/files/js/WoltLabSuite/Core/Media/Manager/Select.js index 21467b2b8b..c1a4ae2316 100644 --- a/wcfsetup/install/files/js/WoltLabSuite/Core/Media/Manager/Select.js +++ b/wcfsetup/install/files/js/WoltLabSuite/Core/Media/Manager/Select.js @@ -96,7 +96,9 @@ define(['Core', 'Dom/Traverse', 'Dom/Util', 'Language', 'ObjectMap', 'Ui/Dialog' } var media = this._media.get(~~elData(event.currentTarget, 'object-id')); // save selected media in store element - elById(elData(this._activeButton, 'store')).value = media.mediaID; + var input = elById(elData(this._activeButton, 'store')); + input.value = media.mediaID; + Core.triggerEvent(input, 'change'); // display selected media var display = elData(this._activeButton, 'display'); if (display) { @@ -174,7 +176,9 @@ define(['Core', 'Dom/Traverse', 'Dom/Util', 'Language', 'ObjectMap', 'Ui/Dialog' var removeButton = event.currentTarget; elHide(removeButton); var button = removeButton.previousElementSibling; - elById(elData(button, 'store')).value = 0; + var input = elById(elData(button, 'store')); + input.value = ''; + Core.triggerEvent(input, 'change'); var display = elData(button, 'display'); if (display) { var displayElement = elById(display); diff --git a/wcfsetup/install/files/ts/WoltLabSuite/Core/Media/Manager/Select.js b/wcfsetup/install/files/ts/WoltLabSuite/Core/Media/Manager/Select.js index 1a03419433..d0f397e033 100644 --- a/wcfsetup/install/files/ts/WoltLabSuite/Core/Media/Manager/Select.js +++ b/wcfsetup/install/files/ts/WoltLabSuite/Core/Media/Manager/Select.js @@ -110,7 +110,9 @@ define(['Core', 'Dom/Traverse', 'Dom/Util', 'Language', 'ObjectMap', 'Ui/Dialog' var media = this._media.get(~~elData(event.currentTarget, 'object-id')); // save selected media in store element - elById(elData(this._activeButton, 'store')).value = media.mediaID; + var input = elById(elData(this._activeButton, 'store')); + input.value = media.mediaID; + Core.triggerEvent(input, 'change'); // display selected media var display = elData(this._activeButton, 'display'); @@ -203,7 +205,9 @@ define(['Core', 'Dom/Traverse', 'Dom/Util', 'Language', 'ObjectMap', 'Ui/Dialog' elHide(removeButton); var button = removeButton.previousElementSibling; - elById(elData(button, 'store')).value = 0; + var input = elById(elData(button, 'store')); + input.value = ''; + Core.triggerEvent(input, 'change'); var display = elData(button, 'display'); if (display) { var displayElement = elById(display);