You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@groovy.apache.org by pa...@apache.org on 2021/05/20 05:03:22 UTC
[groovy] branch master updated: add comments
This is an automated email from the ASF dual-hosted git repository.
paulk pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/groovy.git
The following commit(s) were added to refs/heads/master by this push:
new 7eaaf99 add comments
7eaaf99 is described below
commit 7eaaf99eb6e999287c90c4175c4d313bf17a40e2
Author: nineninesevenfour <ha...@gmail.com>
AuthorDate: Sun May 9 02:09:58 2021 +0200
add comments
Signed-off-by: nineninesevenfour <ha...@gmail.com>
---
.../src/main/groovy/groovy/console/ui/Console.groovy | 7 +++++++
1 file changed, 7 insertions(+)
diff --git a/subprojects/groovy-console/src/main/groovy/groovy/console/ui/Console.groovy b/subprojects/groovy-console/src/main/groovy/groovy/console/ui/Console.groovy
index 4820d8f..df78f09 100644
--- a/subprojects/groovy-console/src/main/groovy/groovy/console/ui/Console.groovy
+++ b/subprojects/groovy-console/src/main/groovy/groovy/console/ui/Console.groovy
@@ -492,6 +492,7 @@ class Console implements CaretListener, HyperlinkListener, ComponentListener, Fo
systemOutInterceptor.start()
systemErrorInterceptor = new SystemOutputInterceptor(this.¬ifySystemErr, false)
systemErrorInterceptor.start()
+ // TODO: would this be a good place to assign the console id?
}
void addToHistory(record) {
@@ -830,6 +831,11 @@ class Console implements CaretListener, HyperlinkListener, ComponentListener, Fo
swing.controller = consoleController
swing.build(ConsoleActions)
swing.build(ConsoleView)
+ // TODO The call to installInterceptor() conveys that the interceptors are installed for the new window,
+ // but this seems not to be the case. Instead the method creates new interceptors for the current window.
+ // The new window inherited the interceptors from this window a few statements above.
+ // Actually - since System.out and System.err exists only once - there should be only one interceptor
+ // forwarding to potentially more than one window.
installInterceptor()
nativeFullScreenForMac(swing.consoleFrame)
swing.consoleFrame.pack()
@@ -1359,6 +1365,7 @@ class Console implements CaretListener, HyperlinkListener, ComponentListener, Fo
runThread = Thread.start {
try {
systemOutInterceptor.setConsoleId(this.getConsoleId())
+ // TODO should systemErrorInterceptor receive the console id, too?
SwingUtilities.invokeLater { showExecutingMessage() }
if (beforeExecution) {
beforeExecution()