private static boolean hasSameDefaultAccelerator ( KeyboardMapping km , KeyStroke ks ) { KeyStroke kmKs = km . getDefaultKeyStroke ( ) ; if ( kmKs == null ) { return false ; } return kmKs . getKeyCode ( ) == ks . getKeyCode ( ) && kmKs . getModifiers ( ) == ks . getModifiers ( ) ; }
Tells whether or not the given keyboard mapping has the given default accelerator .