Exemplo n.º 1
0
        private async Task OnSectionCreated(SectionCreated msg)
        {
            var notebooks = await _notebook.GetNotebooks();

            var updatedParentNotebook =
                notebooks.SingleOrDefault(n => n.Directory.FullName == msg.NewSectionParentNotebook.Directory.FullName);

            await GetSections(updatedParentNotebook);
        }
Exemplo n.º 2
0
        private async Task OnSectionCreated(SectionCreated msg)
        {
            var notebooks = await _notebook.GetNotebooks();

            var selectedNotebook = Notebooks.Single(n => n.IsSelected);

            await DoOnUiDispatcherAsync(() =>
            {
                Notebooks.Clear();
                notebooks.ForEach(n =>
                {
                    if (n.Id == selectedNotebook.Id)
                    {
                        n.Select();
                    }
                    Notebooks.Add(n);
                });
            });
        }
Exemplo n.º 3
0
 public void Handle(SectionCreated evnt)
 {
     SectionTest.SectionId = evnt.SectionId;
     TestBase.EventHandlerWaiter.Set();
 }
Exemplo n.º 4
0
 void IEventHandler <SectionCreated> .Handle(SectionCreated evnt)
 {
     Name = evnt.Name;
 }