public void SignificantMouseMovement(Point initialPosition, Point currentPosition, bool expected)
        {
            var view      = new MockMainFormView();
            var presenter = new MainFormPresenter(MockLogger.Object, view, null, MockBoundaries);

            Assert.Equal(expected, presenter.SignificantMouseMovement(initialPosition, currentPosition));
        }
Exemplo n.º 2
0
        public MainForm()
        {
            InitializeComponent();

            listBoxCommands.DataSource = commands;
            numericUpDownDelay.DataBindings.Add("Value", this, "currentCommandDelay", false, DataSourceUpdateMode.OnPropertyChanged);
            numericUpDownX.DataBindings.Add("Value", this, "currentCommandX", false, DataSourceUpdateMode.OnPropertyChanged);
            numericUpDownY.DataBindings.Add("Value", this, "currentCommandY", false, DataSourceUpdateMode.OnPropertyChanged);
            groupBoxPosition.DataBindings.Add("Enabled", this, "canChangePosition", false, DataSourceUpdateMode.OnPropertyChanged);
            groupBoxEdit.DataBindings.Add("Enabled", this, "canEdit", false, DataSourceUpdateMode.OnPropertyChanged);
            groupBoxKey.DataBindings.Add("Enabled", this, "canChangeKey", false, DataSourceUpdateMode.OnPropertyChanged);


            var groupBoxRecordSettingsEnabledBinding = new Binding("Enabled", this, "isRecordingRunning");

            groupBoxRecordSettingsEnabledBinding.Parse  += switchBool;
            groupBoxRecordSettingsEnabledBinding.Format += switchBool;
            groupBoxRecordSettings.DataBindings.Add(groupBoxRecordSettingsEnabledBinding);


            var groupBoxExecutionSettingsEnabledBinding = new Binding("Enabled", this, "isMacroRunning");

            groupBoxExecutionSettingsEnabledBinding.Parse  += switchBool;
            groupBoxExecutionSettingsEnabledBinding.Format += switchBool;
            groupBoxExecutionSettings.DataBindings.Add(groupBoxExecutionSettingsEnabledBinding);



            presenter          = new MainFormPresenter(this);
            isRecordingRunning = false;
            isMacroRunning     = false;
            dispatcher         = Dispatcher.CurrentDispatcher;
        }
 public void Initialization()
 {
     _controller = new Mock <IApplicationController>();
     _view       = new Mock <IMainFormView>();
     _model      = new Mock <GlobalWizardViewModel>(It.IsAny <string>());
     _presenter  = new MainFormPresenter(_controller.Object, _view.Object, _model.Object);
 }
Exemplo n.º 4
0
        public mainForm()
        {
            InitializeComponent();
            var mainFormPresenter = new MainFormPresenter(this, new AddressBook());

            findAgainToolStripMenuItem.Enabled = false;
        }
 public void Initialization()
 {
     _controller = new Mock<IApplicationController>();
     _view = new Mock<IMainFormView>();
     _model = new Mock<GlobalWizardViewModel>(It.IsAny<string>());
     _presenter = new MainFormPresenter(_controller.Object, _view.Object, _model.Object);
 }
Exemplo n.º 6
0
        public MainForm()
        {
            InitializeComponent();

            var presenter = new MainFormPresenter(this);

            this.Attach(presenter);
        }
Exemplo n.º 7
0
 private void MainForm_Load(object sender, EventArgs e)
 {
     presenter = new MainFormPresenter(this);
     presenter.formLoad();
     timer.Interval = 10;
     timer.Elapsed += timerElapsed;
     timer.Start();
 }
Exemplo n.º 8
0
        static void Main()
        {
            Application.EnableVisualStyles();
            Application.SetCompatibleTextRenderingDefault(false);
            var fridgeShop = new FridgeShop();
            MainFormPresenter mainFormPresenter = new MainFormPresenter(fridgeShop);

            Application.Run(fridgeShop);
        }
        public MainForm()
        {
            InitializeComponent();

            _presetnerMain = new MainFormPresenter(this);
            _displayData   = DisplayOfData.Instance;

            InitializeComponentMainForm();
        }
Exemplo n.º 10
0
        static void Main()
        {
            Application.EnableVisualStyles();
            Application.SetCompatibleTextRenderingDefault(false);
            MainFormView      _view      = new MainFormView();
            MainFormPresenter _presenter = new MainFormPresenter(_view);

            Application.Run(_view);
        }
