protected override void OnMouseDown(MouseEventArgs e) { base.OnMouseDown(e); TimerSession.userOperation(); this.mMouseButton = e.Button; this.mMouseLocation = e.Location; }
private void imgTablet_MouseDown(object sender, MouseEventArgs e) { if (this.keyLayouts != null) { foreach (HuionKeyLayout keyLayout in this.keyLayouts) { if (keyLayout.mouseEnter(e.X, e.Y)) { this.mCheckedKeyLayout = keyLayout; this.imgTablet.Refresh(); if (this.mCheckedKeyLayout.KeyType == HuionKeyType.MULTIKEY) { this.comboBoxMekey.Visible = true; this.comboBoxMekey.Text = this.mCheckedKeyLayout.MutliKeys[this.mTouchIndex].ToString(); this.clickBtn.Visible = false; break; } this.comboBoxMekey.Visible = false; this.clickBtn.Visible = true; this.clickBtn.Text = this.mCheckedKeyLayout.Key.ToString(); break; } } } TimerSession.userOperation(); }
private void imgTablet_MouseMove(object sender, MouseEventArgs e) { TimerSession.userOperation(); if (this.mCurrentKeyLayout != null && this.mCurrentKeyLayout.mouseEnter(e.X, e.Y)) { this.imgTablet.Cursor = Cursors.Hand; } else { if (this.keyLayouts != null) { foreach (HuionKeyLayout keyLayout in this.keyLayouts) { if (keyLayout.mouseEnter(e.X, e.Y)) { this.mCurrentKeyLayout = keyLayout; this.imgTablet.Refresh(); this.imgTablet.Cursor = Cursors.Hand; return; } } } this.imgTablet.Cursor = Cursors.Default; } }
protected override void WndProc(ref Message m) { base.WndProc(ref m); if (m.Msg == 512) { TimerSession.userOperation(); } if (m.Msg == 32752) { PACKET?nullable = HuionApi.SafeMsg2Packet(m); if (!nullable.HasValue) { return; } HNStruct.globalInfo.penData.ps = nullable.Value.pkNormalPressure; this.onPressValueHandle((int)HNStruct.globalInfo.penData.ps); this.drawLineHelper.onDrawline(); } else { if (m.Msg != 1064) { return; } HNStruct.globalInfo.penData = TouchInfoReader.Msg2Packet(m); this.onPressValueHandle((int)HNStruct.globalInfo.penData.ps); this.drawLineHelper.onDrawline(); } }
protected override void WndProc(ref Message m) { if (m.Msg == 512) { TimerSession.userOperation(); } base.WndProc(ref m); }
protected override void WndProc(ref Message m) { base.WndProc(ref m); if (m.Msg != 512) { return; } TimerSession.userOperation(); }
private void setTabPanelClicked(Panel v, TabType tab) { this.mTabType = tab; this.clearForms(); TimerSession.userOperation(); this.panelHotKey.Refresh(); this.panelInfo.Refresh(); this.panelTabletPen.Refresh(); this.panelWorkArea.Refresh(); }
protected override void WndProc(ref Message m) { base.WndProc(ref m); switch (m.Msg) { case 126: break; case 512: TimerSession.userOperation(); break; case 536: switch (m.WParam.ToInt32()) { case 4: this.timer3.Stop(); ThreadPool.QueueUserWorkItem(new WaitCallback(TabletConfigUtils.closeDevice)); break; case 7: this.timer3.Start(); break; } MiddleModule.eventPost += new Post(this.MiddleModule_eventPost); break; case 1044: break; case 1054: if (this.Visible) { break; } this.Show(); this.WindowState = FormWindowState.Normal; break; case 1064: if (this.Visible) { break; } KeyboardUtils.listenHotKey(this.Handle, new Void(this.KeyboardUtils_showFormEvent), SettingsUtil.ShowUIShortcut); break; default: Fixer4Main.onDeviceChanged(ref m); KeyboardUtils.onHotKey(ref m); break; } }
public void onMouseDown(object sender, MouseEventArgs e) { TimerSession.userOperation(); this.isMouseDown = true; if (!this.IsDrawLine) { return; } this.mStartPoint = e.Location; this.onDrawline(e.Location); }
public static void onMouseMove(object sender, EventArgs e) { TimerSession.userOperation(); }
protected override void OnMouseMove(MouseEventArgs e) { base.OnMouseMove(e); TimerSession.userOperation(); if (this.mMouseButton == MouseButtons.Left) { Point location = e.Location; int num1 = location.X - this.mMouseLocation.X; location = e.Location; int num2 = location.Y - this.mMouseLocation.Y; float ratioX = (float)Math.Round((double)num1 / (double)this.mScreenRect.Width, 3); float ratioY = (float)Math.Round((double)num2 / (double)this.mScreenRect.Height, 3); if (this.mMouseInRect == this.mScreenDrawRect) { onRectChanged(ref this.mScreenRectRatio, this.locationType, ratioX, ratioY); } else if (this.mMouseInRect == this.mDeviceDrawRect) { onRectChanged(ref this.mDeviceDrawRectRatio, this.locationType, ratioX, ratioY); } this.mMouseLocation = e.Location; if (this.mMouseInRect == this.mScreenDrawRect) { this.measureScreenRect(); this.mMouseInRect = this.mScreenDrawRect; } else { if (!(this.mMouseInRect == this.mDeviceDrawRect)) { return; } this.measureDeviceRect(); this.mMouseInRect = this.mDeviceDrawRect; } } else { if (this.mMouseInRect != Rectangle.Empty) { this.locationType = ViewUtils.locationType(this.mMouseInRect, e.Location); if (this.locationType == MouseLocationType.EXTERNAL) { this.mMouseInRect = Rectangle.Empty; } else { this.Cursor = ViewUtils.getCursor8LocationType(this.locationType, this.Cursor); return; } } this.locationType = ViewUtils.locationType(this.mScreenDrawRect, e.Location); if (this.locationType == MouseLocationType.EXTERNAL) { this.mMouseInRect = Rectangle.Empty; this.locationType = ViewUtils.locationType(this.mDeviceDrawRect, e.Location); if (this.locationType == MouseLocationType.EXTERNAL) { this.Cursor = Cursors.Default; this.mMouseInRect = Rectangle.Empty; } else { this.mMouseInRect = this.mDeviceDrawRect; this.Cursor = ViewUtils.getCursor8LocationType(this.locationType, this.Cursor); } } else { this.mMouseInRect = this.mScreenDrawRect; this.Cursor = ViewUtils.getCursor8LocationType(this.locationType, this.Cursor); } } }
public void onMouseMove(object sender, MouseEventArgs e) { TimerSession.userOperation(); this.isMouseDown = false; this.onDrawline(e.Location); }