@Override
 protected void onDialogClosed(boolean result) {
   super.onDialogClosed(result);
   if (result) {
     setSummary(getEntry());
   }
 }
Esempio n. 2
0
  @Override
  protected void onDialogClosed(boolean positiveResult) {
    super.onDialogClosed(positiveResult);

    if (!positiveResult) {
      // The button was dismissed - no need to set new value
      return;
    }

    int buttonCdmaSubscriptionMode = Integer.valueOf(getValue()).intValue();
    Log.d(LOG_TAG, "Setting new value " + buttonCdmaSubscriptionMode);
    int statusCdmaSubscriptionMode;
    switch (buttonCdmaSubscriptionMode) {
      case CDMA_SUBSCRIPTION_NV:
        statusCdmaSubscriptionMode = Phone.CDMA_SUBSCRIPTION_NV;
        break;
      case CDMA_SUBSCRIPTION_RUIM_SIM:
        statusCdmaSubscriptionMode = Phone.CDMA_SUBSCRIPTION_RUIM_SIM;
        break;
      default:
        statusCdmaSubscriptionMode = Phone.PREFERRED_CDMA_SUBSCRIPTION;
    }

    // Set the CDMA subscription mode, when mode has been successfully changed
    // handleSetCdmaSubscriptionMode will be invoked and the value saved.
    mPhone.setCdmaSubscription(
        statusCdmaSubscriptionMode,
        mHandler.obtainMessage(
            CdmaSubscriptionButtonHandler.MESSAGE_SET_CDMA_SUBSCRIPTION, getValue()));

    PhoneGlobals.getInstance().removeSubInfoUpdateListener(this);
  }
  @Override
  protected void onDialogClosed(boolean positiveResult) {
    super.onDialogClosed(positiveResult);

    if (positiveResult) {
      String blinkPattern = DrizzleSmsPreferences.getNotificationLedPattern(context);
      if (blinkPattern.equals("custom")) showDialog();
    }
  }
  @Override
  protected void onDialogClosed(boolean positiveResult) {
    super.onDialogClosed(positiveResult);

    if (positiveResult && mEndpointValue != null) {
      if (callChangeListener(mEndpointValue)) {
        setValue(mEndpointValue);
      }
    }
  }