FazBrowse GitHub Viewer | Trending |
URL:
| Home
Tools: [Download Repo ZIP]   [Original HTTPS Page]

fix preproc stupidity from me · Jonham/processing@ac47822 · GitHub

Repository navigation

Commit ac47822

Browse files
committed
fix preproc stupidity from me
1 parent 6f97200 commit ac47822

1 file changed

Lines changed: 5 additions & 5 deletions

File tree

‎java/src/processing/mode/java/preproc/PdePreprocessor.java‎

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -318,7 +318,7 @@ make sure that it uses numbers (or displayWidth/Height), copy into settings
318318
}
319319
String[] noContents = matchMethod("noSmooth", searchArea);
320320
if (noContents != null) {
321-
if (extraStatements != null) {
321+
if (extraStatements.size() != 0) {
322322
throw new SketchException("smooth() and noSmooth() cannot be used in the same sketch");
323323
} else {
324324
extraStatements.append(noContents[0]);
@@ -369,8 +369,8 @@ make sure that it uses numbers (or displayWidth/Height), copy into settings
369369
throw new SketchException("Please fix the size() line to continue.", false);
370370
}
371371

372-
if (extraStatements != null) {
373-
info.statement += extraStatements;
372+
if (extraStatements.size() != 0) {
373+
info.statement += extraStatements.join(" ");
374374
}
375375
info.checkEmpty();
376376
return info;
@@ -401,7 +401,7 @@ make sure that it uses numbers (or displayWidth/Height), copy into settings
401401
}
402402
info.width = "displayWidth";
403403
info.height = "displayHeight";
404-
if (extraStatements != null) {
404+
if (extraStatements.size() != 0) {
405405
info.statement += extraStatements.join(" ");
406406
}
407407
info.checkEmpty();
@@ -410,7 +410,7 @@ make sure that it uses numbers (or displayWidth/Height), copy into settings
410410

411411
// Made it this far, but no size() or fullScreen(), and still
412412
// need to pull out the noSmooth() and smooth(N) methods.
413-
if (extraStatements != null) {
413+
if (extraStatements.size() != 0) {
414414
SurfaceInfo info = new SurfaceInfo();
415415
info.statement = extraStatements.join(" ");
416416
return info;

0 commit comments

Comments
 (0)

Back | FazBrowse Home | New Git URL