(Graphics g, int ofs, boolean sel)
| 54 | public int getValue() { return value; } |
| 55 | |
| 56 | public void drawItem(Graphics g, int ofs, boolean sel) { |
| 57 | int width=g.getClipWidth(); |
| 58 | int height=g.getClipHeight(); |
| 59 | |
| 60 | int itemWidth=6; |
| 61 | int pos=((width-itemWidth)*value)/(steps-1); |
| 62 | |
| 63 | int oldColor=g.getColor(); |
| 64 | |
| 65 | g.setColor(ColorTheme.getColor(ColorTheme.CONTROL_ITEM)); |
| 66 | g.drawLine(4, height/2, width-4, height/2); |
| 67 | |
| 68 | g.fillRect(pos, 2, itemWidth, height-4); |
| 69 | |
| 70 | g.setColor(oldColor); |
| 71 | } |
| 72 | |
| 73 | public void onSelect(){ value=(value+1)%steps; } |
| 74 |
nothing calls this directly
no test coverage detected