コード例 #1
0
        public TaskListView(TaskListController controller)
        {
            InitializeComponent();

            //this.controller = controller;
            controller.OnLoad();
            this.taskListControllerBindingSource.DataSource = controller;
        }
コード例 #2
0
        private void OnApplicationStartup(object sender, StartupEventArgs e)
        {
            CreateMappings();

            var settings = new ApplicationSettings();
            var taskService = new TaskServiceAdo(settings);
            var objectMapper = new MapperAutoMapper();
            controller = new TaskListController(taskService, objectMapper);
            MainWindow = new TaskListView(controller);
            MainWindow.Show();

            controller.OnLoad();
        }