Exemple #1
0
        /// <summary>
        /// Creates a new instance of the Main Program (UI) and loads the various Initialization Functions in order
        /// </summary>
        public UI(Logic logic)
        {
            IntializeTinyAlert();                 //Load UI into TinyAlert to register Form Movements
            InitializeComponent();                //Create Components
            InitializeLogic(logic);               //Sets logic
            InitializeSystemTray();               //Loads Code to place App in System Tray
            InitializeSettings();                 //Set up and Load Settings into ToDo
            InitializeOutputBox();                //Loads Output/Console Box
            InitializeEventHandlers();            //Register All Event Handlers
            InitializePreferencesPanel();         //Load Settings into Preferences Panel
            IntializeTopMenu();                   //Load Settings into Top Menu Control
            InitializeTaskListView();             //Load Settings into Task List View
            InitializeTextInput();                //Sets Text Input in Focus
            IntializeHelpPanel();                 //Loads Help Panel

            Logger.Info("All UI Elements loaded correctly...", "UI");

                        /* HEAD TO LOGIC CONTROL TO DELVE FURTHER */
        }
Exemple #2
0
 static void Main()
 {
     try
     {
     Application.EnableVisualStyles();
     Application.SetCompatibleTextRenderingDefault(false);
     Logger.Info("Starting Application...", "Main");
     Logic logic = new Logic();
     Application.Run(new UI(logic));
     }
     catch (System.IO.FileNotFoundException e)
     {
         AlertBox.Show("Missing some DLL files!");
         Logger.Error(e, "Main::Program");
     }
     catch (Exception e)
     {
         AlertBox.Show(e.ToString());
         Logger.Error(e, "Main::Program");
     }
     Logger.Info("Application terminated!\r\n", "Main");
 }
Exemple #3
0
 /// <summary>
 /// Pair Logic with UI
 /// </summary>
 /// <param name="logic"></param>
 private void InitializeLogic(Logic logic)
 {
     this.logic = logic;
     logic.SetUI(this);
 }