PhoneProxy.java revision 9e652dcc213b96087ccadc730b1e6b1891cd02ae
1/* 2 * Copyright (C) 2008 The Android Open Source Project 3 * 4 * Licensed under the Apache License, Version 2.0 (the "License"); 5 * you may not use this file except in compliance with the License. 6 * You may obtain a copy of the License at 7 * 8 * http://www.apache.org/licenses/LICENSE-2.0 9 * 10 * Unless required by applicable law or agreed to in writing, software 11 * distributed under the License is distributed on an "AS IS" BASIS, 12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 * See the License for the specific language governing permissions and 14 * limitations under the License. 15 */ 16 17package com.android.internal.telephony; 18 19 20import android.app.ActivityManagerNative; 21import android.content.Context; 22import android.content.Intent; 23import android.content.SharedPreferences; 24import android.os.Handler; 25import android.os.Message; 26import android.preference.PreferenceManager; 27import android.telephony.CellLocation; 28import android.telephony.PhoneStateListener; 29import android.telephony.ServiceState; 30import android.telephony.SignalStrength; 31import android.util.Log; 32 33import com.android.internal.telephony.cdma.CDMAPhone; 34import com.android.internal.telephony.gsm.GSMPhone; 35import com.android.internal.telephony.gsm.NetworkInfo; 36import com.android.internal.telephony.gsm.PdpConnection; 37import com.android.internal.telephony.test.SimulatedRadioControl; 38 39import java.util.List; 40 41public class PhoneProxy extends Handler implements Phone { 42 public final static Object lockForRadioTechnologyChange = new Object(); 43// private static boolean radioTechnologyChangeGsmToCdma = false; 44// private static boolean radioTechnologyChangeCdmaToGsm = false; 45 46 private Phone mActivePhone; 47 private String mOutgoingPhone; 48 private CommandsInterface mCommandsInterface; 49 private IccSmsInterfaceManagerProxy mIccSmsInterfaceManagerProxy; 50 private IccPhoneBookInterfaceManagerProxy mIccPhoneBookInterfaceManagerProxy; 51 private PhoneSubInfoProxy mPhoneSubInfoProxy; 52 53 private static final int EVENT_RADIO_TECHNOLOGY_CHANGED = 1; 54 private static final String LOG_TAG = "PHONE"; 55 56 //***** Class Methods 57 public PhoneProxy(Phone phone) { 58 mActivePhone = phone; 59 mIccSmsInterfaceManagerProxy = new IccSmsInterfaceManagerProxy( 60 phone.getIccSmsInterfaceManager()); 61 mIccPhoneBookInterfaceManagerProxy = new IccPhoneBookInterfaceManagerProxy( 62 phone.getIccPhoneBookInterfaceManager()); 63 mPhoneSubInfoProxy = new PhoneSubInfoProxy(phone.getPhoneSubInfo()); 64 mCommandsInterface = ((PhoneBase)mActivePhone).mCM; 65 mCommandsInterface.registerForRadioTechnologyChanged( 66 this, EVENT_RADIO_TECHNOLOGY_CHANGED, null); 67 } 68 69 @Override 70 public void handleMessage(Message msg) { 71 switch(msg.what) { 72 case EVENT_RADIO_TECHNOLOGY_CHANGED: 73 //switch Phone from CDMA to GSM or vice versa 74 mOutgoingPhone = ((PhoneBase)mActivePhone).getPhoneName(); 75 logd("Switching phone from " + mOutgoingPhone + "Phone to " + 76 (mOutgoingPhone.equals("GSM") ? "CDMAPhone" : "GSMPhone") ); 77 boolean oldPowerState = false; //old power state to off 78 if (mCommandsInterface.getRadioState().isOn()) { 79 oldPowerState = true; 80 logd("Setting Radio Power to Off"); 81 mCommandsInterface.setRadioPower(false, null); 82 } 83 if(mOutgoingPhone.equals("GSM")) { 84 logd("Make a new CDMAPhone and destroy the old GSMPhone."); 85 86 ((GSMPhone)mActivePhone).dispose(); 87 Phone oldPhone = mActivePhone; 88 89 //Give the garbage collector a hint to start the garbage collection asap 90 // NOTE this has been disabled since radio technology change could happen during 91 // e.g. a multimedia playing and could slow the system. Tests needs to be done 92 // to see the effects of the GC call here when system is busy. 93 //System.gc(); 94 95 mActivePhone = PhoneFactory.getCdmaPhone(); 96 logd("Resetting Radio"); 97 mCommandsInterface.setRadioPower(oldPowerState, null); 98 ((GSMPhone)oldPhone).removeReferences(); 99 oldPhone = null; 100 } else { 101 logd("Make a new GSMPhone and destroy the old CDMAPhone."); 102 103 ((CDMAPhone)mActivePhone).dispose(); 104 //mActivePhone = null; 105 Phone oldPhone = mActivePhone; 106 107 // Give the GC a hint to start the garbage collection asap 108 // NOTE this has been disabled since radio technology change could happen during 109 // e.g. a multimedia playing and could slow the system. Tests needs to be done 110 // to see the effects of the GC call here when system is busy. 111 //System.gc(); 112 113 mActivePhone = PhoneFactory.getGsmPhone(); 114 logd("Resetting Radio:"); 115 mCommandsInterface.setRadioPower(oldPowerState, null); 116 ((CDMAPhone)oldPhone).removeReferences(); 117 oldPhone = null; 118 } 119 120 //Set the new interfaces in the proxy's 121 mIccSmsInterfaceManagerProxy.setmIccSmsInterfaceManager( 122 mActivePhone.getIccSmsInterfaceManager()); 123 mIccPhoneBookInterfaceManagerProxy.setmIccPhoneBookInterfaceManager( 124 mActivePhone.getIccPhoneBookInterfaceManager()); 125 mPhoneSubInfoProxy.setmPhoneSubInfo(this.mActivePhone.getPhoneSubInfo()); 126 mCommandsInterface = ((PhoneBase)mActivePhone).mCM; 127 128 //Send an Intent to the PhoneApp that we had a radio technology change 129 Intent intent = new Intent(TelephonyIntents.ACTION_RADIO_TECHNOLOGY_CHANGED); 130 intent.putExtra(Phone.PHONE_NAME_KEY, mActivePhone.getPhoneName()); 131 ActivityManagerNative.broadcastStickyIntent(intent, null); 132 break; 133 default: 134 Log.e(LOG_TAG,"Error! This handler was not registered for this message type. Message: " 135 + msg.what); 136 break; 137 } 138 super.handleMessage(msg); 139 } 140 141 private void logv(String msg) { 142 Log.v(LOG_TAG, "[PhoneProxy] " + msg); 143 } 144 145 private void logd(String msg) { 146 Log.d(LOG_TAG, "[PhoneProxy] " + msg); 147 } 148 149 private void logw(String msg) { 150 Log.w(LOG_TAG, "[PhoneProxy] " + msg); 151 } 152 153 private void loge(String msg) { 154 Log.e(LOG_TAG, "[PhoneProxy] " + msg); 155 } 156 157 158 public ServiceState getServiceState() { 159 return mActivePhone.getServiceState(); 160 } 161 162 public CellLocation getCellLocation() { 163 return mActivePhone.getCellLocation(); 164 } 165 166 public DataState getDataConnectionState() { 167 return mActivePhone.getDataConnectionState(); 168 } 169 170 public DataActivityState getDataActivityState() { 171 return mActivePhone.getDataActivityState(); 172 } 173 174 public Context getContext() { 175 return mActivePhone.getContext(); 176 } 177 178 public void disableDnsCheck(boolean b) { 179 mActivePhone.disableDnsCheck(b); 180 } 181 182 public boolean isDnsCheckDisabled() { 183 return mActivePhone.isDnsCheckDisabled(); 184 } 185 186 public State getState() { 187 return mActivePhone.getState(); 188 } 189 190 public String getPhoneName() { 191 return mActivePhone.getPhoneName(); 192 } 193 194 public String[] getActiveApnTypes() { 195 return mActivePhone.getActiveApnTypes(); 196 } 197 198 public String getActiveApn() { 199 return mActivePhone.getActiveApn(); 200 } 201 202 public SignalStrength getSignalStrength() { 203 return mActivePhone.getSignalStrength(); 204 } 205 206 public void registerForUnknownConnection(Handler h, int what, Object obj) { 207 mActivePhone.registerForUnknownConnection(h, what, obj); 208 } 209 210 public void unregisterForUnknownConnection(Handler h) { 211 mActivePhone.unregisterForUnknownConnection(h); 212 } 213 214 public void registerForPreciseCallStateChanged(Handler h, int what, Object obj) { 215 mActivePhone.registerForPreciseCallStateChanged(h, what, obj); 216 } 217 218 public void unregisterForPreciseCallStateChanged(Handler h) { 219 mActivePhone.unregisterForPreciseCallStateChanged(h); 220 } 221 222 public void registerForNewRingingConnection(Handler h, int what, Object obj) { 223 mActivePhone.registerForNewRingingConnection(h, what, obj); 224 } 225 226 public void unregisterForNewRingingConnection(Handler h) { 227 mActivePhone.unregisterForNewRingingConnection(h); 228 } 229 230 public void registerForIncomingRing(Handler h, int what, Object obj) { 231 mActivePhone.registerForIncomingRing(h, what, obj); 232 } 233 234 public void unregisterForIncomingRing(Handler h) { 235 mActivePhone.unregisterForIncomingRing(h); 236 } 237 238 public void registerForDisconnect(Handler h, int what, Object obj) { 239 mActivePhone.registerForDisconnect(h, what, obj); 240 } 241 242 public void unregisterForDisconnect(Handler h) { 243 mActivePhone.unregisterForDisconnect(h); 244 } 245 246 public void registerForMmiInitiate(Handler h, int what, Object obj) { 247 mActivePhone.registerForMmiInitiate(h, what, obj); 248 } 249 250 public void unregisterForMmiInitiate(Handler h) { 251 mActivePhone.unregisterForMmiInitiate(h); 252 } 253 254 public void registerForMmiComplete(Handler h, int what, Object obj) { 255 mActivePhone.registerForMmiComplete(h, what, obj); 256 } 257 258 public void unregisterForMmiComplete(Handler h) { 259 mActivePhone.unregisterForMmiComplete(h); 260 } 261 262 public List<? extends MmiCode> getPendingMmiCodes() { 263 return mActivePhone.getPendingMmiCodes(); 264 } 265 266 public void sendUssdResponse(String ussdMessge) { 267 mActivePhone.sendUssdResponse(ussdMessge); 268 } 269 270 public void registerForServiceStateChanged(Handler h, int what, Object obj) { 271 mActivePhone.registerForServiceStateChanged(h, what, obj); 272 } 273 274 public void unregisterForServiceStateChanged(Handler h) { 275 mActivePhone.unregisterForServiceStateChanged(h); 276 } 277 278 public void registerForSuppServiceNotification(Handler h, int what, Object obj) { 279 mActivePhone.registerForSuppServiceNotification(h, what, obj); 280 } 281 282 public void unregisterForSuppServiceNotification(Handler h) { 283 mActivePhone.unregisterForSuppServiceNotification(h); 284 } 285 286 public void registerForSuppServiceFailed(Handler h, int what, Object obj) { 287 mActivePhone.registerForSuppServiceFailed(h, what, obj); 288 } 289 290 public void unregisterForSuppServiceFailed(Handler h) { 291 mActivePhone.unregisterForSuppServiceFailed(h); 292 } 293 294 public void registerForInCallVoicePrivacyOn(Handler h, int what, Object obj){ 295 mActivePhone.registerForInCallVoicePrivacyOn(h,what,obj); 296 } 297 298 public void unregisterForInCallVoicePrivacyOn(Handler h){ 299 mActivePhone.unregisterForInCallVoicePrivacyOn(h); 300 } 301 302 public void registerForInCallVoicePrivacyOff(Handler h, int what, Object obj){ 303 mActivePhone.registerForInCallVoicePrivacyOff(h,what,obj); 304 } 305 306 public void unregisterForInCallVoicePrivacyOff(Handler h){ 307 mActivePhone.unregisterForInCallVoicePrivacyOff(h); 308 } 309 310 public void registerForCdmaOtaStatusChange(Handler h, int what, Object obj) { 311 mActivePhone.registerForCdmaOtaStatusChange(h,what,obj); 312 } 313 314 public void unregisterForCdmaOtaStatusChange(Handler h) { 315 mActivePhone.unregisterForCdmaOtaStatusChange(h); 316 } 317 318 public void registerForSubscriptionInfoReady(Handler h, int what, Object obj) { 319 mActivePhone.registerForSubscriptionInfoReady(h, what, obj); 320 } 321 322 public void unregisterForSubscriptionInfoReady(Handler h) { 323 mActivePhone.unregisterForSubscriptionInfoReady(h); 324 } 325 326 public boolean getIccRecordsLoaded() { 327 return mActivePhone.getIccRecordsLoaded(); 328 } 329 330 public IccCard getIccCard() { 331 return mActivePhone.getIccCard(); 332 } 333 334 public void acceptCall() throws CallStateException { 335 mActivePhone.acceptCall(); 336 } 337 338 public void rejectCall() throws CallStateException { 339 mActivePhone.rejectCall(); 340 } 341 342 public void switchHoldingAndActive() throws CallStateException { 343 mActivePhone.switchHoldingAndActive(); 344 } 345 346 public boolean canConference() { 347 return mActivePhone.canConference(); 348 } 349 350 public void conference() throws CallStateException { 351 mActivePhone.conference(); 352 } 353 354 public void enableEnhancedVoicePrivacy(boolean enable, Message onComplete) { 355 mActivePhone.enableEnhancedVoicePrivacy(enable, onComplete); 356 } 357 358 public void getEnhancedVoicePrivacy(Message onComplete) { 359 mActivePhone.getEnhancedVoicePrivacy(onComplete); 360 } 361 362 public boolean canTransfer() { 363 return mActivePhone.canTransfer(); 364 } 365 366 public void explicitCallTransfer() throws CallStateException { 367 mActivePhone.explicitCallTransfer(); 368 } 369 370 public void clearDisconnected() { 371 mActivePhone.clearDisconnected(); 372 } 373 374 public Call getForegroundCall() { 375 return mActivePhone.getForegroundCall(); 376 } 377 378 public Call getBackgroundCall() { 379 return mActivePhone.getBackgroundCall(); 380 } 381 382 public Call getRingingCall() { 383 return mActivePhone.getRingingCall(); 384 } 385 386 public Connection dial(String dialString) throws CallStateException { 387 return mActivePhone.dial(dialString); 388 } 389 390 public boolean handlePinMmi(String dialString) { 391 return mActivePhone.handlePinMmi(dialString); 392 } 393 394 public boolean handleInCallMmiCommands(String command) throws CallStateException { 395 return mActivePhone.handleInCallMmiCommands(command); 396 } 397 398 public void sendDtmf(char c) { 399 mActivePhone.sendDtmf(c); 400 } 401 402 public void startDtmf(char c) { 403 mActivePhone.startDtmf(c); 404 } 405 406 public void stopDtmf() { 407 mActivePhone.stopDtmf(); 408 } 409 410 public void setRadioPower(boolean power) { 411 mActivePhone.setRadioPower(power); 412 } 413 414 public boolean getMessageWaitingIndicator() { 415 return mActivePhone.getMessageWaitingIndicator(); 416 } 417 418 public boolean getCallForwardingIndicator() { 419 return mActivePhone.getCallForwardingIndicator(); 420 } 421 422 public String getLine1Number() { 423 return mActivePhone.getLine1Number(); 424 } 425 426 public String getCdmaMin() { 427 return mActivePhone.getCdmaMin(); 428 } 429 430 public boolean isMinInfoReady() { 431 return mActivePhone.isMinInfoReady(); 432 } 433 434 public String getCdmaPrlVersion() { 435 return mActivePhone.getCdmaPrlVersion(); 436 } 437 438 public String getLine1AlphaTag() { 439 return mActivePhone.getLine1AlphaTag(); 440 } 441 442 public void setLine1Number(String alphaTag, String number, Message onComplete) { 443 mActivePhone.setLine1Number(alphaTag, number, onComplete); 444 } 445 446 public String getVoiceMailNumber() { 447 return mActivePhone.getVoiceMailNumber(); 448 } 449 450 /** @hide */ 451 public int getVoiceMessageCount(){ 452 return mActivePhone.getVoiceMessageCount(); 453 } 454 455 public String getVoiceMailAlphaTag() { 456 return mActivePhone.getVoiceMailAlphaTag(); 457 } 458 459 public void setVoiceMailNumber(String alphaTag,String voiceMailNumber, 460 Message onComplete) { 461 mActivePhone.setVoiceMailNumber(alphaTag, voiceMailNumber, onComplete); 462 } 463 464 public void getCallForwardingOption(int commandInterfaceCFReason, 465 Message onComplete) { 466 mActivePhone.getCallForwardingOption(commandInterfaceCFReason, 467 onComplete); 468 } 469 470 public void setCallForwardingOption(int commandInterfaceCFReason, 471 int commandInterfaceCFAction, String dialingNumber, 472 int timerSeconds, Message onComplete) { 473 mActivePhone.setCallForwardingOption(commandInterfaceCFReason, 474 commandInterfaceCFAction, dialingNumber, timerSeconds, onComplete); 475 } 476 477 public void getOutgoingCallerIdDisplay(Message onComplete) { 478 mActivePhone.getOutgoingCallerIdDisplay(onComplete); 479 } 480 481 public void setOutgoingCallerIdDisplay(int commandInterfaceCLIRMode, 482 Message onComplete) { 483 mActivePhone.setOutgoingCallerIdDisplay(commandInterfaceCLIRMode, 484 onComplete); 485 } 486 487 public void getCallWaiting(Message onComplete) { 488 mActivePhone.getCallWaiting(onComplete); 489 } 490 491 public void setCallWaiting(boolean enable, Message onComplete) { 492 mActivePhone.setCallWaiting(enable, onComplete); 493 } 494 495 public void getAvailableNetworks(Message response) { 496 mActivePhone.getAvailableNetworks(response); 497 } 498 499 public void setNetworkSelectionModeAutomatic(Message response) { 500 mActivePhone.setNetworkSelectionModeAutomatic(response); 501 } 502 503 public void selectNetworkManually(NetworkInfo network, Message response) { 504 mActivePhone.selectNetworkManually(network, response); 505 } 506 507 public void setPreferredNetworkType(int networkType, Message response) { 508 mActivePhone.setPreferredNetworkType(networkType, response); 509 } 510 511 public void getPreferredNetworkType(Message response) { 512 mActivePhone.getPreferredNetworkType(response); 513 } 514 515 public void getNeighboringCids(Message response) { 516 mActivePhone.getNeighboringCids(response); 517 } 518 519 public void setOnPostDialCharacter(Handler h, int what, Object obj) { 520 mActivePhone.setOnPostDialCharacter(h, what, obj); 521 } 522 523 public void setMute(boolean muted) { 524 mActivePhone.setMute(muted); 525 } 526 527 public boolean getMute() { 528 return mActivePhone.getMute(); 529 } 530 531 public void invokeOemRilRequestRaw(byte[] data, Message response) { 532 mActivePhone.invokeOemRilRequestRaw(data, response); 533 } 534 535 public void invokeOemRilRequestStrings(String[] strings, Message response) { 536 mActivePhone.invokeOemRilRequestStrings(strings, response); 537 } 538 539 /** 540 * @deprecated 541 */ 542 public void getPdpContextList(Message response) { 543 mActivePhone.getPdpContextList(response); 544 } 545 546 public void getDataCallList(Message response) { 547 mActivePhone.getDataCallList(response); 548 } 549 550 /** 551 * @deprecated 552 */ 553 public List<PdpConnection> getCurrentPdpList() { 554 return mActivePhone.getCurrentPdpList(); 555 } 556 557 public List<DataConnection> getCurrentDataConnectionList() { 558 return mActivePhone.getCurrentDataConnectionList(); 559 } 560 561 public void updateServiceLocation(Message response) { 562 mActivePhone.updateServiceLocation(response); 563 } 564 565 public void enableLocationUpdates() { 566 mActivePhone.enableLocationUpdates(); 567 } 568 569 public void disableLocationUpdates() { 570 mActivePhone.disableLocationUpdates(); 571 } 572 573 public void setUnitTestMode(boolean f) { 574 mActivePhone.setUnitTestMode(f); 575 } 576 577 public boolean getUnitTestMode() { 578 return mActivePhone.getUnitTestMode(); 579 } 580 581 public void setBandMode(int bandMode, Message response) { 582 mActivePhone.setBandMode(bandMode, response); 583 } 584 585 public void queryAvailableBandMode(Message response) { 586 mActivePhone.queryAvailableBandMode(response); 587 } 588 589 public boolean getDataRoamingEnabled() { 590 return mActivePhone.getDataRoamingEnabled(); 591 } 592 593 public void setDataRoamingEnabled(boolean enable) { 594 mActivePhone.setDataRoamingEnabled(enable); 595 } 596 597 public void queryCdmaRoamingPreference(Message response) { 598 mActivePhone.queryCdmaRoamingPreference(response); 599 } 600 601 public void setCdmaRoamingPreference(int cdmaRoamingType, Message response) { 602 mActivePhone.setCdmaRoamingPreference(cdmaRoamingType, response); 603 } 604 605 public void setCdmaSubscription(int cdmaSubscriptionType, Message response) { 606 mActivePhone.setCdmaSubscription(cdmaSubscriptionType, response); 607 } 608 609 public SimulatedRadioControl getSimulatedRadioControl() { 610 return mActivePhone.getSimulatedRadioControl(); 611 } 612 613 public boolean enableDataConnectivity() { 614 return mActivePhone.enableDataConnectivity(); 615 } 616 617 public boolean disableDataConnectivity() { 618 return mActivePhone.disableDataConnectivity(); 619 } 620 621 public int enableApnType(String type) { 622 return mActivePhone.enableApnType(type); 623 } 624 625 public int disableApnType(String type) { 626 return mActivePhone.disableApnType(type); 627 } 628 629 public boolean isDataConnectivityEnabled() { 630 return mActivePhone.isDataConnectivityEnabled(); 631 } 632 633 public boolean isDataConnectivityPossible() { 634 return mActivePhone.isDataConnectivityPossible(); 635 } 636 637 public String getInterfaceName(String apnType) { 638 return mActivePhone.getInterfaceName(apnType); 639 } 640 641 public String getIpAddress(String apnType) { 642 return mActivePhone.getIpAddress(apnType); 643 } 644 645 public String getGateway(String apnType) { 646 return mActivePhone.getGateway(apnType); 647 } 648 649 public String[] getDnsServers(String apnType) { 650 return mActivePhone.getDnsServers(apnType); 651 } 652 653 public String getDeviceId() { 654 return mActivePhone.getDeviceId(); 655 } 656 657 public String getDeviceSvn() { 658 return mActivePhone.getDeviceSvn(); 659 } 660 661 public String getSubscriberId() { 662 return mActivePhone.getSubscriberId(); 663 } 664 665 public String getIccSerialNumber() { 666 return mActivePhone.getIccSerialNumber(); 667 } 668 669 public String getEsn() { 670 return mActivePhone.getEsn(); 671 } 672 673 public String getMeid() { 674 return mActivePhone.getMeid(); 675 } 676 677 public PhoneSubInfo getPhoneSubInfo(){ 678 return mActivePhone.getPhoneSubInfo(); 679 } 680 681 public IccSmsInterfaceManager getIccSmsInterfaceManager(){ 682 return mActivePhone.getIccSmsInterfaceManager(); 683 } 684 685 public IccPhoneBookInterfaceManager getIccPhoneBookInterfaceManager(){ 686 return mActivePhone.getIccPhoneBookInterfaceManager(); 687 } 688 689 public void setTTYMode(int ttyMode, Message onComplete) { 690 mActivePhone.setTTYMode(ttyMode, onComplete); 691 } 692 693 public void queryTTYMode(Message onComplete) { 694 mActivePhone.queryTTYMode(onComplete); 695 } 696 697 public void activateCellBroadcastSms(int activate, Message response) { 698 mActivePhone.activateCellBroadcastSms(activate, response); 699 } 700 701 public void getCellBroadcastSmsConfig(Message response) { 702 mActivePhone.getCellBroadcastSmsConfig(response); 703 } 704 705 public void setCellBroadcastSmsConfig(int[] configValuesArray, Message response) { 706 mActivePhone.setCellBroadcastSmsConfig(configValuesArray, response); 707 } 708 709 public void notifyDataActivity() { 710 mActivePhone.notifyDataActivity(); 711 } 712 713 public void getSmscAddress(Message result) { 714 mActivePhone.getSmscAddress(result); 715 } 716 717 public void setSmscAddress(String address, Message result) { 718 mActivePhone.setSmscAddress(address, result); 719 } 720 721 public int getCdmaEriIconIndex() { 722 return mActivePhone.getCdmaEriIconIndex(); 723 } 724 725 public String getCdmaEriText() { 726 return mActivePhone.getCdmaEriText(); 727 } 728 729 public int getCdmaEriIconMode() { 730 return mActivePhone.getCdmaEriIconMode(); 731 } 732 733 public void sendBurstDtmf(String dtmfString, int on, int off, Message onComplete){ 734 mActivePhone.sendBurstDtmf(dtmfString, on, off, onComplete); 735 } 736 737 public void exitEmergencyCallbackMode(){ 738 mActivePhone.exitEmergencyCallbackMode(); 739 } 740 741 public boolean isOtaSpNumber(String dialStr){ 742 return mActivePhone.isOtaSpNumber(dialStr); 743 } 744 745 public void registerForCallWaiting(Handler h, int what, Object obj){ 746 mActivePhone.registerForCallWaiting(h,what,obj); 747 } 748 749 public void unregisterForCallWaiting(Handler h){ 750 mActivePhone.unregisterForCallWaiting(h); 751 } 752 753 public void registerForSignalInfo(Handler h, int what, Object obj) { 754 mActivePhone.registerForSignalInfo(h,what,obj); 755 } 756 757 public void unregisterForSignalInfo(Handler h) { 758 mActivePhone.unregisterForSignalInfo(h); 759 } 760 761 public void registerForDisplayInfo(Handler h, int what, Object obj) { 762 mActivePhone.registerForDisplayInfo(h,what,obj); 763 } 764 765 public void unregisterForDisplayInfo(Handler h) { 766 mActivePhone.unregisterForDisplayInfo(h); 767 } 768 769 public void registerForNumberInfo(Handler h, int what, Object obj) { 770 mActivePhone.registerForNumberInfo(h, what, obj); 771 } 772 773 public void unregisterForNumberInfo(Handler h) { 774 mActivePhone.unregisterForNumberInfo(h); 775 } 776 777 public void registerForRedirectedNumberInfo(Handler h, int what, Object obj) { 778 mActivePhone.registerForRedirectedNumberInfo(h, what, obj); 779 } 780 781 public void unregisterForRedirectedNumberInfo(Handler h) { 782 mActivePhone.unregisterForRedirectedNumberInfo(h); 783 } 784 785 public void registerForLineControlInfo(Handler h, int what, Object obj) { 786 mActivePhone.registerForLineControlInfo( h, what, obj); 787 } 788 789 public void unregisterForLineControlInfo(Handler h) { 790 mActivePhone.unregisterForLineControlInfo(h); 791 } 792 793 public void registerFoT53ClirlInfo(Handler h, int what, Object obj) { 794 mActivePhone.registerFoT53ClirlInfo(h, what, obj); 795 } 796 797 public void unregisterForT53ClirInfo(Handler h) { 798 mActivePhone.unregisterForT53ClirInfo(h); 799 } 800 801 public void registerForT53AudioControlInfo(Handler h, int what, Object obj) { 802 mActivePhone.registerForT53AudioControlInfo( h, what, obj); 803 } 804 805 public void unregisterForT53AudioControlInfo(Handler h) { 806 mActivePhone.unregisterForT53AudioControlInfo(h); 807 } 808 809 public void setOnEcbModeExitResponse(Handler h, int what, Object obj){ 810 mActivePhone.setOnEcbModeExitResponse(h,what,obj); 811 } 812 813 public void unsetOnEcbModeExitResponse(Handler h){ 814 mActivePhone.unsetOnEcbModeExitResponse(h); 815 } 816} 817