Commit graph

20 commits

Author SHA1 Message Date
Ed Sanders 9111107de8 CodeEditor: Avoid movement while loading
Bug: T73015
Change-Id: I0ce663ebad4bb9ab9f435aeba65c545ee21e0680
2023-10-15 07:21:36 +00:00
Fomafix 0094c01f7f Use namespaced classes
Change-Id: If12b9c731ff89e2ca2d855f9d3ed4b887f9a356e
2023-10-03 09:11:09 +00:00
gerritbot 4f513b6232 Replace some moved Title class uses, now MediaWiki\Title\Title
Bug: T321681
Change-Id: I1de316ddfa572a72ca68f9806b93f958286c8ef2
2023-08-19 04:14:04 +00:00
Umherirrender 4d6a470aae Create HookRunner class and the hook handler interface
Bug: T271013
Change-Id: Ie8e152530599d11da12cb9272a3b757da1cca1ab
2023-06-04 21:23:14 +02:00
gerritbot 417ce7bebf Update moved class EditPage
See T321882. Moved in Ibefc44eb64aed

Bug: T321681
Change-Id: I5a66b76658c3eb19f2afe5b9a8ce4748767e6c2d
2023-05-06 21:19:29 +00:00
Umherirrender 10dddec75b Replace deprecated Hooks::run
Bug: T335536
Change-Id: Ifc18d80c15f714d58aef33c9991079db9406a19e
2023-04-29 20:13:21 +02:00
Roman Stolar 51cd95fac9 Avoid using User::getOption and inject service UserOptionsLookup
Remove using of User:getOption since this method will be hard-deprecated. Now it is soft-deprecated

Bug: T296083
Change-Id: Iae0c0cd3ab4ffdfd6cfce5e7ced81dfae3d4a359
2021-11-26 08:36:11 +00:00
Fomafix ad1930d255 Use HookHandlers and implement hook interfaces
Change-Id: I9313f4cff24ceb9c83d5a529ec3064330eabb8c6
2021-11-25 20:14:37 +00:00
Fomafix d7117949b1 Use namespace MediaWiki\Extension\CodeEditor in PHP
An alias with the old class name CodeEditorHooks is not added because
there are no external findings on
https://codesearch.wmcloud.org/search/?q=CodeEditorHooks

Change-Id: I88cb3a506d196d918ce852e46433dad808ae2a6c
2021-11-25 19:41:48 +00:00
Fomafix bcb7eed32d Use single quotes instead of double quotes in PHP
Change-Id: I9d32e36a14c25139cd735bd6657c5d46df573e15
2021-10-30 19:14:59 +00:00
jenkins-bot d75911245e Merge "Revert "Directly use $wgTitle instead of relying on getContextTitle fallback"" 2020-01-01 23:31:56 +00:00
Legoktm 212477a083 Revert "Directly use $wgTitle instead of relying on getContextTitle fallback"
This reverts commit b3fb04b463.

The problem is *not* getContextTitle() - that's the correct
function to call here. The problem is that something is creating
an EditPage instance without calling setContextTitle() - that's
what needs to be fixed.

Change-Id: Ibc8280c7434bee4c4697142bcdbc1194f00c53c1
2020-01-01 23:16:28 +00:00
Brian Wolff f8d9cdebdb Make CodeEditor compatible with CSP
Adds a "script-src blob:" directive on pages using CodeEditor.
This should allow using the blob-based web-worker that ACE uses.

This bumps the MediaWiki dependency to current master (1.35.0+).

Bug: T214743
Depends-on: I68054644220cd03bc96cf8ffb9c7ee375be77f96
Change-Id: I40612274a7e1d964119433442d992a8bf67f61af
2019-10-28 12:41:05 +00:00
Daimona Eaytoy b3fb04b463 Directly use $wgTitle instead of relying on getContextTitle fallback
This is apparently the only code relying on the fallback. Since it seems to do this most of the time, use $wgTitle directly.

Bug: T176526
Change-Id: I9edc7c3cb7b0f2b024873b2f6fbdb8c275225854
2019-09-30 17:38:56 +00:00
James D. Forrester 988bc3c0b1 Drop wgCodeEditorEnableCore, default on, pointless to disable
Change-Id: I637ac6cc92183dbf73b6bb39d487c6d4099657be
2019-07-12 10:58:50 -07:00
Derick Alangi 92c432ab83 Remove "return true" legacy behavior from hook handler functions
Change-Id: Ie33721116c5ae665f45ed0a8baeace031cfeca89
2019-02-02 10:06:40 +01:00
Derick Alangi ef09440a94 Fix PHPDoc comment @return for CodeEditorHooks methods
Should return "true" (as there is no case for false) and not bool.

Change-Id: I2badcbb3b06c8a9593908b064629bfef8ea82488
2019-01-16 14:46:28 +01:00
Fomafix 6aa0a7016a Add typehints to function parameters
Change-Id: I820f7be8486c2f5d560eabe84629dd41db774735
2018-12-16 12:04:49 +01:00
Kunal Mehta fefe8893a4 Set an explicit visibility on getPageLanguage()
Change-Id: I37407f8aa5f0f9d3066583f1a54e79de0c5ca129
2018-04-14 01:44:58 +00:00
Kunal Mehta 99cd2828eb Move classes into includes/
Change-Id: I9ece489e16d214990191e5077e6271bd95fdb08c
2018-02-09 00:25:20 -08:00