WTSupported in traditional Synergy on Windows
subroutine LDBLCLICK_METHOD a_status ,n a_listid ,n a_data ,a a_inpid ,n a_disabled ,n a_itemindex ,n a_row ,n a_methoddatal ,any . . a_methoddata20 ,any
Returned with the status flag: TRUE if condition handled (proceed) or FALSE if simulate an Enter. (n)
The ID of the list. (n)
(optional) The data associated with the list item. (a)
The ID of the associated input window. (n)
(optional) The true/false flag that indicates whether to disable the list item. (n)
The ordinal index of the list item. (n)
The item’s row number within the currently visible set of rows. (n)
a_methoddata1 through a_methoddata20
(optional) Up to 20 additional data arguments. (any)
LDBLCLICK_METHOD is a subroutine that you write and name. L_PROCESS calls it to handle the event of double-clicking on a list item.
You can register the LDBLCLICK_METHOD using the .LISTCLASS script command, or the L_METHOD or L_CLASS subroutines.
On UNIX and OpenVMS, the LDBLCLICK_METHOD is allowed to be registered, but it will never be called.
If this subroutine returns a_status as false, an Enter is simulated as if no method were registered.
On entry to this subroutine, g_select will be false. If g_select is true when it returns to the current routine, the menu entry contained in g_entnam will be resignaled and if the current routine (L_SELECT or L_PROCESS) recognizes that menu entry, the menu entry will be honored by that routine. Otherwise, it will be returned to the caller. Therefore, you can allow your LDBLCLICK_METHOD to perform any standard list function (such as S_UP or S_DOWN) or cause a full return to the caller.
A_methoddata1 through a_methoddata20 are up to 20 additional optional arguments that can be passed to I_INPUT or L_INPUT. They are passed, in turn, directly to LDBLCLICK_METHOD. This enables you to communicate additional information to LDBCLICK_METHOD.
Toolkit passes the method data arguments to the current list processing routine (L_PROCESS, L_INPUT, or L_SELECT) and to the list methods. Thus, if you pass data arguments to one list processing routine, to ensure these arguments are always available, you must pass them to all the list processing routines.
- .LISTCLASS script command for specifying the LDBLCLICK_METHOD in your script file
- L_CLASS and L_METHOD routines for specifying the LDBLCLICK_METHOD at runtime
- Overloading UI Toolkit routines for more information on creating this subroutine
- Appendix D: Methods
subroutine mydblclk ; ; Description: Double-click method for a list ; ; Arguments: ; a_sts ,n ;Return status a_listid ,n ;List ID a_data ,n ;Data of item a_inpid ,n ;Input window ID a_disabled ,n ;Disabled? a_itmindx ,n ;Item's index a_row ,n ;Item's visible row ; Notes: ; ; This double-click method enables the user to select the ; desired action. It is assumed that the list is being ; processed with L_SELECT. ; ; If the user double-clicks an item in the list, a ; message box is popped up giving the user the option of: ; ; 1. Going to the end of the list (press "Yes") ; 2. Simulating a RETURN (press "No") ; 3. Doing nothing (press "Cancel") .include "WND:tools.def" proc a_sts = TRUE ;Success by default case %u_msgbox("Double-click encountered -- select:\n"+ & " Yes = goto last\n"+ & " No = simulate RETURN\n"+ & " Cancel = do nothing", D_MYESNOCANCEL) of begincase D_MIDYES: begin ;"Yes" selected, go to last item g_select = TRUE g_entnam = "S_BOTTOM" end D_MIDNO: a_sts = FALSE ;"No" select, simulate RETURN D_MIDCANCEL: nop ;"Cancel" just returns TRUE endcase xreturn endsubroutine