Not logged in.  Login/Logout/Register | List snippets | | Create snippet | Upload image | Upload data

11
LINES

< > BotCompany Repo | #1005610 // trackOneClick - track mouse pointer and record (don't forward)

JavaX fragment (include)

1  
// onClick: voidfunc(Point, int) - 2nd parameter is button (1 to 3)
2  
// or voidfunc(Point)
3  
static void trackOneClick(final O onClick) {
4  
  forwardOneClick(func(final Point p, final int button) {
5  
    awt { // Let the window go away first
6  
      callFOpt(onClick, p, button);
7  
      callFOpt(onClick, p);
8  
    }
9  
    false; // don't forward click
10  
  });
11  
}

Author comment

Began life as a copy of #1005566

download  show line numbers  debug dex  old transpilations   

Travelled to 14 computer(s): aoiabmzegqzx, bhatertpkbcr, cbybwowwnfue, cfunsshuasjs, ddnzoavkxhuk, gwrvuhgaqvyk, ishqpsrjomds, lpdgvwnxivlt, mqqgnosmbjvj, pyentgdyhuwx, pzhvpgtvlbxg, tslmcundralx, tvejysmllsmz, vouqrxazstgt

No comments. add comment

Snippet ID: #1005610
Snippet name: trackOneClick - track mouse pointer and record (don't forward)
Eternal ID of this version: #1005610/1
Text MD5: 98e98dfa516ede86c79cff0c5e033636
Author: stefan
Category: javax / gui
Type: JavaX fragment (include)
Public (visible to everyone): Yes
Archived (hidden from active list): No
Created/modified: 2016-11-30 13:50:56
Source code size: 356 bytes / 11 lines
Pitched / IR pitched: No / No
Views / Downloads: 632 / 648
Referenced in: [show references]