Ignore:
Timestamp:
2013-05-13T03:10:05+02:00 (11 years ago)
Author:
Don-vip
Message:
  • Improve PopupMenuLauncher to automatically select JTable/JList/JTree line under cursor
  • Simplify all popup menus with this new feature
  • Remove custom popup menus in BoundingBoxSelection and BoundingBoxSelection to use default text field popup menus recently introduced
  • Fix EDT violations in changeset window
  • Make Autoscale actions publicly available in MainMenu
  • Add a new "Zoom to problem" mode in AutoScaleAction
  • Make "Zoom to problem" menu item in validator dialog use this new feature
  • Update enabled state of "Zoom to Conflict" and "Zoom to problem" against selection of conflict/validator dialog
File:
1 edited

Legend:

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

    r5886 r5958  
    694694            if (cbWireframe.isSelected())
    695695                return;
    696             Point p = evt.getPoint();
    697             int index = tblStyles.rowAtPoint(p);
    698             if (index < 0) return;
    699             if (!tblStyles.getCellRect(index, 1, false).contains(evt.getPoint()))
    700                 return;
    701             if (!tblStyles.isRowSelected(index)) {
    702                 tblStyles.setRowSelectionInterval(index, index);
    703             }
    704             MapPaintPopup menu = new MapPaintPopup();
    705             menu.show(tblStyles, p.x, p.y);
    706         }
    707     }
    708 
     696            super.launch(evt);
     697        }
     698
     699        @Override
     700        protected void showMenu(MouseEvent evt) {
     701            menu = new MapPaintPopup();
     702            super.showMenu(evt);
     703        }
     704    }
     705
     706    /**
     707     * The popup menu displayed when right-clicking a map paint entry
     708     */
    709709    public class MapPaintPopup extends JPopupMenu {
    710710        /**
Note: See TracChangeset for help on using the changeset viewer.