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

11
LINES

< > BotCompany Repo | #1016036 // replaceTreeNodeChildren

JavaX fragment (include)

static bool replaceTreeNodeChildren(final DefaultMutableTreeNode node, fL children) {
  if (node == null) false;
  ret swing(func -> bool {
    L oldChildren = mapMethod('getUserObject, node.children());
    if (eq(oldChildren, children)) false;
    node.removeAllChildren();
    for (O c : children)
      node.add(new DefaultMutableTreeNode(c));
    true;
  });
}

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: #1016036
Snippet name: replaceTreeNodeChildren
Eternal ID of this version: #1016036/1
Text MD5: 5abc11ddc997ea3a6b5c5238ab7502b9
Author: stefan
Category: javax / gui
Type: JavaX fragment (include)
Public (visible to everyone): Yes
Archived (hidden from active list): No
Created/modified: 2018-06-03 12:51:19
Source code size: 375 bytes / 11 lines
Pitched / IR pitched: No / No
Views / Downloads: 298 / 334
Referenced in: [show references]