Ejemplo n.º 1
0
		public MainForm()
		{
			//
			// The InitializeComponent() call is required for Windows Forms designer support.
			//
			InitializeComponent();
			
			AddForm(output);
			Instance = this;
		}
Ejemplo n.º 2
0
		private static void Main(string[] args)
		{
			// Allow user to watch the Loading Of Assemblies O_o
			AppDomain.CurrentDomain.AssemblyLoad += OnAssemblyLoad;
			// Set basic Application settings
            Application.EnableVisualStyles();
            Application.SetCompatibleTextRenderingDefault(false);
            // Initialize program
            _splashScreen = new SplashScreen();
            _splashScreen.Show();
            Application.DoEvents();
            AppDomain.CurrentDomain.AssemblyLoad -= OnAssemblyLoad;
            
            
            _splashScreen.LoadingMsg = "Loading Settings...";
            LSharp.Studio.Core.OptionsLoader.Load();
            
            _splashScreen.LoadingMsg = "Loading Code Editor...";
            MainForm mainDlg = new MainForm();
            
            _splashScreen.LoadingMsg = "Loading Plugins...";
            LSharp.Studio.Plugins.PluginService pm = new LSharp.Studio.Plugins.PluginService(mainDlg);
            pm.FindPlugins();
            
            _splashScreen.LoadingMsg = "Loading Command Line Arguments...";
            foreach (string filename in System.Environment.GetCommandLineArgs())
            {
                try {
                    if (!string.IsNullOrEmpty(filename))
                    {
                        if (!(filename == Application.ExecutablePath))
                            mainDlg.LoadFile(filename);
                    }
                } catch (Exception e) {
                    MessageBox.Show(e.ToString());
                }
            }
            
            _splashScreen.LoadingMsg = "Loading...";
            _splashScreen.Close();
            // Run Application
            Application.ApplicationExit += new EventHandler(Application_ApplicationExit);
            Console.WriteLine("Started!");
            Application.Run(mainDlg);
        }
Ejemplo n.º 3
0
	public PluginService(MainForm parent)
	{
		this.Parent = parent;
		AvailablePlugins = new AvailablePlugins();
	}