Add a hook to Title::getEditNotices() so extensions can add them

FlaggedRevs will have to use this to expose its edit notices to
VisualEditor.

Also add an $oldid parameter so edit notices can be generated based
on the revision ID being edited.

Change-Id: Ie44a01ebfa7002fa3a89f081e0f831442666ac03