Exemplo n.º 11
0
        static void Main()
        {
            Application.EnableVisualStyles();
            Application.SetCompatibleTextRenderingDefault(false);
            MainForm          booksAuthorsPresses = new MainForm();
            MainFormPresenter mainFormPresenter   = new MainFormPresenter(booksAuthorsPresses);

            Application.Run(booksAuthorsPresses);
        }
Exemplo n.º 12
0
        private static void Main()
        {
            Application.EnableVisualStyles();
            Application.SetCompatibleTextRenderingDefault(false);
            var view      = new MainForm();
            var presenter = new MainFormPresenter(view);

            Application.Run(view);
        }
Exemplo n.º 13
0
 public void startNetCheck(MainFormPresenter presenter)
 {
     if (presenter == null)
     {
         return;
     }
     this.presenter = presenter;
     thread         = new Thread(ThreadMethed);
     thread.Start();
 }
        private void officeNavigationBar1_RegisterItem(object sender, NavigationBarNavigationClientItemEventArgs e)
        {
            NavBarGroup navGroup = (NavBarGroup)e.NavigationItem;
            var         type     = (ModuleType)navGroup.Tag;

            e.Item.Tag  = type;
            e.Item.Text = MainFormPresenter.GetDisplayText(type);
            e.Item.Name = "navItem" + MainFormPresenter.GetName(type);
            e.Item.BindCommand((t) => ViewModel.SelectModule(t), ViewModel, () => type);
        }
        public async Task GetImageFromGallery_GalleryDoesntThrowException_IndicatesSuccess()
        {
            var view           = new MockMainFormView();
            var galleryService = new Mock <IGalleryService>();
            var presenter      = new MainFormPresenter(MockLogger.Object, view, galleryService.Object, MockBoundaries);

            var actual = await presenter.GetImageFromGallery(new Size(320, 240));

            Assert.NotNull(actual);
            Assert.False(actual.HadError);
            Assert.True(string.IsNullOrEmpty(actual.ErrorMessage));
        }
 void RegisterNavigationItems(ModuleType[] modules)
 {
     NavBarGroup[] groups = new NavBarGroup[modules.Length];
     for (int i = 0; i < modules.Length; i++)
     {
         NavBarGroup navGroup = new NavBarGroup();
         navGroup.Tag     = modules[i];
         navGroup.Name    = "navGroup" + MainFormPresenter.GetName(modules[i]);
         navGroup.Caption = MainFormPresenter.GetDisplayText(modules[i]);
         groups[i]        = navGroup;
     }
     navBarControl1.Groups.AddRange(groups);
 }
Exemplo n.º 17
0
        public SidePanelActionsHandler(OsuFileIo osuFileIo, ICollectionEditor collectionEditor, IUserDialogs userDialogs, IMainFormView mainForm, IBeatmapListingBindingProvider beatmapListingBindingProvider, MainFormPresenter mainFormPresenter, ILoginFormView loginForm)
        {
            _osuFileIo        = osuFileIo;
            _collectionEditor = collectionEditor;
            _userDialogs      = userDialogs;
            _mainForm         = mainForm;
            _beatmapListingBindingProvider = beatmapListingBindingProvider;
            _mainFormPresenter             = mainFormPresenter;
            _loginForm           = loginForm;
            _collectionGenerator = new CollectionsApiGenerator(Initalizer.OsuFileIo.LoadedMaps);

            BindMainFormActions();
        }
Exemplo n.º 18
0
        public MainForm()
        {
            InitializeComponent();
            AllowTransparency = true;
            presenter         = new MainFormPresenter(this, new JediSettings());

            mouseHook                   = new MouseHook();
            mouseHook.MouseEvent       += MouseHookMouseEvent;
            keyboardHook                = new KeyboardHook();
            keyboardHook.KeyboardEvent += KeyboardHookKeyboardEvent;
            mgr.ShortcutActivated      += mgr_OnShortcutActivated;
            keyboardHook.InstallHook();
        }
