cmsdk: Temporary build fixes

Change-Id: I18a1aa9ade95de63fe18eaaeca388b118c8ffe8c
This commit is contained in:
Adnan Begovic 2015-10-09 13:43:51 -07:00
parent a79a53b8ea
commit fe7a368a69
7 changed files with 28 additions and 21 deletions

View File

@ -201,7 +201,7 @@ public class CMTelephonyManagerService extends SystemService {
} }
private boolean isSubActive(int subId) { private boolean isSubActive(int subId) {
boolean validSubscriptionId = SubscriptionManager.isValidSubscriptionId(subId); /* boolean validSubscriptionId = SubscriptionManager.isValidSubscriptionId(subId);
if (validSubscriptionId) { if (validSubscriptionId) {
int simState = SubscriptionManager.getSimStateForSubscriber(subId); int simState = SubscriptionManager.getSimStateForSubscriber(subId);
@ -223,11 +223,12 @@ public class CMTelephonyManagerService extends SystemService {
} else { } else {
Log.w(TAG, "Invalid subscription identifier: " + subId); Log.w(TAG, "Invalid subscription identifier: " + subId);
return false; return false;
} } */
return false;
} }
private void setSubState(int subId, boolean state) { private void setSubState(int subId, boolean state) {
if (localLOGD) { /* if (localLOGD) {
Log.d(TAG, "Setting the subscription " + subId + " to inactive (false) or active (true): " + state); Log.d(TAG, "Setting the subscription " + subId + " to inactive (false) or active (true): " + state);
} }
@ -235,7 +236,7 @@ public class CMTelephonyManagerService extends SystemService {
SubscriptionManager.activateSubId(subId); SubscriptionManager.activateSubId(subId);
} else { } else {
SubscriptionManager.deactivateSubId(subId); SubscriptionManager.deactivateSubId(subId);
} } */
} }
private boolean isDataConnectionSelectedOnSub(int subId) { private boolean isDataConnectionSelectedOnSub(int subId) {
@ -295,7 +296,7 @@ public class CMTelephonyManagerService extends SystemService {
} }
private void setDefaultPhoneSub(int subId) { private void setDefaultPhoneSub(int subId) {
if (localLOGD) { /* if (localLOGD) {
Log.d(TAG, "Setting the SIM for phone calls on subscription " + subId); Log.d(TAG, "Setting the SIM for phone calls on subscription " + subId);
} }
@ -308,11 +309,11 @@ public class CMTelephonyManagerService extends SystemService {
} else { } else {
SubscriptionManager.setVoicePromptEnabled(false); SubscriptionManager.setVoicePromptEnabled(false);
subscriptionManager.setDefaultVoiceSubId(subId); subscriptionManager.setDefaultVoiceSubId(subId);
} } */
} }
private void setDefaultSmsSub(int subId) { private void setDefaultSmsSub(int subId) {
if (localLOGD) { /* if (localLOGD) {
Log.d(TAG, "Setting the SIM for phone calls on subscription " + subId); Log.d(TAG, "Setting the SIM for phone calls on subscription " + subId);
} }
@ -325,7 +326,7 @@ public class CMTelephonyManagerService extends SystemService {
} else { } else {
SubscriptionManager.setSMSPromptEnabled(false); SubscriptionManager.setSMSPromptEnabled(false);
subscriptionManager.setDefaultSmsSubId(subId); subscriptionManager.setDefaultSmsSubId(subId);
} } */
} }
private void enforceTelephonyReadPermission() { private void enforceTelephonyReadPermission() {

View File

@ -219,25 +219,29 @@ public class PartnerInterfaceService extends SystemService {
Settings.Global.putInt(contentResolver, Settings.Global.putInt(contentResolver,
Settings.Global.ZEN_MODE, Settings.Global.ZEN_MODE,
zenModeValue); zenModeValue);
/*
try { try {
// Setting the exit condition to null signifies "indefinitely" // Setting the exit condition to null signifies "indefinitely"
mNotificationManager.setZenModeCondition(null); mNotificationManager.setZenModeCondition(null);
} catch (RemoteException e) { } catch (RemoteException e) {
// An error occurred, return false since the // An error occurred, return false since the
// condition failed to set. // condition failed to set.
Log.e(TAG, "setZenMode() failed for mode: " + mode); Log.e(TAG, "setZenMode() failed for mode: " + mode);
return false; return false;
} }
*/
return true; return true;
} }
public String getHotwordPackageNameInternal() { public String getHotwordPackageNameInternal() {
String packageName = null; String packageName = null;
/*
try { try {
packageName = mAudioService.getCurrentHotwordInputPackageName(); packageName = mAudioService.getCurrentHotwordInputPackageName();
} catch (RemoteException e) { } catch (RemoteException e) {
Log.e(TAG, "getHotwordPackageName() failed."); Log.e(TAG, "getHotwordPackageName() failed.");
} }
*/
return packageName; return packageName;
} }
} }

View File

@ -78,14 +78,14 @@ public class ProfileTriggerHelper extends BroadcastReceiver {
// mIntentFilter.addAction(AudioManager.A2DP_ROUTE_CHANGED_ACTION); // mIntentFilter.addAction(AudioManager.A2DP_ROUTE_CHANGED_ACTION);
updateEnabled(); updateEnabled();
mContext.getContentResolver().registerContentObserver( /* mContext.getContentResolver().registerContentObserver(
Settings.System.getUriFor(Settings.System.SYSTEM_PROFILES_ENABLED), false, Settings.System.getUriFor(Settings.System.SYSTEM_PROFILES_ENABLED), false,
mSettingsObserver); mSettingsObserver); */
} }
public void updateEnabled() { public void updateEnabled() {
boolean enabled = Settings.System.getInt(mContext.getContentResolver(), boolean enabled = false; // Settings.System.getInt(mContext.getContentResolver(),
Settings.System.SYSTEM_PROFILES_ENABLED, 1) == 1; //Settings.System.SYSTEM_PROFILES_ENABLED, 1) == 1;
if (enabled && !mFilterRegistered) { if (enabled && !mFilterRegistered) {
Log.v(TAG, "Enabling"); Log.v(TAG, "Enabling");
mContext.registerReceiver(this, mIntentFilter); mContext.registerReceiver(this, mIntentFilter);

View File

@ -26,7 +26,7 @@ LOCAL_RESOURCE_DIR := $(addprefix $(LOCAL_PATH)/, res)
# since these resources will be used by many apps. # since these resources will be used by many apps.
# 0x3f/one less than app id # 0x3f/one less than app id
LOCAL_AAPT_FLAGS += -x 63 LOCAL_AAPT_FLAGS += -x
LOCAL_MODULE_TAGS := optional LOCAL_MODULE_TAGS := optional

View File

@ -32,6 +32,7 @@ public class ThemeVersion {
private static final int CM11 = 1; private static final int CM11 = 1;
private static final int CM12_PRE_VERSIONING = 2; private static final int CM12_PRE_VERSIONING = 2;
/*
public static int getVersion() { public static int getVersion() {
int version; int version;
try { try {
@ -203,4 +204,5 @@ public class ThemeVersion {
return new ComponentVersion(id, component, name, minVersion, targetVersion); return new ComponentVersion(id, component, name, minVersion, targetVersion);
} }
} }
*/
} }

View File

@ -22,7 +22,7 @@ import android.content.Context;
import android.content.Intent; import android.content.Intent;
import android.location.LocationManager; import android.location.LocationManager;
import android.net.wifi.WifiManager; import android.net.wifi.WifiManager;
import android.net.wimax.WimaxHelper; /* import android.net.wimax.WimaxHelper; */
import android.nfc.NfcAdapter; import android.nfc.NfcAdapter;
import android.os.Parcel; import android.os.Parcel;
import android.os.Parcelable; import android.os.Parcelable;
@ -325,12 +325,12 @@ public final class ConnectionSettings implements Parcelable {
} }
break; break;
case PROFILE_CONNECTION_WIMAX: case PROFILE_CONNECTION_WIMAX:
if (WimaxHelper.isWimaxSupported(context)) { /* if (WimaxHelper.isWimaxSupported(context)) {
currentState = WimaxHelper.isWimaxEnabled(context); currentState = WimaxHelper.isWimaxEnabled(context);
if (currentState != forcedState) { if (currentState != forcedState) {
WimaxHelper.setWimaxEnabled(context, forcedState); WimaxHelper.setWimaxEnabled(context, forcedState);
} }
} } */
break; break;
case PROFILE_CONNECTION_NFC: case PROFILE_CONNECTION_NFC:
if (nfcAdapter != null) { if (nfcAdapter != null) {

View File

@ -24,9 +24,9 @@ import android.os.RemoteException;
import android.os.ServiceManager; import android.os.ServiceManager;
import android.util.Log; import android.util.Log;
import android.view.WindowManagerPolicy; import android.view.WindowManagerPolicy;
import android.view.WindowManagerPolicyControl; /* import android.view.WindowManagerPolicyControl; */
import com.android.internal.policy.IKeyguardService; import com.android.internal.policy.IKeyguardService;
import com.android.internal.policy.PolicyManager; /* import com.android.internal.policy.PolicyManager; */
import cyanogenmod.app.Profile; import cyanogenmod.app.Profile;
import cyanogenmod.os.Build; import cyanogenmod.os.Build;
@ -110,7 +110,7 @@ public final class LockSettings implements Parcelable {
/** @hide */ /** @hide */
public void processOverride(Context context, IKeyguardService keyguard) { public void processOverride(Context context, IKeyguardService keyguard) {
boolean enable; boolean enable;
final DevicePolicyManager devicePolicyManager = /* final DevicePolicyManager devicePolicyManager =
(DevicePolicyManager) context.getSystemService(Context.DEVICE_POLICY_SERVICE); (DevicePolicyManager) context.getSystemService(Context.DEVICE_POLICY_SERVICE);
if (devicePolicyManager != null && devicePolicyManager.requireSecureKeyguard()) { if (devicePolicyManager != null && devicePolicyManager.requireSecureKeyguard()) {
enable = true; enable = true;
@ -131,7 +131,7 @@ public final class LockSettings implements Parcelable {
keyguard.setKeyguardEnabled(enable); keyguard.setKeyguardEnabled(enable);
} catch (RemoteException e) { } catch (RemoteException e) {
Log.w(TAG, "unable to set keyguard enabled state to: " + enable, e); Log.w(TAG, "unable to set keyguard enabled state to: " + enable, e);
} } */
} }
/** @hide */ /** @hide */