Loading packages/SystemUI/src/com/android/systemui/statusbar/LatestItemView.java +1 −11 Original line number Diff line number Diff line Loading @@ -23,22 +23,12 @@ import android.view.MotionEvent; import android.widget.FrameLayout; public class LatestItemView extends FrameLayout { private boolean mDispatchTorches; public LatestItemView(Context context, AttributeSet attrs) { super(context, attrs); } public boolean dispatchTouchEvent(MotionEvent ev) { if (mDispatchTorches) { return super.dispatchTouchEvent(ev); } else { return onTouchEvent(ev); } } public void setOnClickListener(OnClickListener l) { mDispatchTorches = l == null; super.setOnClickListener(l); } } packages/SystemUI/src/com/android/systemui/statusbar/PhoneStatusBarService.java +0 −4 Original line number Diff line number Diff line Loading @@ -440,8 +440,6 @@ public class PhoneStatusBarService extends StatusBarService { if (contentIntent != null) { oldEntry.content.setOnClickListener(new Launcher(contentIntent, notification.pkg, notification.tag, notification.id)); } else { oldEntry.content.setOnClickListener(null); } // Update the icon. final StatusBarIcon ic = new StatusBarIcon(notification.pkg, Loading Loading @@ -518,8 +516,6 @@ public class PhoneStatusBarService extends StatusBarService { if (contentIntent != null) { content.setOnClickListener(new Launcher(contentIntent, notification.pkg, notification.tag, notification.id)); } else { oldEntry.content.setOnClickListener(null); } View expanded = null; Loading packages/SystemUI/src/com/android/systemui/statusbar/tablet/TabletStatusBarService.java +0 −4 Original line number Diff line number Diff line Loading @@ -370,8 +370,6 @@ public class TabletStatusBarService extends StatusBarService { if (contentIntent != null) { oldEntry.content.setOnClickListener(new NotificationClicker(contentIntent, notification.pkg, notification.tag, notification.id)); } else { oldEntry.content.setOnClickListener(null); } // Update the icon. final StatusBarIcon ic = new StatusBarIcon(notification.pkg, Loading Loading @@ -762,8 +760,6 @@ public class TabletStatusBarService extends StatusBarService { if (contentIntent != null) { content.setOnClickListener(new NotificationClicker(contentIntent, sbn.pkg, sbn.tag, sbn.id)); } else { content.setOnClickListener(null); } View expanded = null; Loading services/java/com/android/server/NotificationManagerService.java +4 −0 Original line number Diff line number Diff line Loading @@ -741,6 +741,10 @@ public class NotificationManagerService extends INotificationManager.Stub throw new IllegalArgumentException("contentView required: pkg=" + pkg + " id=" + id + " notification=" + notification); } if (notification.contentIntent == null) { throw new IllegalArgumentException("contentIntent required: pkg=" + pkg + " id=" + id + " notification=" + notification); } } synchronized (mNotificationList) { Loading tests/StatusBar/src/com/android/statusbartest/NotificationTestList.java +0 −18 Original line number Diff line number Diff line Loading @@ -86,18 +86,6 @@ public class NotificationTestList extends TestActivity } }, new Test("custom intent on text view") { public void run() { Notification n = new Notification(R.drawable.icon1, null, mActivityCreateTime); n.setLatestEventInfo(NotificationTestList.this, "Persistent #1", "This is a notification!!!", null); n.contentView.setOnClickPendingIntent(com.android.internal.R.id.text, makeIntent2()); mNM.notify(1, n); } }, new Test("Ticker 1 line") { public void run() { Notification n = new Notification(R.drawable.icon1, "tick tick tick", Loading Loading @@ -788,12 +776,6 @@ public class NotificationTestList extends TestActivity return PendingIntent.getActivity(this, 0, intent, 0); } private PendingIntent makeIntent2() { Intent intent = new Intent(this, StatusBarTest.class); return PendingIntent.getActivity(this, 0, intent, 0); } class StateStress extends Test { StateStress(String name, int pause, int iterations, Runnable[] tasks) { super(name); Loading Loading
packages/SystemUI/src/com/android/systemui/statusbar/LatestItemView.java +1 −11 Original line number Diff line number Diff line Loading @@ -23,22 +23,12 @@ import android.view.MotionEvent; import android.widget.FrameLayout; public class LatestItemView extends FrameLayout { private boolean mDispatchTorches; public LatestItemView(Context context, AttributeSet attrs) { super(context, attrs); } public boolean dispatchTouchEvent(MotionEvent ev) { if (mDispatchTorches) { return super.dispatchTouchEvent(ev); } else { return onTouchEvent(ev); } } public void setOnClickListener(OnClickListener l) { mDispatchTorches = l == null; super.setOnClickListener(l); } }
packages/SystemUI/src/com/android/systemui/statusbar/PhoneStatusBarService.java +0 −4 Original line number Diff line number Diff line Loading @@ -440,8 +440,6 @@ public class PhoneStatusBarService extends StatusBarService { if (contentIntent != null) { oldEntry.content.setOnClickListener(new Launcher(contentIntent, notification.pkg, notification.tag, notification.id)); } else { oldEntry.content.setOnClickListener(null); } // Update the icon. final StatusBarIcon ic = new StatusBarIcon(notification.pkg, Loading Loading @@ -518,8 +516,6 @@ public class PhoneStatusBarService extends StatusBarService { if (contentIntent != null) { content.setOnClickListener(new Launcher(contentIntent, notification.pkg, notification.tag, notification.id)); } else { oldEntry.content.setOnClickListener(null); } View expanded = null; Loading
packages/SystemUI/src/com/android/systemui/statusbar/tablet/TabletStatusBarService.java +0 −4 Original line number Diff line number Diff line Loading @@ -370,8 +370,6 @@ public class TabletStatusBarService extends StatusBarService { if (contentIntent != null) { oldEntry.content.setOnClickListener(new NotificationClicker(contentIntent, notification.pkg, notification.tag, notification.id)); } else { oldEntry.content.setOnClickListener(null); } // Update the icon. final StatusBarIcon ic = new StatusBarIcon(notification.pkg, Loading Loading @@ -762,8 +760,6 @@ public class TabletStatusBarService extends StatusBarService { if (contentIntent != null) { content.setOnClickListener(new NotificationClicker(contentIntent, sbn.pkg, sbn.tag, sbn.id)); } else { content.setOnClickListener(null); } View expanded = null; Loading
services/java/com/android/server/NotificationManagerService.java +4 −0 Original line number Diff line number Diff line Loading @@ -741,6 +741,10 @@ public class NotificationManagerService extends INotificationManager.Stub throw new IllegalArgumentException("contentView required: pkg=" + pkg + " id=" + id + " notification=" + notification); } if (notification.contentIntent == null) { throw new IllegalArgumentException("contentIntent required: pkg=" + pkg + " id=" + id + " notification=" + notification); } } synchronized (mNotificationList) { Loading
tests/StatusBar/src/com/android/statusbartest/NotificationTestList.java +0 −18 Original line number Diff line number Diff line Loading @@ -86,18 +86,6 @@ public class NotificationTestList extends TestActivity } }, new Test("custom intent on text view") { public void run() { Notification n = new Notification(R.drawable.icon1, null, mActivityCreateTime); n.setLatestEventInfo(NotificationTestList.this, "Persistent #1", "This is a notification!!!", null); n.contentView.setOnClickPendingIntent(com.android.internal.R.id.text, makeIntent2()); mNM.notify(1, n); } }, new Test("Ticker 1 line") { public void run() { Notification n = new Notification(R.drawable.icon1, "tick tick tick", Loading Loading @@ -788,12 +776,6 @@ public class NotificationTestList extends TestActivity return PendingIntent.getActivity(this, 0, intent, 0); } private PendingIntent makeIntent2() { Intent intent = new Intent(this, StatusBarTest.class); return PendingIntent.getActivity(this, 0, intent, 0); } class StateStress extends Test { StateStress(String name, int pause, int iterations, Runnable[] tasks) { super(name); Loading