From ad3c9416092f09213d32eee8b59287766eae5d19 Mon Sep 17 00:00:00 2001 From: Ricardo Cerqueira Date: Tue, 20 Nov 2012 21:17:17 +0000 Subject: Squashed commit of the theme engine support. Updated 4.2 support for the old T-Mobile theme engine, as usual needs the provider and switcher apps installed as well. I'm finally dropping the 400+ commit history on this, since everybody else keeps picking it up from CM as a single patch anyway... But for the record, nothing of this would be possible without Josh, Ed, and the rest of the TMo guys who wrote and maintained it until 2.2: amit chabra Amit Kohli Chris Cogar Dirk Sigurdson Ed Carrigan Gaurav Sharma Hui Feng John Ritz Josh Guilfoyle Mark Roberts Pankaj Kumar Samuel Cheung Sergey Ten Change-Id: I7148d51be48f28a2dc4bdf9ec9018f04b268ffc4 --- services/java/com/android/server/SystemServer.java | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) (limited to 'services/java/com/android/server/SystemServer.java') diff --git a/services/java/com/android/server/SystemServer.java b/services/java/com/android/server/SystemServer.java index 3dd22b0..cec8a4c 100644 --- a/services/java/com/android/server/SystemServer.java +++ b/services/java/com/android/server/SystemServer.java @@ -1,5 +1,6 @@ /* * Copyright (C) 2006 The Android Open Source Project + * This code has been modified. Portions copyright (C) 2010, T-Mobile USA, Inc. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -24,6 +25,7 @@ import android.content.ContentResolver; import android.content.ContentService; import android.content.Context; import android.content.Intent; +import android.content.IntentFilter; import android.content.pm.IPackageManager; import android.content.res.Configuration; import android.media.AudioService; @@ -757,6 +759,13 @@ class ServerThread extends Thread { reportWtf("starting DreamManagerService", e); } } + + try { + Slog.i(TAG, "AssetRedirectionManager Service"); + ServiceManager.addService("assetredirection", new AssetRedirectionManagerService(context)); + } catch (Throwable e) { + Slog.e(TAG, "Failure starting AssetRedirectionManager Service", e); + } } // Before things start rolling, be sure we have decided whether @@ -840,6 +849,15 @@ class ServerThread extends Thread { reportWtf("making Display Manager Service ready", e); } + IntentFilter filter = new IntentFilter(); + filter.addAction(Intent.ACTION_APP_LAUNCH_FAILURE); + filter.addAction(Intent.ACTION_APP_LAUNCH_FAILURE_RESET); + filter.addAction(Intent.ACTION_PACKAGE_ADDED); + filter.addAction(Intent.ACTION_PACKAGE_REMOVED); + filter.addCategory(Intent.CATEGORY_THEME_PACKAGE_INSTALLED_STATE_CHANGE); + filter.addDataScheme("package"); + context.registerReceiver(new AppsLaunchFailureReceiver(), filter); + // These are needed to propagate to the runnable below. final Context contextF = context; final MountService mountServiceF = mountService; -- cgit v1.1