Register schemas using hooks not via globals


Register schemas using hooks not via globals

... and not via a combination of both.

As in the solution to T102708, always register the ext.gather.schema
module but add the required schemas as dependencies when the
EventLogging extension is loaded.

As the EventLogging extension currently isn't loaded using the
ExtensionRegistry, i.e. via the wfLoadExtension function, we have to
reuse a test from the MobileFrontend [0] extension.

[0] https://github.com/wikimedia/mediawiki-extensions-MobileFrontend/blob/master/includes/MobileFrontend.body.php#L21

Bug: T106759
Bug: T102708
Change-Id: I6b13c0bf4b89648d8b8879d3e41ae05ea41ab33a