Skip to content
  • Philip Chimento's avatar
    object: Break init_g_param_from_prop() in half · e5429061
    Philip Chimento authored
    This avoids the awkward triple return state (NO_SUCH_GPROPERTY,
    VALUE_WAS_SET, SOME_ERROR_OCCURRED) by splitting init_g_param_from_prop()
    into an infallible function that looks up the GParamSpec (returning null
    if no such GObject property) and a function that initializes the
    GParameter from the GParamSpec (returning false on error).
    
    Moves the check for overridden JS properties to the place where they are
    set while not constructing, since we previously passed a bool in two
    places in the code for that.
    
    See: #160
    e5429061