index 476b87bc633acea8dda52cbd0c523d5ea6536991..89d38bace98a69eba99ef7defd7291d058819917 100644 (file)
cc->state = SP_CONNECTOR_CONTEXT_IDLE;
desktop->messageStack()->flash( Inkscape::NORMAL_MESSAGE,
- _("Connector endpoint drag canceled."));
+ _("Connector endpoint drag cancelled."));
ret = TRUE;
}
else if (cc->npoints != 0) {
}
- NR::Rect bbox = sp_item_bbox_desktop(cc->active_shape);
- NR::Point center = bbox.midpoint();
- sp_knot_set_position(cc->connpthandle, ¢er, 0);
-
- sp_knot_show(cc->connpthandle);
-
+ NR::Maybe<NR::Rect> bbox = sp_item_bbox_desktop(cc->active_shape);
+ if (bbox) {
+ NR::Point center = bbox->midpoint();
+ sp_knot_set_position(cc->connpthandle, ¢er, 0);
+ sp_knot_show(cc->connpthandle);
+ } else {
+ sp_knot_hide(cc->connpthandle);
+ }
}