掲示板システム
ホーム
アクセス解析
カテゴリ
ログアウト
マウスでリスト選択時、リストの外でマウスを離したイベントを取得するには? (ID:33027)
名前
ホームページ(ブログ、Twitterなど)のURL (省略可)
本文
ぎゃほ、MouseUpイベント発生しないんですね。 Mouse Captureは初めて知りました、勉強になります。 私だったらサブクラス化しているところでした。 http://www.geocities.jp/asumaroyuumaro/program/tips/SubClassProc.html unit Unit1; interface uses Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms, Dialogs, ComCtrls; type TForm1 = class(TForm) ListView1: TListView; procedure FormCreate(Sender: TObject); private { Private 宣言 } OriginProc: TWndMethod; //元のウィンドウ関数保持用 procedure SubClassProc(var msg: TMessage); public { Public 宣言 } end; var Form1: TForm1; implementation {$R *.dfm} procedure TForm1.FormCreate(Sender: TObject); begin OriginProc :=ListView1.WindowProc; ListView1.WindowProc :=SubClassProc; end; procedure TForm1.SubClassProc(var msg: TMessage); begin OriginProc(msg); case msg.Msg of WM_LBUTTONUP :beep; end; end; end. いあ、多分派生コンポーネント化かな…
←解決時は質問者本人がここをチェックしてください。
更新する
戻る
掲示板システム
Copyright 2021 Takeshi Okamoto All Rights Reserved.