It’s time to give the project some love, and put down some code to fix ideas.I created a new solution and started to transfer feature one after one.
I kept the overall structure of the original project to simplify comparison between the two implementation and because I found it quite neat. The two project created are the exe project, containing the shell, and an Infrastructure library, containing common interfaces and classes (just like the original StockTraderRI):
The first step I decided to take is to setup the project structure and have the shell starting.
Original application doesn’t have a presenter for the shell, so I created an IShellPresenter interface in Infrastructure proejct (I’ll need to reference it in the modules) and an implementation in the exe project:
The Singleton attibute is used to auto-register the class within the container with a singleton lifestyle; the View attribute indicates Caliburn which view should be used to “visually represent” the presenter.
The markup for the shell view (ShellView.xaml) was only slightly modified to remove reference to CompositeWPF library and to custom controls, whose features will be implemented later.
To have the first window running, I had to configure Caliburn. I chosen to derive my App class from CaliburnApplication, so I just had to indicate the root model for the application:
That’s all. I can start the application and the main window shows as well (with no content, for now):
Next time I’ll add the first real feature of the app; since all feature in original StockTraderRI resides in modules, I also have to deal with module loading and configuration.
I also should setup an online code repository to share the code.