Cleanup init() function of ElementBrowser
Right now the init() function of the element browser has ~450 lines :)
We should refactor it in the similar way it was already done in SelectImage and BrowseLinks.
This will also allow us to remove duplicate code between these classes.
[TASK] Refactor init() function of ElementBrowser
Splits huge method (~450 lines) into several small methods,
in the similar way it was done for BrowseLinks and SelectImage.
It also removes some duplicated code between these classes.
This patch is not changing functionality, just moving code around.
Reviewed-by: Markus Klein
Tested-by: Markus Klein
Reviewed-by: Christian Kuhn
Tested-by: Christian Kuhn