android 输入法的使用
@Overrideprotected void onCreate(Bundle savedInstanceState) {super.onCreate(savedInstanceState);setContentView(R.layout.softkey);buttonshow = (Button)findViewById(R.id.buttonshow);editshow = (EditText)findViewById(R.id.editshow);buttonshow.setOnClickListener(this);editshow.setOnClickListener(this);}/** * * * * * 输入法的使用 */@Overridepublic void onClick(View v) {switch (v.getId()) {case R.id.buttonshow:showKeyboard();break;case R.id.editshow:showKeyboard();break;default: break; }}private void showKeyboard() {InputMethodManager m=(InputMethodManager) (this.getBaseContext().getSystemService(INPUT_METHOD_SERVICE));m.toggleSoftInput(0, InputMethodManager.HIDE_NOT_ALWAYS);//m.hideSoftInputFromWindow(this.getWindow().getWindowStyle().get, 0);}}?