Ref: remove redundant '== true' when comparing booleans

This commit is contained in:
Bryan Stenson
2021-09-10 11:42:33 +02:00
committed by Laurent Clouet
parent 4c8826a36e
commit b97054738b
2 changed files with 8 additions and 8 deletions

View File

@@ -172,7 +172,7 @@ import okhttp3.HttpUrl;
thread_sender.start(); thread_sender.start();
do { do {
while (this.running == true) { while (this.running) {
this.renderingJob = null; this.renderingJob = null;
synchronized (this) { synchronized (this) {
@@ -368,7 +368,7 @@ import okhttp3.HttpUrl;
(retrySchemeInMilliSeconds.length - 1)]; (retrySchemeInMilliSeconds.length - 1)];
this.gui.status(String.format("No job available. Will try again at %tR", new Date(new Date().getTime() + time_sleep))); this.gui.status(String.format("No job available. Will try again at %tR", new Date(new Date().getTime() + time_sleep)));
int time_slept = 0; int time_slept = 0;
while (time_slept < time_sleep && this.running == true && !this.shuttingdown) { while (time_slept < time_sleep && this.running && !this.shuttingdown) {
try { try {
Thread.sleep(250); Thread.sleep(250);
} }
@@ -415,13 +415,13 @@ import okhttp3.HttpUrl;
catch (InterruptedException e1) { catch (InterruptedException e1) {
} }
} }
break; // if the shutdown signal is triggered then exit the while (this.running == true) loop to initiate the shutdown process break; // if the shutdown signal is triggered then exit the while (this.running) loop to initiate the shutdown process
} }
continue; continue;
} }
if (this.renderingJob.isSynchronousUpload() == true) { // power or compute_method job, need to upload right away if (this.renderingJob.isSynchronousUpload()) { // power or compute_method job, need to upload right away
this.gui.status(String.format("Uploading frame (%.2fMB)", (this.renderingJob.getOutputImageSize() / 1024.0 / 1024.0))); this.gui.status(String.format("Uploading frame (%.2fMB)", (this.renderingJob.getOutputImageSize() / 1024.0 / 1024.0)));
ret = confirmJob(this.renderingJob, step); ret = confirmJob(this.renderingJob, step);
@@ -442,10 +442,10 @@ import okhttp3.HttpUrl;
this.renderingJob = null; this.renderingJob = null;
} }
if (this.shouldWaitBeforeRender() == true) { if (this.shouldWaitBeforeRender()) {
this.gui.status("Sending frames. Please wait"); this.gui.status("Sending frames. Please wait");
while (this.shouldWaitBeforeRender() == true) { while (this.shouldWaitBeforeRender()) {
try { try {
Thread.sleep(4000); // wait a little bit Thread.sleep(4000); // wait a little bit
} }
@@ -823,7 +823,7 @@ import okhttp3.HttpUrl;
// For a maximum of 30 minutes // For a maximum of 30 minutes
do { do {
// if the binary or scene already exists in the cache // if the binary or scene already exists in the cache
if (local_path_file.exists() == true) { if (local_path_file.exists()) {
this.gui.status("Reusing cached " + download_type); this.gui.status("Reusing cached " + download_type);
return Type.OK; return Type.OK;
} }

View File

@@ -78,7 +78,7 @@ public class Log {
if (this.checkpoints.containsKey(checkpointToWrite) && this.checkpoints.get(checkpointToWrite) != null) { if (this.checkpoints.containsKey(checkpointToWrite) && this.checkpoints.get(checkpointToWrite) != null) {
this.checkpoints.get(checkpointToWrite).add(line); this.checkpoints.get(checkpointToWrite).add(line);
} }
if (this.printStdOut == true) { if (this.printStdOut) {
System.out.println(line); System.out.println(line);
} }
} }