Behavior.OnLoseCapture(Glyph, EventArgs) 方法
定义
重要
一些信息与预发行产品相关,相应产品在发行之前可能会进行重大修改。 对于此处提供的信息,Microsoft 不作任何明示或暗示的担保。
装饰器窗口在失去鼠标捕获时调用。
public:
virtual void OnLoseCapture(System::Windows::Forms::Design::Behavior::Glyph ^ g, EventArgs ^ e);
public virtual void OnLoseCapture(System.Windows.Forms.Design.Behavior.Glyph g, EventArgs e);
public virtual void OnLoseCapture(System.Windows.Forms.Design.Behavior.Glyph? g, EventArgs e);
abstract member OnLoseCapture : System.Windows.Forms.Design.Behavior.Glyph * EventArgs -> unit
override this.OnLoseCapture : System.Windows.Forms.Design.Behavior.Glyph * EventArgs -> unit
Public Overridable Sub OnLoseCapture (g As Glyph, e As EventArgs)
参数
注解
一种行为可以通过行为服务请求鼠标捕获,方法是使用 PushCaptureBehavior 该方法将自身推送到行为堆栈。 如果这样做,则会在捕获丢失时通过 OnLoseCapture 方法通知它。 通常,此行为此时会从堆栈中删除自身。 发生以下操作之一时,捕获将丢失:
其他人请求捕获。
另一种行为是推送的。
此行为已删除。
在上述每个情况下, OnLoseCapture 都会对行为进行调用。