Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDarin Wright2001-07-16 19:34:13 +0000
committerDarin Wright2001-07-16 19:34:13 +0000
commit0c627a4e7cf9c78f8a356c91ca6950913a83ac98 (patch)
tree416ff385b6283154610c89cd4d3bc9a4b6f7b4aa
parente01ea82dfb4e1b05c4305b1a4eddeabe91c7766f (diff)
downloadeclipse.platform.debug-0c627a4e7cf9c78f8a356c91ca6950913a83ac98.tar.gz
eclipse.platform.debug-0c627a4e7cf9c78f8a356c91ca6950913a83ac98.tar.xz
eclipse.platform.debug-0c627a4e7cf9c78f8a356c91ca6950913a83ac98.zip
fallback for 1GFW4RT
-rw-r--r--org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/ConsoleDocument.java35
1 files changed, 11 insertions, 24 deletions
diff --git a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/ConsoleDocument.java b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/ConsoleDocument.java
index 4438dd46c..e9ff360d2 100644
--- a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/ConsoleDocument.java
+++ b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/ConsoleDocument.java
@@ -21,8 +21,6 @@ import org.eclipse.swt.widgets.Display;
public class ConsoleDocument extends AbstractDocument implements IDebugEventListener {
private boolean fClosed= false;
-
- protected boolean fCanWrite= true;
protected IProcess fProcess;
private IStreamsProxy fProxy;
@@ -79,7 +77,6 @@ public class ConsoleDocument extends AbstractDocument implements IDebugEventList
*/
protected void fireDocumentChanged(DocumentEvent event) {
super.fireDocumentChanged(event);
-
String eventText= event.getText();
if (eventText == null || 0 >= eventText.length() || eventText.length() > 2) {
return;
@@ -87,28 +84,18 @@ public class ConsoleDocument extends AbstractDocument implements IDebugEventList
String[] lineDelimiters= event.getDocument().getLegalLineDelimiters();
for (int i= 0; i < lineDelimiters.length; i++) {
if (lineDelimiters[i].equals(eventText)) {
- String inText= event.getDocument().get();
- inText= inText.substring(fNewStreamWriteEnd, inText.length());
- if (inText.length() == 0) {
- return;
- }
- if (fCanWrite) {
- final String input= inText;
- Runnable runnable= new Runnable() {
- public void run() {
- try {
- fCanWrite= false;
- fProxy.write(input);
- fCanWrite= true;
- } catch (IOException ioe) {
- DebugUIUtils.logError(ioe);
- }
- }
- };
- Thread proxyWriter= new Thread(runnable);
- proxyWriter.start();
+ try {
+ String inText= event.getDocument().get();
+ inText= inText.substring(fNewStreamWriteEnd, inText.length());
+ if (inText.length() == 0) {
+ return;
+ }
+ fProxy.write(inText);
fLastStreamWriteEnd= getLength();
- }
+ return;
+ } catch (IOException ioe) {
+ DebugUIUtils.logError(ioe);
+ }
}
}
}

Back to the top