public void setAccelerator(JMenuItem item, int key) {
		int mask = (Platform.isMac()) ? KeyEvent.META_MASK : KeyEvent.CTRL_MASK;
		if (key > 0x10000) {
			key -= SHIFT;
			mask |= KeyEvent.SHIFT_MASK;
		}
		KeyStroke stroke = KeyStroke.getKeyStroke((char) key, mask);
		accelerators.put(stroke, item);
		if (Platform.isMac()) {
			item.setAccelerator(stroke);
		} else {
			item.setMnemonic(key);
		}
	}