Beispiel #1
0
        public WiiKeyMapper(int wiimoteID)
        {
            this.WiimoteID = wiimoteID;

            this.initialize();

            this.processMonitor = SystemProcessMonitor.Default;
            this.processMonitor.ProcessChanged += processChanged;
            this.processMonitor.Start();

            homeButtonTimer           = new Timer();
            homeButtonTimer.Interval  = 1000;
            homeButtonTimer.AutoReset = true;
            homeButtonTimer.Elapsed  += homeButtonTimer_Elapsed;

            KeymapConfigWindow.Instance.OnConfigChanged += keymapConfigWindow_OnConfigChanged;
        }
Beispiel #2
0
        private static void Main(string[] args)
        {
            var process = WardenProcess.GetCurrentProcess();

            Console.WriteLine(process.Info);

            SystemProcessMonitor.Start(new MonitorOptions());

            WardenProcess.Start(new WardenStartInfo
            {
                FileName = "spotify://album:27ftYHLeunzcSzb33Wk1hf",
                Track    = false,
            });

            var solitaire = WardenProcess.Start(
                new WardenStartInfo
            {
                FileName    = "xboxliveapp-1297287741:",
                TargetImage = "C:\\Program Files\\WindowsApps\\Microsoft.MicrosoftSolitaireCollection_4.7.10142.0_x64__8wekyb3d8bbwe\\Solitaire.exe",
                Track       = true,
            }, OnFound);

            if (solitaire is { Info : not null })
Beispiel #3
0
        public WiiKeyMapper(int wiimoteID, HandlerFactory handlerFactory)
        {
            this.WiimoteID      = wiimoteID;
            this.outputHandlers = handlerFactory.getOutputHandlers(this.WiimoteID);
            foreach (IOutputHandler handler in outputHandlers)
            {
                handler.connect();
            }

            this.initialize();

            this.processMonitor = SystemProcessMonitor.Default;
            this.processMonitor.ProcessChanged += processChanged;
            this.processMonitor.Start();

            homeButtonTimer           = new Timer();
            homeButtonTimer.Interval  = 1000;
            homeButtonTimer.AutoReset = true;
            homeButtonTimer.Elapsed  += homeButtonTimer_Elapsed;

            this.screenPositionCalculator = new ScreenPositionCalculator();

            KeymapConfigWindow.Instance.OnConfigChanged += keymapConfigWindow_OnConfigChanged;
        }
Beispiel #4
0
        public WiiKeyMapper(int wiimoteID)
        {
            this.WiimoteID = wiimoteID;

            this.initialize();

            this.processMonitor = SystemProcessMonitor.Default;
            this.processMonitor.ProcessChanged += processChanged;
            this.processMonitor.Start();

            homeButtonTimer = new Timer();
            homeButtonTimer.Interval = 1000;
            homeButtonTimer.AutoReset = true;
            homeButtonTimer.Elapsed += homeButtonTimer_Elapsed;

            KeymapConfigWindow.Instance.OnConfigChanged += keymapConfigWindow_OnConfigChanged;
        }
Beispiel #5
0
        public WiiKeyMapper(int wiimoteID, HandlerFactory handlerFactory)
        {
            this.WiimoteID = wiimoteID;
            this.outputHandlers = handlerFactory.getOutputHandlers(this.WiimoteID);
            foreach (IOutputHandler handler in outputHandlers)
            {
                handler.connect();
            }

            this.initialize();

            this.processMonitor = SystemProcessMonitor.Default;
            this.processMonitor.ProcessChanged += processChanged;
            this.processMonitor.Start();

            homeButtonTimer = new Timer();
            homeButtonTimer.Interval = 1000;
            homeButtonTimer.AutoReset = true;
            homeButtonTimer.Elapsed += homeButtonTimer_Elapsed;

            this.screenPositionCalculator = new ScreenPositionCalculator();

            KeymapConfigWindow.Instance.OnConfigChanged += keymapConfigWindow_OnConfigChanged;
        }