public QuestEditorWindow()
        {
            InitializeComponent();

            CommandBindings.Add(new CommandBinding(ApplicationCommands.Delete, ExecutedDelete, CanExecuteDelete));
            CommandBindings.Add(new CommandBinding(AddStage, ExecutedAddStage, CanExecuteAddStage));
            CommandBindings.Add(new CommandBinding(AddQuest, ExecutedAddQuestCommand, CanExecuteAddQuestCommand));

            ModelQuest q = new ModelQuest() { Title = "Test quest", ID = "test" };
            Proxy.ProxyStory s = new Proxy.ProxyStory(mStory);
            s.AddQuest(s.CreateNewQuest());
            s.AddQuest(s.CreateNewQuest());
            s.AddQuest(s.CreateNewQuest());
            s.AddQuest(s.CreateNewQuest());

            mStoryTreeView.DataContext = s;
            mProxyStory = s;

               // CommandBindings.Add(new CommandBinding(QuestEditorWindow.AddQuest, ExecutedAddQuestCommand, CanExecuteAddQuestCommand));
        }
Example #2
0
        public QuestEditorWindow()
        {
            InitializeComponent();

            CommandBindings.Add(new CommandBinding(ApplicationCommands.Delete, ExecutedDelete, CanExecuteDelete));
            CommandBindings.Add(new CommandBinding(AddStage, ExecutedAddStage, CanExecuteAddStage));
            CommandBindings.Add(new CommandBinding(AddQuest, ExecutedAddQuestCommand, CanExecuteAddQuestCommand));

            ModelQuest q = new ModelQuest()
            {
                Title = "Test quest", ID = "test"
            };

            Proxy.ProxyStory s = new Proxy.ProxyStory(mStory);
            s.AddQuest(s.CreateNewQuest());
            s.AddQuest(s.CreateNewQuest());
            s.AddQuest(s.CreateNewQuest());
            s.AddQuest(s.CreateNewQuest());

            mStoryTreeView.DataContext = s;
            mProxyStory = s;

            // CommandBindings.Add(new CommandBinding(QuestEditorWindow.AddQuest, ExecutedAddQuestCommand, CanExecuteAddQuestCommand));
        }