diff options
| author | Maximilian Albert <maximilian.albert@gmail.com> | 2008-06-12 13:23:30 +0000 |
|---|---|---|
| committer | cilix42 <cilix42@users.sourceforge.net> | 2008-06-12 13:23:30 +0000 |
| commit | 30dd228b3490bc81b04c6fa3fb36f8c91ceec4e6 (patch) | |
| tree | cbf33c264f6e4a6e048508046ae011a7dd237d7f /src/pen-context.cpp | |
| parent | Infrastructure in class LivePathEffect::Effect to put Inkscape into 'wait for... (diff) | |
| download | inkscape-30dd228b3490bc81b04c6fa3fb36f8c91ceec4e6.tar.gz inkscape-30dd228b3490bc81b04c6fa3fb36f8c91ceec4e6.zip | |
More infrastructure to have waiting LPEs that are freshly created and applied to yet-to-be-drawn paths
(bzr r5903)
Diffstat (limited to 'src/pen-context.cpp')
| -rw-r--r-- | src/pen-context.cpp | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/src/pen-context.cpp b/src/pen-context.cpp index 4616c04ae..1091408b3 100644 --- a/src/pen-context.cpp +++ b/src/pen-context.cpp @@ -785,8 +785,14 @@ pen_handle_button_release(SPPenContext *const pc, GdkEventButton const &revent) SPEventContext *ec = SP_EVENT_CONTEXT(pc); Inkscape::Selection *selection = sp_desktop_selection (ec->desktop); - pc->waiting_LPE->acceptParamPath(SP_PATH(selection->singleItem())); - selection->add(SP_OBJECT(pc->waiting_item)); + if (pc->waiting_LPE) { + // we have an already created LPE waiting for a path + pc->waiting_LPE->acceptParamPath(SP_PATH(selection->singleItem())); + selection->add(SP_OBJECT(pc->waiting_item)); + } else { + // the case that we need to create a new LPE and apply it to the just-drawn path is + // handled in spdc_check_for_and_apply_waiting_LPE() in draw-context.cpp + } } } |
