diff options
author | Pierre Schmitz <pierre@archlinux.de> | 2014-12-27 15:41:37 +0100 |
---|---|---|
committer | Pierre Schmitz <pierre@archlinux.de> | 2014-12-31 11:43:28 +0100 |
commit | c1f9b1f7b1b77776192048005dcc66dcf3df2bfb (patch) | |
tree | 2b38796e738dd74cb42ecd9bfd151803108386bc /includes/content/CssContentHandler.php | |
parent | b88ab0086858470dd1f644e64cb4e4f62bb2be9b (diff) |
Update to MediaWiki 1.24.1
Diffstat (limited to 'includes/content/CssContentHandler.php')
-rw-r--r-- | includes/content/CssContentHandler.php | 37 |
1 files changed, 6 insertions, 31 deletions
diff --git a/includes/content/CssContentHandler.php b/includes/content/CssContentHandler.php index cb5a349d..b2a8676b 100644 --- a/includes/content/CssContentHandler.php +++ b/includes/content/CssContentHandler.php @@ -27,41 +27,16 @@ * @since 1.21 * @ingroup Content */ -class CssContentHandler extends TextContentHandler { - - public function __construct( $modelId = CONTENT_MODEL_CSS ) { - parent::__construct( $modelId, array( CONTENT_FORMAT_CSS ) ); - } - - public function unserializeContent( $text, $format = null ) { - $this->checkFormat( $format ); - - return new CssContent( $text ); - } - - public function makeEmptyContent() { - return new CssContent( '' ); - } +class CssContentHandler extends CodeContentHandler { /** - * Returns the english language, because CSS is english, and should be handled as such. - * - * @return Language wfGetLangObj( 'en' ) - * - * @see ContentHandler::getPageLanguage() + * @param string $modelId */ - public function getPageLanguage( Title $title, Content $content = null ) { - return wfGetLangObj( 'en' ); + public function __construct( $modelId = CONTENT_MODEL_CSS ) { + parent::__construct( $modelId, array( CONTENT_FORMAT_CSS ) ); } - /** - * Returns the english language, because CSS is english, and should be handled as such. - * - * @return Language wfGetLangObj( 'en' ) - * - * @see ContentHandler::getPageViewLanguage() - */ - public function getPageViewLanguage( Title $title, Content $content = null ) { - return wfGetLangObj( 'en' ); + protected function getContentClass() { + return 'CssContent'; } } |