Commit Graph

28 Commits

Author SHA1 Message Date
Antony Male f7ec7a255a WIP towards getting unit tests working 2019-09-22 17:12:53 +01:00
Antony Male ffac9b6016 Fix bug in ViewManager when searching multiple assemblies
Also helpfully search the same assembly as the ViewModel was in
2016-03-22 18:40:50 +00:00
Antony Male 86896e97e5 Change the ViewManager to take a ViewManagerConfig configuration object
This means it possible for users to provide their own ViewManagers, without
having to use a .ToInstance() binding.
2016-01-29 12:47:16 +00:00
Antony Male 54cd9cf18f Revert the BindingProxy stuff
Trying to do this properly turns out to just be unworkable
2015-10-06 11:54:33 +01:00
Antony Male 81f256d231 Move away from separate ViewManagerConfig class 2015-09-25 15:19:23 +01:00
Antony Male 667564c3af Add support for customising 'View' and 'ViewModel' suffixes in ViewManager 2015-09-25 11:16:50 +01:00
Antony Male 8a6f010fbb Add support for namespace transformations to ViewManager 2015-09-25 10:57:46 +01:00
Antony Male 3dd1ec2bfe Ensure that ViewManagerConfig properties cannot be null 2015-09-25 10:43:17 +01:00
Antony Male 1731f2388a Change how ViewManager is configured
Instead of taking a reference to the Bootstrapper, it takes a configuration
object which is populated by the Bootrapper. This will pave the way for
easier views-in-multiple-assemblies handling in the near future...

This also involved some work to remove registering Stylet's assembly with
the IoC container and the ViewManager. It wasn't really necessary
anyway and just slowed things down.
2015-09-24 17:48:40 +01:00
Antony Male b378027018 Introduce proper testing 2015-09-24 13:02:54 +01:00
Antony Male fc7f164c53 Remove unnecessary usings in unit tests 2015-09-23 21:46:36 +01:00
Antony Male e222af3c84 Throw if the user tries to show a Window using s:View.Model
Fixes #5
2015-03-24 09:23:35 +00:00
Antony Male 21e6441a2f Re-jig ViewManager slightly to make it easier to override 2015-02-27 09:19:36 +00:00
Antony Male d2efcf48cb WindowManager avoids creating a new View if ViewModel already has a View attached 2015-02-22 16:47:34 +00:00
Antony Male dca24b4d5e Get unit test coverage back up 2015-01-14 20:30:51 +00:00
Antony Male f36de34bb2 Execute.Dispatcher can never be null, and dispatches synchronously by default
The previous behaviour was to raise an exception unless Execute.Dispatcher
had been explicitly defined. This was to detect cases where the user hadn't
set up Execute correctly, and treat them as errors rather than simply going
ahead with some possibly-unexpected behaviour.

However, since BootstrapperBase sets Execute.Dispatcher automatically, it's
highly unlikely that itwould ever not be set when it needed to be. Exceptions
are design mode and unit tests, both of which want (or can cope with) a
synchronous dispatcher.

Hence the behaviour change. Execute.Dispatcher is a synchronous dispatcher
by default, but is overridden to one that uses Application.Current.Dispatcher
by the bootstrapper if we're in a real application.
2015-01-04 21:30:34 +00:00
Antony Male 27b80717ea Make View name resolution a bit smarter 2015-01-04 17:05:16 +00:00
Antony Male 9ee23f1469 Remove Execute.TestExecuteSynchronously, in favour of a synchronous IDispatcher implementation 2015-01-04 13:10:37 +00:00
Antony Male 743961ec68 ViewManager now accepts an IViewManagerConfig, which makes the IoC container setup neater 2014-12-02 12:52:58 +00:00
Antony Male a421fc6922 Remove AssemblySource, relying instead on a List<Assembly> on BootstrapperBase 2014-11-30 15:19:13 +00:00
Antony Male e36179098e ViewManager no longer depends on IoC 2014-11-30 14:05:08 +00:00
Antony Male 60aca05dd2 Simplify IViewManager, by aligning it to what someone actually wants the ViewManager to do 2014-07-24 16:39:26 +01:00
Antony Male 3e4e09a598 Prevent double closure of a Screen 2014-07-24 09:45:20 +01:00
Antony Male eeeb761e0d ViewManager methods should have been protected... 2014-05-26 19:13:08 +01:00
Antony Male a914d58668 Refactor the ViewManager, splitting out a few methods to make it easier to customize 2014-05-26 18:54:55 +01:00
Antony Male b89c61a91e Move View into the Xaml namespace, so it's accessible through https://github.com/canton7/Stylet 2014-05-11 20:02:21 +01:00
Antony Male fc4a7fb61c Push coverage up to 99.7% 2014-05-10 20:11:02 +01:00
Antony Male 43fe090fa9 Add more unit tests 2014-05-07 13:20:36 +01:00