Code example for KeyboardView

Methods: getKeyboard, setShifted

0
	 * Helper to update the shift state of our keyboard based on the initial 
	 * editor state. 
	 */ 
	private void updateShiftKeyState(EditorInfo attr) {
		if (attr != null && mInputView != null
				&& mQwertyKeyboard == mInputView.getKeyboard()) {
			int caps = 0;
			EditorInfo ei = getCurrentInputEditorInfo();
			if (ei != null && ei.inputType != EditorInfo.TYPE_NULL) {
				caps = getCurrentInputConnection().getCursorCapsMode(
						attr.inputType);
			} 
			mInputView.setShifted(mCapsLock || caps != 0);
		} 
	} 
 
	/** 
	 * Helper to send a key down / key up pair to the current editor. 
	 */ 
	private void keyDownUp(int keyEventCode) {
		getCurrentInputConnection().sendKeyEvent(