Added proper support for HD smilies
authorAlexander Ebert <ebert@woltlab.com>
Mon, 5 Sep 2016 09:26:18 +0000 (11:26 +0200)
committerAlexander Ebert <ebert@woltlab.com>
Mon, 5 Sep 2016 09:26:27 +0000 (11:26 +0200)
120 files changed:
com.woltlab.wcf/smiley.xml
com.woltlab.wcf/templates/__messageFormSmilies.tpl
wcfsetup/install/files/acp/templates/smileyAdd.tpl
wcfsetup/install/files/acp/templates/smileyList.tpl
wcfsetup/install/files/images/smilies/angry_emojione.png [deleted file]
wcfsetup/install/files/images/smilies/attention_emojione.png [deleted file]
wcfsetup/install/files/images/smilies/biggrin_emojione.png [deleted file]
wcfsetup/install/files/images/smilies/blink_emojione.png [deleted file]
wcfsetup/install/files/images/smilies/confused_emojione.png [deleted file]
wcfsetup/install/files/images/smilies/cool_emojione.png [deleted file]
wcfsetup/install/files/images/smilies/crying_emojione.png [deleted file]
wcfsetup/install/files/images/smilies/cursing_emojione.png [deleted file]
wcfsetup/install/files/images/smilies/emojione/1f44d.png [new file with mode: 0644]
wcfsetup/install/files/images/smilies/emojione/1f44d@2x.png [new file with mode: 0644]
wcfsetup/install/files/images/smilies/emojione/1f44e.png [new file with mode: 0644]
wcfsetup/install/files/images/smilies/emojione/1f44e@2x.png [new file with mode: 0644]
wcfsetup/install/files/images/smilies/emojione/1f600.png [new file with mode: 0644]
wcfsetup/install/files/images/smilies/emojione/1f600@2x.png [new file with mode: 0644]
wcfsetup/install/files/images/smilies/emojione/1f601.png [new file with mode: 0644]
wcfsetup/install/files/images/smilies/emojione/1f601@2x.png [new file with mode: 0644]
wcfsetup/install/files/images/smilies/emojione/1f607.png [new file with mode: 0644]
wcfsetup/install/files/images/smilies/emojione/1f607@2x.png [new file with mode: 0644]
wcfsetup/install/files/images/smilies/emojione/1f608.png [new file with mode: 0644]
wcfsetup/install/files/images/smilies/emojione/1f608@2x.png [new file with mode: 0644]
wcfsetup/install/files/images/smilies/emojione/1f609.png [new file with mode: 0644]
wcfsetup/install/files/images/smilies/emojione/1f609@2x.png [new file with mode: 0644]
wcfsetup/install/files/images/smilies/emojione/1f60d.png [new file with mode: 0644]
wcfsetup/install/files/images/smilies/emojione/1f60d@2x.png [new file with mode: 0644]
wcfsetup/install/files/images/smilies/emojione/1f60e.png [new file with mode: 0644]
wcfsetup/install/files/images/smilies/emojione/1f60e@2x.png [new file with mode: 0644]
wcfsetup/install/files/images/smilies/emojione/1f610.png [new file with mode: 0644]
wcfsetup/install/files/images/smilies/emojione/1f610@2x.png [new file with mode: 0644]
wcfsetup/install/files/images/smilies/emojione/1f612.png [new file with mode: 0644]
wcfsetup/install/files/images/smilies/emojione/1f612@2x.png [new file with mode: 0644]
wcfsetup/install/files/images/smilies/emojione/1f614.png [new file with mode: 0644]
wcfsetup/install/files/images/smilies/emojione/1f614@2x.png [new file with mode: 0644]
wcfsetup/install/files/images/smilies/emojione/1f615.png [new file with mode: 0644]
wcfsetup/install/files/images/smilies/emojione/1f615@2x.png [new file with mode: 0644]
wcfsetup/install/files/images/smilies/emojione/1f618.png [new file with mode: 0644]
wcfsetup/install/files/images/smilies/emojione/1f618@2x.png [new file with mode: 0644]
wcfsetup/install/files/images/smilies/emojione/1f61b.png [new file with mode: 0644]
wcfsetup/install/files/images/smilies/emojione/1f61b@2x.png [new file with mode: 0644]
wcfsetup/install/files/images/smilies/emojione/1f61e.png [new file with mode: 0644]
wcfsetup/install/files/images/smilies/emojione/1f61e@2x.png [new file with mode: 0644]
wcfsetup/install/files/images/smilies/emojione/1f620.png [new file with mode: 0644]
wcfsetup/install/files/images/smilies/emojione/1f620@2x.png [new file with mode: 0644]
wcfsetup/install/files/images/smilies/emojione/1f621.png [new file with mode: 0644]
wcfsetup/install/files/images/smilies/emojione/1f621@2x.png [new file with mode: 0644]
wcfsetup/install/files/images/smilies/emojione/1f62b.png [new file with mode: 0644]
wcfsetup/install/files/images/smilies/emojione/1f62b@2x.png [new file with mode: 0644]
wcfsetup/install/files/images/smilies/emojione/1f62d.png [new file with mode: 0644]
wcfsetup/install/files/images/smilies/emojione/1f62d@2x.png [new file with mode: 0644]
wcfsetup/install/files/images/smilies/emojione/1f62e.png [new file with mode: 0644]
wcfsetup/install/files/images/smilies/emojione/1f62e@2x.png [new file with mode: 0644]
wcfsetup/install/files/images/smilies/emojione/1f62f.png [new file with mode: 0644]
wcfsetup/install/files/images/smilies/emojione/1f62f@2x.png [new file with mode: 0644]
wcfsetup/install/files/images/smilies/emojione/1f631.png [new file with mode: 0644]
wcfsetup/install/files/images/smilies/emojione/1f631@2x.png [new file with mode: 0644]
wcfsetup/install/files/images/smilies/emojione/1f634.png [new file with mode: 0644]
wcfsetup/install/files/images/smilies/emojione/1f634@2x.png [new file with mode: 0644]
wcfsetup/install/files/images/smilies/emojione/1f635.png [new file with mode: 0644]
wcfsetup/install/files/images/smilies/emojione/1f635@2x.png [new file with mode: 0644]
wcfsetup/install/files/images/smilies/emojione/1f644.png [new file with mode: 0644]
wcfsetup/install/files/images/smilies/emojione/1f644@2x.png [new file with mode: 0644]
wcfsetup/install/files/images/smilies/emojione/1f914.png [new file with mode: 0644]
wcfsetup/install/files/images/smilies/emojione/1f914@2x.png [new file with mode: 0644]
wcfsetup/install/files/images/smilies/emojione/1f922.png [new file with mode: 0644]
wcfsetup/install/files/images/smilies/emojione/1f922@2x.png [new file with mode: 0644]
wcfsetup/install/files/images/smilies/emojione/2639.png [new file with mode: 0644]
wcfsetup/install/files/images/smilies/emojione/2639@2x.png [new file with mode: 0644]
wcfsetup/install/files/images/smilies/emojione/263a.png [new file with mode: 0644]
wcfsetup/install/files/images/smilies/emojione/263a@2x.png [new file with mode: 0644]
wcfsetup/install/files/images/smilies/emojione/2753.png [new file with mode: 0644]
wcfsetup/install/files/images/smilies/emojione/2753@2x.png [new file with mode: 0644]
wcfsetup/install/files/images/smilies/emojione/2757.png [new file with mode: 0644]
wcfsetup/install/files/images/smilies/emojione/2757@2x.png [new file with mode: 0644]
wcfsetup/install/files/images/smilies/emojione/2764.png [new file with mode: 0644]
wcfsetup/install/files/images/smilies/emojione/2764@2x.png [new file with mode: 0644]
wcfsetup/install/files/images/smilies/evil_emojione.png [deleted file]
wcfsetup/install/files/images/smilies/grin_emojione.png [deleted file]
wcfsetup/install/files/images/smilies/heart_emojione.png [deleted file]
wcfsetup/install/files/images/smilies/huh_emojione.png [deleted file]
wcfsetup/install/files/images/smilies/kiss_emojione.png [deleted file]
wcfsetup/install/files/images/smilies/love_emojione.png [deleted file]
wcfsetup/install/files/images/smilies/mellow_emojione.png [deleted file]
wcfsetup/install/files/images/smilies/pinch_emojione.png [deleted file]
wcfsetup/install/files/images/smilies/question_emojione.png [deleted file]
wcfsetup/install/files/images/smilies/rolleyes_emojione.png [deleted file]
wcfsetup/install/files/images/smilies/sad_emojione.png [deleted file]
wcfsetup/install/files/images/smilies/saint_emojione.png [deleted file]
wcfsetup/install/files/images/smilies/scared_emojione.png [deleted file]
wcfsetup/install/files/images/smilies/sick_emojione.png [deleted file]
wcfsetup/install/files/images/smilies/sleeping_emojione.png [deleted file]
wcfsetup/install/files/images/smilies/smile_emojione.png [deleted file]
wcfsetup/install/files/images/smilies/thumbdown_emojione.png [deleted file]
wcfsetup/install/files/images/smilies/thumbsup_emojione.png [deleted file]
wcfsetup/install/files/images/smilies/thumbup_emojione.png [deleted file]
wcfsetup/install/files/images/smilies/tired_emojione.png [deleted file]
wcfsetup/install/files/images/smilies/tongue_emojione.png [deleted file]
wcfsetup/install/files/images/smilies/unsure_emojione.png [deleted file]
wcfsetup/install/files/images/smilies/w00t_emojione.png [deleted file]
wcfsetup/install/files/images/smilies/wacko_emojione.png [deleted file]
wcfsetup/install/files/images/smilies/whistling_emojione.png [deleted file]
wcfsetup/install/files/images/smilies/wink_emojione.png [deleted file]
wcfsetup/install/files/js/3rdParty/redactor2/plugins/WoltLabSmiley.js
wcfsetup/install/files/js/WCF.Message.js
wcfsetup/install/files/lib/acp/form/SmileyAddForm.class.php
wcfsetup/install/files/lib/acp/form/SmileyEditForm.class.php
wcfsetup/install/files/lib/data/smiley/Smiley.class.php
wcfsetup/install/files/lib/data/smiley/SmileyAction.class.php
wcfsetup/install/files/lib/data/smiley/SmileyCache.class.php
wcfsetup/install/files/lib/system/bbcode/SimpleMessageParser.class.php
wcfsetup/install/files/lib/system/cache/builder/SmileyCacheBuilder.class.php
wcfsetup/install/files/lib/system/html/input/filter/MessageHtmlInputFilter.class.php
wcfsetup/install/files/lib/system/html/input/node/HtmlInputNodeImg.class.php
wcfsetup/install/files/lib/system/html/output/node/HtmlOutputNodeImg.class.php
wcfsetup/install/files/lib/system/package/plugin/SmileyPackageInstallationPlugin.class.php
wcfsetup/install/lang/de.xml
wcfsetup/install/lang/en.xml
wcfsetup/setup/db/install.sql

index 148459597bf5b501e9dd369ac756db5d36190d4c..4c0fab48dd2bc5fa399eb9747ca9f3562b42a91c 100644 (file)
        <import>
                <smiley name=":)">
                        <title>smile</title>
-                       <path>images/smilies/smile_emojione.png</path>
+                       <path>images/smilies/emojione/263a.png</path>
+                       <path2x>images/smilies/emojione/263a@2x.png</path2x>
                        <aliases><![CDATA[:-)
 (:]]></aliases>
                </smiley>
                <smiley name=":(">
                        <title>sad</title>
