sclass CircleDoubleClicker extends MouseAdapter { CirclesAndLines cal; Canvas canvas; O onClick; *(CirclesAndLines *cal, Canvas *canvas, O *onClick) { if (containsInstance(canvas.tools, CircleDoubleClicker)) ret; canvas.tools.add(this); canvas.addMouseListener(this); } public void mouseClicked(MouseEvent e) { if (e.getButton() == MouseEvent.BUTTON1 && e.getClickCount() == 2) { Pt p = canvas.pointFromEvent(e); Circle c = cal.findCircle(canvas, p); if (c != null) pcallF(onClick, c); } } }
download show line numbers debug dex old transpilations
Travelled to 13 computer(s): aoiabmzegqzx, bhatertpkbcr, cbybwowwnfue, cfunsshuasjs, gwrvuhgaqvyk, ishqpsrjomds, lpdgvwnxivlt, mqqgnosmbjvj, pyentgdyhuwx, pzhvpgtvlbxg, tslmcundralx, tvejysmllsmz, vouqrxazstgt
No comments. add comment
Snippet ID: | #1007464 |
Snippet name: | CircleDoubleClicker |
Eternal ID of this version: | #1007464/6 |
Text MD5: | 8efcfa726ec70a2a4e1980263e65d0e1 |
Author: | stefan |
Category: | javax / a.i. / gui |
Type: | JavaX fragment (include) |
Public (visible to everyone): | Yes |
Archived (hidden from active list): | No |
Created/modified: | 2017-03-23 23:17:30 |
Source code size: | 572 bytes / 20 lines |
Pitched / IR pitched: | No / No |
Views / Downloads: | 521 / 1111 |
Version history: | 5 change(s) |
Referenced in: | #1034167 - Standard Classes + Interfaces (LIVE, continuation of #1003674) |