ダイヤラーアプリを呼び出す必要があるアプリを準備しています。アプリから Dialer アプリを呼び出す方法を教えてください。
私のアプリは EFL で書かれています。
Tizen で EFL アプリを使用している場合は、次を使用します。
service_h service;
service_create(&service);
service_set_package(service, "com.service.call");
service_set_operation(service, "http://tizen.org/appcontrol/operation/main");
service_add_extra_data (service, "launch-type", "MO"); Addtional Data as with Intents
service_send_launch_request(service, NULL,NULL );
service_destroy(service);
これとアプリケーション マニフェストに追加します。
<permit>
<smack permit="com.samsung.w-launcher-app" type="rw"/>
</permit>
アプリケーションxmlで、これを使用します:
<privileges>
<privilege>http://tizen.org/privilege/application.launch</privilege>
</privileges>
必要なのは AppControl ネイティブ API です。この例を見てください: https://developer.tizen.org/dev-guide/2.2.0/org.tizen.native.apireference/classTizen_1_1App_1_1AppControl.html
using namespace Tizen::App;
void
MyAppClass::AppControlDialSample(void)
{
String telUri = L"tel:12345678900";
AppControl* pAc = AppManager::FindAppControlN(L"tizen.phone", L"http://tizen.org/appcontrol/operation/dial");
if(pAc)
{
pAc->Start(&telUri, null, null, null);
delete pAc;
}
}