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

14
LINES

< > BotCompany Repo | #1029923 // Test installInternalFrameSwitcher_v3 with InstaSwitch (now default)

JavaX source code (desktop) [tags: use-pretranspiled] - run with: x30.jar

Download Jar. Libraryless. Click here for Pure Java version (7962L/55K).

1  
!7
2  
3  
p {
4  
  JDesktopPane desktop = jDesktopPane();
5  
  final JTextField tfInput = jCenteredTextField();
6  
  showFrame(northAndCenter(tfInput, desktop));
7  
  SwitchDispatcher dispatcher = installInternalFrameSwitcher_v3(desktop);
8  
  dispatcher.shouldSwitch =
9  
    func -> bool { isFocusedComponent(tfInput) };
10  
  dispatcher.instaSwitch = true;
11  
  addInternalFrame(desktop, "Test", jTextArea());
12  
  addInternalFrame(desktop, "Test 2", jTextArea());
13  
  addInternalFrame(desktop, "Test 3", jTextArea());
14  
}

Author comment

Began life as a copy of #1019719

download  show line numbers  debug dex  old transpilations   

Travelled to 4 computer(s): bhatertpkbcr, mqqgnosmbjvj, pyentgdyhuwx, vouqrxazstgt

No comments. add comment

Snippet ID: #1029923
Snippet name: Test installInternalFrameSwitcher_v3 with InstaSwitch (now default)
Eternal ID of this version: #1029923/4
Text MD5: 7a8f39ea4ff2383e627bb692084f42dd
Transpilation MD5: ffb196a60cdcc0715aae86f8efa5f25c
Author: stefan
Category: javax / gui
Type: JavaX source code (desktop)
Public (visible to everyone): Yes
Archived (hidden from active list): No
Created/modified: 2020-10-06 14:03:43
Source code size: 500 bytes / 14 lines
Pitched / IR pitched: No / No
Views / Downloads: 226 / 771
Version history: 3 change(s)
Referenced in: [show references]