diff options
| author | Diederik van Lierop <mail@diedenrezi.nl> | 2007-04-23 20:16:27 +0000 |
|---|---|---|
| committer | dvlierop2 <dvlierop2@users.sourceforge.net> | 2007-04-23 20:16:27 +0000 |
| commit | 2e3fcd82c1b72008577e1f06625127355c3527d9 (patch) | |
| tree | 1aad15bea481f3033198241f9de66e7187074fb8 /src/sp-use.cpp | |
| parent | patch 1705190 (diff) | |
| download | inkscape-2e3fcd82c1b72008577e1f06625127355c3527d9.tar.gz inkscape-2e3fcd82c1b72008577e1f06625127355c3527d9.zip | |
Fix for bug #1699198: snap nodes of clones
(bzr r2951)
Diffstat (limited to 'src/sp-use.cpp')
| -rw-r--r-- | src/sp-use.cpp | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/src/sp-use.cpp b/src/sp-use.cpp index e31af9356..cd5f81835 100644 --- a/src/sp-use.cpp +++ b/src/sp-use.cpp @@ -48,6 +48,7 @@ static void sp_use_update(SPObject *object, SPCtx *ctx, guint flags); static void sp_use_modified(SPObject *object, guint flags); static void sp_use_bbox(SPItem const *item, NRRect *bbox, NR::Matrix const &transform, unsigned const flags); +static void sp_use_snappoints(SPItem const *item, SnapPointsIter p); static void sp_use_print(SPItem *item, SPPrintContext *ctx); static gchar *sp_use_description(SPItem *item); static NRArenaItem *sp_use_show(SPItem *item, NRArena *arena, unsigned key, unsigned flags); @@ -107,6 +108,7 @@ sp_use_class_init(SPUseClass *classname) item_class->print = sp_use_print; item_class->show = sp_use_show; item_class->hide = sp_use_hide; + item_class->snappoints = sp_use_snappoints; } static void @@ -727,6 +729,22 @@ sp_use_get_original(SPUse *use) return ref; } +static void +sp_use_snappoints(SPItem const *item, SnapPointsIter p) +{ + g_assert (item != NULL); + g_assert (SP_IS_ITEM(item)); + g_assert (SP_IS_USE(item)); + + SPUse *use = SP_USE(item); + SPItem *root = sp_use_root(use); + + SPItemClass const &item_class = *(SPItemClass const *) G_OBJECT_GET_CLASS(root); + if (item_class.snappoints) { + item_class.snappoints(root, p); + } +} + /* Local Variables: |
