From: Alexander Ebert Date: Mon, 22 Aug 2016 09:31:44 +0000 (+0200) Subject: Fixed full quotes being recognized as partial quotes X-Git-Tag: 3.0.0_Beta_1~602 X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=bb202324d9ca5cee2e31f0eaf7a2aeeb788d793b;p=GitHub%2FWoltLab%2FWCF.git Fixed full quotes being recognized as partial quotes --- diff --git a/wcfsetup/install/files/js/WCF.Message.js b/wcfsetup/install/files/js/WCF.Message.js index 28e8955924..92a7aeffaf 100644 --- a/wcfsetup/install/files/js/WCF.Message.js +++ b/wcfsetup/install/files/js/WCF.Message.js @@ -1607,10 +1607,11 @@ WCF.Message.Quote.Manager = Class.extend({ // event forwarding WCF.System.Event.addListener('com.woltlab.wcf.message.quote', 'insert', (function(data) { + //noinspection JSUnresolvedVariable WCF.System.Event.fireEvent('com.woltlab.wcf.redactor2', 'insertQuote_' + (this._editorIdAlternative ? this._editorIdAlternative : this._editorId), { author: data.quote.username, content: data.quote.text, - isText: true, + isText: !data.quote.isFullQuote, link: data.quote.link }); }).bind(this)); @@ -1857,7 +1858,7 @@ WCF.Message.Quote.Manager = Class.extend({ var message = listItem.parents('.message:eq(0)'); var author = message.data('username'); var link = message.data('link'); - var isText = elData(listItem[0], 'is-full-quote'); + var isText = !elDataBool(listItem[0], 'is-full-quote'); WCF.System.Event.fireEvent('com.woltlab.wcf.redactor2', 'insertQuote_' + (this._editorIdAlternative ? this._editorIdAlternative : this._editorId), { author: author, diff --git a/wcfsetup/install/files/lib/system/message/quote/MessageQuoteManager.class.php b/wcfsetup/install/files/lib/system/message/quote/MessageQuoteManager.class.php index 57e85a2ea5..1e3137d976 100644 --- a/wcfsetup/install/files/lib/system/message/quote/MessageQuoteManager.class.php +++ b/wcfsetup/install/files/lib/system/message/quote/MessageQuoteManager.class.php @@ -254,6 +254,8 @@ class MessageQuoteManager extends SingletonFactory { $this->markQuotesForRemoval([$quoteID]); + $renderedQuotes[0]['isFullQuote'] = (isset($this->quoteData[$quoteID . '_fq'])); + return $renderedQuotes[0]; } }