This is an issue derived from the meta issue #1770720: [META] Gradual changes to Field UI and #1786198: Make consistent regions in code for fields UI overview screens.
The changes abstract common behavior into base functionality for the manage fields and manage display screens.
It will also include some very minor changes which add consistency between the two screens.
Form UI functions
Basically this is a straight forward copy from the old form functions into a subclass of Drupal/field_ui/OverviewBase. There are no major changes inside the form api code.
Two alter hooks that were added in core later on (during re-roll) were added here too. For the rest everything is the same. The real refactoring to make it consistent will be done in #1786198: Make consistent regions in code for fields UI overview screens.
The list of changes:
- previous drupal_get_form from router item is changed to a page callback that load the forms from a class method.
- $view_mode became $this->view_mode
- $bundle became $this->bundle
- $entity_type became $this->entity_type
- regions are defined in the Overview object
- Added hook_field_formatter_settings_form_alter
- Added hook_field_formatter_settings_summary_alter
- validate and submit handlers are addressed through OOP methods (and added inside the form function)
- Moving the variables to $form_state['key'] instead of $form['#key'] is a follow up