Пример #1
0
static void motButtonEnterLeaveWindowEvent(Widget w, Ihandle* ih, XEvent *evt, Boolean *cont)
{
  /* Used only when FLAT=Yes, to manage relief */

  iupmotEnterLeaveWindowEvent(w, ih, evt, cont);

  if (evt->type == EnterNotify)
    XtVaSetValues(ih->handle, XmNshadowThickness, 2, NULL);
  else  if (evt->type == LeaveNotify)
    XtVaSetValues(ih->handle, XmNshadowThickness, 0, NULL);
}
Пример #2
0
static void motToggleEnterLeaveWindowEvent(Widget w, Ihandle* ih, XEvent *evt, Boolean *cont)
{
    /* Used only when FLAT=Yes */
    unsigned char check = 0;

    iupmotEnterLeaveWindowEvent(w, ih, evt, cont);

    XtVaGetValues (ih->handle, XmNset, &check, NULL);
    if (check == XmSET)
        XtVaSetValues(ih->handle, XmNshadowThickness, 2, NULL);
    else
    {
        if (evt->type == EnterNotify)
            XtVaSetValues(ih->handle, XmNshadowThickness, 2, NULL);
        else  if (evt->type == LeaveNotify)
            XtVaSetValues(ih->handle, XmNshadowThickness, 0, NULL);
    }
}