Remove even more unneeded complex if statements

This commit is contained in:
wowzaman12 2015-03-28 14:47:33 +00:00
parent c812fd6344
commit 96f1de8ec9
1 changed files with 10 additions and 13 deletions

View File

@ -2003,12 +2003,13 @@ EVT_HANDLER_MASK(ChangeFilter, "Change Pixel Filter", CMDEN_NREC_ANY)
int filt = gopts.filter; int filt = gopts.filter;
if(filt == FF_PLUGIN || if(filt == FF_PLUGIN ||
++gopts.filter == FF_PLUGIN && gopts.filter_plugin.empty()) ++gopts.filter == FF_PLUGIN && gopts.filter_plugin.empty())
gopts.filter = 0; {
gopts.filter = 0;
}
update_opts(); update_opts();
if(panel->panel && if(panel->panel) {
builtin_ff_scale(filt) != builtin_ff_scale(gopts.filter)) { panel->panel->Delete();
panel->panel->Delete(); panel->panel = NULL;
panel->panel = NULL;
} }
} }
@ -2016,14 +2017,10 @@ EVT_HANDLER_MASK(ChangeIFB, "Change Interframe Blending", CMDEN_NREC_ANY)
{ {
gopts.ifb = (gopts.ifb + 1) % 3; gopts.ifb = (gopts.ifb + 1) % 3;
update_opts(); update_opts();
if(panel->panel && if(panel->panel)
// ifb doesn't support 24-bit {
(gopts.ifb != IFB_NONE && systemColorDepth == 24) || panel->panel->Delete();
// standard prefers 24-bit panel->panel = NULL;
(gopts.ifb == IFB_NONE && gopts.filter == FF_NONE &&
systemColorDepth == 32 && gopts.render_method == 0)) {
panel->panel->Delete();
panel->panel = NULL;
} }
} }