Remarks
Obtains the identifier of the rectangle on which a mouse action occurred.
This method can be usually invoked from within the handler function of the TracksBoardMouseNotification event, whose xPos and yPos parameters represent the point where the mouse action occurred.
Position and size of various rectangles can be obtained through the TracksBoard.RectangleGet method.
For details about the use of the TracksBoard refer to the How to use the TracksBoard to visually compose songs tutorial.
For further details about methods of the TracksBoard refer to the TracksBoard class section.
Syntax
[Visual Basic]
Public Function MouseActionRectangleGet (
xPos as Int32,
yPos as Int32,
ByRef nRectangle as enumTracksBoardRectangles,
nTrack as Integer,
nItemUniqueId as Int32,
ByRef nVolumePointIndex as Int32
) as enumErrorCodes
|
|
[C#]
public enumErrorCodes MouseActionRectangleGet (
xPos as Int32,
yPos as Int32,
ref enumTracksBoardRectangles nRectangle,
ref Int32 nTrack,
ref Int32 nItemUniqueId,
ref Int32 nVolumePointIndex
);
|
|
[C++]
public: enumErrorCodes MouseActionRectangleGet (
xPos as Int32,
yPos as Int32,
enumTracksBoardRectangles __gc *nRectangle,
Int32 __gc *nTrack,
Int32 __gc *nItemUniqueId,
Int32 __gc *nVolumePointIndex
);
|
|
Parameter
|
Description
|
|
|
xPos
|
Horizontal position, expressed in pixels respect to the waveform's client area, where the mouse generated the notification.
|
yPos
|
Vertical position, expressed in pixels respect to the waveform's client area, where the mouse generated the notification
|
nRectangle
|
Reference that, on return from the method call, will contain the identifier of the rectangle
Supported values are the following:
Mnemonic value
|
Value
|
Meaning
|
TRACKSBOARD_RECT_TOTAL
|
0
|
Total rectangle of the TracksBoard's window
|
TRACKSBOARD_RECT_ALL_TRACKS
|
1
|
Rectangle containing all of the tracks
|
TRACKSBOARD_RECT_SINGLE_TRACK
|
2
|
Rectangle of a single track; the nTrack parameter to obtain the zero-based index of the track on which the mouse action was performed
|
TRACKSBOARD_RECT_SB_TOP
|
3
|
Top horizontal scrollbar rectangle
|
TRACKSBOARD_RECT_SB_BOTTOM
|
4
|
Bottom horizontal scrollbar rectangle
|
TRACKSBOARD_RECT_SB_RIGHT
|
5
|
Right vertical scrollbar rectangle
|
TRACKSBOARD_RECT_RULER_LEFT
|
6
|
Left ruler rectangle
|
TRACKSBOARD_RECT_RULER_RIGHT
|
7
|
Right ruler rectangle
|
TRACKSBOARD_RECT_RULER_TOP
|
8
|
Top ruler rectangle
|
TRACKSBOARD_RECT_RULER_BOTTOM
|
9
|
Bottom ruler rectangle
|
TRACKSBOARD_RECT_SELECTION
|
10
|
Selected rectangle
|
TRACKSBOARD_RECT_PLAYBACK_LINE
|
11
|
Play head line rectangle
|
TRACKSBOARD_RECT_SINGLE_ITEM
|
12
|
Single item rectangle; use the nItemUniqueId parameter to obtain the unique identification number of the item on which the mouse action occurred.
The unique identification number is assigned to the sound item after being generated by one of the following methods:
|
TRACKSBOARD_RECT_SINGLE_VOLUME_POINT
|
13
|
Single volume point rectangle; use the nItemUniqueId parameter to obtain the unique identification number of the item on which the mouse action occurred.and the nVolumePointIndex parameter to obtain the zero-based index of the volume point on which the mouse action occurred
The unique identification number is assigned to the sound item after being generated by one of the following methods:
The total number of volume points available for the given item can be obtained through the TracksBoard.ItemVolumePointCountGet method
|
|
nTrack
|
Reference that, on return from the method call, will contain the zero-based index of the track on which the mouse action was eventually performed
|
nItemUniqueId
|
Reference that, on return from the method call, will contain the unique identifier of the sound item on which the mouse action was eventually performed
|
nVolumePointIndex
|
Reference that, on return from the method call, will contain the zero-based index of the volume point on which the mouse action occurred
|
Return value
Value
|
Meaning
|
|
|
Negative value
|
An error occurred, check the LastError property value in order to get the error code
|
enumErrorCodes.ERR_NOERROR (0)
|
The method call was successful
|
|