Loading res/values/strings.xml +2 −1 Original line number Diff line number Diff line Loading @@ -1160,7 +1160,8 @@ e mode.</string> <string name="call_data_info_description">Voice call usage time and data usage time</string> <string name="alert_call_over_wifi">Calls will be made over Wi-Fi.</string> <string name="alert_call_no_cellular_coverage">No cellular network available. Connect to available Wi-Fi to make calls.</string> <string name="alert_user_connect_to_wifi_for_call">Connect to Wi-Fi to make calls.</string> <string name="alert_user_connect_to_wifi_for_call">Connect to Wi-Fi to make calls</string> <string name="alert_user_connect_to_wifi_for_call_text">Tap here to view available networks</string> <string name="missing_account_type">(No type)</string> <string name="missing_account_name">(No name)</string> </resources> src/com/android/dialer/dialpad/DialpadFragment.java +1 −0 Original line number Diff line number Diff line Loading @@ -2033,6 +2033,7 @@ public class DialpadFragment extends Fragment } else { if(WifiCallUtils.shallShowWifiCallDialog(getActivity())) { WifiCallUtils.showWifiCallDialog(getActivity()); WifiCallUtils.showWifiCallNotification(getActivity()); } else { getView().performHapticFeedback(HapticFeedbackConstants.VIRTUAL_KEY); handleDialButtonPressed(); Loading src/com/android/dialer/util/WifiCallUtils.java +7 −8 Original line number Diff line number Diff line Loading @@ -149,16 +149,13 @@ public class WifiCallUtils { public static void showWifiCallDialog(final Context context) { String promptMessage = context.getString(com.android.dialer.R.string .alert_call_no_cellular_coverage) +"\n"+ context.getString(com.android.dialer.R .string.alert_user_connect_to_wifi_for_call); .alert_call_no_cellular_coverage); AlertDialog.Builder diaBuilder = new AlertDialog.Builder(context); diaBuilder.setMessage(promptMessage); diaBuilder.setPositiveButton(com.android.internal.R.string.ok, new OnClickListener() { @Override public void onClick(DialogInterface dialog, int which) { Intent intent = new Intent(Intent.ACTION_MAIN); intent.setClassName("com.qualcomm.qti.extsettings", "com.qualcomm.qti.extsettings.wificall.WifiCallingEnhancedSettings"); Intent intent = new Intent(android.provider.Settings.ACTION_WIFI_SETTINGS); context.startActivity(intent); } }); Loading Loading @@ -211,16 +208,18 @@ public class WifiCallUtils { builder.setAutoCancel(true); builder.setSmallIcon(R.drawable.wifi_calling_on_notification); builder.setContentTitle( context.getResources().getString(R.string.alert_user_connect_to_wifi_for_call)); context.getResources().getString( R.string.alert_user_connect_to_wifi_for_call)); builder.setContentText( context.getResources().getString(R.string.alert_user_connect_to_wifi_for_call)); context.getResources().getString( R.string.alert_user_connect_to_wifi_for_call_text)); notiManager.notify(NOTIFICATION_WIFI_CALL_ID, builder.build()); new Handler().postDelayed(new Runnable() { @Override public void run() { notiManager.cancel(NOTIFICATION_WIFI_CALL_ID); } }, 2000); }, 5000); } } } Loading
res/values/strings.xml +2 −1 Original line number Diff line number Diff line Loading @@ -1160,7 +1160,8 @@ e mode.</string> <string name="call_data_info_description">Voice call usage time and data usage time</string> <string name="alert_call_over_wifi">Calls will be made over Wi-Fi.</string> <string name="alert_call_no_cellular_coverage">No cellular network available. Connect to available Wi-Fi to make calls.</string> <string name="alert_user_connect_to_wifi_for_call">Connect to Wi-Fi to make calls.</string> <string name="alert_user_connect_to_wifi_for_call">Connect to Wi-Fi to make calls</string> <string name="alert_user_connect_to_wifi_for_call_text">Tap here to view available networks</string> <string name="missing_account_type">(No type)</string> <string name="missing_account_name">(No name)</string> </resources>
src/com/android/dialer/dialpad/DialpadFragment.java +1 −0 Original line number Diff line number Diff line Loading @@ -2033,6 +2033,7 @@ public class DialpadFragment extends Fragment } else { if(WifiCallUtils.shallShowWifiCallDialog(getActivity())) { WifiCallUtils.showWifiCallDialog(getActivity()); WifiCallUtils.showWifiCallNotification(getActivity()); } else { getView().performHapticFeedback(HapticFeedbackConstants.VIRTUAL_KEY); handleDialButtonPressed(); Loading
src/com/android/dialer/util/WifiCallUtils.java +7 −8 Original line number Diff line number Diff line Loading @@ -149,16 +149,13 @@ public class WifiCallUtils { public static void showWifiCallDialog(final Context context) { String promptMessage = context.getString(com.android.dialer.R.string .alert_call_no_cellular_coverage) +"\n"+ context.getString(com.android.dialer.R .string.alert_user_connect_to_wifi_for_call); .alert_call_no_cellular_coverage); AlertDialog.Builder diaBuilder = new AlertDialog.Builder(context); diaBuilder.setMessage(promptMessage); diaBuilder.setPositiveButton(com.android.internal.R.string.ok, new OnClickListener() { @Override public void onClick(DialogInterface dialog, int which) { Intent intent = new Intent(Intent.ACTION_MAIN); intent.setClassName("com.qualcomm.qti.extsettings", "com.qualcomm.qti.extsettings.wificall.WifiCallingEnhancedSettings"); Intent intent = new Intent(android.provider.Settings.ACTION_WIFI_SETTINGS); context.startActivity(intent); } }); Loading Loading @@ -211,16 +208,18 @@ public class WifiCallUtils { builder.setAutoCancel(true); builder.setSmallIcon(R.drawable.wifi_calling_on_notification); builder.setContentTitle( context.getResources().getString(R.string.alert_user_connect_to_wifi_for_call)); context.getResources().getString( R.string.alert_user_connect_to_wifi_for_call)); builder.setContentText( context.getResources().getString(R.string.alert_user_connect_to_wifi_for_call)); context.getResources().getString( R.string.alert_user_connect_to_wifi_for_call_text)); notiManager.notify(NOTIFICATION_WIFI_CALL_ID, builder.build()); new Handler().postDelayed(new Runnable() { @Override public void run() { notiManager.cancel(NOTIFICATION_WIFI_CALL_ID); } }, 2000); }, 5000); } } }