Example #1
0
 void userJoins(DiscUser usr)
 {
     if (usr.usrDbId == loginInfo.person.Id && wndCtx == null)
     {
         var topic = DbCtx.Get().Topic.FirstOrDefault(t0 => t0.Name.StartsWith("d-editor"));
         wndCtx = new EditorWndCtx(scene,
                                   inkCanv,
                                   palette,
                                   inkPalette,
                                   this,//surface window for focus fix
                                   topic.Id,
                                   topic.Discussion.Id);
         DataContext = this;
         rt.clienRt.SendInitialSceneLoadRequest(topic.Id);
     }
 }
Example #2
0
 void userJoins(DiscUser usr)
 {
     if (usr.usrDbId == loginInfo.person.Id && wndCtx == null)
     {
         var topic = DbCtx.Get().Topic.FirstOrDefault(t0 => t0.Name.StartsWith("d-editor"));
         wndCtx = new EditorWndCtx(scene,
                                   inkCanv,
                                   palette,
                                   inkPalette,
                                   this,//surface window for focus fix
                                   topic.Id,
                                   topic.Discussion.Id);
         DataContext = this;
         rt.clienRt.SendInitialSceneLoadRequest(topic.Id);
     }
 }
Example #3
0
        private void CreateEditCtx()
        {
            CleanupEditCtx();

            avaBar.SelectCurrentUser();

            editCtx = new EditorWndCtx(scene,
                                       inkCanv,
                                       palette,
                                       inkPalette,
                                       this, //surface window for focus fix                                      
                                       _topicId != -1 ? _topicId : CurrentTopic.Id,
                                       _discussionId != -1 ? _discussionId : CurrentTopic.Discussion.Id,
                                       _shapesVisibile);

            editCtx.ZoomManipulator.Delta += Window_ManipulationDelta;

            DataContext = this;
            _sharedClient.clienRt.SendInitialSceneLoadRequest(_topicId != -1 ? _topicId : CurrentTopic.Id);
        }
Example #4
0
        private void CleanupEditCtx()
        {
            if (editCtx != null)
            {
                editCtx.ZoomManipulator.Delta -= Window_ManipulationDelta;

                editCtx.CleanupScene();
                editCtx = null;
            }
        }