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

10
LINES

< > BotCompany Repo | #1020868 // addToHGrid (untested)

JavaX fragment (include)

svoid addToHGrid(final Container hgrid, final Component c) {
  if (hgrid == null || c == null) ret;
  swing {
    hgrid.add(component);
    GridLayout grid = optCast(GridLayout.class, hgrid.getLayout());
    if (grid != null)
      grid.setColumns(countComponents(hgrid));
    revalidate(hgrid);
  }
}

Author comment

Began life as a copy of #1016811

download  show line numbers  debug dex  old transpilations   

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

No comments. add comment

Snippet ID: #1020868
Snippet name: addToHGrid (untested)
Eternal ID of this version: #1020868/3
Text MD5: 081f90a56eccd70607f94a1c0f6f9b01
Author: stefan
Category: javax
Type: JavaX fragment (include)
Public (visible to everyone): Yes
Archived (hidden from active list): No
Created/modified: 2019-01-06 16:07:53
Source code size: 310 bytes / 10 lines
Pitched / IR pitched: No / No
Views / Downloads: 216 / 252
Version history: 2 change(s)
Referenced in: [show references]