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

Method getIdString

src/test/Test_Event.java:308–338  ·  view source on GitHub ↗

SwingJS convenience for debugging @param id @return

(int id)

Source from the content-addressed store, hash-verified

306 * @return
307 */
308 public static String getIdString(int id) {
309 switch (id) {
310 case MouseEvent.MOUSE_PRESSED:
311 return "MOUSE_PRESSED";
312
313 case MouseEvent.MOUSE_RELEASED:
314 return "MOUSE_RELEASED";
315
316 case MouseEvent.MOUSE_CLICKED:
317 return "MOUSE_CLICKED";
318
319 case MouseEvent.MOUSE_ENTERED:
320 return "MOUSE_ENTERED";
321
322 case MouseEvent.MOUSE_EXITED:
323 return "MOUSE_EXITED";
324
325 case MouseEvent.MOUSE_MOVED:
326 return "MOUSE_MOVED";
327
328 case MouseEvent.MOUSE_DRAGGED:
329 return "MOUSE_DRAGGED";
330
331 case MouseEvent.MOUSE_WHEEL:
332 return "MOUSE_WHEEL";
333
334 default:
335 return "unknown type";
336 }
337
338 }
339
340 KeyListener kl = new KeyAdapter() {
341 @Override

Callers 1

showMouseEventMethod · 0.95

Calls

no outgoing calls

Tested by

no test coverage detected