Exemplo n.º 1
0
 private void LoadInjector()
 {
     try
     {
         Injector = new AutoInjector("Dofus", Path.Combine(System.Windows.Forms.Application.StartupPath, "AmaknaProxy.Hooks.dll"), (ContainerLogger)Logger);
         Injector.Start();
         this.Invoke((MethodInvoker)delegate { ToolStripMenuItem_Proxy.Text = "Proxy: Activé"; });
     }
     catch (Exception ex)
     {
         Logger.Error(" (LoadInjector) " + ex.Message);
     }
 }
Exemplo n.º 2
0
        private void ToolStripMenuItem_Proxy_Click(object sender, EventArgs e)
        {
            if (ToolStripMenuItem_Proxy.Text.Contains("Chargement"))
                return;

            this.Invoke((MethodInvoker)delegate
            {
                if (Injector.Running)
                {
                    Injector.Stop();
                    ToolStripMenuItem_Proxy.Text = "Proxy: Désactivé";
                }
                else
                {
                    Injector.Start();
                    ToolStripMenuItem_Proxy.Text = "Proxy: Activé";
                }
            });
        }