From f2c6fbfc1b0046beb9401df115ccc954ca4ed110 Mon Sep 17 00:00:00 2001 From: Paul Licameli Date: Sun, 24 Apr 2016 10:30:46 -0400 Subject: [PATCH] Bug1318 fixed again so that generators and effects on Windows still work --- src/effects/Effect.cpp | 6 ++++-- src/effects/Effect.h | 2 +- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/src/effects/Effect.cpp b/src/effects/Effect.cpp index 2a24f0696..45305a111 100644 --- a/src/effects/Effect.cpp +++ b/src/effects/Effect.cpp @@ -3245,6 +3245,8 @@ void EffectUIHost::OnApply(wxCommandEvent & evt) if (IsModal()) { + mDismissed = true; + EndModal(true); Close(); @@ -3265,7 +3267,7 @@ void EffectUIHost::OnApply(wxCommandEvent & evt) void EffectUIHost::DoCancel() { - if (!mCancelled) { + if (!mDismissed) { mEffect->mUIResultID = wxID_CANCEL; if (IsModal()) @@ -3273,7 +3275,7 @@ void EffectUIHost::DoCancel() else Hide(); - mCancelled = true; + mDismissed = true; } } diff --git a/src/effects/Effect.h b/src/effects/Effect.h index 5ea0b5bc9..eb67f7ecf 100644 --- a/src/effects/Effect.h +++ b/src/effects/Effect.h @@ -659,7 +659,7 @@ private: SelectedRegion mRegion; double mPlayPos; - bool mCancelled{}; + bool mDismissed{}; DECLARE_EVENT_TABLE(); };