コード例 #1
0
  public void onNetworkStateChanged(Intent intent) {
    final boolean noConnection =
        intent.getBooleanExtra(ConnectivityManager.EXTRA_NO_CONNECTIVITY, false);
    mIsNetworkConnected = !noConnection;

    final KeyboardSwitcher switcher = KeyboardSwitcher.getInstance();
    final LatinKeyboard keyboard = switcher.getLatinKeyboard();
    if (keyboard != null) {
      keyboard.updateShortcutKey(isShortcutImeReady(), switcher.getKeyboardView());
    }
  }