Removed some todos
authorAlexander Ebert <ebert@woltlab.com>
Thu, 11 Aug 2016 14:40:08 +0000 (16:40 +0200)
committerAlexander Ebert <ebert@woltlab.com>
Thu, 11 Aug 2016 14:40:08 +0000 (16:40 +0200)
Some of them are already resolved and others don't matter at all.

22 files changed:
com.woltlab.wcf/templates/wysiwyg.tpl
wcfsetup/install/files/acp/js/WCF.ACP.js
wcfsetup/install/files/acp/templates/wysiwyg.tpl
wcfsetup/install/files/js/3rdParty/redactor2/plugins/WoltLabImage.js
wcfsetup/install/files/js/WCF.Message.js
wcfsetup/install/files/lib/acp/form/BBCodeAddForm.class.php
wcfsetup/install/files/lib/acp/form/StyleAddForm.class.php
wcfsetup/install/files/lib/data/menu/item/MenuItem.class.php
wcfsetup/install/files/lib/form/MessageForm.class.php
wcfsetup/install/files/lib/system/cli/command/PackageCLICommand.class.php
wcfsetup/install/files/lib/system/cli/command/WorkerCLICommand.class.php
wcfsetup/install/files/lib/system/clipboard/ClipboardHandler.class.php
wcfsetup/install/files/lib/system/message/embedded/object/AbstractMessageEmbeddedObjectHandler.class.php
wcfsetup/install/files/lib/system/message/quote/MessageQuoteManager.class.php
wcfsetup/install/files/lib/system/option/user/group/TextUserGroupOptionType.class.php
wcfsetup/install/files/lib/system/package/PackageInstallationDispatcher.class.php
wcfsetup/install/files/lib/system/package/PackageInstallationFormManager.class.php
wcfsetup/install/files/lib/system/package/PackageInstallationNodeBuilder.class.php
wcfsetup/install/files/lib/system/package/PackageUninstallationDispatcher.class.php
wcfsetup/install/files/lib/system/poll/PollManager.class.php
wcfsetup/install/files/style/ui/dropdown.scss
wcfsetup/install/files/style/ui/tabMenuMessage.scss

index 77bf603f94cf224131aaafbabcbf980026f185a3..973115b20dd799336e6c3520f44413940dad75c6 100644 (file)
@@ -94,7 +94,6 @@
                        
                        var highlighters = { {implode from=$__wcf->getBBCodeHandler()->getHighlighters() item=__highlighter}'{$__highlighter}': '{lang}wcf.bbcode.code.{@$__highlighter}.title{/lang}'{/implode} };
                        
-                       // TODO: Should the media stuff be here?
                        {include file='mediaJavaScript'}
                        
                        var element = elById('{if $wysiwygSelector|isset}{$wysiwygSelector|encodeJS}{else}text{/if}');
