/[classpath]/classpath/javax/swing/text/AbstractDocument.java
ViewVC logotype

Diff of /classpath/javax/swing/text/AbstractDocument.java

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.26 by mark, Mon Aug 29 17:02:02 2005 UTC revision 1.27 by mark, Sun Sep 4 11:53:12 2005 UTC
# Line 1864  public abstract class AbstractDocument Line 1864  public abstract class AbstractDocument
1864                         int end)                         int end)
1865      {      {
1866        super(parent, attributes);        super(parent, attributes);
       try  
1867          {          {
1868            startPos = parent.getDocument().createPosition(start);            try
1869            endPos = parent.getDocument().createPosition(end);              {
1870          }                if (parent != null)
1871        catch (BadLocationException ex)                  {
1872          {                    startPos = parent.getDocument().createPosition(start);
1873            throw new AssertionError("BadLocationException must not be thrown "                    endPos = parent.getDocument().createPosition(end);
1874                                     + "here. start=" + start + ", end=" + end                  }
1875                                     + ", length=" + getLength());                else
1876                    {
1877                      startPos = createPosition(start);
1878                      endPos = createPosition(end);
1879                    }
1880                }
1881              catch (BadLocationException ex)
1882                {
1883                  AssertionError as;
1884                  as = new AssertionError("BadLocationException thrown "
1885                                          + "here. start=" + start
1886                                          + ", end=" + end
1887                                          + ", length=" + getLength());
1888                  as.initCause(ex);
1889                  throw as;
1890                }
1891          }          }
1892      }      }
1893    

Legend:
Removed from v.1.26  
changed lines
  Added in v.1.27

savannah-hackers-public@gnu.org
ViewVC Help
Powered by ViewVC 1.1.26