Skip to content

Commit e857632

Browse files
John SpurlockAndroid (Google) Code Review
authored andcommitted
Merge "Dock: Renable desk-dock apps" into jb-dev
2 parents fa716c7 + 960779d commit e857632

File tree

2 files changed

+14
-14
lines changed

2 files changed

+14
-14
lines changed

packages/SystemUI/src/com/android/systemui/DreamsDockLauncher.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -58,8 +58,8 @@ public static class DockEventReceiver extends BroadcastReceiver {
5858
@Override
5959
public void onReceive(Context context, Intent intent) {
6060
final boolean activateOnDock = 0 != Settings.Secure.getInt(
61-
context.getContentResolver(),
62-
Settings.Secure.SCREENSAVER_ACTIVATE_ON_DOCK, 1);
61+
context.getContentResolver(),
62+
Settings.Secure.SCREENSAVER_ACTIVATE_ON_DOCK, 0);
6363

6464
if (!activateOnDock) return;
6565

services/java/com/android/server/UiModeManagerService.java

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,7 @@ class UiModeManagerService extends IUiModeManager.Stub {
6565

6666
// Enable launching of applications when entering the dock.
6767
private static final boolean ENABLE_LAUNCH_CAR_DOCK_APP = true;
68-
private static final boolean ENABLE_LAUNCH_DESK_DOCK_APP = false;
68+
private static final boolean ENABLE_LAUNCH_DESK_DOCK_APP = true;
6969

7070
private static final int MSG_UPDATE_TWILIGHT = 0;
7171
private static final int MSG_ENABLE_LOCATION_UPDATES = 1;
@@ -120,7 +120,7 @@ static Intent buildHomeIntent(String category) {
120120
| Intent.FLAG_ACTIVITY_RESET_TASK_IF_NEEDED);
121121
return intent;
122122
}
123-
123+
124124
// The broadcast receiver which receives the result of the ordered broadcast sent when
125125
// the dock state changes. The original ordered broadcast is sent with an initial result
126126
// code of RESULT_OK. If any of the registered broadcast receivers changes this value, e.g.,
@@ -130,15 +130,15 @@ static Intent buildHomeIntent(String category) {
130130
public void onReceive(Context context, Intent intent) {
131131
if (getResultCode() != Activity.RESULT_OK) {
132132
if (LOG) {
133-
Slog.v(TAG, "Handling broadcast result for action " + intent.getAction()
133+
Slog.v(TAG, "Handling broadcast result for action " + intent.getAction()
134134
+ ": canceled: " + getResultCode());
135135
}
136136
return;
137137
}
138138

139139
final int enableFlags = intent.getIntExtra("enableFlags", 0);
140140
final int disableFlags = intent.getIntExtra("disableFlags", 0);
141-
141+
142142
synchronized (mLock) {
143143
// Launch a dock activity
144144
String category = null;
@@ -166,15 +166,15 @@ public void onReceive(Context context, Intent intent) {
166166

167167
if (LOG) {
168168
Slog.v(TAG, String.format(
169-
"Handling broadcast result for action %s: enable=0x%08x disable=0x%08x category=%s",
169+
"Handling broadcast result for action %s: enable=0x%08x disable=0x%08x category=%s",
170170
intent.getAction(), enableFlags, disableFlags, category));
171171
}
172-
172+
173173
if (category != null) {
174174
// This is the new activity that will serve as home while
175175
// we are in care mode.
176176
Intent homeIntent = buildHomeIntent(category);
177-
177+
178178
// Now we are going to be careful about switching the
179179
// configuration and starting the activity -- we need to
180180
// do this in a specific order under control of the
@@ -479,8 +479,8 @@ final void updateConfigurationLocked(boolean sendIt) {
479479
}
480480

481481
if (LOG) {
482-
Slog.d(TAG,
483-
"updateConfigurationLocked: mDockState=" + mDockState
482+
Slog.d(TAG,
483+
"updateConfigurationLocked: mDockState=" + mDockState
484484
+ "; mCarMode=" + mCarModeEnabled
485485
+ "; mNightMode=" + mNightMode
486486
+ "; uiMode=" + uiMode);
@@ -657,7 +657,7 @@ private void adjustStatusBarCarModeLocked() {
657657
boolean mNetworkListenerEnabled;
658658
boolean mDidFirstInit;
659659
long mLastNetworkRegisterTime = -MIN_LOCATION_UPDATE_MS;
660-
660+
661661
@Override
662662
public void handleMessage(Message msg) {
663663
switch (msg.what) {
@@ -682,12 +682,12 @@ public void handleMessage(Message msg) {
682682
// since we last requested an update.
683683
return;
684684
}
685-
685+
686686
// Unregister the current location monitor, so we can
687687
// register a new one for it to get an immediate update.
688688
mNetworkListenerEnabled = false;
689689
mLocationManager.removeUpdates(mEmptyLocationListener);
690-
690+
691691
// Fall through to re-register listener.
692692
case MSG_ENABLE_LOCATION_UPDATES:
693693
// enable network provider to receive at least location updates for a given

0 commit comments

Comments
 (0)