//wnidow Mode public OverlayEyeNew(Configuration configuration, MagnifierMainForm mainForm) { InitializeComponent(); mConfiguration = configuration; this.Cursor = NativeMethods.LoadCustomCursor(); fullScreen = false; mMainForm = mainForm; FormBorderStyle = FormBorderStyle.None; ShowInTaskbar = mConfiguration.ShowInTaskbar; TopMost = true; Width = mConfiguration.MagnifierWidth; Height = mConfiguration.MagnifierHeight; this.DoubleBuffered = true; IsNormal = true; // window is normal wAIOn = false; checkForKeys = true; CheckForKeysJob(); setGazeControllerMode(); }
//Fullscreen Mode public OverlayEyeNew(Configuration configuration, bool fullscreen, MagnifierMainForm mainForm) { InitializeComponent(); mConfiguration = configuration; this.Cursor = NativeMethods.LoadCustomCursor(); mMainForm = mainForm; FormBorderStyle = FormBorderStyle.None; ShowInTaskbar = mConfiguration.ShowInTaskbar; TopMost = true; fullScreen = true; Width = Screen.PrimaryScreen.Bounds.Width; Height = Screen.PrimaryScreen.Bounds.Height; controller = new MouseController(this, mConfiguration); controller.setMovement(MouseController.Movement.HOTKEY); controller.Sensitivity = 7; controller.setMovement(MouseController.Movement.CONTINUOUS); controller.setMode(MouseController.Mode.BOTH_EYE_AND_HEAD); //this.KeyDown += new KeyEventHandler(HandleEsc); FormBorderStyle = FormBorderStyle.None; IsNormal = false; // window is normal checkForKeys = true; CheckForKeysJob(); setGazeControllerMode(); }
//Fullscreen Mode public OverlayEyeNew(Configuration configuration, bool fullscreen, MagnifierMainForm mainForm) { InitializeComponent(); mConfiguration = configuration; this.Cursor = NativeMethods.LoadCustomCursor(); mMainForm = mainForm; FormBorderStyle = FormBorderStyle.None; ShowInTaskbar = mConfiguration.ShowInTaskbar; TopMost = true; fullScreen = true; Width = Screen.PrimaryScreen.Bounds.Width; Height = Screen.PrimaryScreen.Bounds.Height; //this.KeyDown += new KeyEventHandler(HandleEsc); FormBorderStyle = FormBorderStyle.None; IsNormal = false; // window is normal wAIOn = false; checkForKeys = true; CheckForKeysJob(); setGazeControllerMode(); }
//wnidow Mode public OverlayEyeNew(Configuration configuration, MagnifierMainForm mainForm) { InitializeComponent(); mConfiguration = configuration; this.Cursor = NativeMethods.LoadCustomCursor(); fullScreen = false; mMainForm = mainForm; FormBorderStyle = FormBorderStyle.None; ShowInTaskbar = mConfiguration.ShowInTaskbar; TopMost = true; Width = mConfiguration.MagnifierWidth; Height = mConfiguration.MagnifierHeight; this.DoubleBuffered = true; controller = new MouseController(this, mConfiguration); // controller.setMovement(MouseController.Movement.HOTKEY); controller.Sensitivity = 7; controller.setMovement(MouseController.Movement.CONTINUOUS); controller.setMode(MouseController.Mode.BOTH_EYE_AND_HEAD); this.KeyDown += new KeyEventHandler(HandleEsc); FormBorderStyle = FormBorderStyle.None; setGazeControllerMode(); //CheckForKeysJob(); }
public MouseMoveMagnifier(Configuration configuration, Point startPoint, bool fullscreen, MagnifierMainForm mainForm) { InitializeComponent(); mConfiguration = configuration; this.Cursor = NativeMethods.LoadCustomCursor(); mMainForm = mainForm; FormBorderStyle = FormBorderStyle.None; ShowInTaskbar = mConfiguration.ShowInTaskbar; TopMost = true; Width = mConfiguration.MagnifierWidth; Height = mConfiguration.MagnifierHeight; isfullScreen = fullscreen; //fullscreen mode if (isfullScreen) { this.WindowState = FormWindowState.Maximized; } this.DoubleBuffered = true; this.KeyDown += new KeyEventHandler(HandleEsc); FormBorderStyle = FormBorderStyle.None; mStartPoint = startPoint; mTargetPoint = startPoint; mg = new Magnifier(this, mConfiguration, this); CheckForKeysJob(); }
public ConfigurationForm(Configuration configuration, MagnifierMainForm magnifierMainForm) { InitializeComponent(); this.Cursor = NativeMethods.LoadCustomCursor(); this.KeyPreview = true; this.KeyDown += new KeyEventHandler(HandleEsc); mConfiguration = configuration; ChangeWIMcolor_button.BackColor = Color.FromName(mConfiguration.whereIAmColor); // overlayEyeNew = new OverlayEyeNew(mConfiguration); // controller = new MouseController(overlayEyeNew, mConfiguration); mMagnifierMainForm = magnifierMainForm; FormBorderStyle = FormBorderStyle.None; tb_ZoomFactor.Maximum = (int)Configuration.ZOOM_FACTOR_MAX; tb_ZoomFactor.Minimum = (int)Configuration.ZOOM_FACTOR_MIN; tb_ZoomFactor.Value = (int)mConfiguration.ZoomFactor; cb_Symmetry.Checked = mConfiguration.keepSymmetric; tb_SpeedFactor.Maximum = (int)(100 * Configuration.SPEED_FACTOR_MAX); tb_SpeedFactor.Minimum = (int)(100 * Configuration.SPEED_FACTOR_MIN); tb_SpeedFactor.Value = (int)(100 * mConfiguration.SpeedFactor); tb_Width.Maximum = 1000; tb_Width.Minimum = 100; tb_Width.Value = mConfiguration.MagnifierWidth; tb_Height.Maximum = 1000; tb_Height.Minimum = 100; tb_Height.Value = mConfiguration.MagnifierHeight; lbl_ZoomFactor.Text = mConfiguration.ZoomFactor.ToString(); lbl_SpeedFactor.Text = mConfiguration.SpeedFactor.ToString(); lbl_Width.Text = mConfiguration.MagnifierWidth.ToString(); lbl_Height.Text = mConfiguration.MagnifierHeight.ToString(); SetComboBox1Text(); SetComboBoxColorBlindnessText(); //--- Init Boolean Settings --- cb_HideMouseCursor.Checked = mConfiguration.HideMouseCursor; //cb_reverseColor.Checked = mConfiguration.reverseColor; refreshTimer = new Timer(); refreshTimer.Tick += new EventHandler(RefreshScreen); refreshTimer.Interval = 33; refreshTimer.Start(); ShowInTaskbar = false; }
public InformationForm(MagnifierMainForm mainForm, Configuration Configuration) { InitializeComponent(); this.Cursor = NativeMethods.LoadCustomCursor(); this.KeyPreview = true; mMainForm = mainForm; this.KeyDown += new KeyEventHandler(HandleEsc); FormBorderStyle = FormBorderStyle.None; //this.TopMost = true; this.DoubleBuffered = true; mConfiguration = Configuration; lbl_SensitivityFactor.Text = mConfiguration.sensitivityOfTest.ToString(); tb_SensitivityFactor.Value = mConfiguration.sensitivityOfTest; mSensitivityOfTest = mConfiguration.sensitivityOfTest; timer.Enabled = true; timer.Tick += new EventHandler(refreshScreen); timer.Interval = 40; // 40 images per second. timer.Start(); }