/// <summary> /// [コンストラクタ] /// </summary> public TouchPanel() { // ウィンドウをタッチ入力に対応させる Win32ApiWrapper.RegisterTouchWindow(this.Handle, 0); // 軌道を初期化する this.orbit = new List <TouchPoint>(this.Size.Height * this.Size.Width); }
/// <summary> /// [コンストラクタ] /// </summary> public DrawPanel() { // ウィンドウをタッチ入力に対応させる Win32ApiWrapper.RegisterTouchWindow(this.Handle, 0); // 透明の背景色を有効にする enableTransparentBackColor(); // ちらつき防止 this.DoubleBuffered = true; // 軌道を初期化する _orbit = new List <TouchPoint>(this.Size.Height + this.Size.Width); }
/// <summary> /// [メソッド] /// Windows メッセージを処理します。 /// </summary> /// <param name="m">Windowsメッセージ</param> protected override void WndProc(ref Message m) { // WM_TOUCHのメッセージハンドラを実装する if (m.Msg == Win32ApiWrapper.WM_TOUCH) { Win32ApiWrapper.TouchEventData[] eventData = Win32ApiWrapper.GetTouchEventData(m); // 基本イベントを割り当てる allocateBasicEvent(eventData[0]); // 排他的イベントを割り当てる allocateExclusiveEvent(eventData); } base.WndProc(ref m); }