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

void SPDesktop::push_event_context ( GtkType  type,
const gchar *  config,
unsigned int  key 

Push event context onto desktop's context stack.

Definition at line 500 of file desktop.cpp.

References SPEventContext::key, SPEventContext::next, sp_event_context_activate(), sp_event_context_deactivate(), sp_event_context_finish(), and sp_event_context_new().

Referenced by init().

    SPEventContext *ref, *ec;
    Inkscape::XML::Node *repr;

    if (event_context && event_context->key == key) return;
    ref = event_context;
    while (ref && ref->next && ref->next->key != key) ref = ref->next;
    if (ref && ref->next) {
        ec = ref->next;
        ref->next = ec->next;
        sp_event_context_finish (ec);
        g_object_unref (G_OBJECT (ec));

    if (event_context) sp_event_context_deactivate (event_context);
    repr = (config) ? inkscape_get_repr (INKSCAPE, config) : NULL;
    ec = sp_event_context_new (type, this, repr, key);
    ec->next = event_context;
    event_context = ec;
    sp_event_context_activate (ec);
    _event_context_changed_signal.emit (this, ec);

Generated by  Doxygen 1.6.0   Back to index