-                       <path>images/smilies/sad_emojione.png</path>
+                       <path>images/smilies/emojione/2639.png</path>
+                       <path2x>images/smilies/emojione/2639@2x.png</path2x>
                        <aliases><![CDATA[:-(
 ):]]></aliases>
                </smiley>
                <smiley name=";)">
                        <title>wink</title>
-                       <path>images/smilies/wink_emojione.png</path>
+                       <path>images/smilies/emojione/1f609.png</path>
+                       <path2x>images/smilies/emojione/1f609@2x.png</path2x>
                        <aliases><![CDATA[;-)
 (;]]></aliases>
                </smiley>
                <smiley name=":P">
                        <title>tongue</title>
-                       <path>images/smilies/tongue_emojione.png</path>
+                       <path>images/smilies/emojione/1f61b.png</path>
+                       <path2x>images/smilies/emojione/1f61b@2x.png</path2x>
                        <aliases><![CDATA[:-P]]></aliases>
                </smiley>
                <smiley name="^^">
                        <title>grin</title>
-                       <path>images/smilies/grin_emojione.png</path>
+                       <path>images/smilies/emojione/1f600.png</path>
+                       <path2x>images/smilies/emojione/1f600@2x.png</path2x>
                        <aliases><![CDATA[^.^
 ^_^
 ^-^]]></aliases>
                </smiley>
                <smiley name=":D">
                        <title>biggrin</title>
-                       <path>images/smilies/biggrin_emojione.png</path>
+                       <path>images/smilies/emojione/1f601.png</path>
+                       <path2x>images/smilies/emojione/1f601@2x.png</path2x>
                        <aliases><![CDATA[:-D]]></aliases>
                </smiley>
                <smiley name=";(">
                        <title>crying</title>