Exemplo n.º 19
0
        }                                             // = new GuiComponents.UserDialogs();


        public void Run()
        {
            //IUserDialogs can be implemented in WinForm or WPF or Gtk or Console or...?
            UserDialogs = GuiComponentsProvider.Instance.GetClassImplementing <IUserDialogs>();

            //Get osu! directory, or end if it can't be found
            OsuDirectory = OsuFileIo.OsuPathResolver.GetOsuDir(UserDialogs.IsThisPathCorrect, UserDialogs.SelectDirectory);
            if (OsuDirectory == string.Empty)
            {
                UserDialogs.OkMessageBox("Valid osu! directory is required to run Collection Manager" + Environment.NewLine + "Exiting...", "Error", MessageBoxType.Error);
                Quit();
            }

            //Load osu database and setting files
            var osuDbFile = Path.Combine(OsuDirectory, @"osu!.db");

            OsuFileIo.OsuDatabase.Load(osuDbFile);
            OsuFileIo.OsuSettings.Load(OsuDirectory);
            BeatmapUtils.OsuSongsDirectory = OsuFileIo.OsuSettings.CustomBeatmapDirectoryLocation;

            //Init "main" classes
            CollectionsManager = new CollectionsManagerWithCounts(LoadedBeatmaps);

            var collectionAddRemoveForm = GuiComponentsProvider.Instance.GetClassImplementing <ICollectionAddRenameForm>();

            CollectionEditor = new CollectionEditor(CollectionsManager, CollectionsManager, collectionAddRemoveForm, OsuFileIo.LoadedMaps);

            var UpdateChecker = new UpdateChecker();

            UpdateChecker.currentVersion = System.Reflection.Assembly.GetExecutingAssembly()
                                           .GetName()
                                           .Version
                                           .ToString();
            var infoTextModel = new InfoTextModel(UpdateChecker);

            var mainForm      = GuiComponentsProvider.Instance.GetClassImplementing <IMainFormView>();
            var mainPresenter = new MainFormPresenter(mainForm, new MainFormModel(CollectionEditor, UserDialogs), infoTextModel);

            //set initial text info and update events
            SetTextData(infoTextModel);


            var loginForm = GuiComponentsProvider.Instance.GetClassImplementing <ILoginFormView>();

            new GuiActionsHandler(OsuFileIo, CollectionsManager, UserDialogs, mainForm, mainPresenter, loginForm);

            HandleMainWindowActions(mainForm);

            mainForm.ShowAndBlock();
            Quit();
        }
Exemplo n.º 20
0
        private static void SetPresenters(IMainForm mainForm)
        {
            var mainFormPresenter         = new MainFormPresenter(mainForm);
            var chartingViewPresenter     = new ChartingViewPresenter(mainForm.ChartingView, SimpleErrorHandler.Instance);
            var calculationsViewPresenter = new CalculationsPresenter(mainForm.CalculationsView,
                                                                      SimpleErrorHandler.Instance);
            var numericalCalculationsPresenter = new NumericalCalculationsPresenter(mainForm.NumericalCalculationsView,
                                                                                    SimpleErrorHandler.Instance);
            var scriptingViewPresenter       = new ScriptingViewPresenter(mainForm.ScriptingView, SimpleErrorHandler.Instance);
            var customFunctionsViewPresenter = new CustomFunctionsPresenter(mainForm.CustomFunctionsView);

            SharedViewState.Initialize(mainForm.ExpressionView.ExpressionTextBox,
                                       mainForm.CustomFunctionsView.CustomFunctionsEditor);
        }
        public void BoundingRectangle_SingleScreen()
        {
            var view       = new MockMainFormView();
            var boundaries = new List <Rectangle>
            {
                new Rectangle(0, 0, 3840, 2160)
            };
            var presenter = new MainFormPresenter(MockLogger.Object, view, null, boundaries);

            Assert.Equal(0, presenter.BoundingRectangle.X);
            Assert.Equal(0, presenter.BoundingRectangle.Y);
            Assert.Equal(boundaries[0].Width, presenter.BoundingRectangle.Width);
            Assert.Equal(boundaries[0].Height, presenter.BoundingRectangle.Height);
        }
        public async Task GetImageFromGallery_GalleryThrowsException_IndicatesError()
        {
            var view           = new MockMainFormView();
            var galleryService = new Mock <IGalleryService>();

            galleryService.Setup(x => x.GetRandomImage(It.IsAny <Size>())).Throws <Exception>();
            var presenter = new MainFormPresenter(MockLogger.Object, view, galleryService.Object, MockBoundaries);

            var actual = await presenter.GetImageFromGallery(new Size(320, 240));

            Assert.NotNull(actual);
            Assert.True(actual.HadError);
            Assert.False(string.IsNullOrEmpty(actual.ErrorMessage));
        }
