Rm unused warning system from WebInstallerOutput (mostly handled by Status objects...
authorChad Horohoe <demon@users.mediawiki.org>
Fri, 5 Nov 2010 12:48:13 +0000 (12:48 +0000)
committerChad Horohoe <demon@users.mediawiki.org>
Fri, 5 Nov 2010 12:48:13 +0000 (12:48 +0000)
includes/installer/WebInstallerOutput.php
includes/installer/WebInstallerPage.php

index 58bbac9..fb887e0 100644 (file)
  * @since 1.17
  */
 class WebInstallerOutput {
-       
        /**
         * The WebInstaller object this WebInstallerOutput is used by.
         *
         * @var WebInstaller
         */
        public $parent;
-       
-       public $contents = '';
-       public $warnings = '';
-       public $headerDone = false;
+
+       /**
+        * Buffered contents that haven't been output yet
+        * @var String
+        */
+       private $contents = '';
+
+       /**
+        * Has the header (or short header) been output?
+        * @var bool
+        */
+       private $headerDone = false;
+
        public $redirectTarget;
-       public $debug = true;
-       public $useShortHeader = false;
+
+       /**
+        * Whether to use the limited header (used during CC license callbacks)
+        * @var bool
+        */
+       private $useShortHeader = false;
 
        /**
         * Constructor.
@@ -55,16 +67,6 @@ class WebInstallerOutput {
                $this->contents .= $html;
        }
 
-       public function addWarning( $msg ) {
-               $this->warnings .= "<p>$msg</p>\n";
-       }
-       
-       public function addWarningMsg( $msg /*, ... */ ) {
-               $params = func_get_args();
-               array_shift( $params );
-               $this->addWarning( wfMsg( $msg, $params ) );
-       }
-
        public function redirect( $url ) {
                if ( $this->headerDone ) {
                        throw new MWException( __METHOD__ . ' called after sending headers' );
@@ -115,6 +117,10 @@ class WebInstallerOutput {
                );
        }
 
+       /**
+        * Get whether the header has been output
+        * @return bool
+        */
        public function headerDone() {
                return $this->headerDone;
        }
@@ -166,8 +172,6 @@ class WebInstallerOutput {
        }
 
        public function outputFooter() {
-               $this->outputWarnings();
-
                if ( $this->useShortHeader ) {
 ?>
 </body></html>
@@ -229,10 +233,4 @@ class WebInstallerOutput {
        public function getJQueryTipsy() {
                return Html::linkedScript( "../resources/jquery/jquery.tipsy.js" );
        }
-       
-       public function outputWarnings() {
-               $this->addHTML( $this->warnings );
-               $this->warnings = '';
-       }
-       
-}
\ No newline at end of file
+}
index f091186..7a90171 100644 (file)
@@ -50,7 +50,6 @@ abstract class WebInstallerPage {
        }
 
        public function endForm( $continue = 'continue' ) {
-               $this->parent->output->outputWarnings();
                $s = "<div class=\"config-submit\">\n";
                $id = $this->getId();