index 710769e457081d05107a4b8545a636b5db17b814..cc19d57ac1fba504ed260f91e67eb320ad0ccfeb 100644 (file)
@@ -1001,12 +1001,6 @@ WCF.ACP.Package.Search = Class.extend({
                this._packageSearchResultContainer.find('.pagination').wcfPages('destroy').remove();
                
                if (this._pageCount > 1) {
-                       // TODO: Fix ui.wcfPages to properly synchronize multiple instances without triggering events
-                       /*$('<div class="contentNavigation" />').insertBefore(this._packageSearchResultList).wcfPages({
-                               activePage: this._pageNo,
-                               maxPage: this._pageCount
-                       }).on('wcfpagesswitched', $.proxy(this._showPage, this));*/
-                       
                        $('<div class="contentNavigation" />').insertAfter(this._packageSearchResultList).wcfPages({
                                activePage: this._pageNo,
                                maxPage: this._pageCount
index 77bf603f94cf224131aaafbabcbf980026f185a3..973115b20dd799336e6c3520f44413940dad75c6 100644 (file)
@@ -94,7 +94,6 @@
                        
                        var highlighters = { {implode from=$__wcf->getBBCodeHandler()->getHighlighters() item=__highlighter}'{$__highlighter}': '{lang}wcf.bbcode.code.{@$__highlighter}.title{/lang}'{/implode} };
                        
-                       // TODO: Should the media stuff be here?
                        {include file='mediaJavaScript'}
                        
                        var element = elById('{if $wysiwygSelector|isset}{$wysiwygSelector|encodeJS}{else}text{/if}');
index 7d8f83744745c9380b09529c0ca425ccd5e5d11e..f009730ab2c09596ab2ca2898d41f17d9523ef0e 100644 (file)
@@ -7,7 +7,6 @@ $.Redactor.prototype.WoltLabImage = function() {
                        this.button.addCallback(button, this.WoltLabImage.add);
                        
                        // add support for image source when editing
-                       // TODO: float
                        var mpShowEdit = this.image.showEdit;
                        this.image.showEdit = (function($image) {
                                var image = $image[0];
index 5131bb812151050e3dac6c20fdac8d96db33fc78..20e539314419cdf5fbf4c7c5eb8c377fa7a0cf64 100644 (file)
@@ -1603,11 +1603,6 @@ WCF.Message.Quote.Manager = Class.extend({
                
                this._toggleShowQuotes();
                
-               // TODO: when is this event being used?
-               WCF.System.Event.addListener('com.woltlab.wcf.message.quote', 'insert', (function(data) {
-                       this._insertQuote(null, undefined, data);
-               }).bind(this));
-               
                WCF.System.Event.addListener('com.woltlab.wcf.quote', 'reload', this.countQuotes.bind(this));
        },
        
@@ -1832,7 +1827,7 @@ WCF.Message.Quote.Manager = Class.extend({
                
                // insert all quotes
                this._dialog.find('input.jsCheckbox:checked').each($.proxy(function(index, input) {
-                       this._insertQuote(null, input, undefined);
+                       this._insertQuote(null, input);
                }, this));
                
                // close dialog
@@ -1844,11 +1839,8 @@ WCF.Message.Quote.Manager = Class.extend({
         * 
         * @param       {Event}         event
         * @param       {Object}        inputElement
-        * @param       {Object}        data
         */
-       _insertQuote: function(event, inputElement, data) {
-               // TODO: what is with this data attribute, when is the event actually used?
-               
+       _insertQuote: function(event, inputElement) {
                var listItem = $(event ? event.currentTarget : inputElement).parents('li:eq(0)');
                var text = listItem.children('.jsFullQuote')[0].textContent.trim();
                
index 45c4a230bb693541401c7417b78ce7e8d3bb6a2e..29c1b08e3ec936c10f4025c3b7cecb3268beead7 100644 (file)
@@ -127,7 +127,6 @@ class BBCodeAddForm extends AbstractForm {
                if (isset($_POST['showButton'])) $this->showButton = true;
                if (isset($_POST['wysiwygIcon'])) $this->wysiwygIcon = StringUtil::trim($_POST['wysiwygIcon']);
                
-               // TODO: The code below violates every implicit convention of value reading and type casting
                $attributeNo = 0;
                foreach ($this->attributes as $key => $val) {
                        $val['attributeNo'] = $attributeNo++;
index c064a0677edcea6a46e03a1dd8e6ba50d75c6b96..c365820194fd0a2409500e610b6ca098ed583a34 100644 (file)
@@ -207,7 +207,6 @@ class StyleAddForm extends AbstractForm {
                
                I18nHandler::getInstance()->readValues();
                
-               // @TODO
                $colors = [];
                foreach ($this->colors as $categoryName => $variables) {
                        foreach ($variables as $variable) {
index 5e974c3b6ce39ccac98dc7fb02a70b435281ddec..077c1fba33c696d030fd221c3b24b9bee2011b67 100644 (file)
@@ -137,7 +137,7 @@ class MenuItem extends DatabaseObject {
        }
        
        /**
-        * TODO: Comment
+        * Returns the page handler for this item.
         * 
         * @return      IMenuPageHandler|null
         * @throws      SystemException
index d9c487e50f83b82e90cb5dd7c48da0204de29ca5..321a4ca10684e0e375c4e3f670f24c15bb644f36 100644 (file)
@@ -263,25 +263,6 @@ abstract class MessageForm extends AbstractCaptchaForm {
                parent::save();
                
                $this->text = $this->htmlInputProcessor->getHtml();
-               
-               // parse URLs
-               /* TODO
-               if ($this->preParse == 1) {
-                       // BBCodes are enabled
-                       if ($this->enableBBCodes) {
-                               if ($this->allowedBBCodesPermission) {
-                                       $this->text = PreParser::getInstance()->parse($this->text, ArrayUtil::trim(explode(',', WCF::getSession()->getPermission($this->allowedBBCodesPermission))));
-                               }
-                               else {
-                                       $this->text = PreParser::getInstance()->parse($this->text);
-                               }
-                       }
-                       // BBCodes are disabled, thus no allowed BBCodes
-                       else {
-                               $this->text = PreParser::getInstance()->parse($this->text, array());
-                       }
-               }
-               */
        }
        
        /**
index ba3ec95b8f536a1cfbe939378268a786fc8a1f8a..c32c92373eb9546a80cd5ed967de91aefe1d7ef5 100644 (file)
@@ -101,8 +101,6 @@ class PackageCLICommand implements IArgumentedCLICommand {
                // PackageStartInstallForm::validateArchive()
                // try to open the archive
                try {
-                       // TODO: Exceptions thrown within openArchive() are discarded, resulting in
-                       // the meaningless message 'not a valid package'
                        $archive->openArchive();
                }
                catch (SystemException $e) {
@@ -273,7 +271,6 @@ class PackageCLICommand implements IArgumentedCLICommand {
                        $queue = new PackageInstallationQueue($queueID);
                        
                        if (!$queue->queueID) {
-                               // todo: what to output?
                                echo "InstallPackageAction::readParameters()";
                                return;
                        }
index 2aacb4dfe56913df612d75449aeb4cfbdc49d388..48ee2ac37b5d48fa444cc47257e70359760a9cf4 100644 (file)
@@ -189,7 +189,6 @@ class WorkerCLICommand implements IArgumentedCLICommand {
         * @inheritDoc
         */
        public function canAccess() {
-               // TODO: Check access
                return true;
        }
 }
index e9d419f94831241bcbfe3ecd496fb01409556139..2f9111e530275bf228118343d627a02e1631f726 100644 (file)
@@ -169,8 +169,6 @@ class ClipboardHandler extends SingletonFactory {
         * Returns the id of the clipboard object type with the given name or `null` if no such
         * clipboard object type exists.
         * 
-        * TODO: The name of this method does not reflect its return type and appears not to be used.
-        * 
         * @param       string          $objectType
         * @return      integer|null
         */
index 9cc6a47dc1cb4847d6ae74ef2461364cfb6b4500..0d1804d41db001e103cdc605fd842e7a722daea2 100644 (file)
@@ -2,7 +2,6 @@
 namespace wcf\system\message\embedded\object;
 use wcf\data\object\type\ObjectType;
 use wcf\data\DatabaseObjectDecorator;
-use wcf\system\html\input\HtmlInputProcessor;
 
 /**
  * Provides default implementations for message embedded object handlers.
@@ -20,13 +19,4 @@ abstract class AbstractMessageEmbeddedObjectHandler extends DatabaseObjectDecora
         * @inheritDoc
         */
        protected static $baseClass = ObjectType::class;
-       
-       /**
-        * @inheritDoc
-        */
-       public function parse(HtmlInputProcessor $htmlInputProcessor, array $embeddedData) {
-               // TODO: DEBUG ONLY, remove this method!
-               return [];
-       }
-       
 }
index e4cdb4d944002b0d23bb5915eb1ef350517ce49b..702a3a750b2b440882288e2e667bc5d11ad92d10 100644 (file)
@@ -3,7 +3,6 @@ namespace wcf\system\message\quote;
 use wcf\data\object\type\ObjectType;
 use wcf\data\object\type\ObjectTypeCache;
 use wcf\data\IMessage;
-use wcf\system\application\ApplicationHandler;
 use wcf\system\exception\SystemException;
 use wcf\system\SingletonFactory;
 use wcf\system\WCF;
@@ -12,10 +11,10 @@ use wcf\util\ArrayUtil;
 /**
  * Manages message quotes.
  * 
- * @author     Alexander Ebert
- * @copyright  2001-2016 WoltLab GmbH
- * @license    GNU Lesser General Public License <http://opensource.org/licenses/lgpl-license.php>
- * @package    WoltLabSuite\Core\System\Message\Quote
+ * @author      Alexander Ebert
+ * @copyright   2001-2016 WoltLab GmbH
+ * @license     GNU Lesser General Public License <http://opensource.org/licenses/lgpl-license.php>
+ * @package     WoltLabSuite\Core\System\Message\Quote
  */
 class MessageQuoteManager extends SingletonFactory {
        /**
@@ -36,12 +35,6 @@ class MessageQuoteManager extends SingletonFactory {
         */
        protected $objectTypes = [];
        
-       /**
-        * primary application's package id
-        * @var integer
-        */
-       protected $packageID = 0;
-       
        /**
         * list of stored quotes
         * @var mixed[][]
@@ -70,12 +63,8 @@ class MessageQuoteManager extends SingletonFactory {
         * @inheritDoc
         */
        protected function init() {
-               // @todo
-               $this->packageID = 1;
-               //$this->packageID = ApplicationHandler::getInstance()->getPrimaryApplication()->packageID;
-               
                // load stored quotes from session
-               $messageQuotes = WCF::getSession()->getVar('__messageQuotes'.$this->packageID);
+               $messageQuotes = WCF::getSession()->getVar('__messageQuotes');
                if (is_array($messageQuotes)) {
                        $this->quotes = isset($messageQuotes['quotes']) ? $messageQuotes['quotes'] : [];
                        $this->quoteData = isset($messageQuotes['quoteData']) ? $messageQuotes['quoteData'] : [];
@@ -601,7 +590,7 @@ class MessageQuoteManager extends SingletonFactory {
         * Updates data stored in session,
         */
        protected function updateSession() {
-               WCF::getSession()->register('__messageQuotes'.$this->packageID, [
+               WCF::getSession()->register('__messageQuotes', [
                        'quotes' => $this->quotes,
                        'quoteData' => $this->quoteData,
                        'removeQuoteIDs' => $this->removeQuoteIDs
index 3f9cb7efc2052caef78bf5115dc9722c9f85906e..e122f9e502526a0551e30bfe227c1972f65e412b 100644 (file)
@@ -12,9 +12,6 @@ use wcf\util\StringUtil;
  * @copyright  2001-2016 WoltLab GmbH
  * @license    GNU Lesser General Public License <http://opensource.org/licenses/lgpl-license.php>
  * @package    WoltLabSuite\Core\System\Option\User\Group
- * 
- * @todo       text options types can't have line breaks, why use them to split
- *             values? what to do?
  */
 class TextUserGroupOptionType extends TextOptionType implements IUserGroupOptionType {
        /**
index 600573edb0385c8a01205dae3e05cacdfb54f1eb..30ade3e998d450e16aa4da7bda9c6a20821b37ab 100644 (file)
@@ -457,9 +457,7 @@ class PackageInstallationDispatcher {
        }
        
        /**
-        * Saves the localized package infos.
-        * 
-        * @todo        license and readme
+        * Saves the localized package info.
         */
        protected function saveLocalizedPackageInfos() {
                $package = new Package($this->queue->packageID);
index d653a892f611932eb775e7c9ded0c4e12b59477b..72743dfca6ce4e2b5cdbfd28144b0767984b40f7 100644 (file)
@@ -101,7 +101,7 @@ abstract class PackageInstallationFormManager {
                $statement->execute([
                        base64_encode(serialize($document)),
                        $queue->queueID,
-                       $document->formName // TODO: FormDocument::$formName does not exist, FormDocument::getName()?
+                       $document->getName()
                ]);
        }
        
index 6c474d238f33ed27a10d731f4112b36059f2f778..521ee75b8c49e26fe4729d80bed60e3a2e97d2e3 100644 (file)
@@ -507,8 +507,6 @@ class PackageInstallationNodeBuilder {
                                        // the new delivered required version of the package has a
                                        // higher version number, thus update/replace the existing
                                        // package installation queue
-                                       
-                                       // todo
                                }
                        }
                        
index f53dc27b66e27e35aec00a51592302f8b1754147..f91e0fd0674a77ef7832233af7f8f3343e542893 100644 (file)
@@ -139,8 +139,7 @@ class PackageUninstallationDispatcher extends PackageInstallationDispatcher {
        protected function uninstallPackage(array $nodeData) {
                PackageEditor::deleteAll([$this->queue->packageID]);
                
-               // remove localized package infos
-               // todo: license/readme
+               // remove localized package info
                $sql = "DELETE FROM     wcf".WCF_N."_language_item
                        WHERE           languageItem IN (?, ?)";
                $statement = WCF::getDB()->prepareStatement($sql);
index 7643dc2511929ad21ec20faa574acf00b774a708..35e98f90d63c70c288c48d7ef03a0890fabd05e5 100644 (file)
@@ -145,7 +145,6 @@ class PollManager extends SingletonFactory {
                                ORDER BY        showOrder ASC";
                        $statement = WCF::getDB()->prepareStatement($sql);
                        $statement->execute([$this->poll->pollID]);
-                       // TODO?: $this->pollOptions = $statement->fetchAll(\PDO::FETCH_ASSOC);
                        while ($row = $statement->fetchArray()) {
                                $this->pollOptions[] = $row;
                        }
index 52d88c92f38b57ac1a32b998b65446b3c5040ce3..a881bbd352b3827ee5b4e8a4bfac792663376ea2 100644 (file)
@@ -27,7 +27,6 @@
        }
        
        &.preInput {
-               // TODO: use flex-box instead
                display: table;
                width: 100%;
                
index e63b5995758fcd828d5b9da8661e029763b9c376..6542311814fa318b7be69c75a87f370adde42dfc 100644 (file)
@@ -49,7 +49,7 @@
 }
 
 .messageTabMenu + .innerError {
-       margin-top: -1px; // TODO
+       margin-top: -1px;
        width: 100%;
 }