MCPcopy Create free account
hub / github.com/OpenSourcePhysics/osp / focusGained

Method focusGained

src/test/Test_Event.java:418–426  ·  view source on GitHub ↗
(FocusEvent e)

Source from the content-addressed store, hash-verified

416 private FocusListener fl = new FocusListener() {
417
418 @Override
419 public void focusGained(FocusEvent e) {
420 if(logging)System.out.println("focus gained");
421 if(logging)System.out.println("Test_Editor focus GAINED " + getID(e.getSource()) + " opp:" + getID(e.getOppositeComponent()));
422 // ptop.setBackground(Color.LIGHT_GRAY);
423
424 if(logging)System.out.println("Test_Editor Active = " + KeyboardFocusManager.getCurrentKeyboardFocusManager().getActiveWindow());
425 if(logging)System.out.println("Test_Editor Focused = "+ KeyboardFocusManager.getCurrentKeyboardFocusManager().getFocusedWindow());
426 }
427
428 @Override
429 public void focusLost(FocusEvent e) {

Callers

nothing calls this directly

Calls 3

getIDMethod · 0.95
getSourceMethod · 0.80
printlnMethod · 0.65

Tested by

no test coverage detected