Exemplo n.º 23
0
        public async Task Run(string[] args)
        {
            //IUserDialogs can be implemented in WinForm or WPF or Gtk or Console or...?
            UserDialogs = GuiComponentsProvider.Instance.GetClassImplementing <IUserDialogs>();



            //Init "main" classes
            CollectionsManager = new CollectionsManagerWithCounts(LoadedBeatmaps);

            var collectionAddRemoveForm = GuiComponentsProvider.Instance.GetClassImplementing <ICollectionAddRenameForm>();

            CollectionEditor = new CollectionEditor(CollectionsManager, CollectionsManager, collectionAddRemoveForm, OsuFileIo.LoadedMaps);

            var updateChecker = new UpdateChecker();

            updateChecker.CheckForUpdates();
            var infoTextModel = new InfoTextModel(updateChecker);

            var mainForm      = GuiComponentsProvider.Instance.GetClassImplementing <IMainFormView>();
            var mainPresenter = new MainFormPresenter(mainForm, new MainFormModel(CollectionEditor, UserDialogs), infoTextModel, WebCollectionProvider);

            //set initial text info and update events
            SetTextData(infoTextModel);

            var loginForm         = GuiComponentsProvider.Instance.GetClassImplementing <ILoginFormView>();
            var guiActionsHandler = new GuiActionsHandler(OsuFileIo, CollectionsManager, UserDialogs, mainForm, mainPresenter, loginForm);

            if (!string.IsNullOrWhiteSpace(Settings.Default.Osustats_apiKey))
            {
                guiActionsHandler.SidePanelActionsHandler.OsustatsLogin(null, Settings.Default.Osustats_apiKey);
            }

            if (args.Length > 0)
            {
                if (File.Exists(args[0]))
                {
                    CollectionsManager.EditCollection(CollectionEditArgs.AddCollections(OsuFileIo.CollectionLoader.LoadCollection(args[0])));
                }
            }

            StartupPresenter = new StartupPresenter(GuiComponentsProvider.Instance.GetClassImplementing <IStartupForm>(), guiActionsHandler.SidePanelActionsHandler, UserDialogs, CollectionsManager);
            await StartupPresenter.Run();


            mainForm.ShowAndBlock();

            Quit();
        }
Exemplo n.º 24
0
        static void Main()
        {
            Application.EnableVisualStyles();
            Application.SetCompatibleTextRenderingDefault(false);
            IOC.Register <MainForm, IMainForm>();
            IOC.Register <NewProjectForm, INewProjectView>();
            IOC.Register <ProjectService, IProjectService>();
            IOC.Register <MainFormPresenter>();
            IOC.Register <NewProjectPresenter>();
            IOC.Build();

            MainFormPresenter mainForm = IOC.Resolve <MainFormPresenter>();

            Application.Run((Form)mainForm.View);
        }
Exemplo n.º 25
0
        private void BtnEnter_Click(object sender, EventArgs e)
        {
            LogIn?.Invoke(this, EventArgs.Empty);

            if (this.Status != UserStatus.Guest)
            {
                MainForm form = new MainForm(this.Status, this.Name, this.Cash, this.Id, this);

                MainFormPresenter formPresenter =
                    new MainFormPresenter(form, new Model.MatchListModel(), new MessageBoxService.MessageBoxService());

                form.Show();

                this.Hide();
            }
        }
Exemplo n.º 26
0
 public bool Run(ILifetimeScope scope)
 {
     Context.UpdateDb();
     Scope = scope;
     LoginFormPresenter.Run();
     if (LoginAttemptResult != LoginResults.Success)
     {
         return(false);
     }
     MainFormPresenter.Run(User);
     foreach (Form form in Application.OpenForms)
     {
         form.Close();
     }
     return(reloginAttempt);
 }
Exemplo n.º 27
0
        public static Form Execute()
        {
            var mainForm          = new MainForm();
            var mainFormViewModel = new MainFormViewModel();
            var mainFormPresenter = new MainFormPresenter(mainForm, mainFormViewModel);

            var loginPresenter = new LoginControlPresenter(mainForm, );

            //note that in the real thing instead of adding them like this and calling showControl here,
            //i might actually pass in a list of kvp(pageType, new control) and have the construct gen up all of the pages
            //Then the constructor would go to the first page (login)
            mainFormPresenter.AddControlToPagesDictionaryIfNotPresent(Pages.Login, new LoginControl());
            mainFormPresenter.AddControlToPagesDictionaryIfNotPresent(Pages.Ship, new ShipControl());
            mainFormPresenter.AddControlToPagesDictionaryIfNotPresent(Pages.ScaleSetup, new ScaleSetupControl());
            mainFormPresenter.ShowControl(Pages.Login);

            return(mainForm);
        }
