From 7c8557b184a64efd5fa382e2ab6adfac167dd2b1 Mon Sep 17 00:00:00 2001 From: Ben Fry Date: Fri, 5 Aug 2022 21:42:04 -0400 Subject: [PATCH] send code errors during export to the status bar --- java/src/processing/mode/java/JavaEditor.java | 8 ++++---- todo.txt | 18 +++++++----------- 2 files changed, 11 insertions(+), 15 deletions(-) diff --git a/java/src/processing/mode/java/JavaEditor.java b/java/src/processing/mode/java/JavaEditor.java index 9df9de213..a5ac0a782 100644 --- a/java/src/processing/mode/java/JavaEditor.java +++ b/java/src/processing/mode/java/JavaEditor.java @@ -476,24 +476,24 @@ public class JavaEditor extends Editor { * Handler for Sketch → Export Application */ public void handleExportApplication() { -// toolbar.activate(JavaToolbar.EXPORT); - if (handleExportCheckModified()) { statusNotice(Language.text("export.notice.exporting")); try { if (ExportPrompt.trigger(this)) { Platform.openFolder(sketch.getFolder()); statusNotice(Language.text("export.notice.exporting.done")); - //} else { + //} else { // error message will already be visible // or there was no error, in which case it was canceled. } + } catch (SketchException se) { + EventQueue.invokeLater(() -> statusError(se)); + } catch (Exception e) { statusNotice(Language.text("export.notice.exporting.error")); e.printStackTrace(); } } -// toolbar.deactivate(JavaToolbar.EXPORT); } diff --git a/todo.txt b/todo.txt index 42ce7863f..34afb0601 100755 --- a/todo.txt +++ b/todo.txt @@ -6,6 +6,10 @@ X theme_selector.combo_box.enabled.bgcolor X theme_selector.combo_box.enabled.bgcolor X doesn't update dynamically unless you (a) select ‘Minerals’ or ‘Alloys’ X or (b) open, then close the dropdown +X changing between themes not updating the combo box text (though arrow trigger works) +X switching between alloys and minerals will properly update +X if error in the code during export, was just saying "error during export" +X now sending the error to the status bar as expected docs X update theme instructions @@ -21,6 +25,8 @@ X having brought back some gradient themes for beta 9, we'll keep this in plac X create default tools folder (just like libraries) o for tools, maybe don't run on event thread? (makes the gui hang) o but instead, things that affect gui need to be called w/ invokeLater? +X Export to Application was broken with OpenGL (Casey) +X verified to be working movie maker o break Movie Maker out to its own library? @@ -47,12 +53,6 @@ _ https://github.com/processing/processing4/issues/522 _ https://github.com/processing/processing4-javafx/issues/15 -next release -_ changing between themes not updating the combo box text (though arrow trigger works) -_ switching between alloys and minerals will properly update -_ completion mode pop-up not following dark and light mode conventions - - during release of beta 9 _ submit to Microsoft _ https://www.microsoft.com/en-us/wdsi/filesubmission @@ -200,6 +200,7 @@ _ ui scaling in the PDE is important for classes/seeing at a distance 4.0 +_ completion mode pop-up not following dark and light mode conventions _ how to handle contrib manager download/retry/etc and showing progress _ adding a file to an untitled sketch should require a save _ Cannot type quotes with an international keyboard on MacOS @@ -216,8 +217,6 @@ _ really a drag for version control _ https://github.com/processing/processing/issues/5848 _ or at least avoid the multiple _ https://github.com/processing/processing4/issues/330 -_ if error in the code during export, it's just saying "error during export" -_ is this still the case? _ add a version of this to the 4.x repo _ https://github.com/processing/processing/wiki/troubleshooting _ and update the Help menu to link to it @@ -225,14 +224,11 @@ _ and maybe the FAQ too? 4.0 / with Casey -_ Export to Application was broken with OpenGL (Casey) _ resolution for the About screen _ examples still coming from processing-docs repo _ chars[] array is never used in ascii video example - - waiting/video library _ update Video library to use the new layout _ Export to Application not working with the current video library