pike.git / src / post_modules / GTK2 / source / support.c

version» Context lines:

pike.git/src/post_modules/GTK2/source/support.c:522:    break;    case G_TYPE_INT64:    retval=(LONGEST)g_value_get_int64(a);    break;    case G_TYPE_UINT64:    retval=(LONGEST)g_value_get_uint64(a);    break;    case G_TYPE_INT:    retval=(LONGEST)g_value_get_int(a);    break; -  case G_TYPE_ENUM: -  retval=(LONGEST)g_value_get_enum(a); -  break; +     case G_TYPE_FLAGS:    retval=(LONGEST)g_value_get_flags(a);    break;    case G_TYPE_BOOLEAN:    retval=(LONGEST)g_value_get_boolean(a);    break;    case G_TYPE_LONG:    retval=(LONGEST)g_value_get_long(a);    break;    case G_TYPE_CHAR:
pike.git/src/post_modules/GTK2/source/support.c:549:   #endif    break;    default:    retval=(LONGEST)g_value_get_uint(a);    break;    }    push_int64(retval);    return PUSHED_VALUE;   }    + static int pgtk2_push_enum_param(const GValue *a) { +  /* This can't be handled by push_int_param as the type of +  an enumeration is some subclass of G_TYPE_ENUM, rather than +  actually being G_TYPE_ENUM exactly. */ +  push_int64((LONGEST)g_value_get_enum(a)); +  return PUSHED_VALUE; + } +    static int pgtk2_push_float_param(const GValue *a) {    FLOAT_TYPE retval;    if (G_VALUE_TYPE(a)==G_TYPE_FLOAT)    retval=(FLOAT_TYPE)g_value_get_float(a);    else    retval=(FLOAT_TYPE)g_value_get_double(a);    push_float(retval);    return PUSHED_VALUE;   }   
pike.git/src/post_modules/GTK2/source/support.c:652:    CB( GDK_TYPE_MODIFIER_TYPE,pgtk2_push_int_param );       CB( G_TYPE_FLOAT, pgtk2_push_float_param );    CB( G_TYPE_DOUBLE, pgtk2_push_float_param );       CB( G_TYPE_STRING, pgtk2_push_string_param );       CB( G_TYPE_INT, pgtk2_push_int_param );    CB( G_TYPE_INT64, pgtk2_push_int_param );    CB( G_TYPE_UINT64, pgtk2_push_int_param ); -  CB( G_TYPE_ENUM, pgtk2_push_int_param ); +  CB( G_TYPE_ENUM, pgtk2_push_enum_param );    CB( G_TYPE_FLAGS, pgtk2_push_int_param );    CB( G_TYPE_BOOLEAN, pgtk2_push_int_param );    CB( G_TYPE_UINT, pgtk2_push_int_param );    CB( G_TYPE_LONG, pgtk2_push_int_param );    CB( G_TYPE_ULONG, pgtk2_push_int_param );    CB( G_TYPE_CHAR, pgtk2_push_int_param );       CB( G_TYPE_NONE, NULL );       CB( G_TYPE_POINTER, pgtk2_push_pike_object_param );