-                       <path>images/smilies/crying_emojione.png</path>
+                       <path>images/smilies/emojione/1f62d.png</path>
+                       <path2x>images/smilies/emojione/1f62d@2x.png</path2x>
                        <aliases><![CDATA[;-(
 :'(
 ;_;]]></aliases>
                </smiley>
                <smiley name="X(">
                        <title>angry</title>
-                       <path>images/smilies/angry_emojione.png</path>
+                       <path>images/smilies/emojione/1f620.png</path>
+                       <path2x>images/smilies/emojione/1f620@2x.png</path2x>
                        <aliases><![CDATA[>.<
 >_<]]></aliases>
                </smiley>
                <smiley name=":*">
                        <title>kiss</title>
-                       <path>images/smilies/kiss_emojione.png</path>
+                       <path>images/smilies/emojione/1f618.png</path>
+                       <path2x>images/smilies/emojione/1f618@2x.png</path2x>
                        <aliases><![CDATA[:-*
 *:]]></aliases>
                </smiley>
                <smiley name=":|">
                        <title>mellow</title>
-                       <path>images/smilies/mellow_emojione.png</path>
+                       <path>images/smilies/emojione/1f610.png</path>
+                       <path2x>images/smilies/emojione/1f610@2x.png</path2x>
                </smiley>
                <smiley name="8o">
                        <title>w00t</title>
-                       <path>images/smilies/w00t_emojione.png</path>
+                       <path>images/smilies/emojione/1f62f.png</path>
+                       <path2x>images/smilies/emojione/1f62f@2x.png</path2x>
                </smiley>
                <smiley name="=O">
                        <title>scared</title>
-                       <path>images/smilies/scared_emojione.png</path>
+                       <path>images/smilies/emojione/1f631.png</path>
+                       <path2x>images/smilies/emojione/1f631@2x.png</path2x>
                </smiley>
                <smiley name="&lt;X">
                        <title>sick</title>
-                       <path>images/smilies/sick_emojione.png</path>
+                       <path>images/smilies/emojione/1f922.png</path>
+                       <path2x>images/smilies/emojione/1f922@2x.png</path2x>
                </smiley>
                <smiley name="||">
                        <title>tired</title>
-                       <path>images/smilies/tired_emojione.png</path>
+                       <path>images/smilies/emojione/1f62b.png</path>
+                       <path2x>images/smilies/emojione/1f62b@2x.png</path2x>
                </smiley>
                <smiley name=":/">
                        <title>unsure</title>
-                       <path>images/smilies/unsure_emojione.png</path>
+                       <path>images/smilies/emojione/1f914.png</path>
+                       <path2x>images/smilies/emojione/1f914@2x.png</path2x>
                </smiley>
                <smiley name=":S">
                        <title>wacko</title>
-                       <path>images/smilies/wacko_emojione.png</path>
+                       <path>images/smilies/emojione/1f635.png</path>
+                       <path2x>images/smilies/emojione/1f635@2x.png</path2x>
                </smiley>
                <smiley name="X/">
                        <title>pinch</title>
-                       <path>images/smilies/pinch_emojione.png</path>
+                       <path>images/smilies/emojione/1f612.png</path>
+                       <path2x>images/smilies/emojione/1f612@2x.png</path2x>
                </smiley>
                <smiley name="8)">
                        <title>cool</title>
-                       <path>images/smilies/cool_emojione.png</path>
+                       <path>images/smilies/emojione/1f60e.png</path>
+                       <path2x>images/smilies/emojione/1f60e@2x.png</path2x>
                </smiley>
                <smiley name="?(">
                        <title>confused</title>
-                       <path>images/smilies/confused_emojione.png</path>
+                       <path>images/smilies/emojione/1f614.png</path>
+                       <path2x>images/smilies/emojione/1f614@2x.png</path2x>
                </smiley>
                <smiley name=":huh:">
                        <title>Huh</title>
-                       <path>images/smilies/huh_emojione.png</path>
+                       <path>images/smilies/emojione/1f62e.png</path>
+                       <path2x>images/smilies/emojione/1f62e@2x.png</path2x>
                </smiley>
                <smiley name=":rolleyes:">
                        <title>rolleyes</title>
-                       <path>images/smilies/rolleyes_emojione.png</path>
+                       <path>images/smilies/emojione/1f644.png</path>
+                       <path2x>images/smilies/emojione/1f644@2x.png</path2x>
                </smiley>
                <smiley name=":love:">
                        <title>love</title>
-                       <path>images/smilies/love_emojione.png</path>
+                       <path>images/smilies/emojione/1f60d.png</path>
+                       <path2x>images/smilies/emojione/1f60d@2x.png</path2x>
                </smiley>
                <smiley name="8|">
                        <title>blink</title>
-                       <path>images/smilies/blink_emojione.png</path>
+                       <path>images/smilies/emojione/1f615.png</path>
+                       <path2x>images/smilies/emojione/1f615@2x.png</path2x>
                        <aliases><![CDATA[o.O]]></aliases>
                </smiley>
                <smiley name=":cursing:">
                        <title>cursing</title>
-                       <path>images/smilies/cursing_emojione.png</path>
+                       <path>images/smilies/emojione/1f621.png</path>
+                       <path2x>images/smilies/emojione/1f621@2x.png</path2x>
                </smiley>
                <smiley name=":thumbdown:">
                        <title>thumbdown</title>
-                       <path>images/smilies/thumbdown_emojione.png</path>
+                       <path>images/smilies/emojione/1f44e.png</path>
+                       <path2x>images/smilies/emojione/1f44e@2x.png</path2x>
                </smiley>
                <smiley name=":thumbup:">
                        <title>thumbup</title>
-                       <path>images/smilies/thumbup_emojione.png</path>
+                       <path>images/smilies/emojione/1f44d.png</path>
+                       <path2x>images/smilies/emojione/1f44d@2x.png</path2x>
                        <aliases><![CDATA[:thumbsup:]]></aliases>
                </smiley>
                <smiley name=":sleeping:">
                        <title>sleeping</title>
-                       <path>images/smilies/sleeping_emojione.png</path>
+                       <path>images/smilies/emojione/1f634.png</path>
+                       <path2x>images/smilies/emojione/1f634@2x.png</path2x>
                </smiley>
                <smiley name=":whistling:">
                        <title>whistling</title>
-                       <path>images/smilies/whistling_emojione.png</path>
+                       <path>images/smilies/emojione/1f61e.png</path>
+                       <path2x>images/smilies/emojione/1f61e@2x.png</path2x>
                </smiley>
                <smiley name=":evil:">
                        <title>evil</title>
-                       <path>images/smilies/evil_emojione.png</path>
+                       <path>images/smilies/emojione/1f608.png</path>
+                       <path2x>images/smilies/emojione/1f608@2x.png</path2x>
                </smiley>
                <smiley name=":saint:">
                        <title>saint</title>
-                       <path>images/smilies/saint_emojione.png</path>
+                       <path>images/smilies/emojione/1f607.png</path>
+                       <path2x>images/smilies/emojione/1f607@2x.png</path2x>
                </smiley>
                <smiley name="&lt;3">
                        <title>heart</title>
-                       <path>images/smilies/heart_emojione.png</path>
+                       <path>images/smilies/emojione/2764.png</path>
+                       <path2x>images/smilies/emojione/2764@2x.png</path2x>
                </smiley>
                <smiley name=":!:">
                        <title>attention</title>
-                       <path>images/smilies/attention_emojione.png</path>
+                       <path>images/smilies/emojione/2757.png</path>
+                       <path2x>images/smilies/emojione/2757@2x.png</path2x>
                </smiley>
                <smiley name=":?:">
                        <title>question</title>
-                       <path>images/smilies/question_emojione.png</path>
+                       <path>images/smilies/emojione/2753.png</path>
+                       <path2x>images/smilies/emojione/2753@2x.png</path2x>
                </smiley>
        </import>
 </data>
index 1d38ab5842e3e0c087a3480faadac08e90a92c90..bb49b5f545cf8588fdc869d6a45c5f296a1e7524 100644 (file)
@@ -1,5 +1,5 @@
 <ul class="inlineList smileyList">
        {foreach from=$smilies item=smiley}
-               <li><a title="{lang}{$smiley->smileyTitle}{/lang}" class="jsTooltip jsSmiley" data-smiley-code="{$smiley->smileyCode}" data-smiley-path="{$smiley->getURL()}"><img src="{$smiley->getURL()}" alt="{$smiley->smileyCode}"></a></li>
+               <li><a title="{lang}{$smiley->smileyTitle}{/lang}" class="jsTooltip jsSmiley">{@$smiley->getHtml()}</a></li>
        {/foreach}
 </ul>
\ No newline at end of file
index e77787827e5d9fffdc4f1660d949536e2cc6a24a..391495a1cdcec22aefbf4107f73f6e25145a7059 100644 (file)
        <section class="section">
                <h2 class="sectionTitle">{lang}wcf.acp.smiley.smileyFile{/lang}</h2>
                
-               <dl{if $errorField == 'fileUpload'} class="formError"{/if}>
-                       <dt><label for="fileUpload">{lang}wcf.acp.smiley.fileUpload{/lang}</label></dt>
-                       <dd>
-                               {if $uploadedFilename}
-                                       <img src="{@$__wcf->getPath()}images/smilies/{$uploadedFilename}" alt="">
-                                       <input type="hidden" name="uploadedFilename" value="{$uploadedFilename}">
-                               {/if}
-                               <input type="file" id="fileUpload" name="fileUpload" value="">
-                               
-                               {if $errorField == 'fileUpload'}
-                                       <small class="innerError">
-                                               {if $errorType == 'empty'}
-                                                       {lang}wcf.global.form.error.empty{/lang}
-                                               {else}
-                                                       {lang}wcf.acp.smiley.fileUpload.error.{@$errorType}{/lang}
-                                               {/if}
-                                       </small>
-                               {/if}
-                               <small>{lang}wcf.acp.smiley.fileUpload.description{/lang}</small>
-                       </dd>
-               </dl>
-               
-               <dl{if $errorField == 'smileyPath'} class="formError"{/if}>
-                       <dt><label for="smileyPath">{lang}wcf.acp.smiley.smileyPath{/lang}</label></dt>
-                       <dd>
-                               <input type="text" id="smileyPath" name="smileyPath" value="{$smileyPath}" class="long">
-                               
-                               {if $errorField == 'smileyPath'}
-                                       <small class="innerError">
-                                               {if $errorType == 'empty'}
-                                                       {lang}wcf.global.form.error.empty{/lang}
-                                               {else}
-                                                       {lang}wcf.acp.smiley.smileyPath.error.{@$errorType}{/lang}
-                                               {/if}
-                                       </small>
-                               {/if}
-                               <small>{lang}wcf.acp.smiley.smileyPath.description{/lang}</small>
-                       </dd>
-               </dl>
+               <div class="row rowColGap formGrid">
+                       <dl class="col-xs-12 col-md-6{if $errorField == 'fileUpload'} formError{/if}">
+                               <dt><label for="fileUpload">{lang}wcf.acp.smiley.fileUpload{/lang}</label></dt>
+                               <dd>
+                                       {if $uploadedFilename}
+                                               <input type="hidden" name="uploadedFilename" value="{$uploadedFilename}">
+                                       {/if}
+                                       <input type="file" id="fileUpload" name="fileUpload" value="">
+                                       
+                                       {if $errorField == 'fileUpload'}
+                                               <small class="innerError">
+                                                       {if $errorType == 'empty'}
+                                                               {lang}wcf.global.form.error.empty{/lang}
+                                                       {else}
+                                                               {lang}wcf.acp.smiley.fileUpload.error.{@$errorType}{/lang}
+                                                       {/if}
+                                               </small>
+                                       {/if}
+                                       <small>{lang}wcf.acp.smiley.fileUpload.description{/lang}</small>
+                               </dd>
+                       </dl>
+                       
+                       <dl class="col-xs-12 col-md-6{if $errorField == 'smileyPath'} formError{/if}">
+                               <dt><label for="smileyPath">{lang}wcf.acp.smiley.smileyPath{/lang}</label></dt>
+                               <dd>
+                                       <input type="text" id="smileyPath" name="smileyPath" value="{$smileyPath}" class="long">
+                                       
+                                       {if $errorField == 'smileyPath'}
+                                               <small class="innerError">
+                                                       {if $errorType == 'empty'}
+                                                               {lang}wcf.global.form.error.empty{/lang}
+                                                       {else}
+                                                               {lang}wcf.acp.smiley.smileyPath.error.{@$errorType}{/lang}
+                                                       {/if}
+                                               </small>
+                                       {/if}
+                                       <small>{lang}wcf.acp.smiley.smileyPath.description{/lang}</small>
+                               </dd>
+                       </dl>
+               </div>
                
                {event name='smileyFileFields'}
        </section>
        
+       <section class="section">
+               <header class="sectionHeader">
+                       <h2 class="sectionTitle">{lang}wcf.acp.smiley.smileyFile2x{/lang}</h2>
+                       <p class="sectionDescription">{lang}wcf.acp.smiley.smileyFile2x.description{/lang}</p>
+               </header>
+               
+               <div class="row rowColGap formGrid">
+                       <dl class="col-xs-12 col-md-6{if $errorField == 'fileUpload2x'} formError{/if}">
+                               <dt><label for="fileUpload2x">{lang}wcf.acp.smiley.fileUpload{/lang}</label></dt>
+                               <dd>
+                                       {if $uploadedFilename2x}
+                                               <input type="hidden" name="uploadedFilename2x" value="{$uploadedFilename2x}">
+                                       {/if}
+                                       <input type="file" id="fileUpload2x" name="fileUpload2x" value="">
+                                       
+                                       {if $errorField == 'fileUpload2x'}
+                                               <small class="innerError">
+                                                       {if $errorType == 'empty'}
+                                                               {lang}wcf.global.form.error.empty{/lang}
+                                                       {else}
+                                                               {lang}wcf.acp.smiley.fileUpload.error.{@$errorType}{/lang}
+                                                       {/if}
+                                               </small>
+                                       {/if}
+                                       <small>{lang}wcf.acp.smiley.fileUpload.description{/lang}</small>
+                               </dd>
+                       </dl>
+                       
+                       <dl class="col-xs-12 col-md-6{if $errorField == 'smileyPath2x'} formError{/if}">
+                               <dt><label for="smileyPath2x">{lang}wcf.acp.smiley.smileyPath{/lang}</label></dt>
+                               <dd>
+                                       <input type="text" id="smileyPath2x" name="smileyPath2x" value="{$smileyPath2x}" class="long">
+                                       
+                                       {if $errorField == 'smileyPath2x'}
+                                               <small class="innerError">
+                                                       {if $errorType == 'empty'}
+                                                               {lang}wcf.global.form.error.empty{/lang}
+                                                       {else}
+                                                               {lang}wcf.acp.smiley.smileyPath.error.{@$errorType}{/lang}
+                                                       {/if}
+                                               </small>
+                                       {/if}
+                                       <small>{lang}wcf.acp.smiley.smileyPath.description{/lang}</small>
+                               </dd>
+                       </dl>
+               </div>
+               
+               {event name='smileyFile2xFields'}
+       </section>
+       
        {event name='sections'}
        
        <div class="formSubmit">
index 9b216af2bd84d25ed3cc6e02959b8c33e821816f..efd6889daf0ef3809d303e10204d371df76e7fdb 100644 (file)
@@ -47,7 +47,7 @@
                                                {foreach from=$objects item=smiley}
                                                        <li class="sortableNode sortableNoNesting smileyRow" data-object-id="{@$smiley->smileyID}">
                                                                <span class="sortableNodeLabel">
-                                                                       <a href="{link controller='SmileyEdit' id=$smiley->smileyID}{/link}"><img src="{$smiley->getURL()}" alt="" class="smiley"> {lang}{$smiley->smileyTitle}{/lang}</a> <span class="badge">{$smiley->smileyCode}</span>{foreach from=$smiley->getAliases() item='alias'} <span class="badge" style="margin-left: 5px">{$alias}</span>{/foreach}
+                                                                       <a href="{link controller='SmileyEdit' id=$smiley->smileyID}{/link}">{@$smiley->getHtml()} {lang}{$smiley->smileyTitle}{/lang}</a> <span class="badge">{$smiley->smileyCode}</span>{foreach from=$smiley->getAliases() item='alias'} <span class="badge" style="margin-left: 5px">{$alias}</span>{/foreach}
                                                                        
                                                                        <span class="statusDisplay sortableButtonContainer">
                                                                                <a href="{link controller='SmileyEdit' id=$smiley->smileyID}{/link}"><span title="{lang}wcf.global.button.edit{/lang}" class="jsTooltip icon icon16 fa-pencil"></a>
diff --git a/wcfsetup/install/files/images/smilies/angry_emojione.png b/wcfsetup/install/files/images/smilies/angry_emojione.png
deleted file mode 100644 (file)
index cfc4a6e..0000000
Binary files a/wcfsetup/install/files/images/smilies/angry_emojione.png and /dev/null differ
diff --git a/wcfsetup/install/files/images/smilies/attention_emojione.png b/wcfsetup/install/files/images/smilies/attention_emojione.png
deleted file mode 100644 (file)
index 2c14406..0000000
Binary files a/wcfsetup/install/files/images/smilies/attention_emojione.png and /dev/null differ
diff --git a/wcfsetup/install/files/images/smilies/biggrin_emojione.png b/wcfsetup/install/files/images/smilies/biggrin_emojione.png
deleted file mode 100644 (file)
index 418d94c..0000000
Binary files a/wcfsetup/install/files/images/smilies/biggrin_emojione.png and /dev/null differ
diff --git a/wcfsetup/install/files/images/smilies/blink_emojione.png b/wcfsetup/install/files/images/smilies/blink_emojione.png
deleted file mode 100644 (file)
index bd0ac55..0000000
Binary files a/wcfsetup/install/files/images/smilies/blink_emojione.png and /dev/null differ
diff --git a/wcfsetup/install/files/images/smilies/confused_emojione.png b/wcfsetup/install/files/images/smilies/confused_emojione.png
deleted file mode 100644 (file)
index cad0e23..0000000
Binary files a/wcfsetup/install/files/images/smilies/confused_emojione.png and /dev/null differ
diff --git a/wcfsetup/install/files/images/smilies/cool_emojione.png b/wcfsetup/install/files/images/smilies/cool_emojione.png
deleted file mode 100644 (file)
index 2001173..0000000
Binary files a/wcfsetup/install/files/images/smilies/cool_emojione.png and /dev/null differ
diff --git a/wcfsetup/install/files/images/smilies/crying_emojione.png b/wcfsetup/install/files/images/smilies/crying_emojione.png
deleted file mode 100644 (file)
index 52e3517..0000000
Binary files a/wcfsetup/install/files/images/smilies/crying_emojione.png and /dev/null differ
diff --git a/wcfsetup/install/files/images/smilies/cursing_emojione.png b/wcfsetup/install/files/images/smilies/cursing_emojione.png
deleted file mode 100644 (file)
index 9d739bd..0000000
Binary files a/wcfsetup/install/files/images/smilies/cursing_emojione.png and /dev/null differ
diff --git a/wcfsetup/install/files/images/smilies/emojione/1f44d.png b/wcfsetup/install/files/images/smilies/emojione/1f44d.png
new file mode 100644 (file)
index 0000000..5f6781d
Binary files /dev/null and b/wcfsetup/install/files/images/smilies/emojione/1f44d.png differ
diff --git a/wcfsetup/install/files/images/smilies/emojione/1f44d@2x.png b/wcfsetup/install/files/images/smilies/emojione/1f44d@2x.png
new file mode 100644 (file)
index 0000000..5ae9f8c
Binary files /dev/null and b/wcfsetup/install/files/images/smilies/emojione/1f44d@2x.png differ
diff --git a/wcfsetup/install/files/images/smilies/emojione/1f44e.png b/wcfsetup/install/files/images/smilies/emojione/1f44e.png
new file mode 100644 (file)
index 0000000..53816ec
Binary files /dev/null and b/wcfsetup/install/files/images/smilies/emojione/1f44e.png differ
diff --git a/wcfsetup/install/files/images/smilies/emojione/1f44e@2x.png b/wcfsetup/install/files/images/smilies/emojione/1f44e@2x.png
new file mode 100644 (file)
index 0000000..f879f3f
Binary files /dev/null and b/wcfsetup/install/files/images/smilies/emojione/1f44e@2x.png differ
diff --git a/wcfsetup/install/files/images/smilies/emojione/1f600.png b/wcfsetup/install/files/images/smilies/emojione/1f600.png
new file mode 100644 (file)
index 0000000..23384e0
Binary files /dev/null and b/wcfsetup/install/files/images/smilies/emojione/1f600.png differ
diff --git a/wcfsetup/install/files/images/smilies/emojione/1f600@2x.png b/wcfsetup/install/files/images/smilies/emojione/1f600@2x.png
new file mode 100644 (file)
index 0000000..a8c8d12
Binary files /dev/null and b/wcfsetup/install/files/images/smilies/emojione/1f600@2x.png differ
diff --git a/wcfsetup/install/files/images/smilies/emojione/1f601.png b/wcfsetup/install/files/images/smilies/emojione/1f601.png
new file mode 100644 (file)
index 0000000..94b1e1e
Binary files /dev/null and b/wcfsetup/install/files/images/smilies/emojione/1f601.png differ
diff --git a/wcfsetup/install/files/images/smilies/emojione/1f601@2x.png b/wcfsetup/install/files/images/smilies/emojione/1f601@2x.png
new file mode 100644 (file)
index 0000000..f352311
Binary files /dev/null and b/wcfsetup/install/files/images/smilies/emojione/1f601@2x.png differ
diff --git a/wcfsetup/install/files/images/smilies/emojione/1f607.png b/wcfsetup/install/files/images/smilies/emojione/1f607.png
new file mode 100644 (file)
index 0000000..78a9f36
Binary files /dev/null and b/wcfsetup/install/files/images/smilies/emojione/1f607.png differ
diff --git a/wcfsetup/install/files/images/smilies/emojione/1f607@2x.png b/wcfsetup/install/files/images/smilies/emojione/1f607@2x.png
new file mode 100644 (file)
index 0000000..18afe6b
Binary files /dev/null and b/wcfsetup/install/files/images/smilies/emojione/1f607@2x.png differ
diff --git a/wcfsetup/install/files/images/smilies/emojione/1f608.png b/wcfsetup/install/files/images/smilies/emojione/1f608.png
new file mode 100644 (file)
index 0000000..fd21b0a
Binary files /dev/null and b/wcfsetup/install/files/images/smilies/emojione/1f608.png differ
diff --git a/wcfsetup/install/files/images/smilies/emojione/1f608@2x.png b/wcfsetup/install/files/images/smilies/emojione/1f608@2x.png
new file mode 100644 (file)
index 0000000..bc3ef30
Binary files /dev/null and b/wcfsetup/install/files/images/smilies/emojione/1f608@2x.png differ
diff --git a/wcfsetup/install/files/images/smilies/emojione/1f609.png b/wcfsetup/install/files/images/smilies/emojione/1f609.png
new file mode 100644 (file)
index 0000000..dbc444e
Binary files /dev/null and b/wcfsetup/install/files/images/smilies/emojione/1f609.png differ
diff --git a/wcfsetup/install/files/images/smilies/emojione/1f609@2x.png b/wcfsetup/install/files/images/smilies/emojione/1f609@2x.png
new file mode 100644 (file)
index 0000000..b7d6f8f
Binary files /dev/null and b/wcfsetup/install/files/images/smilies/emojione/1f609@2x.png differ
diff --git a/wcfsetup/install/files/images/smilies/emojione/1f60d.png b/wcfsetup/install/files/images/smilies/emojione/1f60d.png
new file mode 100644 (file)
index 0000000..c97b62f
Binary files /dev/null and b/wcfsetup/install/files/images/smilies/emojione/1f60d.png differ
diff --git a/wcfsetup/install/files/images/smilies/emojione/1f60d@2x.png b/wcfsetup/install/files/images/smilies/emojione/1f60d@2x.png
new file mode 100644 (file)
index 0000000..e0efa2b
Binary files /dev/null and b/wcfsetup/install/files/images/smilies/emojione/1f60d@2x.png differ
diff --git a/wcfsetup/install/files/images/smilies/emojione/1f60e.png b/wcfsetup/install/files/images/smilies/emojione/1f60e.png
new file mode 100644 (file)
index 0000000..7d7a272
Binary files /dev/null and b/wcfsetup/install/files/images/smilies/emojione/1f60e.png differ
diff --git a/wcfsetup/install/files/images/smilies/emojione/1f60e@2x.png b/wcfsetup/install/files/images/smilies/emojione/1f60e@2x.png
new file mode 100644 (file)
index 0000000..18fe761
Binary files /dev/null and b/wcfsetup/install/files/images/smilies/emojione/1f60e@2x.png differ
diff --git a/wcfsetup/install/files/images/smilies/emojione/1f610.png b/wcfsetup/install/files/images/smilies/emojione/1f610.png
new file mode 100644 (file)
index 0000000..477d18d
Binary files /dev/null and b/wcfsetup/install/files/images/smilies/emojione/1f610.png differ
diff --git a/wcfsetup/install/files/images/smilies/emojione/1f610@2x.png b/wcfsetup/install/files/images/smilies/emojione/1f610@2x.png
new file mode 100644 (file)
index 0000000..48fd14d
Binary files /dev/null and b/wcfsetup/install/files/images/smilies/emojione/1f610@2x.png differ
diff --git a/wcfsetup/install/files/images/smilies/emojione/1f612.png b/wcfsetup/install/files/images/smilies/emojione/1f612.png
new file mode 100644 (file)
index 0000000..adff311
Binary files /dev/null and b/wcfsetup/install/files/images/smilies/emojione/1f612.png differ
diff --git a/wcfsetup/install/files/images/smilies/emojione/1f612@2x.png b/wcfsetup/install/files/images/smilies/emojione/1f612@2x.png
new file mode 100644 (file)
index 0000000..d6fe566
Binary files /dev/null and b/wcfsetup/install/files/images/smilies/emojione/1f612@2x.png differ
diff --git a/wcfsetup/install/files/images/smilies/emojione/1f614.png b/wcfsetup/install/files/images/smilies/emojione/1f614.png
new file mode 100644 (file)
index 0000000..b30a9a7
Binary files /dev/null and b/wcfsetup/install/files/images/smilies/emojione/1f614.png differ
diff --git a/wcfsetup/install/files/images/smilies/emojione/1f614@2x.png b/wcfsetup/install/files/images/smilies/emojione/1f614@2x.png
new file mode 100644 (file)
index 0000000..69cee20
Binary files /dev/null and b/wcfsetup/install/files/images/smilies/emojione/1f614@2x.png differ
diff --git a/wcfsetup/install/files/images/smilies/emojione/1f615.png b/wcfsetup/install/files/images/smilies/emojione/1f615.png
new file mode 100644 (file)
index 0000000..fa0af7c
Binary files /dev/null and b/wcfsetup/install/files/images/smilies/emojione/1f615.png differ
diff --git a/wcfsetup/install/files/images/smilies/emojione/1f615@2x.png b/wcfsetup/install/files/images/smilies/emojione/1f615@2x.png
new file mode 100644 (file)
index 0000000..47aef54
Binary files /dev/null and b/wcfsetup/install/files/images/smilies/emojione/1f615@2x.png differ
diff --git a/wcfsetup/install/files/images/smilies/emojione/1f618.png b/wcfsetup/install/files/images/smilies/emojione/1f618.png
new file mode 100644 (file)
index 0000000..2272b5d
Binary files /dev/null and b/wcfsetup/install/files/images/smilies/emojione/1f618.png differ
diff --git a/wcfsetup/install/files/images/smilies/emojione/1f618@2x.png b/wcfsetup/install/files/images/smilies/emojione/1f618@2x.png
new file mode 100644 (file)
index 0000000..e281cdc
Binary files /dev/null and b/wcfsetup/install/files/images/smilies/emojione/1f618@2x.png differ
diff --git a/wcfsetup/install/files/images/smilies/emojione/1f61b.png b/wcfsetup/install/files/images/smilies/emojione/1f61b.png
new file mode 100644 (file)
index 0000000..c6bc09b
Binary files /dev/null and b/wcfsetup/install/files/images/smilies/emojione/1f61b.png differ
diff --git a/wcfsetup/install/files/images/smilies/emojione/1f61b@2x.png b/wcfsetup/install/files/images/smilies/emojione/1f61b@2x.png
new file mode 100644 (file)
index 0000000..9ed02b4
Binary files /dev/null and b/wcfsetup/install/files/images/smilies/emojione/1f61b@2x.png differ
diff --git a/wcfsetup/install/files/images/smilies/emojione/1f61e.png b/wcfsetup/install/files/images/smilies/emojione/1f61e.png
new file mode 100644 (file)
index 0000000..e7cea82
Binary files /dev/null and b/wcfsetup/install/files/images/smilies/emojione/1f61e.png differ
diff --git a/wcfsetup/install/files/images/smilies/emojione/1f61e@2x.png b/wcfsetup/install/files/images/smilies/emojione/1f61e@2x.png
new file mode 100644 (file)
index 0000000..37dcd75
Binary files /dev/null and b/wcfsetup/install/files/images/smilies/emojione/1f61e@2x.png differ
diff --git a/wcfsetup/install/files/images/smilies/emojione/1f620.png b/wcfsetup/install/files/images/smilies/emojione/1f620.png
new file mode 100644 (file)
index 0000000..5365338
Binary files /dev/null and b/wcfsetup/install/files/images/smilies/emojione/1f620.png differ
diff --git a/wcfsetup/install/files/images/smilies/emojione/1f620@2x.png b/wcfsetup/install/files/images/smilies/emojione/1f620@2x.png
new file mode 100644 (file)
index 0000000..4cc2e77
Binary files /dev/null and b/wcfsetup/install/files/images/smilies/emojione/1f620@2x.png differ
diff --git a/wcfsetup/install/files/images/smilies/emojione/1f621.png b/wcfsetup/install/files/images/smilies/emojione/1f621.png
new file mode 100644 (file)
index 0000000..9baef4d
Binary files /dev/null and b/wcfsetup/install/files/images/smilies/emojione/1f621.png differ
diff --git a/wcfsetup/install/files/images/smilies/emojione/1f621@2x.png b/wcfsetup/install/files/images/smilies/emojione/1f621@2x.png
new file mode 100644 (file)
index 0000000..1ff2b97
Binary files /dev/null and b/wcfsetup/install/files/images/smilies/emojione/1f621@2x.png differ
diff --git a/wcfsetup/install/files/images/smilies/emojione/1f62b.png b/wcfsetup/install/files/images/smilies/emojione/1f62b.png
new file mode 100644 (file)
index 0000000..43eadbd
Binary files /dev/null and b/wcfsetup/install/files/images/smilies/emojione/1f62b.png differ
diff --git a/wcfsetup/install/files/images/smilies/emojione/1f62b@2x.png b/wcfsetup/install/files/images/smilies/emojione/1f62b@2x.png
new file mode 100644 (file)
index 0000000..e22de4f
Binary files /dev/null and b/wcfsetup/install/files/images/smilies/emojione/1f62b@2x.png differ
diff --git a/wcfsetup/install/files/images/smilies/emojione/1f62d.png b/wcfsetup/install/files/images/smilies/emojione/1f62d.png
new file mode 100644 (file)
index 0000000..fd0c7a4
Binary files /dev/null and b/wcfsetup/install/files/images/smilies/emojione/1f62d.png differ
diff --git a/wcfsetup/install/files/images/smilies/emojione/1f62d@2x.png b/wcfsetup/install/files/images/smilies/emojione/1f62d@2x.png
new file mode 100644 (file)
index 0000000..bba321a
Binary files /dev/null and b/wcfsetup/install/files/images/smilies/emojione/1f62d@2x.png differ
diff --git a/wcfsetup/install/files/images/smilies/emojione/1f62e.png b/wcfsetup/install/files/images/smilies/emojione/1f62e.png
new file mode 100644 (file)
index 0000000..f4b9889
Binary files /dev/null and b/wcfsetup/install/files/images/smilies/emojione/1f62e.png differ
diff --git a/wcfsetup/install/files/images/smilies/emojione/1f62e@2x.png b/wcfsetup/install/files/images/smilies/emojione/1f62e@2x.png
new file mode 100644 (file)
index 0000000..c92819f
Binary files /dev/null and b/wcfsetup/install/files/images/smilies/emojione/1f62e@2x.png differ
diff --git a/wcfsetup/install/files/images/smilies/emojione/1f62f.png b/wcfsetup/install/files/images/smilies/emojione/1f62f.png
new file mode 100644 (file)
index 0000000..74d4dd1
Binary files /dev/null and b/wcfsetup/install/files/images/smilies/emojione/1f62f.png differ
diff --git a/wcfsetup/install/files/images/smilies/emojione/1f62f@2x.png b/wcfsetup/install/files/images/smilies/emojione/1f62f@2x.png
new file mode 100644 (file)
index 0000000..576bd7e
Binary files /dev/null and b/wcfsetup/install/files/images/smilies/emojione/1f62f@2x.png differ
diff --git a/wcfsetup/install/files/images/smilies/emojione/1f631.png b/wcfsetup/install/files/images/smilies/emojione/1f631.png
new file mode 100644 (file)
index 0000000..7b184e5
Binary files /dev/null and b/wcfsetup/install/files/images/smilies/emojione/1f631.png differ
diff --git a/wcfsetup/install/files/images/smilies/emojione/1f631@2x.png b/wcfsetup/install/files/images/smilies/emojione/1f631@2x.png
new file mode 100644 (file)
index 0000000..fbc35ea
Binary files /dev/null and b/wcfsetup/install/files/images/smilies/emojione/1f631@2x.png differ
diff --git a/wcfsetup/install/files/images/smilies/emojione/1f634.png b/wcfsetup/install/files/images/smilies/emojione/1f634.png
new file mode 100644 (file)
index 0000000..d77594c
Binary files /dev/null and b/wcfsetup/install/files/images/smilies/emojione/1f634.png differ
diff --git a/wcfsetup/install/files/images/smilies/emojione/1f634@2x.png b/wcfsetup/install/files/images/smilies/emojione/1f634@2x.png
new file mode 100644 (file)
index 0000000..f80fe49
Binary files /dev/null and b/wcfsetup/install/files/images/smilies/emojione/1f634@2x.png differ
diff --git a/wcfsetup/install/files/images/smilies/emojione/1f635.png b/wcfsetup/install/files/images/smilies/emojione/1f635.png
new file mode 100644 (file)
index 0000000..d6912ec
Binary files /dev/null and b/wcfsetup/install/files/images/smilies/emojione/1f635.png differ
diff --git a/wcfsetup/install/files/images/smilies/emojione/1f635@2x.png b/wcfsetup/install/files/images/smilies/emojione/1f635@2x.png
new file mode 100644 (file)
index 0000000..d669be4
Binary files /dev/null and b/wcfsetup/install/files/images/smilies/emojione/1f635@2x.png differ
diff --git a/wcfsetup/install/files/images/smilies/emojione/1f644.png b/wcfsetup/install/files/images/smilies/emojione/1f644.png
new file mode 100644 (file)
index 0000000..f0799a9
Binary files /dev/null and b/wcfsetup/install/files/images/smilies/emojione/1f644.png differ
diff --git a/wcfsetup/install/files/images/smilies/emojione/1f644@2x.png b/wcfsetup/install/files/images/smilies/emojione/1f644@2x.png
new file mode 100644 (file)
index 0000000..382dc11
Binary files /dev/null and b/wcfsetup/install/files/images/smilies/emojione/1f644@2x.png differ
diff --git a/wcfsetup/install/files/images/smilies/emojione/1f914.png b/wcfsetup/install/files/images/smilies/emojione/1f914.png
new file mode 100644 (file)
index 0000000..2b6df3f
Binary files /dev/null and b/wcfsetup/install/files/images/smilies/emojione/1f914.png differ
diff --git a/wcfsetup/install/files/images/smilies/emojione/1f914@2x.png b/wcfsetup/install/files/images/smilies/emojione/1f914@2x.png
new file mode 100644 (file)
index 0000000..3aefd41
Binary files /dev/null and b/wcfsetup/install/files/images/smilies/emojione/1f914@2x.png differ
diff --git a/wcfsetup/install/files/images/smilies/emojione/1f922.png b/wcfsetup/install/files/images/smilies/emojione/1f922.png
new file mode 100644 (file)
index 0000000..fcc2ed2
Binary files /dev/null and b/wcfsetup/install/files/images/smilies/emojione/1f922.png differ
diff --git a/wcfsetup/install/files/images/smilies/emojione/1f922@2x.png b/wcfsetup/install/files/images/smilies/emojione/1f922@2x.png
new file mode 100644 (file)
index 0000000..61382e6
Binary files /dev/null and b/wcfsetup/install/files/images/smilies/emojione/1f922@2x.png differ
diff --git a/wcfsetup/install/files/images/smilies/emojione/2639.png b/wcfsetup/install/files/images/smilies/emojione/2639.png
new file mode 100644 (file)
index 0000000..b668c08
Binary files /dev/null and b/wcfsetup/install/files/images/smilies/emojione/2639.png differ
diff --git a/wcfsetup/install/files/images/smilies/emojione/2639@2x.png b/wcfsetup/install/files/images/smilies/emojione/2639@2x.png
new file mode 100644 (file)
index 0000000..36ff618
Binary files /dev/null and b/wcfsetup/install/files/images/smilies/emojione/2639@2x.png differ
diff --git a/wcfsetup/install/files/images/smilies/emojione/263a.png b/wcfsetup/install/files/images/smilies/emojione/263a.png
new file mode 100644 (file)
index 0000000..cecd35e
Binary files /dev/null and b/wcfsetup/install/files/images/smilies/emojione/263a.png differ
diff --git a/wcfsetup/install/files/images/smilies/emojione/263a@2x.png b/wcfsetup/install/files/images/smilies/emojione/263a@2x.png
new file mode 100644 (file)
index 0000000..97aa5fc
Binary files /dev/null and b/wcfsetup/install/files/images/smilies/emojione/263a@2x.png differ
diff --git a/wcfsetup/install/files/images/smilies/emojione/2753.png b/wcfsetup/install/files/images/smilies/emojione/2753.png
new file mode 100644 (file)
index 0000000..c341f0d
Binary files /dev/null and b/wcfsetup/install/files/images/smilies/emojione/2753.png differ
diff --git a/wcfsetup/install/files/images/smilies/emojione/2753@2x.png b/wcfsetup/install/files/images/smilies/emojione/2753@2x.png
new file mode 100644 (file)
index 0000000..fcea3f2
Binary files /dev/null and b/wcfsetup/install/files/images/smilies/emojione/2753@2x.png differ
diff --git a/wcfsetup/install/files/images/smilies/emojione/2757.png b/wcfsetup/install/files/images/smilies/emojione/2757.png
new file mode 100644 (file)
index 0000000..9862641
Binary files /dev/null and b/wcfsetup/install/files/images/smilies/emojione/2757.png differ
diff --git a/wcfsetup/install/files/images/smilies/emojione/2757@2x.png b/wcfsetup/install/files/images/smilies/emojione/2757@2x.png
new file mode 100644 (file)
index 0000000..0cace6f
Binary files /dev/null and b/wcfsetup/install/files/images/smilies/emojione/2757@2x.png differ
diff --git a/wcfsetup/install/files/images/smilies/emojione/2764.png b/wcfsetup/install/files/images/smilies/emojione/2764.png
new file mode 100644 (file)
index 0000000..1c84b8e
Binary files /dev/null and b/wcfsetup/install/files/images/smilies/emojione/2764.png differ
diff --git a/wcfsetup/install/files/images/smilies/emojione/2764@2x.png b/wcfsetup/install/files/images/smilies/emojione/2764@2x.png
new file mode 100644 (file)
index 0000000..f4fcdf7
Binary files /dev/null and b/wcfsetup/install/files/images/smilies/emojione/2764@2x.png differ
diff --git a/wcfsetup/install/files/images/smilies/evil_emojione.png b/wcfsetup/install/files/images/smilies/evil_emojione.png
deleted file mode 100644 (file)
index cc2c5f1..0000000
Binary files a/wcfsetup/install/files/images/smilies/evil_emojione.png and /dev/null differ
diff --git a/wcfsetup/install/files/images/smilies/grin_emojione.png b/wcfsetup/install/files/images/smilies/grin_emojione.png
deleted file mode 100644 (file)
index 30957a6..0000000
Binary files a/wcfsetup/install/files/images/smilies/grin_emojione.png and /dev/null differ
diff --git a/wcfsetup/install/files/images/smilies/heart_emojione.png b/wcfsetup/install/files/images/smilies/heart_emojione.png
deleted file mode 100644 (file)
index 638cb72..0000000
Binary files a/wcfsetup/install/files/images/smilies/heart_emojione.png and /dev/null differ
diff --git a/wcfsetup/install/files/images/smilies/huh_emojione.png b/wcfsetup/install/files/images/smilies/huh_emojione.png
deleted file mode 100644 (file)
index f99026a..0000000
Binary files a/wcfsetup/install/files/images/smilies/huh_emojione.png and /dev/null differ
diff --git a/wcfsetup/install/files/images/smilies/kiss_emojione.png b/wcfsetup/install/files/images/smilies/kiss_emojione.png
deleted file mode 100644 (file)
index 0ff808f..0000000
Binary files a/wcfsetup/install/files/images/smilies/kiss_emojione.png and /dev/null differ
diff --git a/wcfsetup/install/files/images/smilies/love_emojione.png b/wcfsetup/install/files/images/smilies/love_emojione.png
deleted file mode 100644 (file)
index 73fbee2..0000000
Binary files a/wcfsetup/install/files/images/smilies/love_emojione.png and /dev/null differ
diff --git a/wcfsetup/install/files/images/smilies/mellow_emojione.png b/wcfsetup/install/files/images/smilies/mellow_emojione.png
deleted file mode 100644 (file)
index 065d193..0000000
Binary files a/wcfsetup/install/files/images/smilies/mellow_emojione.png and /dev/null differ
diff --git a/wcfsetup/install/files/images/smilies/pinch_emojione.png b/wcfsetup/install/files/images/smilies/pinch_emojione.png
deleted file mode 100644 (file)
index 2954017..0000000
Binary files a/wcfsetup/install/files/images/smilies/pinch_emojione.png and /dev/null differ
diff --git a/wcfsetup/install/files/images/smilies/question_emojione.png b/wcfsetup/install/files/images/smilies/question_emojione.png
deleted file mode 100644 (file)
index 5a58f34..0000000
Binary files a/wcfsetup/install/files/images/smilies/question_emojione.png and /dev/null differ
diff --git a/wcfsetup/install/files/images/smilies/rolleyes_emojione.png b/wcfsetup/install/files/images/smilies/rolleyes_emojione.png
deleted file mode 100644 (file)
index 2f77b9f..0000000
Binary files a/wcfsetup/install/files/images/smilies/rolleyes_emojione.png and /dev/null differ
diff --git a/wcfsetup/install/files/images/smilies/sad_emojione.png b/wcfsetup/install/files/images/smilies/sad_emojione.png
deleted file mode 100644 (file)
index 6ae71f2..0000000
Binary files a/wcfsetup/install/files/images/smilies/sad_emojione.png and /dev/null differ
diff --git a/wcfsetup/install/files/images/smilies/saint_emojione.png b/wcfsetup/install/files/images/smilies/saint_emojione.png
deleted file mode 100644 (file)
index 57f5151..0000000
Binary files a/wcfsetup/install/files/images/smilies/saint_emojione.png and /dev/null differ
diff --git a/wcfsetup/install/files/images/smilies/scared_emojione.png b/wcfsetup/install/files/images/smilies/scared_emojione.png
deleted file mode 100644 (file)
index eb8b347..0000000
Binary files a/wcfsetup/install/files/images/smilies/scared_emojione.png and /dev/null differ
diff --git a/wcfsetup/install/files/images/smilies/sick_emojione.png b/wcfsetup/install/files/images/smilies/sick_emojione.png
deleted file mode 100644 (file)
index a566c10..0000000
Binary files a/wcfsetup/install/files/images/smilies/sick_emojione.png and /dev/null differ
diff --git a/wcfsetup/install/files/images/smilies/sleeping_emojione.png b/wcfsetup/install/files/images/smilies/sleeping_emojione.png
deleted file mode 100644 (file)
index 9ecf600..0000000
Binary files a/wcfsetup/install/files/images/smilies/sleeping_emojione.png and /dev/null differ
diff --git a/wcfsetup/install/files/images/smilies/smile_emojione.png b/wcfsetup/install/files/images/smilies/smile_emojione.png
deleted file mode 100644 (file)
index e9e53c0..0000000
Binary files a/wcfsetup/install/files/images/smilies/smile_emojione.png and /dev/null differ
diff --git a/wcfsetup/install/files/images/smilies/thumbdown_emojione.png b/wcfsetup/install/files/images/smilies/thumbdown_emojione.png
deleted file mode 100644 (file)
index b63da2f..0000000
Binary files a/wcfsetup/install/files/images/smilies/thumbdown_emojione.png and /dev/null differ
diff --git a/wcfsetup/install/files/images/smilies/thumbsup_emojione.png b/wcfsetup/install/files/images/smilies/thumbsup_emojione.png
deleted file mode 100644 (file)
index 5bba6dc..0000000
Binary files a/wcfsetup/install/files/images/smilies/thumbsup_emojione.png and /dev/null differ
diff --git a/wcfsetup/install/files/images/smilies/thumbup_emojione.png b/wcfsetup/install/files/images/smilies/thumbup_emojione.png
deleted file mode 100644 (file)
index f9e6f13..0000000
Binary files a/wcfsetup/install/files/images/smilies/thumbup_emojione.png and /dev/null differ
diff --git a/wcfsetup/install/files/images/smilies/tired_emojione.png b/wcfsetup/install/files/images/smilies/tired_emojione.png
deleted file mode 100644 (file)
index 490fb56..0000000
Binary files a/wcfsetup/install/files/images/smilies/tired_emojione.png and /dev/null differ
diff --git a/wcfsetup/install/files/images/smilies/tongue_emojione.png b/wcfsetup/install/files/images/smilies/tongue_emojione.png
deleted file mode 100644 (file)
index 2575734..0000000
Binary files a/wcfsetup/install/files/images/smilies/tongue_emojione.png and /dev/null differ
diff --git a/wcfsetup/install/files/images/smilies/unsure_emojione.png b/wcfsetup/install/files/images/smilies/unsure_emojione.png
deleted file mode 100644 (file)
index 7074afc..0000000
Binary files a/wcfsetup/install/files/images/smilies/unsure_emojione.png and /dev/null differ
diff --git a/wcfsetup/install/files/images/smilies/w00t_emojione.png b/wcfsetup/install/files/images/smilies/w00t_emojione.png
deleted file mode 100644 (file)
index c3bea9f..0000000
Binary files a/wcfsetup/install/files/images/smilies/w00t_emojione.png and /dev/null differ
diff --git a/wcfsetup/install/files/images/smilies/wacko_emojione.png b/wcfsetup/install/files/images/smilies/wacko_emojione.png
deleted file mode 100644 (file)
index f0dae7b..0000000
Binary files a/wcfsetup/install/files/images/smilies/wacko_emojione.png and /dev/null differ
diff --git a/wcfsetup/install/files/images/smilies/whistling_emojione.png b/wcfsetup/install/files/images/smilies/whistling_emojione.png
deleted file mode 100644 (file)
index 39d325f..0000000
Binary files a/wcfsetup/install/files/images/smilies/whistling_emojione.png and /dev/null differ
diff --git a/wcfsetup/install/files/images/smilies/wink_emojione.png b/wcfsetup/install/files/images/smilies/wink_emojione.png
deleted file mode 100644 (file)
index 7ea7810..0000000
Binary files a/wcfsetup/install/files/images/smilies/wink_emojione.png and /dev/null differ
index 6d2b7f5f7e48c9a6d5ab934a8ed08f4aa83e8b79..3b82fdc12ab52f7d75ef02f81d2909a1be36fcf0 100644 (file)
@@ -11,7 +11,7 @@ $.Redactor.prototype.WoltLabSmiley = function() {
                _insert: function(data) {
                        this.buffer.set();
                        
-                       this.insert.html('<img src="' + data.path + '" class="smiley" alt="' + data.code + '">');
+                       this.insert.html(data.img.cloneNode().outerHTML);
                }
        }
 };
