recombine StatusBarService and PhoneStatusBarService

Change-Id: I64178209985bfac283740d6a667211d2f962f71a
This commit is contained in:
Joe Onorato
2010-06-28 17:19:12 -04:00
parent b54ef61434
commit 1c95ecb47a
9 changed files with 1523 additions and 1579 deletions

View File

@ -22,7 +22,7 @@
<resources xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
<!-- Component to be used as the status bar service. Must implement the IStatusBar
interface. This name is in the ComponentName flattened format (package/class) -->
<string name="config_statusBarComponent">com.android.systemui/com.android.systemui.statusbar.PhoneStatusBarService</string>
<string name="config_statusBarComponent">com.android.systemui/com.android.systemui.statusbar.StatusBarService</string>
<!-- Do not translate. Defines the slots for the right-hand side icons. That is to say, the
icons in the status bar that are not notifications. -->

View File

@ -10,7 +10,7 @@
android:icon="@drawable/ic_launcher_settings">
<service
android:name=".statusbar.PhoneStatusBarService"
android:name=".statusbar.StatusBarService"
android:exported="false"
/>

View File

@ -23,7 +23,7 @@ import android.widget.LinearLayout;
public class CloseDragHandle extends LinearLayout {
PhoneStatusBarService mService;
StatusBarService mService;
public CloseDragHandle(Context context, AttributeSet attrs) {
super(context, attrs);

View File

@ -27,7 +27,7 @@ import android.util.Slog;
public class ExpandedView extends LinearLayout {
PhoneStatusBarService mService;
StatusBarService mService;
int mPrevHeight = -1;
public ExpandedView(Context context, AttributeSet attrs) {
@ -50,10 +50,10 @@ public class ExpandedView extends LinearLayout {
super.onLayout(changed, left, top, right, bottom);
int height = bottom - top;
if (height != mPrevHeight) {
//Slog.d(PhoneStatusBarService.TAG, "height changed old=" + mPrevHeight
//Slog.d(StatusBarService.TAG, "height changed old=" + mPrevHeight
// + " new=" + height);
mPrevHeight = height;
mService.updateExpandedViewPos(PhoneStatusBarService.EXPANDED_LEAVE_ALONE);
mService.updateExpandedViewPos(StatusBarService.EXPANDED_LEAVE_ALONE);
}
}
}

View File

@ -65,7 +65,7 @@ public class StatusBarIconView extends AnimatedImageView {
if (!iconEquals) {
Drawable drawable = getIcon(icon);
if (drawable == null) {
Slog.w(PhoneStatusBarService.TAG, "No icon for slot " + mSlot);
Slog.w(StatusBarService.TAG, "No icon for slot " + mSlot);
return false;
}
setImageDrawable(drawable);
@ -99,7 +99,7 @@ public class StatusBarIconView extends AnimatedImageView {
try {
r = context.getPackageManager().getResourcesForApplication(icon.iconPackage);
} catch (PackageManager.NameNotFoundException ex) {
Slog.e(PhoneStatusBarService.TAG, "Icon package not found: " + icon.iconPackage);
Slog.e(StatusBarService.TAG, "Icon package not found: " + icon.iconPackage);
return null;
}
} else {
@ -113,7 +113,7 @@ public class StatusBarIconView extends AnimatedImageView {
try {
return r.getDrawable(icon.iconId);
} catch (RuntimeException e) {
Slog.w(PhoneStatusBarService.TAG, "Icon not found in "
Slog.w(StatusBarService.TAG, "Icon not found in "
+ (icon.iconPackage != null ? icon.iconId : "<system>")
+ ": " + Integer.toHexString(icon.iconId));
}

View File

@ -34,7 +34,7 @@ public class StatusBarView extends FrameLayout {
static final int DIM_ANIM_TIME = 400;
PhoneStatusBarService mService;
StatusBarService mService;
boolean mTracking;
int mStartX, mStartY;
ViewGroup mNotificationIcons;
@ -94,7 +94,7 @@ public class StatusBarView extends FrameLayout {
@Override
protected void onSizeChanged(int w, int h, int oldw, int oldh) {
super.onSizeChanged(w, h, oldw, oldh);
mService.updateExpandedViewPos(PhoneStatusBarService.EXPANDED_LEAVE_ALONE);
mService.updateExpandedViewPos(StatusBarService.EXPANDED_LEAVE_ALONE);
}
@Override

View File

@ -26,7 +26,7 @@ import android.widget.LinearLayout;
public class TrackingView extends LinearLayout {
final Display mDisplay;
PhoneStatusBarService mService;
StatusBarService mService;
boolean mTracking;
int mStartX, mStartY;