avalon-cvs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From l...@apache.org
Subject cvs commit: jakarta-avalon-excalibur/src/scratchpad/org/apache/avalon/excalibur/altprofile/profiler/gui ProfilerFrame.java
Date Tue, 05 Mar 2002 13:28:45 GMT
leif        02/03/05 05:28:45

  Modified:    src/scratchpad/org/apache/avalon/excalibur/altprofile/profiler/gui
                        ProfilerFrame.java
  Log:
  Allow a default desktop file to be provided to the ProfileFrame
  
  Revision  Changes    Path
  1.6       +10 -7     jakarta-avalon-excalibur/src/scratchpad/org/apache/avalon/excalibur/altprofile/profiler/gui/ProfilerFrame.java
  
  Index: ProfilerFrame.java
  ===================================================================
  RCS file: /home/cvs/jakarta-avalon-excalibur/src/scratchpad/org/apache/avalon/excalibur/altprofile/profiler/gui/ProfilerFrame.java,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -r1.5 -r1.6
  --- ProfilerFrame.java	5 Mar 2002 13:04:48 -0000	1.5
  +++ ProfilerFrame.java	5 Mar 2002 13:28:45 -0000	1.6
  @@ -42,7 +42,7 @@
   /**
    *
    * @author <a href="mailto:leif@silveregg.co.jp">Leif Mortenson</a>
  - * @version CVS $Revision: 1.5 $ $Date: 2002/03/05 13:04:48 $
  + * @version CVS $Revision: 1.6 $ $Date: 2002/03/05 13:28:45 $
    * @since 4.1
    */
   public class ProfilerFrame
  @@ -87,14 +87,17 @@
       public void loadDesktopStateFromFile( File file, boolean showErrorDialog )
           throws SAXException, IOException, ConfigurationException
       {
  -        FileInputStream is = new FileInputStream( file );
  -        try
  +        if ( file.exists() )
           {
  -            loadDesktopStateFromStream( is, showErrorDialog );
  -        }
  -        finally
  -        {
  -            is.close();
  +            FileInputStream is = new FileInputStream( file );
  +            try
  +            {
  +                loadDesktopStateFromStream( is, showErrorDialog );
  +            }
  +            finally
  +            {
  +                is.close();
  +            }
           }
           
           m_desktopFile = file;
  
  
  

--
To unsubscribe, e-mail:   <mailto:avalon-cvs-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:avalon-cvs-help@jakarta.apache.org>


Mime
View raw message