Exemplo n.º 28
0
        public MainForm()
        {
            InitializeComponent();
            AllowTransparency = true;
            presenter         = new MainFormPresenter(this, new JediSettings());

            mouseHook                   = new MouseHook();
            mouseHook.MouseEvent       += MouseHookMouseEvent;
            keyboardHook                = new KeyboardHook();
            keyboardHook.KeyboardEvent += KeyboardHookKeyboardEvent;
            mgr.ShortcutActivated      += mgr_OnShortcutActivated;
            keyboardHook.InstallHook();

            if (Settings.Default.CleanLogfile && !string.IsNullOrEmpty(Settings.Default.Logfile))
            {
                using (System.IO.StreamWriter file = new System.IO.StreamWriter(Settings.Default.Logfile))
                {
                    file.Write("");
                }
            }
        }
Exemplo n.º 29
0
        static void Main()
        {
            Application.EnableVisualStyles();
            Application.SetCompatibleTextRenderingDefault(false);

            // Loading specific UI Modules.
            ModuleCatalog.Instance.Add(ModuleOptions.LightSelector, new LightSelectorViewFactory());
            ModuleCatalog.Instance.Add(ModuleOptions.Snake, new SnakeViewFactory());
            ModuleCatalog.Instance.Add(ModuleOptions.AmpSine, new AmpSineViewFactory());
            ModuleCatalog.Instance.Add(ModuleOptions.Thunder, new ThunderViewFactory());
            ModuleCatalog.Instance.Add(ModuleOptions.Room, new RoomViewFactory());

            LightState state = new LightState(11);
            MainFormView view = new MainFormView();
            view.StartPosition = FormStartPosition.CenterScreen;
            MainFormPresenter pres = new MainFormPresenter(view, state);

            LoginScreen login = new LoginScreen(view);
            login.StartPosition = FormStartPosition.CenterScreen;
            login.ShowDialog(view);

            Application.Run(view);
        }
Exemplo n.º 30
0
        static void Main()
        {
            Application.EnableVisualStyles();
            Application.SetCompatibleTextRenderingDefault(false);

            var mainForm = new MainForm(new LoadingMainForm());

            mainForm.InitBoard();

            var mainFormPresenter = new MainFormPresenter(mainForm);

            var addStudentBoardPresenter = new AddStudentBoardPresenter(mainForm.addStudentBoard, new GroupViewBoard());

            var dataBoardPresenter = new DataBoardPresenter(mainForm.dataBoard);

            var addGroupBoardPresenter = new AddGroupBoardPresenter(
                mainForm.addGroupBoard, new StudentViewBoard(), new AddedStudentViewBoard());

            var editStudentBoardFirstPresenter =
                new EditStudentBoardFirstPresenter(mainForm.editStudentBoard.editStudentBoardFirst, new EditStudentViewBoard());

            var editStudentBoardSecondPresenter =
                new EditStudentBoardSecondPresenter(mainForm.editStudentBoard.editStudentBoardSecond, new GroupViewBoard());

            var editGroupBoardFirstPresenter = new EditGroupBoardFirstPresenter(
                mainForm.editGroupBoard.editGroupBoardFirst,
                new GroupViewBoard(Color.RoyalBlue));

            var editGroupBoardSecondPresenter = new EditGroupBoardSecondPresenter(
                mainForm.editGroupBoard.editGroupBoardSecond,
                new StudentViewBoard(), new AddedStudentViewBoard());

            var statisticBoardPresenter = new StatisticBoardPresenter(mainForm.statisticBoard);

            Application.Run(mainForm);
            Console.ReadKey();
        }
