Logo Search packages:      
Sourcecode: inkscape version File versions  Download package

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

Requests that a modification notification signal be emitted later (e.g. during the idle loop)

Parameters:
flagsflags indicating what has been modified

Request modified always bubbles *up* the tree, as opposed to request display update, which trickles down and relies on the flags set during this pass...

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

References SPObject::requestModified().

Referenced by SPObject::requestModified(), SPObject::requestOrphanCollection(), SPGradient::setSpread(), SPGradient::setUnits(), sp_style_filter_ref_modified(), and sp_style_paint_server_ref_modified().

{
    g_return_if_fail( this->document != NULL );

    /* requestModified must be used only to set one of SP_OBJECT_MODIFIED_FLAG or
     * SP_OBJECT_CHILD_MODIFIED_FLAG */
    g_return_if_fail(!(flags & SP_OBJECT_PARENT_MODIFIED_FLAG));
    g_return_if_fail((flags & SP_OBJECT_MODIFIED_FLAG) || (flags & SP_OBJECT_CHILD_MODIFIED_FLAG));
    g_return_if_fail(!((flags & SP_OBJECT_MODIFIED_FLAG) && (flags & SP_OBJECT_CHILD_MODIFIED_FLAG)));

    bool already_propagated = (!(this->mflags & (SP_OBJECT_MODIFIED_FLAG | SP_OBJECT_CHILD_MODIFIED_FLAG)));

    this->mflags |= flags;

    /* If requestModified has already been called on this object or one of its children, then we
     * don't need to set CHILD_MODIFIED on our ancestors because it's already been done.
     */
    if (already_propagated) {
        SPObject *parent=SP_OBJECT_PARENT(this);
        if (parent) {
            parent->requestModified(SP_OBJECT_CHILD_MODIFIED_FLAG);
        } else {
            sp_document_request_modified(SP_OBJECT_DOCUMENT(this));
        }
    }
}

Here is the call graph for this function:

Here is the caller graph for this function:


Generated by  Doxygen 1.6.0   Back to index