Aggiunta get_focus_id
git-svn-id: svn://10.65.10.50/trunk@2933 c028cbd2-c16b-5b4b-a496-9718f37d4682
This commit is contained in:
parent
d95f3d2b6b
commit
a6aa890338
@ -22,6 +22,19 @@ typedef struct _stx_data
|
|||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
short get_focus_id(WINDOW win)
|
||||||
|
{
|
||||||
|
XI_OBJ * itf = xi_get_itf(win);
|
||||||
|
XI_OBJ * obj = xi_get_focus(itf);
|
||||||
|
|
||||||
|
if (obj == NULL || obj->type == XIT_ITF)
|
||||||
|
return -1;
|
||||||
|
if (obj->type == XIT_CELL || (obj->type == XIT_BTN && obj->v.btn->type == XIBT_RADIOBTN))
|
||||||
|
obj = obj->parent;
|
||||||
|
return obj->cid;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
#define CAMPI_SCAVATI FALSE
|
#define CAMPI_SCAVATI FALSE
|
||||||
|
|
||||||
HIDDEN int X_FU_MULTIPLE = 0;
|
HIDDEN int X_FU_MULTIPLE = 0;
|
||||||
|
@ -21,7 +21,7 @@ WINDOW create_interface(WINDOW parent, short x, short y, short dx, short dy,
|
|||||||
const char* caption, TWindow* mask, bool tags);
|
const char* caption, TWindow* mask, bool tags);
|
||||||
|
|
||||||
void attach_interface(WINDOW win, COLOR back = COLOR_WHITE);
|
void attach_interface(WINDOW win, COLOR back = COLOR_WHITE);
|
||||||
|
short get_focus_id(WINDOW win);
|
||||||
|
|
||||||
///////////////////////////////////////////////////////////
|
///////////////////////////////////////////////////////////
|
||||||
// Custom control
|
// Custom control
|
||||||
|
Loading…
x
Reference in New Issue
Block a user