quick and dirty:
PHP Code:
//#CLIENTSIDE
function onPlayerChats()
{
if( player.chat == "/dragtest" )
{
DragTestWindow.destroy();
new GuiWindowCtrl( DragTestWindow )
{
x = 100;
width = 100;
y = 100;
height = 100;
profile = GuiBlueWindowProfile;
new GuiTextListCtrl( DragTestWindowList )
{
profile = GuiBlueTextListProfile;
x = 10;
y = 30;
seticonsize(32,32);
width = 80;
height = 80;
with( addRow( 0, "test" ) )
{
icon.drawImage(0,0,"block.png");
with( icon )
{
thiso.catchevent( this, "onMouseDragged", "onMDrag" );
}
}
}
}
}
}
function onMDrag(keymodifier,mousescreenx,mousescreeny)
{
player.chat = "drag";
}
i tried the catchevent within the row didnt work
i tried the catchevent within the guitextlist, works
i guess i have to use it in guitextlist ctrl and check mousex and y to get the row x.x