Changeset 16132 in josm for trunk/src/org/openstreetmap


Ignore:
Timestamp:
2020-03-15T13:26:29+01:00 (6 years ago)
Author:
GerdP
Message:

fix #18769: Each time I open JOSM, the right pane gets slightly wider
Correct the calculation of the preference value toggleDialogs.width

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/org/openstreetmap/josm/gui/MapFrame.java

    r15859 r16132  
    343343        MainApplication.getLayerManager().removeActiveLayerChangeListener(this);
    344344        MainApplication.getMenu().modeMenu.removeAll();
     345        rememberToggleDialogWidth();
    345346        dialogsPanel.destroy();
    346347        Config.getPref().removePreferenceChangeListener(sidetoolbarPreferencesChangedListener);
     
    739740    public void rememberToggleDialogWidth() {
    740741        if (dialogsPanel.isVisible()) {
    741             TOGGLE_DIALOGS_WIDTH.put(splitPane.getWidth() - splitPane.getDividerLocation());
     742            TOGGLE_DIALOGS_WIDTH.put(splitPane.getWidth() - splitPane.getDividerLocation() - splitPane.getDividerSize() - 1);
    742743        }
    743744    }
Note: See TracChangeset for help on using the changeset viewer.