Exemplo n.º 31
0
        static void Main(string[] args)
        {
            // redirect console output to parent process;
            // must be before any calls to Console.WriteLine()
            //AttachConsole(ATTACH_PARENT_PROCESS);
            EPTPresenterProxy proxy = new EPTPresenterProxy();

            if (args.Length == 2)
            {
                if (args[1].Equals("EPTReport") || args[1].Equals("EPT Report"))
                {
                    //Sending the enter key is not really needed, but otherwise the user thinks the app is still running by looking at the commandline.
                    //The enter key takes care of displaying the prompt again.
                    //SpreadsheetGearWorkbookViewController svc = new SpreadsheetGearWorkbookViewController();
                    string contourHtmlLocation = proxy.WriteContourHtml(proxy.GetContourHTML(args[0]), args[0]);
                    string surfaceHtmlLocation = proxy.WriteSurfaceHtml(proxy.GetSurfaceHTML(args[0]), args[0]);
                    //Opening the html file in default browser
                    //proxy.OpenHTML(htmlLocation);
                    //Capturing Screenshop as png format.
                    string imageLocation = proxy.Screenshot(contourHtmlLocation, "Contour.png");
                    //string directoryLocation = proxy.GetDirectory(args[0]); //if we want to create directory according to same name as input file
                    string directoryLocation = proxy.GetPath(args[0]) + "/ContourImages";
                    Directory.CreateDirectory(directoryLocation);
                    proxy.SplitImage(imageLocation, directoryLocation);
                    imageLocation     = proxy.Screenshot(surfaceHtmlLocation, "Surface3D.png");
                    directoryLocation = proxy.GetPath(args[0]) + "/Surface3DImages";
                    Directory.CreateDirectory(directoryLocation);
                    proxy.SplitImage(imageLocation, directoryLocation);
                    System.Windows.Forms.SendKeys.SendWait("{ENTER}");
                    Application.Exit();
                }
                else
                {
                    Console.WriteLine("Please Enter the report name correctly! (e.g. EPTReport)");
                }

                // pass input/output path as argument e.g. "C:\Users\Downloads\test-Copy.xlsx" "EPTReport""
            }
            else if (args.Length == 3)
            {
                if (args[2].Equals("EPTReport") || args[2].Equals("EPT Report"))
                {
                    //Sending the enter key is not really needed, but otherwise the user thinks the app is still running by looking at the commandline.
                    //The enter key takes care of displaying the prompt again.
                    //SpreadsheetGearWorkbookViewController svc = new SpreadsheetGearWorkbookViewController();
                    string contourHtmlLocation = proxy.WriteContourHtml(proxy.GetContourHTML(args[0]), args[1]);
                    string surfaceHtmlLocation = proxy.WriteSurfaceHtml(proxy.GetSurfaceHTML(args[0]), args[1]);
                    //Opening the html file in default browser
                    //proxy.OpenHTML(args[1]);
                    //Capturing Screenshop as png format.
                    string imageLocation = proxy.Screenshot(contourHtmlLocation, "Contour.png");
                    //string directoryLocation = proxy.GetDirectory(args[0]); //if we want to create directory according to same name as input file
                    string directoryLocation = proxy.GetPath(args[1]) + "/ContourImages";
                    Directory.CreateDirectory(directoryLocation);
                    proxy.SplitImage(imageLocation, directoryLocation);
                    imageLocation     = proxy.Screenshot(surfaceHtmlLocation, "Surface3D.png");
                    directoryLocation = proxy.GetPath(args[1]) + "/Surface3DImages";
                    Directory.CreateDirectory(directoryLocation);
                    proxy.SplitImage(imageLocation, directoryLocation);
                    System.Windows.Forms.SendKeys.SendWait("{ENTER}");
                    Application.Exit();
                    //pass input/output path as argument e.g. "C:\Users\Downloads\test-Copy.xlsx" "C:\Users\Downloads\" "EPTReport"
                }
                else
                {
                    Console.WriteLine("Please Enter the report name correctly! (e.g. EPTReport)");
                }
            }
            else
            {
                Application.EnableVisualStyles();
                Application.SetCompatibleTextRenderingDefault(false);
                // initialize
                MainForm             view      = new MainForm();
                ViewsProviders       providers = new ViewsProviders();
                ConfigurationManager manager   = ConfigurationManager.Default;
                ConfigurationManager.ExceptionThrown +=
                    (s, e) => ViewsProviders.ShowMessageBox(e.Value);
                MainFormPresenter presenter = new MainFormPresenter(view, providers, manager);
                Application.Run((Form)presenter.View);
            }
        }
Exemplo n.º 32
0
 public MainForm()
 {
     InitializeComponent();
     DBStatus.init();
     presenter = new MainFormPresenter(this);
 }