Groovy is driving me crazy!
I use already a long time the same piece of code for my FancyBox skin en for the PhotoSwipe skin for the same set of images and settings.
It works OK with fancyBox, but now suddenly it crashes with PhotoSwipe:
Stack trace for jAlbum 31.0.1 using skin PhotoSwipe 5.4.3:
se.datadosen.util.ScriptException: org.codehaus.groovy.control.MultipleCompilationErrorsException: startup failed:
Script143.groovy: 24: Unexpected input: '{\r\n if (showExposureDateThumb||showFilenames||showTitle||showDescriptions) {\r\n System.out.println("2 textToShow: " + textToShow);\r\n out.print("<div class="\"thumbText\"">"); \r\n if (showFilenames) {\r\n out.print("<small>"); \r\n out.print(label.replaceAll("_"," "));\r\n \tout.print("</small><br>"); \r\n }\r\n\r\n if (showTitle && fileTitle.length() > 0) {\r\n out.print("<strong>"); \r\n out.print(fileTitle);\r\n out.print("</strong><br>"); \r\n }\r\n \r\n if (showDescriptions) {\r\n out.print(shortComment); \r\n }\r\nif (exists.originalDate) {\r\n if (showExposureDateThumb) )' in index.htt at line number 634 at column number 30
at se.datadosen.util.ScriptException.of(ScriptException.java:59)
This is the piece of code:
<%
boolean textToShow= (showExposureDateThumb||showFilenames || (showTitle && (fileTitle.length() > 0)) || (showDescriptions && (shortComment.length() > 0)));
System.out.println("1 textToShow: " + textToShow);
if (!masonryGallery || (masonryGallery && textToShow)) {
if (showExposureDateThumb||showFilenames||showTitle||showDescriptions) {
System.out.println("2 textToShow: " + textToShow);
out.print("<div class="\"thumbText\"">");
if (showFilenames) {
out.print("<small>");
out.print(label.replaceAll("_"," "));
out.print("</small><br>");
}
if (showTitle && fileTitle.length() > 0) {
out.print("<strong>");
out.print(fileTitle);
out.print("</strong><br>");
}
if (showDescriptions) {
out.print(shortComment);
}
if (exists.originalDate) {
if (showExposureDateThumb) ) {
if (showDescriptions && shortComment.length()>0) {
out.print("<br>");
}
out.print(originalDate);
}
}
out.print("</div>");
}
}
%>
Can anybody explain this difference in behavior?
I spent already a day on this problem, but I can't solve the problem.
Replacing
boolean textToShow=
by
textToShow=
does not help.
There is no crash if I remove this piece of code completely