Code

Let acceptsNumClicks() distinguish between invalid LPE and valid ones that expect...
authorcilix42 <cilix42@users.sourceforge.net>
Mon, 18 Aug 2008 00:44:23 +0000 (00:44 +0000)
committercilix42 <cilix42@users.sourceforge.net>
Mon, 18 Aug 2008 00:44:23 +0000 (00:44 +0000)
src/live_effects/effect.cpp

index 4a71b26565dfc2e441b01289429628e2987d58dc..5dfd3fb2027e981169f9e0d1605277077728a713 100644 (file)
@@ -110,6 +110,7 @@ const Util::EnumDataConverter<EffectType> LPETypeConverter(LPETypeData, sizeof(L
 int
 Effect::acceptsNumClicks(EffectType type) {
     switch (type) {
+        case INVALID_LPE: return -1; // in case we want to distinguish between invalid LPE and valid ones that expect zero clicks
         case ANGLE_BISECTOR: return 3;
         case CIRCLE_3PTS: return 3;
         case CIRCLE_WITH_RADIUS: return 2;