git-svn-id: https://synfig.svn.sourceforge.net/svnroot/synfig@2288
1f10aa63-cdf2-0310-b900-
c93c546f37ac
{
const Duck::Handle& duck(iter->second);
- if(duck->get_ignore())
+ if(duck->get_ignore() ||
+ (duck->get_type() && !(type & duck->get_type())))
continue;
+
Real dist((duck->get_trans_point()-point).mag_squared());
if(duck->get_type()&Duck::TYPE_VERTEX)
else if(duck->get_type()&Duck::TYPE_RADIUS)
dist*=0.9999;
- if(dist<closest && !( duck->get_type() && (!(type & duck->get_type())) ) )
+ if(dist<closest)
{
closest=dist;
ret=duck;