Exemple #1
0
        private void ShowAddressBook()
        {
            activeContactController      = contactControllerFactory.CreateExport().Value;
            activeContactController.Root = Root;
            activeContactController.Initialize();
            activeContactController.Run();

            var uiNewContactCommand = new ToolBarCommand(activeContactController.NewContactCommand, "_New contact", "Creates a new contact.");
            var uiDeleteCommand     = new ToolBarCommand(activeContactController.DeleteContactCommand, "_Delete", "Deletes the selected contact.");

            shellService.AddToolBarCommands(new[] { uiNewContactCommand, uiDeleteCommand });
        }
Exemple #2
0
    private void ShowEmails(EmailFolder emailFolder)
    {
        activeEmailFolderController             = emailFolderControllerFactory.CreateExport().Value;
        activeEmailFolderController.EmailFolder = emailFolder;
        activeEmailFolderController.Initialize();
        activeEmailFolderController.Run();
        var uiNewEmailCommand      = new ToolBarCommand(newEmailCommand, "_New email", "Creates a new email.");
        var uiDeleteEmailCommand   = new ToolBarCommand(activeEmailFolderController.DeleteEmailCommand, "_Delete", "Deletes the selected email.");
        var uiEmailAccountsCommand = new ToolBarCommand(emailAccountsController.EmailAccountsCommand, "_Email accounts", "Opens a window that shows the email accounts.");

        shellService.AddToolBarCommands(new[] { uiNewEmailCommand, uiDeleteEmailCommand, uiEmailAccountsCommand });
    }