Clone wizard and related: refactor, clean-up, fixes or improvements
At some stage, it was hard to change or improve anything in Clone wizard
or reuse some of its components without some global refactor or clean-up.
This changeset introduces some common patterns of handling internal pages
validation and inter-pages dependencies, it tries to address existing
issues (complicated internal dependencies, redundant asymmetrical code)
with clone code that IMHO were making it hard to maintain or modify.
Some of these changes introduce new behavior (fixes or improvements),
as it was hard for me to separate this in my iterative process...
- Remove mess of using both setPageComplete() and custom isPageComplete().
Now, checkPage() is used (calling setPageComplete()) instead - for
internal validation, while direct setPageComplete() calls are used in
special situations like handling inter-pages dependencies.
- RepositorySelection class introduces encapsulated result of
RepositorySelectionPage with helper methods working on that result.
- SelectionChangeListener became new common interface for notifying other
(dependent) pages about selection changes in current page.
BaseWizardPage is helper abstract class handling these listeners.
- User can move backward in wizard, change something, revert this change,
then subsequent pages doesn't set page complete to false. It's now
supported in common way in whole wizard by *selectionEquals() methods.
- Real-time checking for some fields of destination page is introduced.
- Minor changes like renames or some simplifications, forgotten changes.
Some of this commit resulting components, may be reused in other places,
that's why they are actually in .components package.
Signed-off-by: Marek Zawirski <marek.zawirski@gmail.com>
Signed-off-by: Robin Rosenberg <robin.rosenberg@dewire.com>