aboutsummaryrefslogtreecommitdiffstats
path: root/phpBB/phpbb/textformatter
diff options
context:
space:
mode:
authorMáté Bartus <mate.bartus@gmail.com>2015-07-13 15:35:21 +0200
committerMáté Bartus <mate.bartus@gmail.com>2015-07-13 15:35:21 +0200
commitd54f9d176e1a36806cbbb69a134a5b5d62b6fb39 (patch)
tree14aaffb016bda2ece41a33dc377d907349fe2e36 /phpBB/phpbb/textformatter
parent8df16ed92c65228593167d3f187a05ccf85f5a9d (diff)
parent0d52d36b37e0434824e93af592bbe0ce3c994da6 (diff)
downloadforums-d54f9d176e1a36806cbbb69a134a5b5d62b6fb39.tar
forums-d54f9d176e1a36806cbbb69a134a5b5d62b6fb39.tar.gz
forums-d54f9d176e1a36806cbbb69a134a5b5d62b6fb39.tar.bz2
forums-d54f9d176e1a36806cbbb69a134a5b5d62b6fb39.tar.xz
forums-d54f9d176e1a36806cbbb69a134a5b5d62b6fb39.zip
Merge pull request #3753 from s9e/ticket/14000
[ticket/14000] Added support for emoji
Diffstat (limited to 'phpBB/phpbb/textformatter')
-rw-r--r--phpBB/phpbb/textformatter/s9e/factory.php5
1 files changed, 5 insertions, 0 deletions
diff --git a/phpBB/phpbb/textformatter/s9e/factory.php b/phpBB/phpbb/textformatter/s9e/factory.php
index 2f6498197f..2aab97b667 100644
--- a/phpBB/phpbb/textformatter/s9e/factory.php
+++ b/phpBB/phpbb/textformatter/s9e/factory.php
@@ -324,6 +324,11 @@ class factory implements \phpbb\textformatter\cache_interface
$configurator->registeredVars['max_img_height'] = 0;
$configurator->registeredVars['max_img_width'] = 0;
+ // Load the Emoji plugin and modify its tag's template to obey viewsmilies
+ $configurator->Emoji->setImageSize(18);
+ $tag = $configurator->Emoji->getTag();
+ $tag->template = '<xsl:choose><xsl:when test="$S_VIEWSMILIES">' . str_replace('class="emoji"', 'class="smilies"', $tag->template) . '</xsl:when><xsl:otherwise><xsl:value-of select="."/></xsl:otherwise></xsl:choose>';
+
/**
* Modify the s9e\TextFormatter configurator after the default settings are set
*