index 5c60d3921addfc9e2a9fbb17b7e3702f7ef9162a..dc489546a41bc2249e7126af3680a226f4027a7c 100644 (file)
@@ -719,8 +719,7 @@ WCF.Message.Smilies = Class.extend({
                
                require(['EventHandler'], (function(EventHandler) {
                        EventHandler.fire('com.woltlab.wcf.redactor2', 'insertSmiley_' + this._editorId, {
-                               code: elData(event.currentTarget, 'smiley-code'),
-                               path: elData(event.currentTarget, 'smiley-path')
+                               img: event.currentTarget.children[0]
                        });
                }).bind(this));
        }
index 853c702b5afef50c5c476be7e9ae39f21ffdc2fb..507d72409a749169fb35cf77db86109fa1baa18d 100644 (file)
@@ -48,7 +48,7 @@ class SmileyAddForm extends AbstractForm {
        public $smileyCode = '';
        
        /**
-        * showorder value
+        * show order value
         * @var integer
         */
        public $showOrder = 0;
@@ -77,6 +77,12 @@ class SmileyAddForm extends AbstractForm {
         */
        public $smileyPath = '';
        
+       /**
+        * path to the smiley file (2x)
+        * @var string
+        */
+       public $smileyPath2x = '';
+       
        /**
         * node tree with available smiley categories
         * @var CategoryNodeTree
@@ -85,16 +91,28 @@ class SmileyAddForm extends AbstractForm {
        
        /**
         * data of the uploaded smiley file
-        * @var array()
+        * @var array
         */
        public $fileUpload = [];
        
+       /**
+        * data of the uploaded smiley file (2x)
+        * @var array
+        */
+       public $fileUpload2x = [];
+       
        /**
         * temporary name of the uploaded smiley file
         * @var string
         */
        public $uploadedFilename = '';
        
+       /**
+        * temporary name of the uploaded smiley file (2x)
+        * @var string
+        */
+       public $uploadedFilename2x = '';
+       
        /**
         * @inheritDoc
         */
@@ -111,8 +129,10 @@ class SmileyAddForm extends AbstractForm {
                        'smileyCode' => $this->smileyCode,
                        'aliases' => $this->aliases,
                        'smileyPath' => $this->smileyPath,
+                       'smileyPath2x' => $this->smileyPath2x,
                        'categoryNodeList' => $this->categoryNodeTree->getIterator(),
-                       'uploadedFilename' => $this->uploadedFilename
+                       'uploadedFilename' => $this->uploadedFilename,
+                       'uploadedFilename2x' => $this->uploadedFilename2x
                ]);
        }
        
@@ -151,6 +171,9 @@ class SmileyAddForm extends AbstractForm {
                if (isset($_POST['smileyPath'])) $this->smileyPath = FileUtil::removeLeadingSlash(StringUtil::trim($_POST['smileyPath']));
                if (isset($_POST['uploadedFilename'])) $this->uploadedFilename = StringUtil::trim($_POST['uploadedFilename']);
                if (isset($_FILES['fileUpload'])) $this->fileUpload = $_FILES['fileUpload'];
+               if (isset($_POST['smileyPath2x'])) $this->smileyPath2x = FileUtil::removeLeadingSlash(StringUtil::trim($_POST['smileyPath2x']));
+               if (isset($_POST['uploadedFilename2x'])) $this->uploadedFilename2x = StringUtil::trim($_POST['uploadedFilename2x']);
+               if (isset($_FILES['fileUpload2x'])) $this->fileUpload2x = $_FILES['fileUpload2x'];
        }
        
        /**
@@ -165,11 +188,13 @@ class SmileyAddForm extends AbstractForm {
                                'smileyCode' => $this->smileyCode,
                                'aliases' => $this->aliases,
                                'smileyPath' => $this->smileyPath,
+                               'smileyPath2x' => $this->smileyPath2x,
                                'showOrder' => $this->showOrder,
                                'categoryID' => $this->categoryID ?: null,
                                'packageID' => 1
                        ]),
-                       'fileLocation' => $this->uploadedFilename ? WCF_DIR.'images/smilies/'.$this->uploadedFilename : ''
+                       'fileLocation' => $this->uploadedFilename ? WCF_DIR.'images/smilies/'.$this->uploadedFilename : '',
+                       'fileLocation2x' => $this->uploadedFilename2x ? WCF_DIR.'images/smilies/'.$this->uploadedFilename2x : ''
                ]);
                $this->objectAction->executeAction();
                $returnValues = $this->objectAction->getReturnValues();
@@ -189,9 +214,9 @@ class SmileyAddForm extends AbstractForm {
                $this->smileyCode = '';
                $this->categoryID = 0;
                $this->showOrder = 0;
-               $this->smileyPath = '';
+               $this->smileyPath = $this->smileyPath2x = '';
                $this->aliases = '';
-               $this->uploadedFilename = '';
+               $this->uploadedFilename = $this->uploadedFilename2x = '';
                
                I18nHandler::getInstance()->reset();
                
@@ -239,6 +264,32 @@ class SmileyAddForm extends AbstractForm {
                        }
                }
                
+               if ($this->uploadedFilename2x) {
+                       if (!file_exists(WCF_DIR.'images/smilies/'.$this->uploadedFilename2x)) {
+                               $this->uploadedFilename2x = '';
+                               throw new UserInputException('fileUpload2x', 'uploadFailed');
+                       }
+               }
+               else if (!empty($this->fileUpload2x['name'])) {
+                       if (!getimagesize($this->fileUpload2x['tmp_name'])) {
+                               $this->uploadedFilename2x = '';
+                               throw new UserInputException('fileUpload2x', 'noImage');
+                       }
+                       
+                       do {
+                               $this->uploadedFilename2x = StringUtil::getRandomID().'.'.mb_strtolower(mb_substr($this->fileUpload2x['name'], mb_strrpos($this->fileUpload2x['name'], '.') + 1));
+                       }
+                       while (file_exists(WCF_DIR.'images/smilies/'.$this->uploadedFilename2x));
+                       
+                       if (!@move_uploaded_file($this->fileUpload2x['tmp_name'], WCF_DIR.'images/smilies/'.$this->uploadedFilename2x)) {
+                               $this->uploadedFilename2x = '';
+                               throw new UserInputException('fileUpload2x', 'uploadFailed');
+                       }
+               }
+               else if ($this->smileyPath2x && !is_file(WCF_DIR.$this->smileyPath2x)) {
+                       throw new UserInputException('smileyPath2x', 'notFound');
+               }
+               
                // validate title
                if (!I18nHandler::getInstance()->validateValue('smileyTitle')) {
                        if (I18nHandler::getInstance()->isPlainValue('smileyTitle')) {
index 560e968d301962981a47a0c74663dd637274b465..4564dcfa654db1fba2914a094ab770d1b4c36168 100644 (file)
@@ -73,10 +73,12 @@ class SmileyEditForm extends SmileyAddForm {
                                'smileyCode' => $this->smileyCode,
                                'aliases' => $this->aliases,
                                'smileyPath' => $this->smileyPath,
+                               'smileyPath2x' => $this->smileyPath2x,
                                'showOrder' => $this->showOrder,
                                'categoryID' => $this->categoryID ?: null
                        ]),
-                       'fileLocation' => $this->uploadedFilename ? WCF_DIR.'images/smilies/'.$this->uploadedFilename : ''
+                       'fileLocation' => $this->uploadedFilename ? WCF_DIR.'images/smilies/'.$this->uploadedFilename : '',
+                       'fileLocation2x' => $this->uploadedFilename2x ? WCF_DIR.'images/smilies/'.$this->uploadedFilename2x : ''
                ]);
                $this->objectAction->executeAction();
                
@@ -101,6 +103,7 @@ class SmileyEditForm extends SmileyAddForm {
                        $this->smileyCode = $this->smiley->smileyCode;
                        $this->aliases = $this->smiley->aliases;
                        $this->smileyPath = $this->smiley->smileyPath;
+                       $this->smileyPath2x = $this->smiley->smileyPath2x;
                        $this->showOrder = $this->smiley->showOrder;
                        $this->categoryID = $this->smiley->categoryID;
                }
index bd6a491c0b84bbc996ab0882cc06a35da5fb6f92..704e388f0165b0d06cee08aaf3c85bee94c46c35 100644 (file)
@@ -15,13 +15,18 @@ use wcf\util\StringUtil;
  * @property-read      integer         $smileyID       unique id of the smiley
  * @property-read      integer         $packageID      id of the package which delivers the smiley
  * @property-read      integer|null    $categoryID     id of the category the smiley belongs to or `null` if it belongs to the default category
- * @property-read      string          $smileyPath     path to the smiley file relative to wcf's defsult path
+ * @property-read      string          $smileyPath     path to the smiley file relative to wcf's default path
+ * @property-read       string          $smileyPath2x   path to the smiley file relative to wcf's default path (2x version)
  * @property-read      string          $smileyTitle    title of the smiley
  * @property-read      string          $smileyCode     code used for displaying the smiley
  * @property-read      string          $aliases        alternative codes used for displaying the smiley
  * @property-read      integer         $showOrder      position of the smiley in relation to the other smileys in the same category
  */
 class Smiley extends DatabaseObject {
+       protected $height;
+       
+       public $smileyCodes;
+       
        /**
         * Returns the url to this smiley.
         * 
@@ -31,6 +36,10 @@ class Smiley extends DatabaseObject {
                return WCF::getPath().$this->smileyPath;
        }
        
+       public function getURL2x() {
+               return ($this->smileyPath2x) ? WCF::getPath().$this->smileyPath2x : '';
+       }
+       
        /**
         * Returns all aliases for this smiley.
         * 
@@ -41,4 +50,28 @@ class Smiley extends DatabaseObject {
                
                return explode("\n", StringUtil::unifyNewlines($this->aliases));
        }
+       
+       public function getHeight() {
+               if ($this->height === null) {
+                       $this->height = 0;
+                       
+                       $file = WCF_DIR . $this->smileyPath;
+                       if (file_exists($file) && preg_match('~\.(gif|jpe?g|png)$~', $file)) {
+                               $data = getimagesize($file);
+                               if ($data !== false) {
+                                       // index '1' contains the height of the image
+                                       $this->height = $data[1];
+                               }
+                       }
+               }
+               
+               return $this->height;
+       }
+       
+       public function getHtml() {
+               $srcset = ($this->smileyPath2x) ? ' srcset="' . StringUtil::encodeHTML($this->getURL2x()) . ' 2x"' : '';
+               $style = ($this->getHeight()) ? ' style="height: ' . $this->getHeight() . 'px"' : '';
+               
+               return '<img src="' . StringUtil::encodeHTML($this->getURL()) . '" alt="' . StringUtil::encodeHTML($this->smileyCode) . '" class="smiley"' . $srcset . $style . '>';
+       }
 }
index 2ee0764aed67aa705d8b475b7b9a16b611f7ea34..748f6cd1868c20242b53b63ceb4910e4cd0cb3aa 100644 (file)
@@ -46,14 +46,25 @@ class SmileyAction extends AbstractDatabaseObjectAction implements ISortableActi
                /** @var Smiley $smiley */
                $smiley = parent::create();
                
+               $data = [];
                if (!empty($this->parameters['fileLocation'])) {
                        $smileyFilename = 'smiley'.$smiley->smileyID.'.'.mb_strtolower(mb_substr($this->parameters['fileLocation'], mb_strrpos($this->parameters['fileLocation'], '.') + 1));
                        @rename($this->parameters['fileLocation'], WCF_DIR.'images/smilies/'.$smileyFilename);
                        
+                       $data['smileyPath'] = 'images/smilies/'.$smileyFilename;
+                       
+                       
+               }
+               if (!empty($this->parameters['fileLocation2x'])) {
+                       $smileyFilename2x = 'smiley'.$smiley->smileyID.'@2x.'.mb_strtolower(mb_substr($this->parameters['fileLocation2x'], mb_strrpos($this->parameters['fileLocation2x'], '.') + 1));
+                       @rename($this->parameters['fileLocation2x'], WCF_DIR.'images/smilies/'.$smileyFilename2x);
+                       
+                       $data['smileyPath2x'] = 'images/smilies/'.$smileyFilename2x;
+               }
+               
+               if (!empty($data)) {
                        $smileyEditor = new SmileyEditor($smiley);
-                       $smileyEditor->update([
-                               'smileyPath' => 'images/smilies/'.$smileyFilename
-                       ]);
+                       $smileyEditor->update($data);
                        
                        $smiley = new Smiley($smiley->smileyID);
                }
@@ -69,12 +80,21 @@ class SmileyAction extends AbstractDatabaseObjectAction implements ISortableActi
                        $this->readObjects();
                }
                
-               if (count($this->objects) == 1 && !empty($this->parameters['fileLocation'])) {
-                       $smiley = reset($this->objects);
-                       $smileyFilename = 'smiley'.$smiley->smileyID.'.'.mb_strtolower(mb_substr($this->parameters['fileLocation'], mb_strrpos($this->parameters['fileLocation'], '.') + 1));
-                       @rename($this->parameters['fileLocation'], WCF_DIR.'images/smilies/'.$smileyFilename);
-                       
-                       $this->parameters['data']['smileyPath'] = 'images/smilies/'.$smileyFilename;
+               if (count($this->objects) == 1) {
+                       if (!empty($this->parameters['fileLocation'])) {
+                               $smiley = reset($this->objects);
+                               $smileyFilename = 'smiley' . $smiley->smileyID . '.' . mb_strtolower(mb_substr($this->parameters['fileLocation'], mb_strrpos($this->parameters['fileLocation'], '.') + 1));
+                               @rename($this->parameters['fileLocation'], WCF_DIR . 'images/smilies/' . $smileyFilename);
+                               
+                               $this->parameters['data']['smileyPath'] = 'images/smilies/' . $smileyFilename;
+                       }
+                       if (!empty($this->parameters['fileLocation2x'])) {
+                               $smiley = reset($this->objects);
+                               $smileyFilename2x = 'smiley' . $smiley->smileyID . '@2x.' . mb_strtolower(mb_substr($this->parameters['fileLocation2x'], mb_strrpos($this->parameters['fileLocation2x'], '.') + 1));
+                               @rename($this->parameters['fileLocation2x'], WCF_DIR . 'images/smilies/' . $smileyFilename2x);
+                               
+                               $this->parameters['data']['smileyPath2x'] = 'images/smilies/' . $smileyFilename2x;
+                       }
                }
                
                parent::update();
index b4942d274afc28be9e2934e630b910a27440c28f..d9280e5301883f80928a68805519b877f79a9875 100644 (file)
@@ -21,6 +21,8 @@ class SmileyCache extends SingletonFactory {
         */
        protected $cachedSmilies = [];
        
+       protected $cachedSmileyByCode = [];
+       
        /**
         * cached smiley categories
         * @var SmileyCategory[]
@@ -39,6 +41,7 @@ class SmileyCache extends SingletonFactory {
        protected function init() {
                // get smiley cache
                $this->cachedSmilies = SmileyCacheBuilder::getInstance()->getData([], 'smilies');
+               $this->cachedSmileyByCode = SmileyCacheBuilder::getInstance()->getData([], 'codes');
                $smileyCategories = CategoryHandler::getInstance()->getCategories('com.woltlab.wcf.bbcode.smiley');
                
                $this->cachedCategories[null] = new SmileyCategory(new Category(null, [
@@ -64,6 +67,14 @@ class SmileyCache extends SingletonFactory {
                return $this->cachedSmilies;
        }
        
+       public function getSmileyByCode($code) {
+               if (isset($this->cachedSmileyByCode[$code])) {
+                       return $this->cachedSmileyByCode[$code];
+               }
+               
+               return null;
+       }
+       
        /**
         * Returns all smiley categories.
         * 
index 3be450ed3a77eeddde62c08fbb710e6b32607c69..7196737972a20fefb54e2d00a6c7d42e75bf5f69 100644 (file)
@@ -61,7 +61,7 @@ class SimpleMessageParser extends SingletonFactory {
                                /** @var Smiley $smiley */
                                foreach ($categorySmilies as $smiley) {
                                        foreach ($smiley->smileyCodes as $smileyCode) {
-                                               $this->smilies[$smileyCode] = '<img src="'.$smiley->getURL().'" alt="'.StringUtil::encodeHTML($smiley->smileyCode).'">';
+                                               $this->smilies[$smileyCode] = $smiley->getHtml();
                                        }
                                }
                        }
index 0146422a9967e0d14f6e846dac83f4a05b1dd4fc..fad1de0078fd6659a041b6b2d1a8640729b6ac22 100644 (file)
@@ -16,7 +16,7 @@ class SmileyCacheBuilder extends AbstractCacheBuilder {
         * @inheritDoc
         */
        protected function rebuild(array $parameters) {
-               $data = ['smilies' => []];
+               $data = ['codes' => [], 'smilies' => []];
                
                // get smilies
                $sql = "SELECT          *
@@ -30,7 +30,14 @@ class SmileyCacheBuilder extends AbstractCacheBuilder {
                        $object->smileyCodes = $object->getAliases();
                        $object->smileyCodes[] = $object->smileyCode;
                        
+                       // this call will cause the image height to be added to the cache
+                       $object->getHeight();
+                       
                        $data['smilies'][$object->categoryID][$object->smileyID] = $object;
+                       
+                       foreach ($object->smileyCodes as $smileyCode) {
+                               $data['codes'][$smileyCode] = $object;
+                       }
                }
                
                return $data;
index 88ea19e562d452f4660932f6f5b51f448bfa7f00..0253362cfb4b7c381903ec93961103db6c4028fe 100644 (file)
@@ -93,6 +93,7 @@ class MessageHtmlInputFilter implements IHtmlInputFilter {
                
                // add data-attachment-id="" for <img>
                $definition->addAttribute('img', 'data-attachment-id', 'Number');
+               $definition->addAttribute('img', 'srcset', 'Text');
                
                $parameters = [
                        'config' => $config,
index 2980b210e669ac51192604565f9bcdd4d7e355bf..9739473e07ab59c1799207eb5ff6bb29b4d68196 100644 (file)
@@ -1,5 +1,7 @@
 <?php
 namespace wcf\system\html\input\node;
+use wcf\data\smiley\Smiley;
+use wcf\data\smiley\SmileyCache;
 use wcf\system\bbcode\BBCodeHandler;
 use wcf\system\html\node\AbstractHtmlNodeProcessor;
 use wcf\util\DOMUtil;
@@ -34,36 +36,62 @@ class HtmlInputNodeImg extends AbstractHtmlInputNode {
                /** @var \DOMElement $element */
                foreach ($elements as $element) {
                        $class = $element->getAttribute('class');
-                       if (!preg_match('~\bwoltlabAttachment\b~', $class)) {
-                               continue;
+                       if (preg_match('~\bwoltlabAttachment\b~', $class)) {
+                               $this->handleAttachment($element, $class);
                        }
-                       
-                       $attachmentID = intval($element->getAttribute('data-attachment-id'));
-                       if (!$attachmentID) {
-                               continue;
-                       }
-                       
-                       $float = 'none';
-                       $thumbnail = false;
-                       
-                       if (strpos($element->getAttribute('src'), 'thumbnail=1') !== false) {
-                               $thumbnail = true;
-                       }
-                       
-                       if (preg_match('~\bmessageFloatObject(?P<float>Left|Right)\b~', $class, $matches)) {
-                               $float = ($matches['float'] === 'Left') ? 'left' : 'right';
+                       else if (preg_match('~\bsmiley\b~', $class)) {
+                               $this->handleSmiley($element);
                        }
+               }
+       }
+       
+       protected function handleAttachment(\DOMElement $element, $class) {
+               $attachmentID = intval($element->getAttribute('data-attachment-id'));
+               if (!$attachmentID) {
+                       return;
+               }
+               
+               $float = 'none';
+               $thumbnail = false;
+               
+               if (strpos($element->getAttribute('src'), 'thumbnail=1') !== false) {
+                       $thumbnail = true;
+               }
+               
+               if (preg_match('~\bmessageFloatObject(?P<float>Left|Right)\b~', $class, $matches)) {
+                       $float = ($matches['float'] === 'Left') ? 'left' : 'right';
+               }
+               
+               $attributes = [
+                       $attachmentID,
+                       $float,
+                       $thumbnail
+               ];
+               
+               $newElement = $element->ownerDocument->createElement('woltlab-metacode');
+               $newElement->setAttribute('data-name', 'attach');
+               $newElement->setAttribute('data-attributes', base64_encode(JSON::encode($attributes)));
+               DOMUtil::replaceElement($element, $newElement, false);
+       }
+       
+       protected function handleSmiley(\DOMElement $element) {
+               $code = $element->getAttribute('alt');
+               
+               /** @var Smiley $smiley */
+               $smiley = SmileyCache::getInstance()->getSmileyByCode($code);
+               if ($smiley === null) {
+                       $element->parentNode->insertBefore($element->ownerDocument->createTextNode($code), $element);
+                       $element->parentNode->removeChild($element);
+               }
+               else {
+                       // enforce database values for src, srcset and style
+                       $element->setAttribute('src', $smiley->getURL());
                        
-                       $attributes = [
-                               $attachmentID,
-                               $float,
-                               $thumbnail
-                       ];
+                       if ($smiley->getHeight()) $element->setAttribute('style', 'height: ' . $smiley->getHeight() . 'px');
+                       else $element->removeAttribute('style');
                        
-                       $newElement = $element->ownerDocument->createElement('woltlab-metacode');
-                       $newElement->setAttribute('data-name', 'attach');
-                       $newElement->setAttribute('data-attributes', base64_encode(JSON::encode($attributes)));
-                       DOMUtil::replaceElement($element, $newElement, false);
+                       if ($smiley->smileyPath2x) $element->setAttribute('srcset', $smiley->getURL2x() . ' 2x');
+                       else $element->removeAttribute('srcset');
                }
        }
 }
index 99a3a7d271a8b8a6daefaa42482fa3ed6ade95a2..d2d9885d711e31285acd446c2c6f5a98a73d6677 100644 (file)
@@ -1,5 +1,7 @@
 <?php
 namespace wcf\system\html\output\node;
+use wcf\data\smiley\Smiley;
+use wcf\data\smiley\SmileyCache;
 use wcf\system\html\node\AbstractHtmlNodeProcessor;
 use wcf\system\request\LinkHandler;
 use wcf\util\exception\CryptoException;
@@ -24,15 +26,35 @@ class HtmlOutputNodeImg extends AbstractHtmlOutputNode {
         * @inheritDoc
         */
        public function process(array $elements, AbstractHtmlNodeProcessor $htmlNodeProcessor) {
-               if (!MODULE_IMAGE_PROXY) {
-                       return;
-               }
-               
                /** @var \DOMElement $element */
                foreach ($elements as $element) {
-                       $src = $element->getAttribute('src');
-                       if ($src) {
-                               $element->setAttribute('src', $this->getProxyLink($src));
+                       $class = $element->getAttribute('class');
+                       if (preg_match('~\bsmiley\b~', $class)) {
+                               $code = $element->getAttribute('alt');
+                               
+                               /** @var Smiley $smiley */
+                               $smiley = SmileyCache::getInstance()->getSmileyByCode($code);
+                               if ($smiley === null) {
+                                       // output as raw code instead
+                                       $element->parentNode->insertBefore($element->ownerDocument->createTextNode($code), $element);
+                                       $element->parentNode->removeChild($element);
+                               }
+                               else {
+                                       // enforce database values for src, srcset and style
+                                       $element->setAttribute('src', $smiley->getURL());
+                                       
+                                       if ($smiley->getHeight()) $element->setAttribute('style', 'height: ' . $smiley->getHeight() . 'px');
+                                       else $element->removeAttribute('style');
+                                       
+                                       if ($smiley->smileyPath2x) $element->setAttribute('srcset', $smiley->getURL2x() . ' 2x');
+                                       else $element->removeAttribute('srcset');
+                               }
+                       }
+                       else if (MODULE_IMAGE_PROXY) {
+                               $src = $element->getAttribute('src');
+                               if ($src) {
+                                       $element->setAttribute('src', $this->getProxyLink($src));
+                               }
                        }
                }
        }
index 0c2c288bd992017b630f2ca35c4caa4ce16e086e..aee184d4d251545a4d2b3834dba05830b7efba5c 100644 (file)
@@ -53,6 +53,7 @@ class SmileyPackageInstallationPlugin extends AbstractXMLPackageInstallationPlug
                        'smileyCode' => $data['attributes']['name'],
                        'smileyTitle' => $data['elements']['title'],
                        'smileyPath' => $data['elements']['path'],
+                       'smileyPath2x' => isset($data['elements']['path2x']) ? $data['elements']['path2x'] : '',
                        'aliases' => isset($data['elements']['aliases']) ? $data['elements']['aliases'] : '',
                        'showOrder' => $showOrder
                ];
index f177265568ff9749e1c36cfe6db46cff695f7e6f..7cd8fd36df92e102bb8d3d786704e82b826698a5 100644 (file)
@@ -1544,6 +1544,8 @@ GmbH=Gesellschaft mit beschränkter Haftung]]></item>
                <item name="wcf.acp.smiley.smileyPath.description"><![CDATA[Der Smiley-Pfad wird relativ zu „{$__wcf->getPath()}“ interpretiert.]]></item>
                <item name="wcf.acp.smiley.smileyPath.error.notFound"><![CDATA[Es wurde keine Datei unter dem angegebenen Pfad gefunden]]></item>
                <item name="wcf.acp.smiley.smileyFile"><![CDATA[Smiley-Datei]]></item>
+               <item name="wcf.acp.smiley.smileyFile2x"><![CDATA[Smiley-Datei (HD)]]></item>
+               <item name="wcf.acp.smiley.smileyFile2x.description"><![CDATA[Optionale Grafik die auf hochauflösenden Bildschirmen (z.B. Apple Retina-Display oder 4K/UHD-Monitore) verwendet wird, diese muss doppelt so groß sein wie die normale Grafik.]]></item>
                <item name="wcf.acp.smiley.fileUpload"><![CDATA[Smiley hochladen]]></item>
                <item name="wcf.acp.smiley.fileUpload.description"><![CDATA[{if LANGUAGE_USE_INFORMAL_VARIANT}Lade{else}Laden Sie{/if} hier die Bilddatei des Smileys hoch.]]></item>
                <item name="wcf.acp.smiley.fileUpload.error.noImage"><![CDATA[Bei der hochgeladenen Datei handelt es sich um keine Bilddatei.]]></item>
index fc5f4ed284c194019c6fe2f63387b910d9743851..b862d9b1c5cbf8d5e6b3359c86a68c770dd05de5 100644 (file)
@@ -1516,6 +1516,8 @@ GmbH=Gesellschaft mit beschränkter Haftung]]></item>
                <item name="wcf.acp.smiley.smileyPath.description"><![CDATA[Smiley path is relative to “{$__wcf->getPath()}”.]]></item>
                <item name="wcf.acp.smiley.smileyPath.error.notFound"><![CDATA[Unable to find a file on given path.]]></item>
                <item name="wcf.acp.smiley.smileyFile"><![CDATA[Smiley File]]></item>
+               <item name="wcf.acp.smiley.smileyFile2x"><![CDATA[Smiley File (HD)]]></item>
+               <item name="wcf.acp.smiley.smileyFile2x.description"><![CDATA[Optional image used for display on high resolution displays such as Apple Retina or 4K/UHD-displays. Image must be double times the dimensions of the normal image to work.]]></item>
                <item name="wcf.acp.smiley.fileUpload"><![CDATA[Upload Smiley]]></item>
                <item name="wcf.acp.smiley.fileUpload.description"><![CDATA[Upload the image file for the smiley.]]></item>
                <item name="wcf.acp.smiley.fileUpload.error.noImage"><![CDATA[The uploaded file is not an image file.]]></item>
index c36ed4cae99bc8c22ee8c183659707a3a49a6730..6ba2f05043c74cf010f3eff83aa5db92828e99f0 100644 (file)
@@ -1119,6 +1119,7 @@ CREATE TABLE wcf1_smiley (
        packageID INT(10) NOT NULL,
        categoryID INT(10),
        smileyPath VARCHAR(255) NOT NULL DEFAULT '',
+       smileyPath2x VARCHAR(255) NOT NULL DEFAULT '',
        smileyTitle VARCHAR(255) NOT NULL DEFAULT '',
        smileyCode VARCHAR(191) NOT NULL DEFAULT '',
        aliases TEXT NOT NULL,