Changeset 3040


Ignore:
Timestamp:
08/03/07 15:02:07 (13 years ago)
Author:
curtis
Message:

Add a hack to filter out stupid clipboard stack traces on Mac OS X.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/loci/visbio/util/OutputConsole.java

    r3015 r3040  
    135135  } 
    136136 
    137 //  private boolean lastInvalid; 
     137  private boolean lastInvalid; 
    138138 
    139139  public void write(byte[] b, int off, int len) throws IOException { 
     
    152152//    if (lastInvalid && s.trim().equals("")) return; 
    153153//    lastInvalid = false; 
     154 
     155    // HACK - filter out stupid IOException clipboard stack trace on Mac OS X 
     156    if (s.startsWith("java.io.IOException: " + 
     157      "system clipboard data is unavailable")) 
     158    { 
     159      lastInvalid = true; 
     160      return; 
     161    } 
     162    // ignore remainder of stack trace 
     163    if (lastInvalid && s.startsWith("\tat ")) return; 
     164    lastInvalid = false; 
    154165 
    155166    SwingUtilities.invokeLater(new Runnable() { 
Note: See TracChangeset for help on using the changeset viewer.