2011-08-03 10 views

答えて

1

あなたはITelephony.aidlその後、通話を終了するために、このメソッドを使用して、このファイルを追加する必要があります。

public static void callReject(Context context) throws Exception{ 
     try{ 
      TelephonyManager manager = (TelephonyManager)context.getSystemService(Context.TELEPHONY_SERVICE); 
      Class c = Class.forName(manager.getClass().getName()); 
      Method m = c.getDeclaredMethod("getITelephony"); 
      m.setAccessible(true); 
      ITelephony telephony = (ITelephony)m.invoke(manager); 
      telephony.endCall(); 
     } catch(Exception e){ 
      Log.d("",e.getMessage()); 
     } 
    } 
+0

がhttp://dl.dropbox.com/u/31740476/ITelephonyからITelephony.aidlファイルを取得します。 aidl –

+0

他にもいくつかのオプションがありますか?私はちょうどITelephonyを使用したくない – Speise

+0

いいえアイデアだが、なぜあなたはITelephonyを使いたくないのですか? –

関連する問題