Initialize Hipri correctly.

The old code was dependent on the order of things in config.xml.  This fixes that
so hipri will get the correct dependency-met value at startup.  Good ITS test.

bug:5382518
Change-Id: Ie327ab1abbc5697ffab0ed4d8c9d6de321513adb
This commit is contained in:
Robert Greenwalt
2011-10-18 11:49:24 -07:00
parent 11116b80d8
commit a4bc82aca5

View File

@@ -273,7 +273,14 @@ public final class GsmDataConnectionTracker extends DataConnectionTracker {
break;
case ConnectivityManager.TYPE_MOBILE_HIPRI:
apnContext = addApnContext(Phone.APN_TYPE_HIPRI);
break;
ApnContext defaultContext = mApnContexts.get(Phone.APN_TYPE_DEFAULT);
if (defaultContext != null) {
applyNewState(apnContext, apnContext.isEnabled(),
defaultContext.getDependencyMet());
} else {
// the default will set the hipri dep-met when it is created
}
continue;
case ConnectivityManager.TYPE_MOBILE_FOTA:
apnContext = addApnContext(Phone.APN_TYPE_FOTA);
break;