Only open the activity in certain areas on the widget
This commit is contained in:
parent
24f55f76f5
commit
f43bb58a65
@ -17,7 +17,6 @@
|
||||
along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
-->
|
||||
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:id="@+id/layout"
|
||||
android:layout_width="fill_parent"
|
||||
android:layout_height="fill_parent"
|
||||
android:orientation="horizontal"
|
||||
@ -37,6 +36,7 @@
|
||||
android:layout_height="fill_parent"
|
||||
android:layout_weight="1">
|
||||
<LinearLayout
|
||||
android:id="@+id/text"
|
||||
android:layout_width="fill_parent"
|
||||
android:layout_height="0dip"
|
||||
android:layout_weight="1"
|
||||
|
@ -128,7 +128,8 @@ public class FourLongWidget extends AppWidgetProvider {
|
||||
|
||||
intent = new Intent(context, LaunchActivity.class);
|
||||
pendingIntent = PendingIntent.getActivity(context, 0, intent, 0);
|
||||
views.setOnClickPendingIntent(R.id.layout, pendingIntent);
|
||||
views.setOnClickPendingIntent(R.id.cover, pendingIntent);
|
||||
views.setOnClickPendingIntent(R.id.text, pendingIntent);
|
||||
|
||||
intent = new Intent(PlaybackService.ACTION_PREVIOUS_SONG).setComponent(service);
|
||||
pendingIntent = PendingIntent.getService(context, 0, intent, 0);
|
||||
|
Loading…
x
Reference in New Issue
Block a user