Withoutaname has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/148282

Change subject: Remove functions deprecated since 1.21 from EditPage.php
......................................................................

Remove functions deprecated since 1.21 from EditPage.php

Specifically functions getContent(), getPreloadedText(), mergeChangesInto()
and setPreloadedText().

Change-Id: I5a258b4f060b1a3ae1218b8a8f424f2c9e8f146e
---
M RELEASE-NOTES-1.24
M includes/EditPage.php
2 files changed, 2 insertions(+), 79 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/core 
refs/changes/82/148282/1

diff --git a/RELEASE-NOTES-1.24 b/RELEASE-NOTES-1.24
index ead5196..8f64077 100644
--- a/RELEASE-NOTES-1.24
+++ b/RELEASE-NOTES-1.24
@@ -265,7 +265,8 @@
 * Removed maintenance script importTextFile.php. Use edit.php script instead.
 * A _from_namespace field has been added to the templatelinks, pagelinks,
   and filelinks tables. Run update.php to apply this change to the schema.
-
+* Removed functions getContent(), getPreloadedText(), mergeChangesInto() and
+  setPreloadedText() from EditPage.php. (deprecated since 1.21)
 
 ==== Renamed classes ====
 * CLDRPluralRuleConverter_Expression to CLDRPluralRuleConverterExpression
diff --git a/includes/EditPage.php b/includes/EditPage.php
index a8a6811..1946152 100644
--- a/includes/EditPage.php
+++ b/includes/EditPage.php
@@ -981,29 +981,6 @@
        }
 
        /**
-        * Fetch initial editing page content.
-        *
-        * @param string|bool $def_text
-        * @return string|bool string on success, $def_text for invalid sections
-        * @private
-        * @deprecated since 1.21, get WikiPage::getContent() instead.
-        */
-       function getContent( $def_text = false ) {
-               ContentHandler::deprecated( __METHOD__, '1.21' );
-
-               if ( $def_text !== null && $def_text !== false && $def_text !== 
'' ) {
-                       $def_content = $this->toEditContent( $def_text );
-               } else {
-                       $def_content = false;
-               }
-
-               $content = $this->getContentObject( $def_content );
-
-               // Note: EditPage should only be used with text based content 
anyway.
-               return $this->toEditText( $content );
-       }
-
-       /**
         * @param Content|null $def_content The default value to return
         *
         * @return Content|null Content on success, $def_content for invalid 
sections
@@ -1191,20 +1168,6 @@
        }
 
        /**
-        * Use this method before edit() to preload some text into the edit box
-        *
-        * @param string $text
-        * @deprecated since 1.21, use setPreloadedContent() instead.
-        */
-       public function setPreloadedText( $text ) {
-               ContentHandler::deprecated( __METHOD__, "1.21" );
-
-               $content = $this->toEditContent( $text );
-
-               $this->setPreloadedContent( $content );
-       }
-
-       /**
         * Use this method before edit() to preload some content into the edit 
box
         *
         * @param Content $content
@@ -1213,25 +1176,6 @@
         */
        public function setPreloadedContent( Content $content ) {
                $this->mPreloadContent = $content;
-       }
-
-       /**
-        * Get the contents to be preloaded into the box, either set by
-        * an earlier setPreloadText() or by loading the given page.
-        *
-        * @param string $preload representing the title to preload from.
-        *
-        * @return string
-        *
-        * @deprecated since 1.21, use getPreloadedContent() instead
-        */
-       protected function getPreloadedText( $preload ) {
-               ContentHandler::deprecated( __METHOD__, "1.21" );
-
-               $content = $this->getPreloadedContent( $preload );
-               $text = $this->toEditText( $content );
-
-               return $text;
        }
 
        /**
@@ -2023,28 +1967,6 @@
                                $dbw->commit( $fname );
                        } );
                }
-       }
-
-       /**
-        * Attempts to merge text content with base and current revisions
-        *
-        * @param string $editText
-        *
-        * @return bool
-        * @deprecated since 1.21, use mergeChangesIntoContent() instead
-        */
-       function mergeChangesInto( &$editText ) {
-               ContentHandler::deprecated( __METHOD__, "1.21" );
-
-               $editContent = $this->toEditContent( $editText );
-
-               $ok = $this->mergeChangesIntoContent( $editContent );
-
-               if ( $ok ) {
-                       $editText = $this->toEditText( $editContent );
-                       return true;
-               }
-               return false;
        }
 
        /**

-- 
To view, visit https://gerrit.wikimedia.org/r/148282
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I5a258b4f060b1a3ae1218b8a8f424f2c9e8f146e
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/core
Gerrit-Branch: master
Gerrit-Owner: Withoutaname <[email protected]>

_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits

Reply via email to