Example #1
0
 public bool Gestured(PointInfo ActionPoint)
 {
     try
     {
         SystemWindow.ForegroundWindow = SystemWindow.AllToplevelWindows.Where
                                         (w => w.Visible &&	// Must be a visible windows
                                          //w.WindowState != FormWindowState.Minimized &&
                                          w.Title != "" &&	// Must have a window title
                                         //(w.Style & WindowStyleFlags.POPUPWINDOW)
                                         //	!= WindowStyleFlags.POPUPWINDOW &&
                                         (w.ExtendedStyle & WindowExStyleFlags.TOOLWINDOW)
                                             != WindowExStyleFlags.TOOLWINDOW	// Must not be a tool window
                                         ).Last();
     }
     catch (InvalidOperationException ex)
     {
         // Do nothing here, no other window open..
     }
     catch (Exception ex)
     {
         MessageBox.Show("Oops! - "+ex.Message);
     }
     finally { }
     return true;
 }
Example #2
0
        public bool Gestured(PointInfo ActionPoint)
        {
            // Extract default browser path from registery
            string defaultBrowserPath = GetDefaultBrowserPath();

            // If path is incorrect or empty and exception will be thrown, catch it and return false
            try { Process.Start(defaultBrowserPath); }
            catch { return false; }

            return true;
        }
Example #3
0
        public bool Gestured(PointInfo ActionPoint)
        {
            try
            {
                if (ActionPoint.WindowHandle.ToInt64() != ManagedWinapi.Windows.SystemWindow.ForegroundWindow.HWnd.ToInt64())
                    ManagedWinapi.Windows.SystemWindow.ForegroundWindow = ActionPoint.Window;

                SendKeys.Send(TypedGUI.txtSendKeys.Text);

                return true;
            }
            catch
            {
                return false;
            }
        }
Example #4
0
 public bool Gestured(PointInfo ActionPoint)
 {
     _HostControl.TrayManager.ToggleDisableGestures();
     return true;
 }
Example #5
0
 public bool Gestured(PointInfo ActionPoint)
 {
     return true;
 }
Example #6
0
        public bool Gestured(PointInfo ActionPoint)
        {
            Thread newThread = new Thread(new ParameterizedThreadStart(ExecuteCommand));
            newThread.Start(_Settings);

            return true;
        }
Example #7
0
        public bool Gestured(PointInfo ActionPoint)
        {
            if (ActionPoint.WindowHandle.ToInt64() != ManagedWinapi.Windows.SystemWindow.ForegroundWindow.HWnd.ToInt64())
                ManagedWinapi.Windows.SystemWindow.ForegroundWindow = ActionPoint.Window;

            SendShortcutKeys(_Settings);

            return true;
        }