GetViewportUnderMouse

導入

v5.0

カテゴリ

ビューイング

詳細

マウス ポインタの下にあるビュー ペイン(A、B、C、または D)を戻します。ポインタがビュー マネージャ内にない場合は前回のビュー ペインを戻します。

スクリプト構文

oReturn = GetViewportUnderMouse();

戻り値

ビュー ペイン(A、B、C、または D)を文字列で戻します。

1. VBScript の例

' Get the viewport under the mouse
Application.LogMessage "The view pane with the focus is " & GetViewportUnderMouse
' Logged message will be similar to this:
'INFO : The view pane with the focus is B

2. JScript の例

// Get the type of view embedded in the viewport under the mouse
var oVM = Application.Desktop.ActiveLayout.Views.Find( "View Manager" );
var oView = oVM.Views( GetViewportUnderMouse() );
Application.LogMessage( oView.FullName + ", " + oView.Type );
// Logged message will be similar to this:
//INFO : B, Explorer

関連項目

GetFocusedViewport SetFocusedViewport