application reusable code refactored

Should now permit to update the preferences dialog and main reusable
code from the iPlug source code with lesser code duplication.