Logo Search packages:      
Sourcecode: inkscape version File versions

void SPObject::emitModified ( unsigned int  flags  )  [inherited]

Emits a modification notification signal.

Parameters:
flags indicating what has been modified
Emits the MODIFIED signal with the object's flags. The object's mflags are the original set aside during the update pass for later delivery here. Once emitModified() is called, those flags don't need to be stored any longer.

Definition at line 1341 of file sp-object.cpp.

References SPObjectClass::modified.

Referenced by sp_gradient_modified().

{
    /* only the MODIFIED_CASCADE flag is legal here */
    g_return_if_fail(!(flags & ~SP_OBJECT_MODIFIED_CASCADE));

#ifdef SP_OBJECT_DEBUG_CASCADE
    g_print("Modified %s:%s %x %x %x\n", g_type_name_from_instance((GTypeInstance *) this), SP_OBJECT_ID(this), flags, this->uflags, this->mflags);
#endif

    flags |= this->mflags;
    /* We have to clear mflags beforehand, as signal handlers may
     * make changes and therefore queue new modification notifications
     * themselves. */
    this->mflags = 0;

    g_object_ref(G_OBJECT(this));
    SPObjectClass *klass=(SPObjectClass *)G_OBJECT_GET_CLASS(this);
    if (klass->modified) {
        klass->modified(this, flags);
    }
    _modified_signal.emit(this, flags);
    g_object_unref(G_OBJECT(this));
}


Generated by  Doxygen 1.6.0   Back to index