[MediaWiki-commits] [Gerrit] Stop PHPStorm hating me - change (mediawiki...TranslateSvg)
Jarry1250 has uploaded a new change for review. https://gerrit.wikimedia.org/r/55081 Change subject: Stop PHPStorm hating me .. Stop PHPStorm hating me Mostly docs changes and type hinting. Also some more substantive changes, but only really of the "tweak" variety. Change-Id: I3335526fc00bb8a5e0c1faaa7f1692486f93d98d --- M SVGFormatReader.php M SVGFormatWriter.php M SVGMessageGroup.php M TranslateSvgHooks.php M TranslateSvgTasks.php M resources/ext.translatesvg.filepage.js 6 files changed, 91 insertions(+), 61 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/TranslateSvg refs/changes/81/55081/1 diff --git a/SVGFormatReader.php b/SVGFormatReader.php index a237a90..54319c9 100644 --- a/SVGFormatReader.php +++ b/SVGFormatReader.php @@ -143,8 +143,8 @@ foreach( $texts as $text ) { $translatableNodes[] = $text; } - foreach( $translatableNodes as $translatableNode ) { + /** @var DOMElement $translatableNode */ if( $translatableNode->hasAttribute( 'id' ) ) { $id = trim( $translatableNode->getAttribute( 'id' ) ); $translatableNode->setAttribute( 'id', $id ); @@ -175,6 +175,7 @@ $textLength = $this->svg->getElementsByTagName( 'text' )->length; for( $i = 0; $i < $textLength; $i++ ) { + /** @var DOMElement $text */ $text = $texts->item( $i ); // Text strings like $1, $2 will cause problems later because @@ -191,6 +192,8 @@ $switch = $text->parentNode; $siblings = $switch->childNodes; foreach( $siblings as $sibling ) { + /** @var DOMElement $sibling */ + $languagesPresent = array(); if( $sibling->nodeType === XML_TEXT_NODE ) { if( trim( $sibling->textContent ) !== '' ) { @@ -278,7 +281,7 @@ // Ensure that child tspan translations prompt new s to be created // by duplicating the fallback version. - foreach( $translations as $key => $languages ) { + foreach( $translations as $languages ) { foreach( $languages as $language => $translation ) { if( isset( $languages['fallback']['data-parent'] ) ) { $parent = $languages['fallback']['data-parent']; @@ -313,7 +316,11 @@ // Some sort of deep hierarchy, can't translate continue; } - $textId = $fallback->item( 0 )->getAttribute( 'id' ); + + /** @var DOMElement $fallbackText */ + $fallbackText = $fallback->item( 0 ); + $textId = $fallbackText->getAttribute( 'id' ); + foreach( $translations[$textId] as $language => $translation ) { // Sort out systemLanguage attribute if( $language !== 'fallback' ) { @@ -389,7 +396,9 @@ $translations = array(); $this->filteredTextNodes = array(); // Reset for( $i = 0; $i < $number; $i++ ) { + /** @var DOMElement $switch */ $switch = $switches->item( $i ); + $texts = $switch->getElementsByTagName( 'text' ); $count = $texts->length; if( $count === 0 ) { @@ -402,10 +411,16 @@ // Some sort of deep hierarchy, can't translate continue; } - $textId = $fallback->item( 0 )->getAttribute( 'id' ); + + /** @var DOMElement $fallbackText */ + $fallbackText = $fallback->item( 0 ); + $textId = $fallbackText->getAttribute( 'id' ); + for( $j = 0; $j < $count; $j++ ) { // Don't want to manipulate actual node - $text = clone $texts->item( $j ); + /** @var DOMElement $actualNode */ + $actualNode = $texts->item( $j ); + $text = clone $actualNode; $numChildren = $text->childNodes->length; $hasActualTextContent = TranslateSvgUtils::hasActualTextContent( $text ); $lang = $text->hasAttribute( 'systemL
[MediaWiki-commits] [Gerrit] Provide helper links on file description pages. - change (mediawiki...TranslateSvg)
Jarry1250 has submitted this change and it was merged. Change subject: Provide helper links on file description pages. .. Provide helper links on file description pages. These come in a few different flavours: no translations, do you wish to start?; translations, just view; and translations, view and translate. The &chooselanguage=1 parameter doesn't do anything yet, but it will shortly. Change-Id: I360f2fdc219d96e5c10670c34796d6f40fbed2b4 --- M TranslateSvg.php M TranslateSvgHooks.php A resources/ext.translatesvg.filepage.js 3 files changed, 237 insertions(+), 0 deletions(-) Approvals: Nikerabbit: Looks good to me, but someone else must approve Jarry1250: Verified; Looks good to me, approved diff --git a/TranslateSvg.php b/TranslateSvg.php index d6d31ff..5321d9c 100644 --- a/TranslateSvg.php +++ b/TranslateSvg.php @@ -53,7 +53,28 @@ 'remoteExtPath' => 'TranslateSvg' ); +$wgResourceModules['ext.translatesvg.filepage'] = array( + 'scripts' => array( 'resources/ext.translatesvg.filepage.js' ), + 'dependencies' => array( 'mediawiki.Uri' ), + 'messages' => array( + 'translate-svg-filepage-caption', + 'translate-svg-filepage-caption-translator', + 'translate-svg-filepage-edit', + 'translate-svg-filepage-finish', + 'translate-svg-filepage-item', + 'translate-svg-filepage-another', + 'translate-svg-filepage-other', + 'translate-svg-filepage-invite', + 'comma-separator' + ), + 'localBasePath' => dirname( __FILE__ ), + 'remoteExtPath' => 'TranslateSvg' +); + +$wgHooks['BeforePageDisplay'][] = 'TranslateSvgHooks::updateFileDescriptionPages'; $wgHooks['LoadExtensionSchemaUpdates'][] = 'TranslateSvgHooks::schemaUpdates'; +$wgHooks['MakeGlobalVariablesScript'][] = 'TranslateSvgHooks::makeFilePageGlobalVariables'; +$wgHooks['TranslateBeforeAddModules'][] = 'TranslateSvgHooks::addModules'; $wgHooks['TranslateGetBoxes'][] = 'TranslateSvgHooks::addThumbnail'; $wgHooks['TranslateGetBoxes'][] = 'TranslateSvgHooks::removeQQQ'; $wgHooks['TranslateGetSpecialTranslateOptions'][] = 'TranslateSvgHooks::makeExportAsSvgOptionDefault'; diff --git a/TranslateSvgHooks.php b/TranslateSvgHooks.php index 68c8b64..dd8db19 100644 --- a/TranslateSvgHooks.php +++ b/TranslateSvgHooks.php @@ -259,6 +259,21 @@ return true; } + /* +* Function used to add modules via the resource loader on +* the file pages of SVG files via the BeforePageDisplay MediaWiki hook +* +* @param $out Contextual OutputPage instance +* @return \bool true +*/ + public static function updateFileDescriptionPages( $out ) { + $title = $out->getTitle(); + if( TranslateSvgUtils::isSVGFilePage( $title ) ) { + $out->addModules( 'ext.translatesvg.filepage' ); + } + return true; + } + /** * Process the thumbnail property for use with the mgprop parameter of * action=query&meta=messagegroups API queries. @@ -344,7 +359,60 @@ $group = Title::newFromRow( $r )->getText(); $list[$group] = new SVGMessageGroup( $group ); } + return true; + } + /** +* Function used to expose various new globals to the +* JavaScript of the file description pages of SVG files +* via the MakeGlobalVariablesScript MediaWiki hook. +* +* @param &$vars Array of variables to be exposed to JavaScript +* @param $out Contextual OutputPage instance +* @return \bool true +*/ + public static function makeFilePageGlobalVariables( &$vars, $out ) { + global $wgLanguageNames; + + $title = $out->getTitle(); + if( !TranslateSvgUtils::isSVGFilePage( $title ) ) { + return true; + } + + $user = $out->getUser(); + $vars['wgUserLanguageName'] = Language::fetchLanguageName( + $user->getOption( 'language' ) + ); + $vars['wgUserCanTranslate'] = $user->isAllowed( 'translate' ); + + $id = $title->getText(); + $messageGroup = new SVGMessageGroup( $id ); + $reader = new SVGFormatReader( $messageGroup ); + $vars['wgFileCanBeTranslated'] = ( $reader !== null ); + if( !$vars['wgFileCanBeTranslated'] || !MessageGroups::getGroup( $id ) ) { + // Not translatable or not yet translated, let's save time and return immediately + $vars['wgFileFullTranslations'] = array(); + $vars['wgFilePartialTranslations'] = array(); + return tru
[MediaWiki-commits] [Gerrit] Stop PHPStorm hating me - change (mediawiki...TranslateSvg)
Jarry1250 has submitted this change and it was merged. Change subject: Stop PHPStorm hating me .. Stop PHPStorm hating me Mostly docs changes and type hinting. Also some more substantive changes, but only really of the "tweak" variety. Change-Id: I3335526fc00bb8a5e0c1faaa7f1692486f93d98d --- M SVGFormatReader.php M SVGFormatWriter.php M SVGMessageGroup.php M TranslateSvgHooks.php M TranslateSvgTasks.php M resources/ext.translatesvg.filepage.js 6 files changed, 91 insertions(+), 61 deletions(-) Approvals: Jarry1250: Verified; Looks good to me, approved diff --git a/SVGFormatReader.php b/SVGFormatReader.php index a237a90..54319c9 100644 --- a/SVGFormatReader.php +++ b/SVGFormatReader.php @@ -143,8 +143,8 @@ foreach( $texts as $text ) { $translatableNodes[] = $text; } - foreach( $translatableNodes as $translatableNode ) { + /** @var DOMElement $translatableNode */ if( $translatableNode->hasAttribute( 'id' ) ) { $id = trim( $translatableNode->getAttribute( 'id' ) ); $translatableNode->setAttribute( 'id', $id ); @@ -175,6 +175,7 @@ $textLength = $this->svg->getElementsByTagName( 'text' )->length; for( $i = 0; $i < $textLength; $i++ ) { + /** @var DOMElement $text */ $text = $texts->item( $i ); // Text strings like $1, $2 will cause problems later because @@ -191,6 +192,8 @@ $switch = $text->parentNode; $siblings = $switch->childNodes; foreach( $siblings as $sibling ) { + /** @var DOMElement $sibling */ + $languagesPresent = array(); if( $sibling->nodeType === XML_TEXT_NODE ) { if( trim( $sibling->textContent ) !== '' ) { @@ -278,7 +281,7 @@ // Ensure that child tspan translations prompt new s to be created // by duplicating the fallback version. - foreach( $translations as $key => $languages ) { + foreach( $translations as $languages ) { foreach( $languages as $language => $translation ) { if( isset( $languages['fallback']['data-parent'] ) ) { $parent = $languages['fallback']['data-parent']; @@ -313,7 +316,11 @@ // Some sort of deep hierarchy, can't translate continue; } - $textId = $fallback->item( 0 )->getAttribute( 'id' ); + + /** @var DOMElement $fallbackText */ + $fallbackText = $fallback->item( 0 ); + $textId = $fallbackText->getAttribute( 'id' ); + foreach( $translations[$textId] as $language => $translation ) { // Sort out systemLanguage attribute if( $language !== 'fallback' ) { @@ -389,7 +396,9 @@ $translations = array(); $this->filteredTextNodes = array(); // Reset for( $i = 0; $i < $number; $i++ ) { + /** @var DOMElement $switch */ $switch = $switches->item( $i ); + $texts = $switch->getElementsByTagName( 'text' ); $count = $texts->length; if( $count === 0 ) { @@ -402,10 +411,16 @@ // Some sort of deep hierarchy, can't translate continue; } - $textId = $fallback->item( 0 )->getAttribute( 'id' ); + + /** @var DOMElement $fallbackText */ + $fallbackText = $fallback->item( 0 ); + $textId = $fallbackText->getAttribute( 'id' ); + for( $j = 0; $j < $count; $j++ ) { // Don't want to manipulate actual node - $text = clone $texts->item( $j ); + /** @var DOMElement $actualNode */ + $actualNode = $texts->item( $j ); + $text = clone $actualNode; $numChildren = $text->childNodes->length; $hasActualTextContent = TranslateSvgUtils::hasActualTextContent( $text ); $lang = $text->hasAttribute( 'systemLanguage' ) ? $text->getAttribute( 'systemLanguage' ) : 'fallback'; @@ -41
[MediaWiki-commits] [Gerrit] Miscellaneous bugfixes and amendments. - change (mediawiki...TranslateSvg)
Jarry1250 has uploaded a new change for review. https://gerrit.wikimedia.org/r/55094 Change subject: Miscellaneous bugfixes and amendments. .. Miscellaneous bugfixes and amendments. Change-Id: I8a43465340e30ec256498372c36bc59180c16563 --- M SVGFormatReader.php M SVGMessageGroup.php M TranslateSvg.php M TranslateSvgHooks.php M TranslateSvgUtils.php 5 files changed, 27 insertions(+), 6 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/TranslateSvg refs/changes/94/55094/1 diff --git a/SVGFormatReader.php b/SVGFormatReader.php index 54319c9..c25696a 100644 --- a/SVGFormatReader.php +++ b/SVGFormatReader.php @@ -534,7 +534,7 @@ break; } } - if( $fullSoFar ) { + if( $fullSoFar || $savedLanguage == $this->group->getSourceLanguage() ) { $full[] = $savedLanguage; } else { $partial[] = $savedLanguage; diff --git a/SVGMessageGroup.php b/SVGMessageGroup.php index 245df74..3ee90e6 100644 --- a/SVGMessageGroup.php +++ b/SVGMessageGroup.php @@ -33,7 +33,7 @@ $title = Title::newFromText( $prefixedFilename ); $rev = ''; if( $title->exists() ) { - $rev = Revision::newFromTitle( $title )->getContent()->getDefaultFormat(); + $rev = Revision::newFromTitle( $title )->getContent()->getWikitextForTransclusion(); $revsections = explode( "\n==", $rev ); foreach( $revsections as $revsection ) { // Attempt to trim the file description page down to only the most relevant content @@ -69,7 +69,7 @@ foreach( $subpages as $subpage ) { /** @var Title $subpage */ if( $this->isSourceLanguage( $subpage->getSubpageText() ) ) { - $definition = Revision::newFromTitle( $subpage )->getContent()->getDefaultFormat(); + $definition = Revision::newFromTitle( $subpage )->getContent()->getWikitextForTransclusion(); $definition = TranslateSvgUtils::stripPropertyString( $definition ); // Is there really not an easier way to get the parent page than: @@ -94,7 +94,7 @@ } $rev = Revision::newFromTitle( $title ); - $definition = $rev->getContent()->getDefaultFormat(); + $definition = $rev->getContent()->getWikitextForTransclusion(); $definition = TranslateSvgUtils::stripPropertyString( $definition ); return $definition; } @@ -111,7 +111,7 @@ if ( !$title->exists() ) { return ''; } - $translation = Revision::newFromTitle( $title )->getContent()->getDefaultFormat(); + $translation = Revision::newFromTitle( $title )->getContent()->getWikitextForTransclusion(); $properties = TranslateSvgUtils::extractPropertyString( $translation ); return $properties; diff --git a/TranslateSvg.php b/TranslateSvg.php index 5321d9c..99bb2db 100644 --- a/TranslateSvg.php +++ b/TranslateSvg.php @@ -77,6 +77,7 @@ $wgHooks['TranslateBeforeAddModules'][] = 'TranslateSvgHooks::addModules'; $wgHooks['TranslateGetBoxes'][] = 'TranslateSvgHooks::addThumbnail'; $wgHooks['TranslateGetBoxes'][] = 'TranslateSvgHooks::removeQQQ'; +$wgHooks['TranslateGetBoxes'][] = 'TranslateSvgHooks::removeSuggestions'; $wgHooks['TranslateGetSpecialTranslateOptions'][] = 'TranslateSvgHooks::makeExportAsSvgOptionDefault'; $wgHooks['TranslatePrefillTranslation'][] = 'TranslateSvgHooks::getDefaultPropertiesFromGroup'; $wgHooks['TranslateGetExtraInputs'][] = 'TranslateSvgHooks::propertiesToExtraInputs'; @@ -91,6 +92,7 @@ $wgSpecialPages['TranslateNewSVG'] = 'SpecialTranslateNewSVG'; $wgSpecialPageGroups['TranslateNewSVG'] = 'wiki'; +$wgTranslateMessageNamespaces[] = NS_FILE; /** * List of typefaces (or keywords) that can safely be incorporated into SVG diff --git a/TranslateSvgHooks.php b/TranslateSvgHooks.php index e1c5d26..a81a9ff 100644 --- a/TranslateSvgHooks.php +++ b/TranslateSvgHooks.php @@ -57,6 +57,25 @@ } /** +* Function used to remove the translation memory suggestions helper box via +* the TranslateGetBoxes hook +* +* @todo Replace this with a better helper rather than no helper +* @param $group \MessageGroup The message group to which the message being translated belongs +* @param $handle \MessageHandle The MessageHandle of the message being translated +* @param $boxes \array The array from which t
[MediaWiki-commits] [Gerrit] Miscellaneous bugfixes and amendments. - change (mediawiki...TranslateSvg)
Jarry1250 has submitted this change and it was merged. Change subject: Miscellaneous bugfixes and amendments. .. Miscellaneous bugfixes and amendments. Change-Id: I8a43465340e30ec256498372c36bc59180c16563 --- M SVGFormatReader.php M SVGMessageGroup.php M TranslateSvg.php M TranslateSvgHooks.php M TranslateSvgUtils.php 5 files changed, 27 insertions(+), 6 deletions(-) Approvals: Jarry1250: Verified; Looks good to me, approved diff --git a/SVGFormatReader.php b/SVGFormatReader.php index 54319c9..c25696a 100644 --- a/SVGFormatReader.php +++ b/SVGFormatReader.php @@ -534,7 +534,7 @@ break; } } - if( $fullSoFar ) { + if( $fullSoFar || $savedLanguage == $this->group->getSourceLanguage() ) { $full[] = $savedLanguage; } else { $partial[] = $savedLanguage; diff --git a/SVGMessageGroup.php b/SVGMessageGroup.php index 245df74..3ee90e6 100644 --- a/SVGMessageGroup.php +++ b/SVGMessageGroup.php @@ -33,7 +33,7 @@ $title = Title::newFromText( $prefixedFilename ); $rev = ''; if( $title->exists() ) { - $rev = Revision::newFromTitle( $title )->getContent()->getDefaultFormat(); + $rev = Revision::newFromTitle( $title )->getContent()->getWikitextForTransclusion(); $revsections = explode( "\n==", $rev ); foreach( $revsections as $revsection ) { // Attempt to trim the file description page down to only the most relevant content @@ -69,7 +69,7 @@ foreach( $subpages as $subpage ) { /** @var Title $subpage */ if( $this->isSourceLanguage( $subpage->getSubpageText() ) ) { - $definition = Revision::newFromTitle( $subpage )->getContent()->getDefaultFormat(); + $definition = Revision::newFromTitle( $subpage )->getContent()->getWikitextForTransclusion(); $definition = TranslateSvgUtils::stripPropertyString( $definition ); // Is there really not an easier way to get the parent page than: @@ -94,7 +94,7 @@ } $rev = Revision::newFromTitle( $title ); - $definition = $rev->getContent()->getDefaultFormat(); + $definition = $rev->getContent()->getWikitextForTransclusion(); $definition = TranslateSvgUtils::stripPropertyString( $definition ); return $definition; } @@ -111,7 +111,7 @@ if ( !$title->exists() ) { return ''; } - $translation = Revision::newFromTitle( $title )->getContent()->getDefaultFormat(); + $translation = Revision::newFromTitle( $title )->getContent()->getWikitextForTransclusion(); $properties = TranslateSvgUtils::extractPropertyString( $translation ); return $properties; diff --git a/TranslateSvg.php b/TranslateSvg.php index 5321d9c..99bb2db 100644 --- a/TranslateSvg.php +++ b/TranslateSvg.php @@ -77,6 +77,7 @@ $wgHooks['TranslateBeforeAddModules'][] = 'TranslateSvgHooks::addModules'; $wgHooks['TranslateGetBoxes'][] = 'TranslateSvgHooks::addThumbnail'; $wgHooks['TranslateGetBoxes'][] = 'TranslateSvgHooks::removeQQQ'; +$wgHooks['TranslateGetBoxes'][] = 'TranslateSvgHooks::removeSuggestions'; $wgHooks['TranslateGetSpecialTranslateOptions'][] = 'TranslateSvgHooks::makeExportAsSvgOptionDefault'; $wgHooks['TranslatePrefillTranslation'][] = 'TranslateSvgHooks::getDefaultPropertiesFromGroup'; $wgHooks['TranslateGetExtraInputs'][] = 'TranslateSvgHooks::propertiesToExtraInputs'; @@ -91,6 +92,7 @@ $wgSpecialPages['TranslateNewSVG'] = 'SpecialTranslateNewSVG'; $wgSpecialPageGroups['TranslateNewSVG'] = 'wiki'; +$wgTranslateMessageNamespaces[] = NS_FILE; /** * List of typefaces (or keywords) that can safely be incorporated into SVG diff --git a/TranslateSvgHooks.php b/TranslateSvgHooks.php index e1c5d26..a81a9ff 100644 --- a/TranslateSvgHooks.php +++ b/TranslateSvgHooks.php @@ -57,6 +57,25 @@ } /** +* Function used to remove the translation memory suggestions helper box via +* the TranslateGetBoxes hook +* +* @todo Replace this with a better helper rather than no helper +* @param $group \MessageGroup The message group to which the message being translated belongs +* @param $handle \MessageHandle The MessageHandle of the message being translated +* @param $boxes \array The array from which the thumbnail helper is removed +* @return \bool True +*/
[MediaWiki-commits] [Gerrit] Make it possible to use a custom selection of translation aids. - change (mediawiki...Translate)
Jarry1250 has uploaded a new change for review. https://gerrit.wikimedia.org/r/56622 Change subject: Make it possible to use a custom selection of translation aids. .. Make it possible to use a custom selection of translation aids. For both removals and additions, the list of TranslationAids available must be set on group-by-group basis. Here, the existing (static) method provides the base set to the MessageGroup and MessageGroupOld base classes. Changes can then be made by overriding the MessageGroup(Old) default set. Custom removals are effected by allowing use of a new UnsupportedTranslationAid class that always errors, ensuring that handlers need only check for the presence of an error response rather than also testing for the existence of a response at all. Custom additions require the new identifier to be registered using a repurposed TranslateTranslationAid hook in addition to the obvious addition to the base list when overriding the base class. Also, expose the group-type via Tux to allow for usable hook runs (it is already exposed in the default interface). _autoload.php and hooks.txt updated accordingly. Change-Id: Ifb0a2d510487bb5f888930a824d227f1ae6d50b2 --- M _autoload.php M api/ApiQueryTranslationAids.php M hooks.txt M messagegroups/MessageGroup.php M messagegroups/MessageGroupBase.php M messagegroups/MessageGroupOld.php M resources/js/ext.translate.editor.helpers.js M translationaids/TranslationAid.php A translationaids/UnsupportedTranslationAid.php M utils/TuxMessageTable.php 10 files changed, 69 insertions(+), 5 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/Translate refs/changes/22/56622/1 diff --git a/_autoload.php b/_autoload.php index 5788ec1..f999050 100644 --- a/_autoload.php +++ b/_autoload.php @@ -265,6 +265,7 @@ $wgAutoloadClasses['SupportAid'] = "$dir/translationaids/SupportAid.php"; $wgAutoloadClasses['TTMServerAid'] = "$dir/translationaids/TTMServerAid.php"; $wgAutoloadClasses['TranslationAid'] = "$dir/translationaids/TranslationAid.php"; +$wgAutoloadClasses['UnsupportedTranslationAid'] = "$dir/translationaids/UnsupportedTranslationAid.php"; $wgAutoloadClasses['UpdatedDefinitionAid'] = "$dir/translationaids/UpdatedDefinitionAid.php"; /**@}*/ diff --git a/api/ApiQueryTranslationAids.php b/api/ApiQueryTranslationAids.php index 392b687..e61030d 100644 --- a/api/ApiQueryTranslationAids.php +++ b/api/ApiQueryTranslationAids.php @@ -42,9 +42,12 @@ $props = $params['prop']; - $types = TranslationAid::getTypes(); + $types = $group->getTranslationAids(); $result = $this->getResult(); foreach ( $props as $type ) { + // Do not continue if not supported for this message group + if( !isset( $types[$type] ) ) continue; + $start = microtime( true ); $class = $types[$type]; $obj = new $class( $group, $handle, $this ); @@ -70,6 +73,7 @@ public function getAllowedParams() { $props = array_keys( TranslationAid::getTypes() ); + wfRunHooks( 'TranslateTranslationAids', array( &$props ) ); return array( 'title' => array( diff --git a/hooks.txt b/hooks.txt index 081402a..52894d5 100644 --- a/hooks.txt +++ b/hooks.txt @@ -142,8 +142,8 @@ array &$list: List of languages indexed by language code string $language: Language code of the language of which language names are in -;TranslateTranslationAids: Allows adding (and removing) new translation aids - array &$types: List of translation aid classes indexed by type identifier +;TranslateTranslationAids: Allows adding new translation aids + array &$types: List of translation aid indentifiers, numerically indexed === JavaScript events === @@ -155,3 +155,7 @@ ;beforeSubmit: Provides an opportunity to modify a Translate translation form immediately before it is submitted jQuery form: The form being submitted + +;showTranslationHelpers: Provides an opportunity to handle custom translation helpers + objectresult.helpers: JSON subset focussing on the helpers returned e.g. result.helpers.definition + jQuerytranslateEditor.$editor: The current translation-editing form diff --git a/messagegroups/MessageGroup.php b/messagegroups/MessageGroup.php index f75cdb0..149a6fe 100644 --- a/messagegroups/MessageGroup.php +++ b/messagegroups/MessageGroup.php @@ -161,4 +161,12 @@ * @return array|null The language codes as array keys. */ public function getTranslatableLanguages(); + + /** +* List of available message types mapped to the classes +* implementing them. +* +* @return array +*/ + public f
[MediaWiki-commits] [Gerrit] Readd formatMessageBeforeTable hook - change (mediawiki...Translate)
Jarry1250 has uploaded a new change for review. https://gerrit.wikimedia.org/r/56882 Change subject: Readd formatMessageBeforeTable hook .. Readd formatMessageBeforeTable hook The hook has a PHP variant in MessageTable.php, but that is not replicated in TUX at the moment. Includes documentation. Change-Id: I1080132bf5c85d70722bddf8fc977db8c41dc3dd --- M hooks.txt M resources/js/ext.translate.messagetable.js 2 files changed, 6 insertions(+), 0 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/Translate refs/changes/82/56882/1 diff --git a/hooks.txt b/hooks.txt index 52894d5..77094a2 100644 --- a/hooks.txt +++ b/hooks.txt @@ -156,6 +156,9 @@ ;beforeSubmit: Provides an opportunity to modify a Translate translation form immediately before it is submitted jQuery form: The form being submitted +;formatMessageBeforeTable: Provides an opportunity to manipulate the display of translation strings (messages) in the main table + object message: The message object, with a range of useful (and manipulable) properties + ;showTranslationHelpers: Provides an opportunity to handle custom translation helpers objectresult.helpers: JSON subset focussing on the helpers returned e.g. result.helpers.definition jQuerytranslateEditor.$editor: The current translation-editing form diff --git a/resources/js/ext.translate.messagetable.js b/resources/js/ext.translate.messagetable.js index 7d223b4..bd9232f 100644 --- a/resources/js/ext.translate.messagetable.js +++ b/resources/js/ext.translate.messagetable.js @@ -126,6 +126,9 @@ add: function ( message ) { var $message; + // Prepare the message for display + mw.translateHooks.run( 'formatMessageBeforeTable', message ); + if ( this.mode === 'translate' ) { this.addTranslate( message ); -- To view, visit https://gerrit.wikimedia.org/r/56882 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I1080132bf5c85d70722bddf8fc977db8c41dc3dd Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/Translate Gerrit-Branch: master Gerrit-Owner: Jarry1250 ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Update thumb.php to handle "langXX"-type thumbnail names - change (mediawiki/core)
Jarry1250 has uploaded a new change for review. https://gerrit.wikimedia.org/r/69019 Change subject: Update thumb.php to handle "langXX"-type thumbnail names .. Update thumb.php to handle "langXX"-type thumbnail names See changeset #25838 for the introduction of that type, rationale, etc. See also bug #49629 for why we may want to abandon this approach at some point (probably not now though). Tested locally. Change-Id: I3e703c84ff84e30d8b96acf491318829767eb2ab --- M thumb.php 1 file changed, 4 insertions(+), 0 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/core refs/changes/19/69019/1 diff --git a/thumb.php b/thumb.php index 4a0c9fb..f171ac9 100644 --- a/thumb.php +++ b/thumb.php @@ -330,6 +330,10 @@ $params['page'] = $pagenum; } return $params; // valid thumbnail URL + } elseif ( preg_match( '!^lang([a-z]+(?:-[a-z]+)*)-(\d*)px-[^/]*$!', $thumbname, $matches ) ) { + $params['lang'] = $matches[1]; + $params['width'] = array_pop( $matches ); + return $params; // valid thumbnail URL } return null; // not a valid thumbnail URL -- To view, visit https://gerrit.wikimedia.org/r/69019 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I3e703c84ff84e30d8b96acf491318829767eb2ab Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/core Gerrit-Branch: master Gerrit-Owner: Jarry1250 ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Move dependency on ext.translateHooks to base module - change (mediawiki...Translate)
Jarry1250 has uploaded a new change for review. https://gerrit.wikimedia.org/r/65338 Change subject: Move dependency on ext.translateHooks to base module .. Move dependency on ext.translateHooks to base module The dependency needs to be migrated to allow hooks to be used with "new" JavaScript. Given the expansion in the use of hooks, it is probably prudent to move it to be a base dependency now, at minimal performance cost. Change-Id: I8e4781852d328732813937831e9de558d7820b4d --- M Resources.php 1 file changed, 1 insertion(+), 1 deletion(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/Translate refs/changes/38/65338/1 diff --git a/Resources.php b/Resources.php index aa3bd2c..dfe8d8a 100644 --- a/Resources.php +++ b/Resources.php @@ -21,6 +21,7 @@ 'dependencies' => array( 'mediawiki.util', 'mediawiki.api', + 'ext.translate.hooks' ), 'messages' => array( 'translate-js-support-unsaved-warning', @@ -209,7 +210,6 @@ 'styles' => 'resources/css/ext.translate.quickedit.css', 'messages' => array( 'translate-js-nonext', 'translate-js-save-failed' ), 'dependencies' => array( - 'ext.translate.hooks', 'jquery.form', 'jquery.ui.dialog', 'jquery.autoresize', -- To view, visit https://gerrit.wikimedia.org/r/65338 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I8e4781852d328732813937831e9de558d7820b4d Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/Translate Gerrit-Branch: master Gerrit-Owner: Jarry1250 Gerrit-Reviewer: jenkins-bot ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Reimplement beforeSubmit, afterSubmit and afterRegisterFeatu... - change (mediawiki...Translate)
Jarry1250 has uploaded a new change for review. https://gerrit.wikimedia.org/r/65339 Change subject: Reimplement beforeSubmit, afterSubmit and afterRegisterFeatures hooks .. Reimplement beforeSubmit, afterSubmit and afterRegisterFeatures hooks All three were present in pre- but not post-TUX JavaScript. Here, they are recreated in a backwards-friendly way. Change-Id: Ieae2148dfe2cd1b2e3005683c6e4b1eec3afb263 --- M resources/js/ext.translate.editor.helpers.js M resources/js/ext.translate.editor.js 2 files changed, 5 insertions(+), 2 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/Translate refs/changes/39/65339/1 diff --git a/resources/js/ext.translate.editor.helpers.js b/resources/js/ext.translate.editor.helpers.js index d7d0a5f..98a42f7 100644 --- a/resources/js/ext.translate.editor.helpers.js +++ b/resources/js/ext.translate.editor.helpers.js @@ -444,6 +444,7 @@ translateEditor.showSupportOptions( result.helpers.support ); translateEditor.addDefinitionDiff( result.helpers.definitiondiff ); mw.translateHooks.run( 'showTranslationHelpers', result.helpers, translateEditor.$editor ); + mw.translateHooks.run( 'afterRegisterFeatures', translateEditor.$editor ); } ).fail( function ( errorCode, results ) { mw.log( 'Error loading translation aids ' + errorCode + results.error.info ); diff --git a/resources/js/ext.translate.editor.js b/resources/js/ext.translate.editor.js index ed130fe..110b780 100644 --- a/resources/js/ext.translate.editor.js +++ b/resources/js/ext.translate.editor.js @@ -115,9 +115,10 @@ */ save: function () { var translateEditor = this, - api = new mw.Api(), - translation = translateEditor.$editor.find( '.editcolumn textarea' ).val(); + api = new mw.Api(); + mw.translateHooks.run( 'beforeSubmit', translateEditor.$editor ); + var translation = translateEditor.$editor.find( '.editcolumn textarea' ).val(); translateEditor.saving = true; // beforeSave callback @@ -162,6 +163,7 @@ } mw.translate.dirty = false; + mw.translateHooks.run( 'afterSubmit', translateEditor.$editor ); } ).fail( function ( errorCode, results ) { translateEditor.savingError( results.error.info ); -- To view, visit https://gerrit.wikimedia.org/r/65339 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: Ieae2148dfe2cd1b2e3005683c6e4b1eec3afb263 Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/Translate Gerrit-Branch: master Gerrit-Owner: Jarry1250 Gerrit-Reviewer: jenkins-bot ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Tweak file handling code, particularly to improve performance - change (mediawiki...TranslateSvg)
Jarry1250 has uploaded a new change for review. https://gerrit.wikimedia.org/r/65458 Change subject: Tweak file handling code, particularly to improve performance .. Tweak file handling code, particularly to improve performance Tidy up variables and use $this->getBackend()->fileExists() to avoid regenerating files that already exist. Could be annoying in the event of a hash collision (probability 2.8e14, so I'm not too concerned). Should significant improve performance for some kinds of edits. Change-Id: I2b43823c295a1e70084771704997ee9351230ee5 --- M SVGFormatWriter.php 1 file changed, 14 insertions(+), 4 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/TranslateSvg refs/changes/58/65458/1 diff --git a/SVGFormatWriter.php b/SVGFormatWriter.php index 04362f7..ebecadd 100644 --- a/SVGFormatWriter.php +++ b/SVGFormatWriter.php @@ -66,7 +66,17 @@ $nameHash = md5( $this->filename ); $nameHashPath = substr( $nameHash, 0, 1 ) . '/' . substr( $nameHash, 0, 2 ); $dstPath = $this->getBackend()->getRootStoragePath() . - '/translatesvg-render/' . "$nameHashPath/"; + '/translatesvg-render/'; + $dstName = "$nameHashPath/$contentsHash-" . $this->filename . '.png'; + $dstUrl = $wgTranslateSvgPath . '/' . $dstName; + + if( $this->getBackend()->fileExists( array( 'src' => $dstPath . $dstName ) ) ) { + // We've already generated this SVG; no point regenerating + return array( + 'success' => true, + 'message' => $dstUrl, + ); + } // Save the SVG to a temporary file if( !$svg->save( $srcPath ) ) { @@ -94,19 +104,19 @@ // Create any containers/directories as needed... $backend = $this->getBackend(); - if ( !$backend->prepare( array( 'dir' => $dstPath ) )->isOK() ) { + if ( !$backend->prepare( array( 'dir' => "$dstPath/$nameHashPath/" ) )->isOK() ) { return array( 'success' => false, 'message' => wfMessage( 'thumbnail_dest_directory' )->text()); } // Store the file at the final storage path... if ( !$backend->quickStore( array( - 'src' => $intPath, 'dst' => "$dstPath$contentsHash-" . $this->filename . '.png' + 'src' => $intPath, 'dst' => $dstPath . $dstName ) )->isOK() ) { return array( 'success' => false, 'message' => wfMessage( 'thumbnail-dest-create' )->text() ); } return array( 'success' => true, - 'message' => $wgTranslateSvgPath . '/' . $nameHashPath . "/$contentsHash-" . $this->filename . '.png' + 'message' => $dstUrl ); } -- To view, visit https://gerrit.wikimedia.org/r/65458 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I2b43823c295a1e70084771704997ee9351230ee5 Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/TranslateSvg Gerrit-Branch: master Gerrit-Owner: Jarry1250 ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Support non-duplicative sublocales (pt_BR, en_GB, etc.) - change (mediawiki...TranslateSvg)
Jarry1250 has uploaded a new change for review. https://gerrit.wikimedia.org/r/65460 Change subject: Support non-duplicative sublocales (pt_BR, en_GB, etc.) .. Support non-duplicative sublocales (pt_BR, en_GB, etc.) Two parts: (1) Read support (2) Write support Write support relies on rewriting pt-br to pt_BR and sorting it to the top of the switch (as it is intended to be more specific than pt). Read support is simply a case of rewriting pt_BR to pt-br. Broken if a manual edit has introduced pt_PT, en_US system languages -- because Translate doesn't understand that "en-us" and "en" are synonymous. Change-Id: Ic274351887bd0f72b33a9437e2b23ffae4ce3fb9 --- M SVGFormatReader.php 1 file changed, 12 insertions(+), 1 deletion(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/TranslateSvg refs/changes/60/65460/1 diff --git a/SVGFormatReader.php b/SVGFormatReader.php index c25696a..a161324 100644 --- a/SVGFormatReader.php +++ b/SVGFormatReader.php @@ -324,6 +324,10 @@ foreach( $translations[$textId] as $language => $translation ) { // Sort out systemLanguage attribute if( $language !== 'fallback' ) { + if ( strpos( $language, '-' ) !== false ) { + list( $before, $after ) = explode( '-', $language ); + $language = $before . '_' . strtoupper( $after ); + } $translation['systemLanguage'] = $language; } @@ -370,7 +374,13 @@ } } } - + // Move sublocales to the beginning of their switch elements + $sublocales = $this->xpath->query("//text[contains(@systemLanguage,'_')]|//svg:text[contains(@systemLanguage,'_')]"); + $count = $sublocales->length; + for( $i = 0; $i < $count; $i++ ) { + $firstSibling = $sublocales->item( $i )->parentNode->childNodes->item( 0 ); + $sublocales->item( $i )->parentNode->insertBefore( $sublocales->item( $i ), $firstSibling ); + } // Move fallbacks to the end of their switch elements $fallbacks = $this->xpath->query("//text[not(@systemLanguage)]|//svg:text[not(@systemLanguage)]"); $count = $fallbacks->length; @@ -424,6 +434,7 @@ $numChildren = $text->childNodes->length; $hasActualTextContent = TranslateSvgUtils::hasActualTextContent( $text ); $lang = $text->hasAttribute( 'systemLanguage' ) ? $text->getAttribute( 'systemLanguage' ) : 'fallback'; + $lang = str_replace( '_', '-', strtolower( $lang ) ); $counter = 1; for( $k = 0; $k < $numChildren; $k++ ) { $child = $text->childNodes->item( $k ); -- To view, visit https://gerrit.wikimedia.org/r/65460 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: Ic274351887bd0f72b33a9437e2b23ffae4ce3fb9 Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/TranslateSvg Gerrit-Branch: master Gerrit-Owner: Jarry1250 ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Upgrade TranslateSvg for use with TUX - change (mediawiki...TranslateSvg)
Jarry1250 has uploaded a new change for review. https://gerrit.wikimedia.org/r/65462 Change subject: Upgrade TranslateSvg for use with TUX .. Upgrade TranslateSvg for use with TUX Add two translation aids (properties and thumbnail) in PHP and JS. Rewrite JavaScript to take account of new class names, ids, structures, etc. Fix task management, which seems to be associated. Change-Id: I3b638a98c1ecfe85cf3a95367744856b162cf50d --- A PropertiesTranslationAid.php M SVGMessageGroup.php A ThumbnailTranslationAid.php M TranslateSvg.php M TranslateSvgHooks.php M resources/ext.translatesvg.core.js 6 files changed, 149 insertions(+), 14 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/TranslateSvg refs/changes/62/65462/1 diff --git a/PropertiesTranslationAid.php b/PropertiesTranslationAid.php new file mode 100644 index 000..4fbde26 --- /dev/null +++ b/PropertiesTranslationAid.php @@ -0,0 +1,35 @@ +http://www.gnu.org/copyleft/gpl.html GNU General Public License 2.0 or later + */ + +/** + * Translation aid which gives the original SVG thumnail where the QQQ documentation would otherwise go. + * It is later updated dynamically using JavaScript + * + * @ingroup TranslationAids + * @since 2013-01-01 + */ +class PropertiesTranslationAid extends TranslationAid { + public function getData() { + $title = $this->handle->getTitle(); + $translation = TranslateUtils::getMessageContent( + $this->handle->getKey(), + $this->handle->getCode(), + $title->getNamespace() + ); + + // As long as we have to code for both interfaces in parallel I reserve the right to do this + $result = ""; + TranslateSvgHooks::getDefaultPropertiesFromGroup( $translation, $this->handle ); + TranslateSvgHooks::propertiesToExtraInputs( $translation, $result ); + return array( + 'html' => $result + ); + } +} diff --git a/SVGMessageGroup.php b/SVGMessageGroup.php index 3ee90e6..d8c47c1 100644 --- a/SVGMessageGroup.php +++ b/SVGMessageGroup.php @@ -194,4 +194,23 @@ } return $languages; } + + public function getTranslationAids() { + // TODO: translation hinting for non-template portion + $aids = array( + 'properties' => 'PropertiesTranslationAid', + 'thumbnail' => 'ThumbnailTranslationAid', + 'definition' => 'MessageDefinitionAid', + 'translation' => 'CurrentTranslationAid', + 'inotherlanguages' => 'InOtherLanguagesAid', + + 'documentation' => 'UnsupportedTranslationAid', + 'mt' => 'UnsupportedTranslationAid', + 'definitiondiff' => 'UnsupportedTranslationAid', + 'ttmserver' => 'UnsupportedTranslationAid', + 'support' => 'UnsupportedTranslationAid', + 'gettext' => 'UnsupportedTranslationAid', + ); + return $aids; + } } diff --git a/ThumbnailTranslationAid.php b/ThumbnailTranslationAid.php new file mode 100644 index 000..52a4de8 --- /dev/null +++ b/ThumbnailTranslationAid.php @@ -0,0 +1,31 @@ +http://www.gnu.org/copyleft/gpl.html GNU General Public License 2.0 or later + */ + +/** + * Translation aid which gives the original SVG thumnail where the QQQ documentation would otherwise go. + * It is later updated dynamically using JavaScript + * + * @ingroup TranslationAids + * @since 2013-01-01 + */ +class ThumbnailTranslationAid extends TranslationAid { + public function getData() { + global $wgContLang; + $language = $this->handle->getCode(); + $key = $this->handle->getKey(); + list( $filename, ) = explode( '/', $key ); + $prefixedFilename = $wgContLang->getNsText( NS_FILE ) . ':' . $filename; + $desc = "[[$prefixedFilename|frameless|center|upright|lang=$language|275x275px]]"; + return array( + 'value' => $desc, + 'html' => '' . $this->context->getOutput()->parse( $desc ) .'', + ); + } +} diff --git a/TranslateSvg.php b/TranslateSvg.php index 99bb2db..ac5c4ec 100644 --- a/TranslateSvg.php +++ b/TranslateSvg.php @@ -17,6 +17,7 @@ ); $dir = dirname( __FILE__ ) . '/'; +$wgAutoloadClasses['PropertiesTranslationAid'] = $dir . 'PropertiesTranslationAid.php'; $wgAutoloadClasses['SpecialTranslateNewSVG'] = $dir . 'SpecialTranslateNewSVG.php'; $wgAutoloadClasses['SVGFormatReader'] = $dir . 'SVGFormatReader.php'; $wgAutoloadClasses['SVGFormatWriter'] = $dir . 'SVGFormatWriter.php'; @@ -25,7 +26,9 @@ $wgAutoloa
[MediaWiki-commits] [Gerrit] Add loading spinner and tweak display time. - change (mediawiki...TranslateSvg)
Jarry1250 has uploaded a new change for review. https://gerrit.wikimedia.org/r/65464 Change subject: Add loading spinner and tweak display time. .. Add loading spinner and tweak display time. Uses jquery.spinner methods. Change-Id: I3e63f6cf3e0cdc2ececdbf5fec8558d69eef71fc --- M TranslateSvg.php M resources/ext.translatesvg.core.js 2 files changed, 16 insertions(+), 1 deletion(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/TranslateSvg refs/changes/64/65464/1 diff --git a/TranslateSvg.php b/TranslateSvg.php index 6926573..f714961 100644 --- a/TranslateSvg.php +++ b/TranslateSvg.php @@ -45,6 +45,7 @@ 'jquery.autoresize', 'jquery.colorpicker', 'jquery.json', + 'jquery.spinner', 'ext.translate.hooks', 'ext.translate.editor' ), diff --git a/resources/ext.translatesvg.core.js b/resources/ext.translatesvg.core.js index 1a40cfb..91b9372 100644 --- a/resources/ext.translatesvg.core.js +++ b/resources/ext.translatesvg.core.js @@ -122,7 +122,7 @@ // than 5 times a second window.clearTimeout( tsvgLoader.updateThumbnailTimer ); tsvgLoader.updateThumbnailTimer = window.setTimeout( - function () { tsvgLoader.updateThumbnail($form) }, 200 + function () { tsvgLoader.updateThumbnail( $form ) }, 300 ); }, updateThumbnail: function ( $form ) { @@ -140,6 +140,11 @@ return; } var identifiers = name.split( '/' ); + + // Inform the user we are working + $thumbnail.find( 'div.center' ).first().hide(); + $thumbnail.append( $.createSpinner( { 'id': 'translatesvg-' + identifiers[2], 'size': 'large' } ) ); + $( '.mw-spinner' ).css( 'margin', 'auto' ).css( 'display', 'block' ); // Create and set overrides[identifier][langcode] var overrideValue = $textarea.val() + tsvgLoader.propertiesToString( $form ); @@ -164,8 +169,17 @@ var newSrc = data.query.messagegroups[0].thumbnail.message; $thumbnail.find('img').attr( 'src', newSrc ); } + window.setTimeout( + function () { tsvgLoader.hideSpinner( $thumbnail, identifiers[2] ) }, 500 + ); } } ); + }, + hideSpinner: function ( $thumbnail, id ) { + // Hide a spinner after a delay to ensure that the system has redrawn the SVG + // before it gets shown. + $thumbnail.find( 'div.center' ).first().show(); + $.removeSpinner( 'translatesvg-' + id ); } }; $( document ).ready( function () { -- To view, visit https://gerrit.wikimedia.org/r/65464 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I3e63f6cf3e0cdc2ececdbf5fec8558d69eef71fc Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/TranslateSvg Gerrit-Branch: master Gerrit-Owner: Jarry1250 ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Tidy and miscellaneous bugfix - change (mediawiki...TranslateSvg)
Jarry1250 has uploaded a new change for review. https://gerrit.wikimedia.org/r/65466 Change subject: Tidy and miscellaneous bugfix .. Tidy and miscellaneous bugfix Change-Id: I262c6e1d05383657fec34de61cfa85288ed21449 --- M SVGFormatWriter.php M TranslateSvg.php M TranslateSvgTasks.php 3 files changed, 1 insertion(+), 5 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/TranslateSvg refs/changes/66/65466/1 diff --git a/SVGFormatWriter.php b/SVGFormatWriter.php index ebecadd..f8d03c4 100644 --- a/SVGFormatWriter.php +++ b/SVGFormatWriter.php @@ -168,9 +168,6 @@ return $this->processVerificationError( $details ); } - // URL needed later for redirect to file description page - $this->url = $uploader->getLocalFile()->getTitle()->getFullURL(); - // Actually perform upload $bot = User::newFromName( $wgTranslateSvgBotName, false ); $status = $uploader->performUpload( $comment, false, false, $bot ); diff --git a/TranslateSvg.php b/TranslateSvg.php index f714961..6b8f219 100644 --- a/TranslateSvg.php +++ b/TranslateSvg.php @@ -42,7 +42,6 @@ 'dependencies' => array( 'jquery.form', 'jquery.ui.dialog', - 'jquery.autoresize', 'jquery.colorpicker', 'jquery.json', 'jquery.spinner', diff --git a/TranslateSvgTasks.php b/TranslateSvgTasks.php index 4b9b076..3ca90b6 100644 --- a/TranslateSvgTasks.php +++ b/TranslateSvgTasks.php @@ -25,7 +25,7 @@ } /** @var SVGFormatWriter $writer */ - $writer = $this->group->getWriter(); + $writer = new SVGFormatWriter( $this->group ); $ret = $writer->exportToSVG( $this->context->getUser() ); if( $ret === true ) { global $wgOut; -- To view, visit https://gerrit.wikimedia.org/r/65466 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I262c6e1d05383657fec34de61cfa85288ed21449 Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/TranslateSvg Gerrit-Branch: master Gerrit-Owner: Jarry1250 ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Support non-duplicative sublocales (pt_BR, en_GB, etc.) - change (mediawiki...TranslateSvg)
Jarry1250 has submitted this change and it was merged. Change subject: Support non-duplicative sublocales (pt_BR, en_GB, etc.) .. Support non-duplicative sublocales (pt_BR, en_GB, etc.) Two parts: (1) Read support (2) Write support Write support relies on rewriting pt-br to pt_BR and sorting it to the top of the switch (as it is intended to be more specific than pt). Read support is simply a case of rewriting pt_BR to pt-br. Broken if a manual edit has introduced pt_PT, en_US system languages -- because Translate doesn't understand that "en-us" and "en" are synonymous. Change-Id: Ic274351887bd0f72b33a9437e2b23ffae4ce3fb9 --- M SVGFormatReader.php 1 file changed, 17 insertions(+), 2 deletions(-) Approvals: Jarry1250: Verified; Looks good to me, approved diff --git a/SVGFormatReader.php b/SVGFormatReader.php index c25696a..d9616d2 100644 --- a/SVGFormatReader.php +++ b/SVGFormatReader.php @@ -324,6 +324,10 @@ foreach( $translations[$textId] as $language => $translation ) { // Sort out systemLanguage attribute if( $language !== 'fallback' ) { + if ( strpos( $language, '-' ) !== false ) { + list( $before, $after ) = explode( '-', $language ); + $language = $before . '_' . strtoupper( $after ); + } $translation['systemLanguage'] = $language; } @@ -370,9 +374,19 @@ } } } - + // Move sublocales to the beginning of their switch elements + $sublocales = $this->xpath->query( + "//text[contains(@systemLanguage,'_')]" . "|" . "//svg:text[contains(@systemLanguage,'_')]" + ); + $count = $sublocales->length; + for( $i = 0; $i < $count; $i++ ) { + $firstSibling = $sublocales->item( $i )->parentNode->childNodes->item( 0 ); + $sublocales->item( $i )->parentNode->insertBefore( $sublocales->item( $i ), $firstSibling ); + } // Move fallbacks to the end of their switch elements - $fallbacks = $this->xpath->query("//text[not(@systemLanguage)]|//svg:text[not(@systemLanguage)]"); + $fallbacks = $this->xpath->query( + "//text[not(@systemLanguage)]" . "|" . "//svg:text[not(@systemLanguage)]" + ); $count = $fallbacks->length; for( $i = 0; $i < $count; $i++ ) { $fallbacks->item( $i )->parentNode->appendChild( $fallbacks->item( $i ) ); @@ -424,6 +438,7 @@ $numChildren = $text->childNodes->length; $hasActualTextContent = TranslateSvgUtils::hasActualTextContent( $text ); $lang = $text->hasAttribute( 'systemLanguage' ) ? $text->getAttribute( 'systemLanguage' ) : 'fallback'; + $lang = str_replace( '_', '-', strtolower( $lang ) ); $counter = 1; for( $k = 0; $k < $numChildren; $k++ ) { $child = $text->childNodes->item( $k ); -- To view, visit https://gerrit.wikimedia.org/r/65460 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: Ic274351887bd0f72b33a9437e2b23ffae4ce3fb9 Gerrit-PatchSet: 2 Gerrit-Project: mediawiki/extensions/TranslateSvg Gerrit-Branch: master Gerrit-Owner: Jarry1250 Gerrit-Reviewer: Anomie Gerrit-Reviewer: Jarry1250 ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Add and use wgFileTranslationStarted to improve user experience - change (mediawiki...TranslateSvg)
Jarry1250 has uploaded a new change for review. https://gerrit.wikimedia.org/r/65628 Change subject: Add and use wgFileTranslationStarted to improve user experience .. Add and use wgFileTranslationStarted to improve user experience Change-Id: I2cf619f5dc24d7f57ee372dcb4a1b9c662ce779c --- M TranslateSvgHooks.php M resources/ext.translatesvg.filepage.js 2 files changed, 13 insertions(+), 6 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/TranslateSvg refs/changes/28/65628/1 diff --git a/TranslateSvgHooks.php b/TranslateSvgHooks.php index a81a9ff..aff094a 100644 --- a/TranslateSvgHooks.php +++ b/TranslateSvgHooks.php @@ -409,8 +409,9 @@ $messageGroup = new SVGMessageGroup( $id ); $reader = new SVGFormatReader( $messageGroup ); $vars['wgFileCanBeTranslated'] = ( $reader !== null ); - if( !$vars['wgFileCanBeTranslated'] || !MessageGroups::getGroup( $id ) ) { + if( !$vars['wgFileCanBeTranslated'] || MessageGroups::getGroup( $id ) === null ) { // Not translatable or not yet translated, let's save time and return immediately + $vars['wgFileTranslationStarted'] = false; $vars['wgFileFullTranslations'] = array(); $vars['wgFilePartialTranslations'] = array(); return true; @@ -433,6 +434,7 @@ } $vars['wgFileFullTranslations'] = $full; $vars['wgFilePartialTranslations'] = $partial; + $vars['wgFileTranslationStarted'] = true; return true; } } diff --git a/resources/ext.translatesvg.filepage.js b/resources/ext.translatesvg.filepage.js index 3e1e7b1..f61bc59 100644 --- a/resources/ext.translatesvg.filepage.js +++ b/resources/ext.translatesvg.filepage.js @@ -19,6 +19,7 @@ return; } + var translationStarted = mw.config.get( 'wgFileTranslationStarted' ); var full = mw.config.get( 'wgFileFullTranslations' ); var partial = mw.config.get( 'wgFilePartialTranslations' ); @@ -26,15 +27,19 @@ // other wikis. var parent = ( $( 'p.SVGThumbs' ).length > 0 ) ? $( 'p.SVGThumbs' ) : $( 'div.fullMedia' ); - if ( full.length === 0 && partial.length === 0 ) { + if ( !translationStarted ) { if ( mw.config.get( 'wgFileCanBeTranslated' ) && mw.config.get( 'wgUserCanTranslate' ) ) { - // No existing translations, can't translate - // TODO: suggest "log in to translate"? + // No existing translations, can translate + // TODO: suggest "log in to translate" if not? parent.append( '' + this.getNoTranslationsString() ); } } else { - // Existing translations, show view link and/or translate links - parent.append( '' + this.getHasTranslationsString( full, partial ) ); + if ( full.length > 0 || partial.length > 0 ) { + // Existing translations, show view link and/or translate links + parent.append( '' + this.getHasTranslationsString( full, partial ) ); + } else { + // TODO: Awkward + } } }, -- To view, visit https://gerrit.wikimedia.org/r/65628 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I2cf619f5dc24d7f57ee372dcb4a1b9c662ce779c Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/TranslateSvg Gerrit-Branch: master Gerrit-Owner: Jarry1250 ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Add and use wgFileTranslationStarted to improve user experience - change (mediawiki...TranslateSvg)
Jarry1250 has submitted this change and it was merged. Change subject: Add and use wgFileTranslationStarted to improve user experience .. Add and use wgFileTranslationStarted to improve user experience Change-Id: I2cf619f5dc24d7f57ee372dcb4a1b9c662ce779c --- M TranslateSvgHooks.php M resources/ext.translatesvg.filepage.js 2 files changed, 13 insertions(+), 6 deletions(-) Approvals: Jarry1250: Verified; Looks good to me, approved diff --git a/TranslateSvgHooks.php b/TranslateSvgHooks.php index a81a9ff..aff094a 100644 --- a/TranslateSvgHooks.php +++ b/TranslateSvgHooks.php @@ -409,8 +409,9 @@ $messageGroup = new SVGMessageGroup( $id ); $reader = new SVGFormatReader( $messageGroup ); $vars['wgFileCanBeTranslated'] = ( $reader !== null ); - if( !$vars['wgFileCanBeTranslated'] || !MessageGroups::getGroup( $id ) ) { + if( !$vars['wgFileCanBeTranslated'] || MessageGroups::getGroup( $id ) === null ) { // Not translatable or not yet translated, let's save time and return immediately + $vars['wgFileTranslationStarted'] = false; $vars['wgFileFullTranslations'] = array(); $vars['wgFilePartialTranslations'] = array(); return true; @@ -433,6 +434,7 @@ } $vars['wgFileFullTranslations'] = $full; $vars['wgFilePartialTranslations'] = $partial; + $vars['wgFileTranslationStarted'] = true; return true; } } diff --git a/resources/ext.translatesvg.filepage.js b/resources/ext.translatesvg.filepage.js index 3e1e7b1..f61bc59 100644 --- a/resources/ext.translatesvg.filepage.js +++ b/resources/ext.translatesvg.filepage.js @@ -19,6 +19,7 @@ return; } + var translationStarted = mw.config.get( 'wgFileTranslationStarted' ); var full = mw.config.get( 'wgFileFullTranslations' ); var partial = mw.config.get( 'wgFilePartialTranslations' ); @@ -26,15 +27,19 @@ // other wikis. var parent = ( $( 'p.SVGThumbs' ).length > 0 ) ? $( 'p.SVGThumbs' ) : $( 'div.fullMedia' ); - if ( full.length === 0 && partial.length === 0 ) { + if ( !translationStarted ) { if ( mw.config.get( 'wgFileCanBeTranslated' ) && mw.config.get( 'wgUserCanTranslate' ) ) { - // No existing translations, can't translate - // TODO: suggest "log in to translate"? + // No existing translations, can translate + // TODO: suggest "log in to translate" if not? parent.append( '' + this.getNoTranslationsString() ); } } else { - // Existing translations, show view link and/or translate links - parent.append( '' + this.getHasTranslationsString( full, partial ) ); + if ( full.length > 0 || partial.length > 0 ) { + // Existing translations, show view link and/or translate links + parent.append( '' + this.getHasTranslationsString( full, partial ) ); + } else { + // TODO: Awkward + } } }, -- To view, visit https://gerrit.wikimedia.org/r/65628 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: I2cf619f5dc24d7f57ee372dcb4a1b9c662ce779c Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/TranslateSvg Gerrit-Branch: master Gerrit-Owner: Jarry1250 Gerrit-Reviewer: Jarry1250 ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Tweak file handling code, particularly to improve performance - change (mediawiki...TranslateSvg)
Jarry1250 has submitted this change and it was merged. Change subject: Tweak file handling code, particularly to improve performance .. Tweak file handling code, particularly to improve performance Tidy up variables and use $this->getBackend()->fileExists() to avoid regenerating files that already exist. Could be annoying in the event of a hash collision (probability 2.8e14, so I'm not too concerned). Should significant improve performance for some kinds of edits. Change-Id: I2b43823c295a1e70084771704997ee9351230ee5 --- M SVGFormatWriter.php 1 file changed, 14 insertions(+), 4 deletions(-) Approvals: Aaron Schulz: Looks good to me, approved Nikerabbit: Looks good to me, but someone else must approve Jarry1250: Verified; Looks good to me, approved diff --git a/SVGFormatWriter.php b/SVGFormatWriter.php index 04362f7..ebecadd 100644 --- a/SVGFormatWriter.php +++ b/SVGFormatWriter.php @@ -66,7 +66,17 @@ $nameHash = md5( $this->filename ); $nameHashPath = substr( $nameHash, 0, 1 ) . '/' . substr( $nameHash, 0, 2 ); $dstPath = $this->getBackend()->getRootStoragePath() . - '/translatesvg-render/' . "$nameHashPath/"; + '/translatesvg-render/'; + $dstName = "$nameHashPath/$contentsHash-" . $this->filename . '.png'; + $dstUrl = $wgTranslateSvgPath . '/' . $dstName; + + if( $this->getBackend()->fileExists( array( 'src' => $dstPath . $dstName ) ) ) { + // We've already generated this SVG; no point regenerating + return array( + 'success' => true, + 'message' => $dstUrl, + ); + } // Save the SVG to a temporary file if( !$svg->save( $srcPath ) ) { @@ -94,19 +104,19 @@ // Create any containers/directories as needed... $backend = $this->getBackend(); - if ( !$backend->prepare( array( 'dir' => $dstPath ) )->isOK() ) { + if ( !$backend->prepare( array( 'dir' => "$dstPath/$nameHashPath/" ) )->isOK() ) { return array( 'success' => false, 'message' => wfMessage( 'thumbnail_dest_directory' )->text()); } // Store the file at the final storage path... if ( !$backend->quickStore( array( - 'src' => $intPath, 'dst' => "$dstPath$contentsHash-" . $this->filename . '.png' + 'src' => $intPath, 'dst' => $dstPath . $dstName ) )->isOK() ) { return array( 'success' => false, 'message' => wfMessage( 'thumbnail-dest-create' )->text() ); } return array( 'success' => true, - 'message' => $wgTranslateSvgPath . '/' . $nameHashPath . "/$contentsHash-" . $this->filename . '.png' + 'message' => $dstUrl ); } -- To view, visit https://gerrit.wikimedia.org/r/65458 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: I2b43823c295a1e70084771704997ee9351230ee5 Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/TranslateSvg Gerrit-Branch: master Gerrit-Owner: Jarry1250 Gerrit-Reviewer: Aaron Schulz Gerrit-Reviewer: Jarry1250 Gerrit-Reviewer: Nikerabbit ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] (bug #43509) Special:Whatlinkshere pagination broken - change (mediawiki/core[master])
Jarry1250 has uploaded a new change for review. Change subject: (bug #43509) Special:Whatlinkshere pagination broken .. (bug #43509) Special:Whatlinkshere pagination broken Resolve by switching from a from/back system to an offset/dir system, as is already used on (e.g.) Special:Categories. Change-Id: Ibe30cac4c9bc89c9c91263c23861437894f1aeb1 --- M includes/specials/SpecialWhatlinkshere.php 1 file changed, 52 insertions(+), 26 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/core refs/changes/86/41386/1 -- To view, visit https://gerrit.wikimedia.org/r/41386 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: Ibe30cac4c9bc89c9c91263c23861437894f1aeb1 Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/core Gerrit-Branch: master Gerrit-Owner: Jarry1250 ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Add Special:TranslateNewSvg - change (mediawiki...TranslateSvg[master])
Jarry1250 has submitted this change and it was merged. Change subject: Add Special:TranslateNewSvg .. Add Special:TranslateNewSvg The special page allows user to select the source language, then "import" it (register it for translation). Change-Id: I90849cd3d696f549c15f826c6b7f18eb4b9aef0a --- A SpecialTranslateNewSVG.php M TranslateSvg.php M TranslateSvgHooks.php A sql/translate_svg.sql 4 files changed, 172 insertions(+), 3 deletions(-) Approvals: Jarry1250: Verified; Looks good to me, approved -- To view, visit https://gerrit.wikimedia.org/r/19767 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: I90849cd3d696f549c15f826c6b7f18eb4b9aef0a Gerrit-PatchSet: 11 Gerrit-Project: mediawiki/extensions/TranslateSvg Gerrit-Branch: master Gerrit-Owner: Jarry1250 Gerrit-Reviewer: Jarry1250 Gerrit-Reviewer: MaxSem Gerrit-Reviewer: Nikerabbit Gerrit-Reviewer: SPQRobin ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Followup I90849cd3: small logic fixes and improvements - change (mediawiki...TranslateSvg[master])
Jarry1250 has uploaded a new change for review. Change subject: Followup I90849cd3: small logic fixes and improvements .. Followup I90849cd3: small logic fixes and improvements Specifically, fix invocation of $dbr->select, avoid use of $wgTitle, fix permissions checking and the language default for the language selector. Change-Id: I6c54e12c8ec163b4ebf2ba321c39ff3ed7234d61 --- M SpecialTranslateNewSVG.php M TranslateSvgHooks.php 2 files changed, 12 insertions(+), 14 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/TranslateSvg refs/changes/58/41958/1 -- To view, visit https://gerrit.wikimedia.org/r/41958 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I6c54e12c8ec163b4ebf2ba321c39ff3ed7234d61 Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/TranslateSvg Gerrit-Branch: master Gerrit-Owner: Jarry1250 ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Followup I90849cd3: small logic fixes and improvements - change (mediawiki...TranslateSvg[master])
Jarry1250 has submitted this change and it was merged. Change subject: Followup I90849cd3: small logic fixes and improvements .. Followup I90849cd3: small logic fixes and improvements Specifically, fix invocation of $dbr->select, avoid use of $wgTitle, fix permissions checking and the language default for the language selector. Change-Id: I6c54e12c8ec163b4ebf2ba321c39ff3ed7234d61 --- M SpecialTranslateNewSVG.php M TranslateSvgHooks.php 2 files changed, 12 insertions(+), 14 deletions(-) Approvals: Jarry1250: Verified; Looks good to me, approved -- To view, visit https://gerrit.wikimedia.org/r/41958 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: I6c54e12c8ec163b4ebf2ba321c39ff3ed7234d61 Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/TranslateSvg Gerrit-Branch: master Gerrit-Owner: Jarry1250 Gerrit-Reviewer: Jarry1250 ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Add librsvg to contint puppet manifest - change (operations/puppet[production])
Jarry1250 has uploaded a new change for review. Change subject: Add librsvg to contint puppet manifest .. Add librsvg to contint puppet manifest Having librsvg on gallium and/or any other continuious integration servers allows SVGs to be used in unit tests. Change-Id: I74b9a095fc5e9335f450429e8b9f0483cc5c61d4 --- M manifests/misc/contint.pp 1 file changed, 1 insertion(+), 1 deletion(-) git pull ssh://gerrit.wikimedia.org:29418/operations/puppet refs/changes/83/36583/1 -- To view, visit https://gerrit.wikimedia.org/r/36583 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I74b9a095fc5e9335f450429e8b9f0483cc5c61d4 Gerrit-PatchSet: 1 Gerrit-Project: operations/puppet Gerrit-Branch: production Gerrit-Owner: Jarry1250 ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] (bug #19185) Don't display p-personal if it contains no link... - change (mediawiki/core[master])
Jarry1250 has uploaded a new change for review. Change subject: (bug #19185) Don't display p-personal if it contains no links. .. (bug #19185) Don't display p-personal if it contains no links. Also tidy up with the weird formatting of that foreach(). Change-Id: I9a4e6e00c521c8e941bb4eb8e6745cbea3e2f5b1 --- M skins/MonoBook.php 1 file changed, 5 insertions(+), 4 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/core refs/changes/24/37224/1 -- To view, visit https://gerrit.wikimedia.org/r/37224 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I9a4e6e00c521c8e941bb4eb8e6745cbea3e2f5b1 Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/core Gerrit-Branch: master Gerrit-Owner: Jarry1250 ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Rectify missing dependency on mediawiki.Uri - change (mediawiki...Translate[master])
Jarry1250 has uploaded a new change for review. Change subject: Rectify missing dependency on mediawiki.Uri .. Rectify missing dependency on mediawiki.Uri Change-Id: Ib39f8ed59e0626bb4c2a549338a018b080e89d4c --- M Translate.php 1 file changed, 1 insertion(+), 0 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/Translate refs/changes/27/37627/1 -- To view, visit https://gerrit.wikimedia.org/r/37627 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: Ib39f8ed59e0626bb4c2a549338a018b080e89d4c Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/Translate Gerrit-Branch: master Gerrit-Owner: Jarry1250 ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Fix simple but deadly logic error - change (mediawiki...TranslateSvg[master])
Jarry1250 has uploaded a new change for review. Change subject: Fix simple but deadly logic error .. Fix simple but deadly logic error Change-Id: I586bc8995f4016765991aa53ccd40f330aabd313 --- M TranslateSvgHooks.php 1 file changed, 1 insertion(+), 1 deletion(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/TranslateSvg refs/changes/29/37629/1 -- To view, visit https://gerrit.wikimedia.org/r/37629 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I586bc8995f4016765991aa53ccd40f330aabd313 Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/TranslateSvg Gerrit-Branch: master Gerrit-Owner: Jarry1250 ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Fix simple but deadly logic error - change (mediawiki...TranslateSvg[master])
Jarry1250 has submitted this change and it was merged. Change subject: Fix simple but deadly logic error .. Fix simple but deadly logic error Change-Id: I586bc8995f4016765991aa53ccd40f330aabd313 --- M TranslateSvgHooks.php 1 file changed, 1 insertion(+), 1 deletion(-) Approvals: Jarry1250: Verified; Looks good to me, approved -- To view, visit https://gerrit.wikimedia.org/r/37629 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: I586bc8995f4016765991aa53ccd40f330aabd313 Gerrit-PatchSet: 2 Gerrit-Project: mediawiki/extensions/TranslateSvg Gerrit-Branch: master Gerrit-Owner: Jarry1250 Gerrit-Reviewer: Jarry1250 ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] (bug #20789) What links here pager falsely says "No pages li... - change (mediawiki/core[master])
Jarry1250 has uploaded a new change for review. Change subject: (bug #20789) What links here pager falsely says "No pages link to" .. (bug #20789) What links here pager falsely says "No pages link to" Create some (4) new messages and use them to give the user more appropriate advice about how to proceed. Change-Id: Ia9cf83f07bb5629979268bdd45627f62e0d91454 --- M includes/specials/SpecialWhatlinkshere.php M languages/messages/MessagesEn.php M languages/messages/MessagesQqq.php 3 files changed, 21 insertions(+), 3 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/core refs/changes/85/37685/1 -- To view, visit https://gerrit.wikimedia.org/r/37685 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: Ia9cf83f07bb5629979268bdd45627f62e0d91454 Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/core Gerrit-Branch: master Gerrit-Owner: Jarry1250 ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Commit ExportSVGMessagesTask and SVGFormatWriter classes - change (mediawiki...TranslateSvg[master])
Jarry1250 has submitted this change and it was merged. Change subject: Commit ExportSVGMessagesTask and SVGFormatWriter classes .. Commit ExportSVGMessagesTask and SVGFormatWriter classes Together, these provide export functionality. Also, add hook that makes it the default export option Update Dec 2012: now uses FileBackend properly Change-Id: I934bdd1f798556e6529d9ee95a87134e70171044 --- A SVGFormatWriter.php M TranslateSvg.php M TranslateSvgHooks.php A TranslateSvgTasks.php 4 files changed, 322 insertions(+), 0 deletions(-) Approvals: Jarry1250: Verified; Looks good to me, approved -- To view, visit https://gerrit.wikimedia.org/r/20295 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: I934bdd1f798556e6529d9ee95a87134e70171044 Gerrit-PatchSet: 5 Gerrit-Project: mediawiki/extensions/TranslateSvg Gerrit-Branch: master Gerrit-Owner: Jarry1250 Gerrit-Reviewer: Aaron Schulz Gerrit-Reviewer: Jarry1250 Gerrit-Reviewer: MaxSem Gerrit-Reviewer: Nikerabbit ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] ApiGroupReview: Protect against spaces in example group name - change (mediawiki...Translate[master])
Jarry1250 has uploaded a new change for review. Change subject: ApiGroupReview: Protect against spaces in example group name .. ApiGroupReview: Protect against spaces in example group name Replace spaces with underscores to ensure a working link. Change-Id: I316007a086d9275379c2653bf35f3e10017db57c --- M api/ApiGroupReview.php 1 file changed, 1 insertion(+), 0 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/Translate refs/changes/19/39319/1 -- To view, visit https://gerrit.wikimedia.org/r/39319 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I316007a086d9275379c2653bf35f3e10017db57c Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/Translate Gerrit-Branch: master Gerrit-Owner: Jarry1250 ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Bugfix missing backslash, private->public function, &misc - change (mediawiki...TranslateSvg[master])
Jarry1250 has uploaded a new change for review. Change subject: Bugfix missing backslash, private->public function, &misc .. Bugfix missing backslash, private->public function, &misc Change-Id: I251ea3ba6da125bcaddd2335c1712dcb38030e73 --- M SVGFormatReader.php M TranslateSvgUtils.php 2 files changed, 9 insertions(+), 8 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/TranslateSvg refs/changes/72/39372/1 -- To view, visit https://gerrit.wikimedia.org/r/39372 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I251ea3ba6da125bcaddd2335c1712dcb38030e73 Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/TranslateSvg Gerrit-Branch: master Gerrit-Owner: Jarry1250 ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Bugfix missing backslash, private->public function, &misc - change (mediawiki...TranslateSvg[master])
Jarry1250 has submitted this change and it was merged. Change subject: Bugfix missing backslash, private->public function, &misc .. Bugfix missing backslash, private->public function, &misc Change-Id: I251ea3ba6da125bcaddd2335c1712dcb38030e73 --- M SVGFormatReader.php M TranslateSvgUtils.php 2 files changed, 9 insertions(+), 8 deletions(-) Approvals: Jarry1250: Verified; Looks good to me, approved -- To view, visit https://gerrit.wikimedia.org/r/39372 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: I251ea3ba6da125bcaddd2335c1712dcb38030e73 Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/TranslateSvg Gerrit-Branch: master Gerrit-Owner: Jarry1250 Gerrit-Reviewer: Jarry1250 ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Make the PNG thumbnail update live - change (mediawiki...TranslateSvg[master])
Jarry1250 has uploaded a new change for review. Change subject: Make the PNG thumbnail update live .. Make the PNG thumbnail update live A live-updated thumbnail allows users to perfect the formatting of translated messages. There are essentially two parts to this commit, rolled together to allow testing and to make it clear why certain design decisions were taken. The first is a series of hooks into Translate to amend the API meta=messagegroups. The second is a JavaScript section that uses the the amended API methods to provide the live update service. Change-Id: I9c75d38028adc7cbab48a1d17f97c30a0ae12123 --- M TranslateSvg.php M TranslateSvgHooks.php M resources/ext.translatesvg.core.js 3 files changed, 133 insertions(+), 0 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/TranslateSvg refs/changes/80/39380/1 -- To view, visit https://gerrit.wikimedia.org/r/39380 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I9c75d38028adc7cbab48a1d17f97c30a0ae12123 Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/TranslateSvg Gerrit-Branch: master Gerrit-Owner: Jarry1250 ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Make the PNG thumbnail update live - change (mediawiki...TranslateSvg[master])
Jarry1250 has submitted this change and it was merged. Change subject: Make the PNG thumbnail update live .. Make the PNG thumbnail update live A live-updated thumbnail allows users to perfect the formatting of translated messages. Patch includes related fix to SVGMessageGroup. There are essentially two parts to this commit, rolled together to allow testing and to make it clear why certain design decisions were taken. The first is a series of hooks into Translate to amend the API meta=messagegroups. The second is a JavaScript section that uses the the amended API methods to provide the live update service. For live test version, see //translatesvg.wmflabs.org/wiki/Special:Translate Change-Id: I9c75d38028adc7cbab48a1d17f97c30a0ae12123 --- M SVGMessageGroup.php M TranslateSvg.php M TranslateSvgHooks.php M resources/ext.translatesvg.core.js 4 files changed, 158 insertions(+), 15 deletions(-) Approvals: Jarry1250: Verified; Looks good to me, approved -- To view, visit https://gerrit.wikimedia.org/r/39380 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: I9c75d38028adc7cbab48a1d17f97c30a0ae12123 Gerrit-PatchSet: 4 Gerrit-Project: mediawiki/extensions/TranslateSvg Gerrit-Branch: master Gerrit-Owner: Jarry1250 Gerrit-Reviewer: Jarry1250 Gerrit-Reviewer: MarkTraceur Gerrit-Reviewer: Matmarex Gerrit-Reviewer: Nikerabbit ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Use , in search suggestions instead of endless ... - change (mediawiki/core[master])
Jarry1250 has uploaded a new change for review. Change subject: Use , in search suggestions instead of endless s. .. Use , in search suggestions instead of endless s. It's more semantic, and, well, sensible. Instead of find/replacing, I've tried to make the JavaScript more markup agnostic. Change-Id: Id772bb0ceb25a06c8564434c7d4318597bd32262 --- M resources/jquery/jquery.suggestions.css M resources/jquery/jquery.suggestions.js M resources/mediawiki/mediawiki.searchSuggest.js 3 files changed, 16 insertions(+), 12 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/core refs/changes/64/41364/1 -- To view, visit https://gerrit.wikimedia.org/r/41364 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: Id772bb0ceb25a06c8564434c7d4318597bd32262 Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/core Gerrit-Branch: master Gerrit-Owner: Jarry1250 ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] [DO NOT MERGE] Rough and ready proof of concept for search s... - change (mediawiki/core[master])
Jarry1250 has uploaded a new change for review. Change subject: [DO NOT MERGE] Rough and ready proof of concept for search suggestions .. [DO NOT MERGE] Rough and ready proof of concept for search suggestions For MatmaRex's benefit. Lots of CSS issues, no proper hrefs, caching or right-clicks. But I think it works...? Change-Id: Ia20b1a625816c61cc325c626c09a5d6cfd437f77 --- M resources/jquery/jquery.suggestions.css M resources/jquery/jquery.suggestions.js M resources/mediawiki/mediawiki.searchSuggest.js 3 files changed, 28 insertions(+), 13 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/core refs/changes/65/41365/1 -- To view, visit https://gerrit.wikimedia.org/r/41365 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: Ia20b1a625816c61cc325c626c09a5d6cfd437f77 Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/core Gerrit-Branch: master Gerrit-Owner: Jarry1250 ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Convert core to use new ThumbnailImage() constructor - change (mediawiki/core[master])
Jarry1250 has uploaded a new change for review. Change subject: Convert core to use new ThumbnailImage() constructor .. Convert core to use new ThumbnailImage() constructor See change #21321 for the introduction of that new constructor and the reasoning behind it. Change-Id: I15843fab4217333077e16ae187e7c09f76d47e58 --- M includes/filerepo/file/File.php M includes/media/Bitmap.php M includes/media/Bitmap_ClientOnly.php M includes/media/DjVu.php M includes/media/ImageHandler.php M includes/media/SVG.php 6 files changed, 35 insertions(+), 18 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/core refs/changes/01/22301/1 -- To view, visit https://gerrit.wikimedia.org/r/22301 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I15843fab4217333077e16ae187e7c09f76d47e58 Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/core Gerrit-Branch: master Gerrit-Owner: Jarry1250 ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Add extra unset( ... ); to MessageGroups::clearCache . - change (mediawiki...Translate[master])
Jarry1250 has uploaded a new change for review. Change subject: Add extra unset( ... ); to MessageGroups::clearCache . .. Add extra unset( ... ); to MessageGroups::clearCache . This has been the cause of a couple of problems for me, because it gets cached early and then sticks, maing dynamic groups difficult. Dynamic groups are in use in TranslateSvg and are required for good unit test coverage. Change-Id: I534120053ab152e821feedc1dec3f07636d914b3 --- M MessageGroups.php 1 file changed, 1 insertion(+), 0 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/Translate refs/changes/82/23582/1 -- To view, visit https://gerrit.wikimedia.org/r/23582 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I534120053ab152e821feedc1dec3f07636d914b3 Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/Translate Gerrit-Branch: master Gerrit-Owner: Jarry1250 ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Add extra = null; to MessageGroups::clearCache . - change (mediawiki...Translate[translatesvg])
Jarry1250 has uploaded a new change for review. Change subject: Add extra = null; to MessageGroups::clearCache . .. Add extra = null; to MessageGroups::clearCache . The lack of this has been the cause of a couple of problems for me, because it gets cached early and then sticks, causing problems when trying to use dynamic groups. Dynamic groups are in use in TranslateSvg and are required for good unit test coverage. Change-Id: I534120053ab152e821feedc1dec3f07636d914b3 --- M MessageGroups.php 1 file changed, 1 insertion(+), 0 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/Translate refs/changes/84/23584/1 -- To view, visit https://gerrit.wikimedia.org/r/23584 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I534120053ab152e821feedc1dec3f07636d914b3 Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/Translate Gerrit-Branch: translatesvg Gerrit-Owner: Jarry1250 ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] (bug #32987) The language used to render SVGs should be defi... - change (mediawiki/core[master])
Jarry1250 has uploaded a new change for review. Change subject: (bug #32987) The language used to render SVGs should be definable .. (bug #32987) The language used to render SVGs should be definable See bug for context. The implementation is slightly untidy because I've written it so as to avoid invalidating the existing SVG thumbs -- there will be no immediate difference (visual/performance/other) as a result of this. Tested by me in both... * [[File:Example.svg|thumb|lang=fr]] AND * http://example.org/w/index.php?title=File:Example.svg&lang=fr ...modes Change-Id: I4cadf96ecd5e169a88ad468a0478d355db980103 --- M includes/ImagePage.php M includes/media/MediaTransformOutput.php M includes/media/SVG.php M languages/messages/MessagesEn.php 4 files changed, 108 insertions(+), 12 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/core refs/changes/38/25838/1 -- To view, visit https://gerrit.wikimedia.org/r/25838 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I4cadf96ecd5e169a88ad468a0478d355db980103 Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/core Gerrit-Branch: master Gerrit-Owner: Jarry1250 ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Followup I15843fab: don't show &page=1 in file link - change (mediawiki/core[master])
Jarry1250 has uploaded a new change for review. Change subject: Followup I15843fab: don't show &page=1 in file link .. Followup I15843fab: don't show &page=1 in file link By standardising the file parameters were handed around, the normalised parameter "page" (set to 1) is being passed to the linker. Since it's the default, I don't think we really need it in the link, where it is (a) meaningless and (b) confusing, since it is set for some media types that don't even have pages (e.g. SVGs). Change-Id: Ib80a85125366ec32ab05b061b06d28144dc244fc --- M includes/media/MediaTransformOutput.php 1 file changed, 4 insertions(+), 1 deletion(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/core refs/changes/52/28452/1 -- To view, visit https://gerrit.wikimedia.org/r/28452 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: Ib80a85125366ec32ab05b061b06d28144dc244fc Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/core Gerrit-Branch: master Gerrit-Owner: Jarry1250 ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Add all necessary hooks to allow for meaningful properties s... - change (mediawiki...Translate[master])
Jarry1250 has uploaded a new change for review. Change subject: Add all necessary hooks to allow for meaningful properties system. .. Add all necessary hooks to allow for meaningful properties system. Also, tweak display to cope with thumbnail helper. [Required for TranslateSvg phase 1.] Change-Id: Ia7f7be12db8e00ad0788ae504b461e8e81cca5da --- A hooks.txt M resources/ext.translate.quickedit.css M resources/ext.translate.quickedit.js M utils/MessageTable.php M utils/TranslationEditPage.php M utils/TranslationHelpers.php 6 files changed, 149 insertions(+), 24 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/Translate refs/changes/87/14887/1 -- To view, visit https://gerrit.wikimedia.org/r/14887 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: Ia7f7be12db8e00ad0788ae504b461e8e81cca5da Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/Translate Gerrit-Branch: master Gerrit-Owner: Jarry1250 ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Create new SVGMessageGroup to enable SVG translation. [Phase... - change (mediawiki...TranslateSvg[master])
Jarry1250 has submitted this change and it was merged. Change subject: Create new SVGMessageGroup to enable SVG translation. [Phase 1] .. Create new SVGMessageGroup to enable SVG translation. [Phase 1] Also some minor whitespace, header, tweaks to correct earlier commit. Change-Id: Ia078c57138fdfc62007d22d0dbeecc78ff330d8f --- A SVGMessageGroup.php M TranslateSvg.i18n.php M TranslateSvg.php 3 files changed, 269 insertions(+), 12 deletions(-) Approvals: Jarry1250: Verified; Looks good to me, approved -- To view, visit https://gerrit.wikimedia.org/r/12392 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: Ia078c57138fdfc62007d22d0dbeecc78ff330d8f Gerrit-PatchSet: 6 Gerrit-Project: mediawiki/extensions/TranslateSvg Gerrit-Branch: master Gerrit-Owner: Jarry1250 Gerrit-Reviewer: Amire80 Gerrit-Reviewer: Jarry1250 Gerrit-Reviewer: Nikerabbit ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Add class to autoload to resolve random error I was encounte... - change (mediawiki...Translate[translatesvg])
Jarry1250 has uploaded a new change for review. Change subject: Add class to autoload to resolve random error I was encountering. .. Add class to autoload to resolve random error I was encountering. [Required for TranslateSvg phase 2.] Change-Id: Ie904e62b918ebc5f27f4b612f9a1420e834447a3 --- M _autoload.php 1 file changed, 1 insertion(+), 0 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/Translate refs/changes/23/14923/1 -- To view, visit https://gerrit.wikimedia.org/r/14923 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: Ie904e62b918ebc5f27f4b612f9a1420e834447a3 Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/Translate Gerrit-Branch: translatesvg Gerrit-Owner: Jarry1250 ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Add afterRegisterFeatures hook plus documentation. - change (mediawiki...Translate[translatesvg])
Jarry1250 has uploaded a new change for review. Change subject: Add afterRegisterFeatures hook plus documentation. .. Add afterRegisterFeatures hook plus documentation. The hook allows for live thumbnail updates and would allow for other event handlers to be added. [Required for TranslateSvg phase 2.] Change-Id: I53a2115d10131df58637d2cbf737401dfc6eddba --- M hooks.txt M resources/ext.translate.quickedit.js 2 files changed, 8 insertions(+), 0 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/Translate refs/changes/25/14925/1 -- To view, visit https://gerrit.wikimedia.org/r/14925 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I53a2115d10131df58637d2cbf737401dfc6eddba Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/Translate Gerrit-Branch: translatesvg Gerrit-Owner: Jarry1250 ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Add TranslateGetOptions hook plus documentation. - change (mediawiki...Translate[translatesvg])
Jarry1250 has uploaded a new change for review. Change subject: Add TranslateGetOptions hook plus documentation. .. Add TranslateGetOptions hook plus documentation. The hook allows for the export task (or any other task) to be overrided. [Required for TranslateSvg phase 2.] Change-Id: I418d6350b163eb8ecf5ce43829bbcf195b054d57 --- M hooks.txt M specials/SpecialTranslate.php 2 files changed, 5 insertions(+), 0 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/Translate refs/changes/26/14926/1 -- To view, visit https://gerrit.wikimedia.org/r/14926 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I418d6350b163eb8ecf5ce43829bbcf195b054d57 Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/Translate Gerrit-Branch: translatesvg Gerrit-Owner: Jarry1250 ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Add help hidden "group" element - change (mediawiki...Translate[translatesvg])
Jarry1250 has uploaded a new change for review. Change subject: Add help hidden "group" element .. Add help hidden "group" element Allows JavaScript to know what kind of message group is present. [Required for TranslateSvg phase 2.] Change-Id: I4a91e5d988788b2d4dd070ddd87efd4d283c3f81 --- M specials/SpecialTranslate.php 1 file changed, 1 insertion(+), 0 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/Translate refs/changes/27/14927/1 -- To view, visit https://gerrit.wikimedia.org/r/14927 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I4a91e5d988788b2d4dd070ddd87efd4d283c3f81 Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/Translate Gerrit-Branch: translatesvg Gerrit-Owner: Jarry1250 ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Add TranslateBeforeAddModules hook plus documentation. - change (mediawiki...Translate[translatesvg])
Jarry1250 has uploaded a new change for review. Change subject: Add TranslateBeforeAddModules hook plus documentation. .. Add TranslateBeforeAddModules hook plus documentation. The hook allows for extra modules to be added to the ResourceLoader in the same batch. [Required for TranslateSvg phase 2.] Change-Id: I929f865a703d984b6a8f7f35183726ac10f79ce2 --- M hooks.txt M utils/TranslationHelpers.php 2 files changed, 6 insertions(+), 1 deletion(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/Translate refs/changes/50/15450/1 -- To view, visit https://gerrit.wikimedia.org/r/15450 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I929f865a703d984b6a8f7f35183726ac10f79ce2 Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/Translate Gerrit-Branch: translatesvg Gerrit-Owner: Jarry1250 ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Resolve "On succesful save, update the MessageTable display ... - change (mediawiki...Translate[master])
Jarry1250 has uploaded a new change for review. Change subject: Resolve "On succesful save, update the MessageTable display too" .. Resolve "On succesful save, update the MessageTable display too" Specifically, add onSuccess-style callback for the editor that updates the main MessageTable, changing the text, removing the green background and adding a class for extensibility. Change-Id: I3a6350e115bf86eefc3dc1e09b0e68d47af5d822 --- M resources/ext.translate.quickedit.js 1 file changed, 7 insertions(+), 2 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/Translate refs/changes/70/15970/1 -- To view, visit https://gerrit.wikimedia.org/r/15970 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I3a6350e115bf86eefc3dc1e09b0e68d47af5d822 Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/Translate Gerrit-Branch: master Gerrit-Owner: Jarry1250 ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Add 'TranslateNoSuchGroupFound' hook plus documentation - change (mediawiki...Translate[translatesvg])
Jarry1250 has uploaded a new change for review. Change subject: Add 'TranslateNoSuchGroupFound' hook plus documentation .. Add 'TranslateNoSuchGroupFound' hook plus documentation Allows extensions to match ids to groups e.g. to create fully "dynamic" groups that have ids that are nowhere written down. [Required for TranslateSvg phase 3.] Change-Id: I7a5a6b2a22c86a9d752125a9d3402c92897767cf --- M MessageGroups.php M hooks.txt 2 files changed, 8 insertions(+), 0 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/Translate refs/changes/76/16076/1 -- To view, visit https://gerrit.wikimedia.org/r/16076 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I7a5a6b2a22c86a9d752125a9d3402c92897767cf Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/Translate Gerrit-Branch: translatesvg Gerrit-Owner: Jarry1250 ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Add 'TranslateBeforeSpecialTranslate' hook plus documentatio... - change (mediawiki...Translate[translatesvg])
Jarry1250 has uploaded a new change for review. Change subject: Add 'TranslateBeforeSpecialTranslate' hook plus documentation. .. Add 'TranslateBeforeSpecialTranslate' hook plus documentation. Hook provides an opportunity for an extension to override the usual display of Special:Translate, e.g. to create parallels to the built-in Special:Translate/editpage [Required for TranslateSvg phase 3.] Change-Id: Idcb0b845b37b5575f587b0873334065f7f8c --- M hooks.txt M specials/SpecialTranslate.php 2 files changed, 6 insertions(+), 0 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/Translate refs/changes/81/16081/1 -- To view, visit https://gerrit.wikimedia.org/r/16081 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: Idcb0b845b37b5575f587b0873334065f7f8c Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/Translate Gerrit-Branch: translatesvg Gerrit-Owner: Jarry1250 ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Add all interface messages required for TranslateSvg - change (mediawiki...TranslateSvg[master])
Jarry1250 has uploaded a new change for review. Change subject: Add all interface messages required for TranslateSvg .. Add all interface messages required for TranslateSvg Includes messages from phases 1, 2 and 3, with documentation (qqq) included. Change-Id: Iade5fa83b0d8e88ca0e2e7cb4d11017882d2a4ef --- M TranslateSvg.i18n.php 1 file changed, 70 insertions(+), 3 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/TranslateSvg refs/changes/73/16773/1 -- To view, visit https://gerrit.wikimedia.org/r/16773 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: Iade5fa83b0d8e88ca0e2e7cb4d11017882d2a4ef Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/TranslateSvg Gerrit-Branch: master Gerrit-Owner: Jarry1250 ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Add all interface messages required for TranslateSvg - change (mediawiki...TranslateSvg[master])
Jarry1250 has submitted this change and it was merged. Change subject: Add all interface messages required for TranslateSvg .. Add all interface messages required for TranslateSvg Includes messages from phases 1, 2 and 3, with documentation (qqq) included. Change-Id: Iade5fa83b0d8e88ca0e2e7cb4d11017882d2a4ef --- M TranslateSvg.i18n.php 1 file changed, 70 insertions(+), 3 deletions(-) Approvals: Jarry1250: Verified; Looks good to me, approved -- To view, visit https://gerrit.wikimedia.org/r/16773 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: Iade5fa83b0d8e88ca0e2e7cb4d11017882d2a4ef Gerrit-PatchSet: 2 Gerrit-Project: mediawiki/extensions/TranslateSvg Gerrit-Branch: master Gerrit-Owner: Jarry1250 Gerrit-Reviewer: Jarry1250 Gerrit-Reviewer: Nikerabbit ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Commit TranslateSvgUtils, a collection of helper functions. - change (mediawiki...TranslateSvg[master])
Jarry1250 has uploaded a new change for review. Change subject: Commit TranslateSvgUtils, a collection of helper functions. .. Commit TranslateSvgUtils, a collection of helper functions. Contains 13 miscellaneous functions, each of which is required for a phase of TranslateSvg. Complete with docs. Change-Id: Ie93fc789cf7cdeee2f40dbd65d3438f485f7eebb --- A TranslateSvgUtils.php 1 file changed, 395 insertions(+), 0 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/TranslateSvg refs/changes/91/16891/1 -- To view, visit https://gerrit.wikimedia.org/r/16891 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: Ie93fc789cf7cdeee2f40dbd65d3438f485f7eebb Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/TranslateSvg Gerrit-Branch: master Gerrit-Owner: Jarry1250 ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] SVGMessageGroup: override isSourceLanguage(), add getOnWikiL... - change (mediawiki...TranslateSvg[master])
Jarry1250 has uploaded a new change for review. Change subject: SVGMessageGroup: override isSourceLanguage(), add getOnWikiLanguages() .. SVGMessageGroup: override isSourceLanguage(), add getOnWikiLanguages() getSourceLanguage() overrides parent method, effectively ensuring "default" is recognised as the source language for all SVGMessageGroups. getOnWikiLanguages() returns a useful list of languages current used on-wiki for a file. Change-Id: Ife184b7bc596b1936208f4f5e77bcf0523791dd4 --- M SVGMessageGroup.php 1 file changed, 30 insertions(+), 0 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/TranslateSvg refs/changes/94/16894/1 -- To view, visit https://gerrit.wikimedia.org/r/16894 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: Ife184b7bc596b1936208f4f5e77bcf0523791dd4 Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/TranslateSvg Gerrit-Branch: master Gerrit-Owner: Jarry1250 ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Resolve "On succesful save, update the MessageTable display ... - change (mediawiki...Translate[translatesvg])
Jarry1250 has uploaded a new change for review. Change subject: Resolve "On succesful save, update the MessageTable display too" .. Resolve "On succesful save, update the MessageTable display too" Specifically, add onSuccess-style callback for the editor that updates the main MessageTable, changing the text, removing the green background and adding a class for extensibility. Change-Id: I3a6350e115bf86eefc3dc1e09b0e68d47af5d822 --- M resources/ext.translate.quickedit.js 1 file changed, 13 insertions(+), 4 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/Translate refs/changes/47/17647/1 -- To view, visit https://gerrit.wikimedia.org/r/17647 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I3a6350e115bf86eefc3dc1e09b0e68d47af5d822 Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/Translate Gerrit-Branch: translatesvg Gerrit-Owner: Jarry1250 ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Followup change #15970, fix underscore comparison - change (mediawiki...Translate[translatesvg])
Jarry1250 has uploaded a new change for review. Change subject: Followup change #15970, fix underscore comparison .. Followup change #15970, fix underscore comparison Page uses underscores, whereas data uses spaces, making comparisons without conversion fail. This changeset resolves that issue. Change-Id: Iebd7cea2fed23286c38f9836eb78bb559d2993a3 --- M resources/ext.translate.quickedit.js 1 file changed, 1 insertion(+), 1 deletion(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/Translate refs/changes/48/17648/1 -- To view, visit https://gerrit.wikimedia.org/r/17648 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: Iebd7cea2fed23286c38f9836eb78bb559d2993a3 Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/Translate Gerrit-Branch: translatesvg Gerrit-Owner: Jarry1250 ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Followup change #15970, fix underscore comparison - change (mediawiki...Translate[master])
Jarry1250 has uploaded a new change for review. Change subject: Followup change #15970, fix underscore comparison .. Followup change #15970, fix underscore comparison Page uses underscores, whereas data uses spaces, making comparisons without conversion fail. This changeset resolves that issue. Change-Id: Iebd7cea2fed23286c38f9836eb78bb559d2993a3 --- M resources/ext.translate.quickedit.js 1 file changed, 1 insertion(+), 1 deletion(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/Translate refs/changes/49/17649/1 -- To view, visit https://gerrit.wikimedia.org/r/17649 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: Iebd7cea2fed23286c38f9836eb78bb559d2993a3 Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/Translate Gerrit-Branch: master Gerrit-Owner: Jarry1250 ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Add FCFontFinder::findFamily() - change (mediawiki...Translate[master])
Jarry1250 has uploaded a new change for review. Change subject: Add FCFontFinder::findFamily() .. Add FCFontFinder::findFamily() Sometimes it's useful to not just have a path to the TTF but to get the name as well. Not as optimised as it could be because it doesn't share cache values with self::find(), but functional by my reckoning. Change-Id: I8863f89f17342589777f11b54d309c01ccc62bf6 --- M utils/Font.php 1 file changed, 51 insertions(+), 0 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/Translate refs/changes/72/17772/1 -- To view, visit https://gerrit.wikimedia.org/r/17772 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I8863f89f17342589777f11b54d309c01ccc62bf6 Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/Translate Gerrit-Branch: master Gerrit-Owner: Jarry1250 ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Local changes - change (mediawiki...Translate[master])
Jarry1250 has uploaded a new change for review. Change subject: Local changes .. Local changes Change-Id: Iba1edb06141db0650d4fc5d104bb1f675c245032 --- M MessageGroups.php M _autoload.php M hooks.txt M specials/SpecialTranslate.php M utils/TranslationHelpers.php 5 files changed, 35 insertions(+), 5 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/Translate refs/changes/71/17771/1 -- To view, visit https://gerrit.wikimedia.org/r/17771 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: Iba1edb06141db0650d4fc5d104bb1f675c245032 Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/Translate Gerrit-Branch: master Gerrit-Owner: Jarry1250 ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Amend messages, and add new ones as required. - change (mediawiki...TranslateSvg[master])
Jarry1250 has submitted this change and it was merged. Change subject: Amend messages, and add new ones as required. .. Amend messages, and add new ones as required. Change-Id: Ia3c3abf853db726595b01ade992053392f8d19c6 --- M TranslateSvg.i18n.php 1 file changed, 24 insertions(+), 2 deletions(-) Approvals: Nikerabbit: Looks good to me, approved Jarry1250: Verified; Looks good to me, approved -- To view, visit https://gerrit.wikimedia.org/r/18046 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: Ia3c3abf853db726595b01ade992053392f8d19c6 Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/TranslateSvg Gerrit-Branch: master Gerrit-Owner: Jarry1250 Gerrit-Reviewer: Jarry1250 Gerrit-Reviewer: MaxSem Gerrit-Reviewer: Nikerabbit ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Add FCFontFinder::findFamily() - change (mediawiki...Translate[translatesvg])
Jarry1250 has uploaded a new change for review. Change subject: Add FCFontFinder::findFamily() .. Add FCFontFinder::findFamily() Sometimes it's useful to not just have a path to the TTF but to get the name as well. Change-Id: I8863f89f17342589777f11b54d309c01ccc62bf6 --- M utils/Font.php 1 file changed, 45 insertions(+), 7 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/Translate refs/changes/76/18276/1 -- To view, visit https://gerrit.wikimedia.org/r/18276 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I8863f89f17342589777f11b54d309c01ccc62bf6 Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/Translate Gerrit-Branch: translatesvg Gerrit-Owner: Jarry1250 ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Add basic query=translateinfo API method to Translate. - change (mediawiki...Translate[translatesvg])
Jarry1250 has uploaded a new change for review. Change subject: Add basic query=translateinfo API method to Translate. .. Add basic query=translateinfo API method to Translate. At the moment, returns only label and ID. Could be used to replace Special:Translate/editpage; I'll be using it to replace Special:Translate/thumbnailpage. [Required for TranslateSvg phase 3.] Change-Id: I43e86abc6e7ae746a1ed134729f68bca620d6f63 --- M Translate.php M _autoload.php A api/ApiTranslateInfo.php 3 files changed, 122 insertions(+), 0 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/Translate refs/changes/96/18696/1 -- To view, visit https://gerrit.wikimedia.org/r/18696 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I43e86abc6e7ae746a1ed134729f68bca620d6f63 Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/Translate Gerrit-Branch: translatesvg Gerrit-Owner: Jarry1250 ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] SVGMessageGroup: override getSourceLanguage(), add two other... - change (mediawiki...TranslateSvg[master])
Jarry1250 has uploaded a new change for review. Change subject: SVGMessageGroup: override getSourceLanguage(), add two others .. SVGMessageGroup: override getSourceLanguage(), add two others getSourceLanguage() overrides parent method, getting a source language from the database and returning it. setSourceLanguage() sets the source language in the database. getOnWikiLanguages() returns a useful list of languages current used on-wiki for a file. Change-Id: I0c44b2fd5db25da0f9a5719c72dd368ef962dca1 --- M SVGMessageGroup.php 1 file changed, 43 insertions(+), 0 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/TranslateSvg refs/changes/40/18840/1 -- To view, visit https://gerrit.wikimedia.org/r/18840 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I0c44b2fd5db25da0f9a5719c72dd368ef962dca1 Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/TranslateSvg Gerrit-Branch: master Gerrit-Owner: Jarry1250 ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Commit TranslateSvgUtils, a collection of helper functions. - change (mediawiki...TranslateSvg[master])
Jarry1250 has submitted this change and it was merged. Change subject: Commit TranslateSvgUtils, a collection of helper functions. .. Commit TranslateSvgUtils, a collection of helper functions. Contains 13 miscellaneous functions, each of which is required for a phase of TranslateSvg. Complete with docs. Change-Id: Ie93fc789cf7cdeee2f40dbd65d3438f485f7eebb --- M TranslateSvg.php A TranslateSvgUtils.php 2 files changed, 379 insertions(+), 0 deletions(-) Approvals: Nikerabbit: Looks good to me, but someone else must approve Jarry1250: Verified; Looks good to me, approved -- To view, visit https://gerrit.wikimedia.org/r/16891 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: Ie93fc789cf7cdeee2f40dbd65d3438f485f7eebb Gerrit-PatchSet: 6 Gerrit-Project: mediawiki/extensions/TranslateSvg Gerrit-Branch: master Gerrit-Owner: Jarry1250 Gerrit-Reviewer: Jarry1250 Gerrit-Reviewer: MaxSem Gerrit-Reviewer: Nikerabbit Gerrit-Reviewer: Reedy ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Whitespace changes + take advantage of TranslateSvgUtils - change (mediawiki...TranslateSvg[master])
Jarry1250 has submitted this change and it was merged. Change subject: Whitespace changes + take advantage of TranslateSvgUtils .. Whitespace changes + take advantage of TranslateSvgUtils Also, remove extraneous load() method, same as parent Change-Id: Ib641485974d769c23235d55c31052a880b81594f --- M SVGMessageGroup.php 1 file changed, 21 insertions(+), 30 deletions(-) Approvals: Jarry1250: Verified; Looks good to me, approved -- To view, visit https://gerrit.wikimedia.org/r/16893 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: Ib641485974d769c23235d55c31052a880b81594f Gerrit-PatchSet: 4 Gerrit-Project: mediawiki/extensions/TranslateSvg Gerrit-Branch: master Gerrit-Owner: Jarry1250 Gerrit-Reviewer: Jarry1250 Gerrit-Reviewer: MaxSem Gerrit-Reviewer: Nikerabbit ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Fix and tidy broken getProperties method - change (mediawiki...TranslateSvg[master])
Jarry1250 has submitted this change and it was merged. Change subject: Fix and tidy broken getProperties method .. Fix and tidy broken getProperties method Change-Id: Ieb181a4c96f538b668e74190586236ea067a323c --- M SVGMessageGroup.php 1 file changed, 3 insertions(+), 4 deletions(-) Approvals: Jarry1250: Verified; Looks good to me, approved -- To view, visit https://gerrit.wikimedia.org/r/17024 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: Ieb181a4c96f538b668e74190586236ea067a323c Gerrit-PatchSet: 3 Gerrit-Project: mediawiki/extensions/TranslateSvg Gerrit-Branch: master Gerrit-Owner: Jarry1250 Gerrit-Reviewer: Jarry1250 ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Add importTranslations() to class SVGMessageGroup - change (mediawiki...TranslateSvg[master])
Jarry1250 has uploaded a new change for review. Change subject: Add importTranslations() to class SVGMessageGroup .. Add importTranslations() to class SVGMessageGroup This method imports translations from the file, onto the wiki. Requires SVGFormatReader class, hence the dependency. Essentially, this just calls SVGFormatReader, gets it to generate a list of embedded translations, then loops through creating the pages required for them. Change-Id: I15eba1e304561e292333271975e9a0fad9f25acf --- M SVGMessageGroup.php 1 file changed, 34 insertions(+), 0 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/TranslateSvg refs/changes/28/19228/1 -- To view, visit https://gerrit.wikimedia.org/r/19228 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I15eba1e304561e292333271975e9a0fad9f25acf Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/TranslateSvg Gerrit-Branch: master Gerrit-Owner: Jarry1250 ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Reimplement updated interface messages via JavaScript [Phase... - change (mediawiki...TranslateSvg[master])
Jarry1250 has submitted this change and it was merged. Change subject: Reimplement updated interface messages via JavaScript [Phase 1] .. Reimplement updated interface messages via JavaScript [Phase 1] These are interface messages from Translate which should be customised (made more specific) when viewing a group known to be a SVG file. Change-Id: I98a20f894f8ac256f39d89c190160af76e2076b3 --- M TranslateSvg.php A TranslateSvgHooks.php A resources/ext.translatesvg.core.js 3 files changed, 73 insertions(+), 2 deletions(-) Approvals: MarkTraceur: Looks good to me, but someone else must approve Jarry1250: Verified; Looks good to me, approved -- To view, visit https://gerrit.wikimedia.org/r/12469 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: I98a20f894f8ac256f39d89c190160af76e2076b3 Gerrit-PatchSet: 6 Gerrit-Project: mediawiki/extensions/TranslateSvg Gerrit-Branch: master Gerrit-Owner: Jarry1250 Gerrit-Reviewer: Jarry1250 Gerrit-Reviewer: MarkTraceur Gerrit-Reviewer: Nikerabbit ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Fix whitespace problems - change (mediawiki...TranslateSvg[master])
Jarry1250 has submitted this change and it was merged. Change subject: Fix whitespace problems .. Fix whitespace problems Mark failed at pasting code, so he fixed it. There was also a whitespace error somewhere in the main PHP file. :( Change-Id: I1a3a5c2eb0ac44d3c1b0f7b3839c07512e897e5d --- M TranslateSvg.php M resources/ext.translatesvg.core.js 2 files changed, 22 insertions(+), 22 deletions(-) Approvals: Jarry1250: Verified; Looks good to me, approved -- To view, visit https://gerrit.wikimedia.org/r/19383 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: I1a3a5c2eb0ac44d3c1b0f7b3839c07512e897e5d Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/TranslateSvg Gerrit-Branch: master Gerrit-Owner: MarkTraceur Gerrit-Reviewer: Jarry1250 ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Tweak the definition of a TranslateSVG message. - change (mediawiki...TranslateSvg[master])
Jarry1250 has uploaded a new change for review. Change subject: Tweak the definition of a TranslateSVG message. .. Tweak the definition of a TranslateSVG message. Sorry translators, just realised that this message will be wrong in some circumstances, thought I'd update the source ASAP. Change-Id: Ied6b4368d5515523a5c22aa100a301b558ea207d --- M TranslateSvg.i18n.php 1 file changed, 2 insertions(+), 2 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/TranslateSvg refs/changes/52/19652/1 -- To view, visit https://gerrit.wikimedia.org/r/19652 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: Ied6b4368d5515523a5c22aa100a301b558ea207d Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/TranslateSvg Gerrit-Branch: master Gerrit-Owner: Jarry1250 ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Provide more info to 'TranslateFormatMessageBeforeTable' hoo... - change (mediawiki...Translate[translatesvg])
Jarry1250 has uploaded a new change for review. Change subject: Provide more info to 'TranslateFormatMessageBeforeTable' hooks .. Provide more info to 'TranslateFormatMessageBeforeTable' hooks Specifically, add $group and $targetLanguage parameters and simplify by passing $m (which has translation() and original() methods) rather than $translation and $original. Found I needed these details when I came to tweak my own usage of the hook, which is sufficiently new (and still in this branch) that I can't believe anyone else is using it at the moment. Change-Id: If063e4dddbbb0104dc58968527971f879283c30e --- M hooks.txt M utils/MessageTable.php 2 files changed, 5 insertions(+), 4 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/Translate refs/changes/40/19740/1 -- To view, visit https://gerrit.wikimedia.org/r/19740 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: If063e4dddbbb0104dc58968527971f879283c30e Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/Translate Gerrit-Branch: translatesvg Gerrit-Owner: Jarry1250 ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Implement SVG-based properties via {{Translation properties}... - change (mediawiki...TranslateSvg[master])
Jarry1250 has submitted this change and it was merged. Change subject: Implement SVG-based properties via {{Translation properties}} .. Implement SVG-based properties via {{Translation properties}} Specifically, add support for: * x * y * typeface * font-size * bold / italic / underline * color all via Translate-based hooks. [Part of SVG translation project, phase 1] Change-Id: Ieca97a456107fc4ac9c5fb4e9d930bc60e0af011 --- M TranslateSvg.php M TranslateSvgHooks.php M resources/ext.translatesvg.core.js A resources/jquery.colorpicker.css A resources/jquery.colorpicker.js 5 files changed, 339 insertions(+), 3 deletions(-) Approvals: Jarry1250: Verified; Looks good to me, approved -- To view, visit https://gerrit.wikimedia.org/r/12968 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: Ieca97a456107fc4ac9c5fb4e9d930bc60e0af011 Gerrit-PatchSet: 5 Gerrit-Project: mediawiki/extensions/TranslateSvg Gerrit-Branch: master Gerrit-Owner: Jarry1250 Gerrit-Reviewer: Jarry1250 Gerrit-Reviewer: MaxSem Gerrit-Reviewer: Nikerabbit ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] SVGMessageGroup: override getSourceLanguage(), add two other... - change (mediawiki...TranslateSvg[master])
Jarry1250 has submitted this change and it was merged. Change subject: SVGMessageGroup: override getSourceLanguage(), add two others .. SVGMessageGroup: override getSourceLanguage(), add two others getSourceLanguage() overrides parent method, getting a source language from the database and returning it. setSourceLanguage() sets the source language in the database. getOnWikiLanguages() returns a useful list of languages current used on-wiki for a file. Change-Id: Ife184b7bc596b1936208f4f5e77bcf0523791dd4 --- M SVGMessageGroup.php 1 file changed, 43 insertions(+), 0 deletions(-) Approvals: Jarry1250: Verified; Looks good to me, approved -- To view, visit https://gerrit.wikimedia.org/r/16894 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: Ife184b7bc596b1936208f4f5e77bcf0523791dd4 Gerrit-PatchSet: 7 Gerrit-Project: mediawiki/extensions/TranslateSvg Gerrit-Branch: master Gerrit-Owner: Jarry1250 Gerrit-Reviewer: Jarry1250 Gerrit-Reviewer: MaxSem Gerrit-Reviewer: Nikerabbit ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Provide helper links on file description pages. - change (mediawiki...TranslateSvg[master])
Jarry1250 has uploaded a new change for review. Change subject: Provide helper links on file description pages. .. Provide helper links on file description pages. These come in a few different flavours: no translations, do you wish to start?; translations, just view; and translations, view and translate. Change-Id: I360f2fdc219d96e5c10670c34796d6f40fbed2b4 --- M TranslateSvg.php M TranslateSvgHooks.php A resources/ext.translatesvg.filepage.js 3 files changed, 242 insertions(+), 4 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/TranslateSvg refs/changes/07/20007/1 -- To view, visit https://gerrit.wikimedia.org/r/20007 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I360f2fdc219d96e5c10670c34796d6f40fbed2b4 Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/TranslateSvg Gerrit-Branch: master Gerrit-Owner: Jarry1250 ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Add a couple of global config variables that were accidental... - change (mediawiki...TranslateSvg[master])
Jarry1250 has submitted this change and it was merged. Change subject: Add a couple of global config variables that were accidentally left out of a previous commit. .. Add a couple of global config variables that were accidentally left out of a previous commit. Change-Id: I5023374f4c72e3acab07952408abfd073e9a6f74 --- M TranslateSvg.php 1 file changed, 13 insertions(+), 0 deletions(-) Approvals: Jarry1250: Verified; Looks good to me, approved -- To view, visit https://gerrit.wikimedia.org/r/20042 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: I5023374f4c72e3acab07952408abfd073e9a6f74 Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/TranslateSvg Gerrit-Branch: master Gerrit-Owner: Jarry1250 Gerrit-Reviewer: Jarry1250 ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Standardise global variable names to TranslateSvg caps - change (mediawiki...TranslateSvg[master])
Jarry1250 has submitted this change and it was merged. Change subject: Standardise global variable names to TranslateSvg caps .. Standardise global variable names to TranslateSvg caps Change-Id: I1a7e32e79dd6f982e0f516f902dec1162672c457 --- M TranslateSvgUtils.php 1 file changed, 7 insertions(+), 7 deletions(-) Approvals: Jarry1250: Verified; Looks good to me, approved -- To view, visit https://gerrit.wikimedia.org/r/20061 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: I1a7e32e79dd6f982e0f516f902dec1162672c457 Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/TranslateSvg Gerrit-Branch: master Gerrit-Owner: Jarry1250 Gerrit-Reviewer: Jarry1250 ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Add two messages that were accidentally omitted - change (mediawiki...TranslateSvg[master])
Jarry1250 has uploaded a new change for review. Change subject: Add two messages that were accidentally omitted .. Add two messages that were accidentally omitted Both relate to exporting. Also, remove duplicate of my name from @author list. Change-Id: Ifd487ce12ed1418c052072c7fd7535f64298cfd0 --- M TranslateSvg.i18n.php 1 file changed, 2 insertions(+), 1 deletion(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/TranslateSvg refs/changes/94/20294/1 -- To view, visit https://gerrit.wikimedia.org/r/20294 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: Ifd487ce12ed1418c052072c7fd7535f64298cfd0 Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/TranslateSvg Gerrit-Branch: master Gerrit-Owner: Jarry1250 ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Half-merge of the Translatesvg branch - change (mediawiki...Translate[master])
Jarry1250 has uploaded a new change for review. Change subject: Half-merge of the Translatesvg branch .. Half-merge of the Translatesvg branch Change-Id: I8948ac58d33133b5834fa900b7ecfb29ff9b4fce --- A hooks.txt M specials/SpecialTranslate.php M utils/Font.php M utils/TranslationHelpers.php 4 files changed, 111 insertions(+), 11 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/Translate refs/changes/09/20709/1 -- To view, visit https://gerrit.wikimedia.org/r/20709 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I8948ac58d33133b5834fa900b7ecfb29ff9b4fce Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/Translate Gerrit-Branch: master Gerrit-Owner: Jarry1250 ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Second merge commit generated from the translatesvg branch - change (mediawiki...Translate[master])
Jarry1250 has uploaded a new change for review. Change subject: Second merge commit generated from the translatesvg branch .. Second merge commit generated from the translatesvg branch Change-Id: Ic6dac5408637371660705877a6a0fa1eeef8455f --- M Translate.php M hooks.txt A resources/ext.translate.hooks.js M resources/ext.translate.quickedit.css M resources/ext.translate.quickedit.js M utils/MessageTable.php M utils/TranslationEditPage.php M utils/TranslationHelpers.php 8 files changed, 78 insertions(+), 14 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/Translate refs/changes/01/20901/1 -- To view, visit https://gerrit.wikimedia.org/r/20901 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: Ic6dac5408637371660705877a6a0fa1eeef8455f Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/Translate Gerrit-Branch: master Gerrit-Owner: Jarry1250 ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Third and final merge commit from the translatesvg branch - change (mediawiki...Translate[master])
Jarry1250 has uploaded a new change for review. Change subject: Third and final merge commit from the translatesvg branch .. Third and final merge commit from the translatesvg branch Change-Id: Icfe1f058b03549969da737d7c2c3841b92c07bde --- M hooks.txt M resources/ext.translate.quickedit.js 2 files changed, 26 insertions(+), 15 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/Translate refs/changes/03/20903/1 -- To view, visit https://gerrit.wikimedia.org/r/20903 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: Icfe1f058b03549969da737d7c2c3841b92c07bde Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/Translate Gerrit-Branch: master Gerrit-Owner: Jarry1250 ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Fix a couple of messages that will now take a link. - change (mediawiki...TranslateSvg[master])
Jarry1250 has submitted this change and it was merged. Change subject: Fix a couple of messages that will now take a link. .. Fix a couple of messages that will now take a link. Per aharoni. Change-Id: Ib4269794d98eba33bba09b0a1b0e6c07315d6b39 --- M TranslateSvg.i18n.php 1 file changed, 4 insertions(+), 2 deletions(-) Approvals: Jarry1250: Verified; Looks good to me, approved -- To view, visit https://gerrit.wikimedia.org/r/21039 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: Ib4269794d98eba33bba09b0a1b0e6c07315d6b39 Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/TranslateSvg Gerrit-Branch: master Gerrit-Owner: Jarry1250 Gerrit-Reviewer: Jarry1250 ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Third and final merge commit from the translatesvg branch - change (mediawiki...Translate[translatesvg])
Jarry1250 has uploaded a new change for review. Change subject: Third and final merge commit from the translatesvg branch .. Third and final merge commit from the translatesvg branch Change-Id: Icfe1f058b03549969da737d7c2c3841b92c07bde --- M hooks.txt M resources/ext.translate.quickedit.js 2 files changed, 27 insertions(+), 16 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/Translate refs/changes/41/21041/1 -- To view, visit https://gerrit.wikimedia.org/r/21041 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: Icfe1f058b03549969da737d7c2c3841b92c07bde Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/Translate Gerrit-Branch: translatesvg Gerrit-Owner: Jarry1250 ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Commit SVGFormatReader, cornerstone of TranslateSvg - change (mediawiki...TranslateSvg[master])
Jarry1250 has submitted this change and it was merged. Change subject: Commit SVGFormatReader, cornerstone of TranslateSvg .. Commit SVGFormatReader, cornerstone of TranslateSvg SVGFormatReader is the class TranslateSvg uses for reading and manipulating the content of SVG files. It has a few functions of interest, most notably makeTranslationReady(), getTranslations() and getSVG(). Change-Id: I5c2e0f0a34dfc01e6738047c0b3934918f179618 --- A SVGFormatReader.php M TranslateSvg.php 2 files changed, 547 insertions(+), 1 deletion(-) Approvals: Jarry1250: Verified; Looks good to me, approved -- To view, visit https://gerrit.wikimedia.org/r/18182 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: I5c2e0f0a34dfc01e6738047c0b3934918f179618 Gerrit-PatchSet: 8 Gerrit-Project: mediawiki/extensions/TranslateSvg Gerrit-Branch: master Gerrit-Owner: Jarry1250 Gerrit-Reviewer: Jarry1250 Gerrit-Reviewer: MaxSem Gerrit-Reviewer: Nikerabbit ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Rewrite the ThumbnailImage constructor to take parameter arr... - change (mediawiki/core[master])
Jarry1250 has uploaded a new change for review. Change subject: Rewrite the ThumbnailImage constructor to take parameter array .. Rewrite the ThumbnailImage constructor to take parameter array This is required for a full resolution of bug #32987. Per Brion's commentary on that bug, for the long-term preservation of sanity we can't just keep adding arguments to the constructor whenever a new feature is added. Instead, we can have an array of optional parameters. At the moment, this situation is a bit iffy for width and height: we should really specify either a default height / width or error if one is not found. I'm open to ideas on that, but it's not a big deal since nothing uses the new syntax yet. When that is agreed, I'll convert all usage in core and maybe some extensions too. Change-Id: I116f71aeb90ef7c786f0874b150c7bcca527e106 --- M includes/media/MediaTransformOutput.php 1 file changed, 25 insertions(+), 5 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/core refs/changes/21/21321/1 -- To view, visit https://gerrit.wikimedia.org/r/21321 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I116f71aeb90ef7c786f0874b150c7bcca527e106 Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/core Gerrit-Branch: master Gerrit-Owner: Jarry1250 ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Minor cleanup. - change (mediawiki...TranslateSvg[master])
Jarry1250 has submitted this change and it was merged. Change subject: Minor cleanup. .. Minor cleanup. * Remove unused local variables. * Clarify pass-by-reference usage. * Use wfMessage()->text() instead of deprecated wfMsg(). Change-Id: I93fbf80cf3086aff9085efeeb0848e076a58caf3 --- M SVGFormatReader.php M TranslateSvgHooks.php 2 files changed, 16 insertions(+), 15 deletions(-) Approvals: Jarry1250: Verified; Looks good to me, approved -- To view, visit https://gerrit.wikimedia.org/r/21477 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: I93fbf80cf3086aff9085efeeb0848e076a58caf3 Gerrit-PatchSet: 2 Gerrit-Project: mediawiki/extensions/TranslateSvg Gerrit-Branch: master Gerrit-Owner: Siebrand Gerrit-Reviewer: Jarry1250 Gerrit-Reviewer: Nikerabbit ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] rm now unnecessary todo - change (mediawiki...TranslateSvg[master])
Jarry1250 has uploaded a new change for review. Change subject: rm now unnecessary todo .. rm now unnecessary todo Change-Id: Icc879adc2028c0344d2a855fea6ade217490a520 --- M TranslateSvgHooks.php 1 file changed, 0 insertions(+), 1 deletion(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/TranslateSvg refs/changes/13/21713/1 -- To view, visit https://gerrit.wikimedia.org/r/21713 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: Icc879adc2028c0344d2a855fea6ade217490a520 Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/TranslateSvg Gerrit-Branch: master Gerrit-Owner: Jarry1250 ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] rm now unnecessary todo - change (mediawiki...TranslateSvg[master])
Jarry1250 has submitted this change and it was merged. Change subject: rm now unnecessary todo .. rm now unnecessary todo Change-Id: Icc879adc2028c0344d2a855fea6ade217490a520 --- M TranslateSvgHooks.php 1 file changed, 0 insertions(+), 1 deletion(-) Approvals: Jarry1250: Verified; Looks good to me, approved -- To view, visit https://gerrit.wikimedia.org/r/21713 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: Icc879adc2028c0344d2a855fea6ade217490a520 Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/TranslateSvg Gerrit-Branch: master Gerrit-Owner: Jarry1250 Gerrit-Reviewer: Jarry1250 ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits