Changeset 604 in josm


Ignore:
Timestamp:
2008-04-12T11:48:54+02:00 (13 years ago)
Author:
ramack
Message:
  • make gps-direction preference editable without einstein-mode (related to ticket #688)
File:
1 edited

Legend:

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

    r597 r604  
    1818        private JCheckBox largeGpsPoints = new JCheckBox(tr("Draw large GPS points."));
    1919        private JCheckBox directionHint = new JCheckBox(tr("Draw Direction Arrows"));
     20        private JCheckBox drawGpsArrows = new JCheckBox(tr("Draw Direction Arrows"));
    2021        private JCheckBox interestingDirections = new JCheckBox(tr("Only interesting direction hints (e.g. with oneway tag)."));
    2122        private JCheckBox segmentOrderNumber = new JCheckBox(tr("Draw segment order numbers"));
     
    2728                drawRawGpsLines.addActionListener(new ActionListener(){
    2829                        public void actionPerformed(ActionEvent e) {
    29                                 if (!drawRawGpsLines.isSelected())
    30                                         forceRawGpsLines.setSelected(false);
    31                                 forceRawGpsLines.setEnabled(drawRawGpsLines.isSelected());
     30                            if (!drawRawGpsLines.isSelected()){
     31                                forceRawGpsLines.setSelected(false);
     32                                drawGpsArrows.setSelected(false);
     33                            }
     34                            forceRawGpsLines.setEnabled(drawRawGpsLines.isSelected());
     35                            drawGpsArrows.setEnabled(drawRawGpsLines.isSelected());
    3236                        }
    3337                });
     
    4145                forceRawGpsLines.setEnabled(drawRawGpsLines.isSelected());
    4246                gui.display.add(forceRawGpsLines, GBC.eop().insets(40,0,0,0));
     47               
     48                // drawGpsArrows
     49                drawGpsArrows.setToolTipText(tr("Draw direction arrows for lines, connecting GPS points."));
     50                drawGpsArrows.setSelected(Main.pref.getBoolean("draw.rawgps.direction"));
     51                drawGpsArrows.setEnabled(drawRawGpsLines.isSelected());
     52                gui.display.add(drawGpsArrows, GBC.eop().insets(40,0,0,0));
    4353               
    4454                // largeGpsPoints
     
    8797                Main.pref.put("draw.rawgps.lines", drawRawGpsLines.isSelected());
    8898                Main.pref.put("draw.rawgps.lines.force", forceRawGpsLines.isSelected());
     99                Main.pref.put("draw.rawgps.direction", drawGpsArrows.isSelected());
    89100                Main.pref.put("draw.rawgps.large", largeGpsPoints.isSelected());
    90101                Main.pref.put("draw.segment.direction", directionHint.isSelected());
Note: See TracChangeset for help on using the changeset viewer.