sk.baka.ambient
Class PhoneStateHandler

java.lang.Object
  extended by android.telephony.PhoneStateListener
      extended by sk.baka.ambient.PhoneStateHandler

final class PhoneStateHandler
extends PhoneStateListener

Handles the phone state events and reacts appropriately.

Author:
Martin Vysny

Field Summary
 
Fields inherited from class android.telephony.PhoneStateListener
LISTEN_CALL_FORWARDING_INDICATOR, LISTEN_CALL_STATE, LISTEN_CELL_LOCATION, LISTEN_DATA_ACTIVITY, LISTEN_DATA_CONNECTION_STATE, LISTEN_MESSAGE_WAITING_INDICATOR, LISTEN_NONE, LISTEN_SERVICE_STATE, LISTEN_SIGNAL_STRENGTH
 
Constructor Summary
PhoneStateHandler(AmbientApplication context)
          Creates new phone state handler.
 
Method Summary
 void onCallStateChanged(int state, String incomingNumber)
           
 
Methods inherited from class android.telephony.PhoneStateListener
onCallForwardingIndicatorChanged, onCellLocationChanged, onDataActivity, onDataConnectionStateChanged, onMessageWaitingIndicatorChanged, onServiceStateChanged, onSignalStrengthChanged
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

PhoneStateHandler

PhoneStateHandler(AmbientApplication context)
Creates new phone state handler. There should be at most one instance of the handler!

Parameters:
context - the context
Method Detail

onCallStateChanged

public void onCallStateChanged(int state,
                               String incomingNumber)
Overrides:
onCallStateChanged in class PhoneStateListener


Copyright © 2007-2008. All Rights Reserved.