Beispiel #1
0
        public Form1()
        {
            InitializeComponent();
            thisForm  = this;
            BackColor = Color.FromArgb(0, 0, 1);
            UpdateButtonOnOffDelegate = new UpdateButtonOnOffType(UpdateButtonOnOff);
            Global.Init();
            Global.runScript = RunScript;
            WindowPosition.Deserialize(this, Global.windowPosition.MainFormPosition);
            buttonOnOff.Image = imageList1.Images["loading"];
            UpdateToolbarVisible();
            browser.ObjectForScripting = Global.script;
            browser.Url = new Uri("file://" + Path.Combine(Application.StartupPath, "html\\base.html"));
            ApplyOptions();
            Global.agth.LoadAppProfiles();
            UseCommandLineArgs();
            if (Global.agth.TryConnectPipe())
            {
                turnOn();
            }
            else
            {
                turnOff();
            }
            buttonOnOff.Enabled = true;
            FormTooltip.instance.Show();
            this.Activate();

            Application.Idle += PreloadOnIdle;
        }
Beispiel #2
0
        public Form1()
        {
            InitializeComponent();
            thisForm = this;
            BackColor = Color.FromArgb(0, 0, 1);
            UpdateButtonOnOffDelegate = new UpdateButtonOnOffType(UpdateButtonOnOff);
            Global.Init();
            Global.runScript = RunScript;
            WindowPosition.Deserialize(this, Global.windowPosition.MainFormPosition);
            buttonOnOff.Image = imageList1.Images["loading"];
            UpdateToolbarVisible();
            browser.ObjectForScripting = Global.script;
            browser.Url = new Uri("file://" + Path.Combine(Application.StartupPath, "html\\base.html"));
            ApplyOptions();
            Global.agth.LoadAppProfiles();
            UseCommandLineArgs();
            if (Global.agth.TryConnectPipe())
                turnOn();
            else
                turnOff();
            buttonOnOff.Enabled = true;
            FormTooltip.instance.Show();
            this.Activate();

            Application.Idle += PreloadOnIdle;
        }