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

13
LINES

< > BotCompany Repo | #1026604 // onBoundsChange

JavaX fragment (include)

static <A extends Component> A onBoundsChange(A c, fO r) {
  if (c != null && r != null) swing {
    c.addComponentListener(new ComponentAdapter {
      public void componentResized(ComponentEvent e) { pcallF(r); }
      public void componentMoved(ComponentEvent e) { pcallF(r); }
    });
  }
  ret c;
}

static <A extends Component> A onBoundsChange(O r, A c) {
  ret onBoundsChange(c, r);
}

Author comment

Began life as a copy of #1007285

download  show line numbers  debug dex  old transpilations   

Travelled to 7 computer(s): bhatertpkbcr, mqqgnosmbjvj, pyentgdyhuwx, pzhvpgtvlbxg, tvejysmllsmz, vouqrxazstgt, xrpafgyirdlv

No comments. add comment

Snippet ID: #1026604
Snippet name: onBoundsChange
Eternal ID of this version: #1026604/1
Text MD5: d265580745860c8787c0a38572e56d7b
Author: stefan
Category: javax / gui
Type: JavaX fragment (include)
Public (visible to everyone): Yes
Archived (hidden from active list): No
Created/modified: 2020-01-15 18:50:01
Source code size: 404 bytes / 13 lines
Pitched / IR pitched: No / No
Views / Downloads: 257 / 287
Referenced in: #1006654 - Standard functions list 2 (LIVE, continuation of #761)