From 5c4ef78cc983212a0c2e0868929aa2b699855087 Mon Sep 17 00:00:00 2001 From: Bertrik Sikken Date: Fri, 1 Jan 2010 22:47:25 +0000 Subject: Simplify some expressions using the ? operator git-svn-id: svn://svn.rockbox.org/rockbox/trunk@24136 a1c6a512-1295-4272-9138-f99709370657 --- apps/codecs/mod.c | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) (limited to 'apps/codecs/mod.c') diff --git a/apps/codecs/mod.c b/apps/codecs/mod.c index cbeaf0837f..3e2e4284de 100644 --- a/apps/codecs/mod.c +++ b/apps/codecs/mod.c @@ -250,7 +250,7 @@ void mixer_playsample(int channel, int instrument) p_channel->channelactive = true; p_channel->samplepos = p_instrument->sampledataoffset; p_channel->samplefractpos = 0; - p_channel->loopsample = (p_instrument->repeatlength > 2) ? true : false; + p_channel->loopsample = (p_instrument->repeatlength > 2); if (p_channel->loopsample) { p_channel->loopstart = p_instrument->repeatoffset + p_instrument->sampledataoffset; @@ -807,8 +807,7 @@ void playline(int pattern, int line) { /* Set Filter */ case 0x0: - modplayer.amigafilterenabled = - (effecty>0) ? false : true; + modplayer.amigafilterenabled = (effecty == 0); break; /* Fineslide up */ case 0x1: @@ -834,8 +833,7 @@ void playline(int pattern, int line) break; /* Set glissando on/off */ case 0x3: - modplayer.glissandoenabled = - (effecty > 0) ? true:false; + modplayer.glissandoenabled = (effecty > 0); break; /* Set Vibrato waveform */ case 0x4: -- cgit v1.2.3