Changeset 2384 in josm for trunk


Ignore:
Timestamp:
2009-11-02T16:19:08+01:00 (15 years ago)
Author:
bastiK
Message:

WindowGeometry: don't put warning on the command line if a default value is available, but has not jet been written to the preference file

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/org/openstreetmap/josm/tools/WindowGeometry.java

    r2181 r2384  
    116116    protected void initFromPreferences(String preferenceKey) throws WindowGeometryException {
    117117        String value = Main.pref.get(preferenceKey);
    118         if (value == null)
     118        if (value == null || value.equals(""))
    119119            throw new WindowGeometryException(tr("Preference with key ''{0}'' does not exist. Can''t restore window geometry from preferences.", preferenceKey));
    120120        topLeft = new Point();
     
    156156            initFromPreferences(preferenceKey);
    157157        } catch(WindowGeometryException e) {
    158             System.out.println(tr("Warning: Failed to restore window geometry from key ''{0}''. Falling back to default geometry. Details: {1}", preferenceKey, e.getMessage()));
     158//            System.out.println(tr("Warning: Failed to restore window geometry from key ''{0}''. Falling back to default geometry. Details: {1}", preferenceKey, e.getMessage()));
    159159            initFromWindowGeometry(defaultGeometry);
    160160        }
Note: See TracChangeset for help on using the changeset viewer.