Pennywise 0 Posted December 13, 2007 Too bad we don't have a BTS anymore. I seem to have come across a bug. Otherwise the wiki just doesn't describe too well how to use onMouseButtonDblClick: http://community.bistudio.com/wiki/User_Interface_Event_Handlers When assigning the onMouseButtonDblClick to a picture control. The eventhandler doesn't respond. It doesn't seem to get mapped at all: <table border="0" align="center" width="95%" cellpadding="0" cellspacing="0"><tr><td>Code Sample </td></tr><tr><td id="CODE"> _display = findDisplay _idd; _control = _display displayCtrl _picidc; _control ctrlSetEventHandler ["MouseButtonDblClick", [_this Select 0] call compile loadfile ('src\dialogs\fRemove.sqf')]; Otherwise, OnLBSelChanged, LBSelChanged, and several others seemed to work fine with listboxes. MouseButtonDblClick does nothing no matter where I double-click. Share this post Link to post Share on other sites
Pennywise 0 Posted December 13, 2007 Lucky me, I found a work around. How to make a picture respond to the User_Interface_Event_Handlers: <table border="0" align="center" width="95%" cellpadding="0" cellspacing="0"><tr><td>Code Sample </td></tr><tr><td id="CODE"> //Standard active text. class CRscActiveText { idc = -1; access = RAD_ReadAndWrite; type = RAD_CT_ACTIVETEXT; style = RAD_ST_CENTER; h = 0.05; w = 0.15; font = RAD_FontMAIN; sizeEx = RAD_Size_Text_Default; color[] = RAD_Color_Text; colorActive[] = RAD_Color_Active_Text; soundEnter[] = {"", 0.1, 1}; soundPush[] = {"", 0.1, 1}; soundClick[] = {"", 0.1, 1}; soundEscape[] = {"", 0.1, 1}; text = ""; default = 0; }; class CRscButtonPic : CRscActiveText { idc = -1; style = RAD_ST_PICTURE; font = BitStream; sizeEx = 0.04; color[] = {1, 1, 1, 1}; colorBackground[] = RAD_ColorBackground; colorText[] = RAD_Color_White; }; Then you can call ctrlSetEventHandler and set event handlers to the picture and have them respond to the event Share this post Link to post Share on other sites