Add Application.mainWindow attribute
Add Application.mainWindow attribute

Also define the Application public interface.

There are a lot of changes and many things left to test, so this is
somewhat of a work in progress.

tmandry/Swindler,tmandry/Swindler,tmandry/AXSwift,tmandry/Swindler,tmandry/AXSwift