[MediaWiki-commits] [Gerrit] Add hook MathMLChanged - change (mediawiki...Math)
Physikerwelt has uploaded a new change for review. https://gerrit.wikimedia.org/r/117840 Change subject: Add hook MathMLChanged .. Add hook MathMLChanged The MathMLChanged hook is called every time the MathML value is changed. It can be used for compression, normalization or introduction of custom hyperlinks etc. Change-Id: I3f72c26f928a02fd4e84a7fad500c7c8591b2dab --- M MathRenderer.php M docs/hooks.txt 2 files changed, 8 insertions(+), 1 deletion(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/Math refs/changes/40/117840/1 diff --git a/MathRenderer.php b/MathRenderer.php index a8f2656..50c2a87 100644 --- a/MathRenderer.php +++ b/MathRenderer.php @@ -484,6 +484,7 @@ */ public function setMathml( $mathml ) { $this-changed = true; + wfRunHooks( 'MathMLChanged', array( $this , $mathml) ); $this-mathml = $mathml; } diff --git a/docs/hooks.txt b/docs/hooks.txt index afb02b8..7c7b646 100644 --- a/docs/hooks.txt +++ b/docs/hooks.txt @@ -18,4 +18,10 @@ 'MathAfterTexvc': $this: MathTexvc object -$errmsg: error message \ No newline at end of file +$errmsg: error message + +'MathMLChanged': Is called before the MathML property is changed + can be used e.g. for compression, normalization or introduction of + custom hyperlinks etc. +$this: MathRenderer object +$mathml: error message \ No newline at end of file -- To view, visit https://gerrit.wikimedia.org/r/117840 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I3f72c26f928a02fd4e84a7fad500c7c8591b2dab Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/Math Gerrit-Branch: dev Gerrit-Owner: Physikerwelt w...@physikerwelt.de ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Add hook MathMLChanged - change (mediawiki...Math)
jenkins-bot has submitted this change and it was merged. Change subject: Add hook MathMLChanged .. Add hook MathMLChanged The MathMLChanged hook is called every time the MathML value is changed. It can be used for compression, normalization or introduction of custom hyperlinks etc. Change-Id: I3f72c26f928a02fd4e84a7fad500c7c8591b2dab --- M MathRenderer.php M docs/hooks.txt 2 files changed, 8 insertions(+), 1 deletion(-) Approvals: Physikerwelt: Looks good to me, approved jenkins-bot: Verified diff --git a/MathRenderer.php b/MathRenderer.php index a8f2656..50c2a87 100644 --- a/MathRenderer.php +++ b/MathRenderer.php @@ -484,6 +484,7 @@ */ public function setMathml( $mathml ) { $this-changed = true; + wfRunHooks( 'MathMLChanged', array( $this , $mathml) ); $this-mathml = $mathml; } diff --git a/docs/hooks.txt b/docs/hooks.txt index afb02b8..7c7b646 100644 --- a/docs/hooks.txt +++ b/docs/hooks.txt @@ -18,4 +18,10 @@ 'MathAfterTexvc': $this: MathTexvc object -$errmsg: error message \ No newline at end of file +$errmsg: error message + +'MathMLChanged': Is called before the MathML property is changed + can be used e.g. for compression, normalization or introduction of + custom hyperlinks etc. +$this: MathRenderer object +$mathml: error message \ No newline at end of file -- To view, visit https://gerrit.wikimedia.org/r/117840 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: I3f72c26f928a02fd4e84a7fad500c7c8591b2dab Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/Math Gerrit-Branch: dev Gerrit-Owner: Physikerwelt w...@physikerwelt.de Gerrit-Reviewer: Physikerwelt w...@physikerwelt.de Gerrit-Reviewer: jenkins-bot ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits