public MainPresenter(AppController controller)
        {
            //inicialização dos controles
            this.controller = controller;
            this.mainWindow = new MainWindow(this);
            this.mainPage = new Main(this);
            this.principalPage = new Principal(this);
            this.shortcutsPage = new Shortcuts(this);

            //carregamento de paginas e conteudos visuais adicionais
            this.mainWindow.principal.Navigate(this.principalPage);
            this.mainWindow.shortcuts.Navigate(this.shortcutsPage);

            //carregamento dos dados
            IEnumerable<Testamento> testamentos = from Testamento t in controller.DefaultContainer
                                        select t;
            IEnumerable<Livro> livros = from Livro l in controller.DefaultContainer
                                        select l;

            this.textSuggest = new SimpleTextSuggester(livros, ActivateSbItem);
            this.sbItemSuggest = new SimpleSbItemSuggester(livros, ActivateSbItem);

            this.shortcutsPage.Traducoes = (new SbDbManager()).Databases;
            this.shortcutsPage.Testamentos = testamentos;

            //carregamento das configurações salvas
            this.principalPage.busca.Text = this.controller.DefaultTerm;

            //exibição do site no primeiro acesso ou em uma atualização de versão
            if (Settings.Default.VersaoVisualizadaNoSite != Application.ResourceAssembly.GetName().Version.ToString())
            {
                StaticContentGenerator.OpenSite(Resources.linkSitePrimeiroUso);
                Settings.Default.VersaoVisualizadaNoSite = Application.ResourceAssembly.GetName().Version.ToString();
            }
        }
        public MainPresenter(AppController controller)
        {
            //inicialização dos controles
            this.controller    = controller;
            this.mainWindow    = new MainWindow(this);
            this.mainPage      = new Main(this);
            this.principalPage = new Principal(this);
            this.shortcutsPage = new Shortcuts(this);

            //carregamento de paginas e conteudos visuais adicionais
            this.mainWindow.principal.Navigate(this.principalPage);
            this.mainWindow.shortcuts.Navigate(this.shortcutsPage);

            //carregamento dos dados
            IEnumerable <Testamento> testamentos = from Testamento t in controller.DefaultContainer
                                                   select t;
            IEnumerable <Livro> livros = from Livro l in controller.DefaultContainer
                                         select l;

            this.textSuggest   = new SimpleTextSuggester(livros, ActivateSbItem);
            this.sbItemSuggest = new SimpleSbItemSuggester(livros, ActivateSbItem);

            this.shortcutsPage.Traducoes   = (new SbDbManager()).Databases;
            this.shortcutsPage.Testamentos = testamentos;

            //carregamento das configurações salvas
            this.principalPage.busca.Text = this.controller.DefaultTerm;

            //exibição do site no primeiro acesso ou em uma atualização de versão
            if (Settings.Default.VersaoVisualizadaNoSite != Application.ResourceAssembly.GetName().Version.ToString())
            {
                StaticContentGenerator.OpenSite(Resources.linkSitePrimeiroUso);
                Settings.Default.VersaoVisualizadaNoSite = Application.ResourceAssembly.GetName().Version.ToString();
            }
        }
        public Searcher(string containerFileName, string indexFileName)
        {
            this.DefaultContainer = Container.GetContainer(containerFileName);
            this.DefaultIndex = new Index(indexFileName);

            IEnumerable<Livro> livros = from Livro l in DefaultContainer
                                        select l;
            this.sbItemSuggest = new SimpleSbItemSuggester(livros, ActivateSbItem);
        }
        public Searcher(string containerFileName, string indexFileName)
        {
            this.DefaultContainer = Container.GetContainer(containerFileName);
            this.DefaultIndex     = new Index(indexFileName);

            IEnumerable <Livro> livros = from Livro l in DefaultContainer
                                         select l;

            this.sbItemSuggest = new SimpleSbItemSuggester(livros, ActivateSbItem);
        }