Changeset 1726 in josm for trunk/src/org/openstreetmap
- Timestamp:
- 2009-07-03T23:50:09+02:00 (15 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/org/openstreetmap/josm/gui/layer/markerlayer/ButtonMarker.java
r1724 r1726 52 52 Point mousePosition = mv.getMousePosition(); 53 53 54 if (mousePosition != null) { 55 // mouse is inside the window 56 if (mousePressed) { 57 b = BorderFactory.createBevelBorder(BevelBorder.LOWERED); 58 } else { 59 b = BorderFactory.createBevelBorder(BevelBorder.RAISED); 60 } 61 Insets inset = b.getBorderInsets(mv); 62 Rectangle r = new Rectangle(buttonRectangle); 63 r.grow((inset.top+inset.bottom)/2, (inset.left+inset.right)/2); 64 b.paintBorder(mv, g, r.x, r.y, r.width, r.height); 54 // mouse is inside the window 55 if (mousePosition != null && mousePressed) { 56 b = BorderFactory.createBevelBorder(BevelBorder.LOWERED); 57 } else { 58 b = BorderFactory.createBevelBorder(BevelBorder.RAISED); 65 59 } 60 Insets inset = b.getBorderInsets(mv); 61 Rectangle r = new Rectangle(buttonRectangle); 62 r.grow((inset.top+inset.bottom)/2, (inset.left+inset.right)/2); 63 b.paintBorder(mv, g, r.x, r.y, r.width, r.height); 66 64 if ((text != null) && (show.equalsIgnoreCase("show")) && Main.pref.getBoolean("marker.buttonlabels", true)) 67 65 g.drawString(text, screen.x+4, screen.y+2);
Note:
See TracChangeset
for help on using the changeset viewer.