Simplify some boolean expressions that compare directly against 'true'
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@24144 a1c6a512-1295-4272-9138-f99709370657
This commit is contained in:
parent
d03768bc14
commit
799a0a5cd4
7 changed files with 9 additions and 9 deletions
|
@ -701,7 +701,7 @@ static void update_total(struct game_context* bj) {
|
||||||
static signed int check_for_aces(struct card temp_cards[], unsigned int size) {
|
static signed int check_for_aces(struct card temp_cards[], unsigned int size) {
|
||||||
unsigned int i;
|
unsigned int i;
|
||||||
for(i = 0; i < size; i++) {
|
for(i = 0; i < size; i++) {
|
||||||
if (temp_cards[i].is_soft_ace == true)
|
if (temp_cards[i].is_soft_ace)
|
||||||
return i;
|
return i;
|
||||||
}
|
}
|
||||||
return -1;
|
return -1;
|
||||||
|
|
|
@ -70,7 +70,7 @@ void traversedir(char* location, char* name)
|
||||||
if (dir) {
|
if (dir) {
|
||||||
entry = rb->readdir(dir);
|
entry = rb->readdir(dir);
|
||||||
while (entry) {
|
while (entry) {
|
||||||
if (abort == true)
|
if (abort)
|
||||||
break;
|
break;
|
||||||
/* Skip .. and . */
|
/* Skip .. and . */
|
||||||
if (entry->d_name[0] == '.')
|
if (entry->d_name[0] == '.')
|
||||||
|
|
|
@ -389,7 +389,7 @@ int plugin_main(void)
|
||||||
((CONFIG_CODEC == MAS3587F) || (CONFIG_CODEC == MAS3539F)))
|
((CONFIG_CODEC == MAS3587F) || (CONFIG_CODEC == MAS3539F)))
|
||||||
|
|
||||||
/* This will make the stars pulse to the music */
|
/* This will make the stars pulse to the music */
|
||||||
if(pulse==true){
|
if(pulse){
|
||||||
|
|
||||||
/* Get the peaks. ( Borrowed from vu_meter ) */
|
/* Get the peaks. ( Borrowed from vu_meter ) */
|
||||||
#if (CONFIG_CODEC == SWCODEC)
|
#if (CONFIG_CODEC == SWCODEC)
|
||||||
|
|
|
@ -164,7 +164,7 @@ void traversedir(char* location, char* name)
|
||||||
if (dir) {
|
if (dir) {
|
||||||
entry = rb->readdir(dir);
|
entry = rb->readdir(dir);
|
||||||
while (entry) {
|
while (entry) {
|
||||||
if (abort == true)
|
if (abort)
|
||||||
break;
|
break;
|
||||||
/* Skip .. and . */
|
/* Skip .. and . */
|
||||||
if (rb->strcmp(entry->d_name, ".") && rb->strcmp(entry->d_name, ".."))
|
if (rb->strcmp(entry->d_name, ".") && rb->strcmp(entry->d_name, ".."))
|
||||||
|
@ -227,7 +227,7 @@ enum plugin_status plugin_start(const void* parameter)
|
||||||
lasttick = *rb->current_tick;
|
lasttick = *rb->current_tick;
|
||||||
|
|
||||||
traversedir("", "");
|
traversedir("", "");
|
||||||
if (abort == true) {
|
if (abort) {
|
||||||
rb->splash(HZ, "Aborted");
|
rb->splash(HZ, "Aborted");
|
||||||
return PLUGIN_OK;
|
return PLUGIN_OK;
|
||||||
}
|
}
|
||||||
|
|
|
@ -416,7 +416,7 @@ void SERIAL0(void)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
bool pkt = iap_getc(temp);
|
bool pkt = iap_getc(temp);
|
||||||
if(newpkt == true && pkt == false)
|
if(newpkt && !pkt)
|
||||||
autobaud = 0; /* Found good baud */
|
autobaud = 0; /* Found good baud */
|
||||||
newpkt = pkt;
|
newpkt = pkt;
|
||||||
}
|
}
|
||||||
|
|
|
@ -300,7 +300,7 @@ int ipod_rmt_tuner_set(int setting, int value)
|
||||||
case RADIO_FREQUENCY:
|
case RADIO_FREQUENCY:
|
||||||
{
|
{
|
||||||
rmt_tuner_set_freq(value);
|
rmt_tuner_set_freq(value);
|
||||||
if (reply_timeout() == true)
|
if (reply_timeout())
|
||||||
return 0;
|
return 0;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
@ -326,7 +326,7 @@ int ipod_rmt_tuner_set(int setting, int value)
|
||||||
else
|
else
|
||||||
rmt_tuner_scan(1);
|
rmt_tuner_scan(1);
|
||||||
|
|
||||||
if (reply_timeout() == true)
|
if (reply_timeout())
|
||||||
return 0;
|
return 0;
|
||||||
radio_tuned = 0;
|
radio_tuned = 0;
|
||||||
}
|
}
|
||||||
|
|
|
@ -356,7 +356,7 @@ void usb_storage_try_release_storage(void)
|
||||||
bool canrelease=true;
|
bool canrelease=true;
|
||||||
int i;
|
int i;
|
||||||
for(i=0;i<storage_num_drives();i++) {
|
for(i=0;i<storage_num_drives();i++) {
|
||||||
if(ejected[i]==false && locked[i]==true) {
|
if(!ejected[i] && locked[i]) {
|
||||||
canrelease=false;
|
canrelease=false;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue