• After 15+ years, we've made a big change: Android Forums is now Early Bird Club. Learn more here.

Apps PreferenceActivity as main Activity. Widget

How do I configure the AndroidManifest to use a PreferenceActivity as main Activity for my Widget. The preference should appear when creating the widget. If I use the AndroidManifest posted below, I get a popup-message telling me that the application is not installed on my phone when lauching/creating a new widget.

Code:
<application
    android:icon="@drawable/icon"
    android:label="@string/app_name"
    android:debuggable="true">
    <activity
        android:name=".WidgetPreference"
        android:label="@string/app_name">
        <intent-filter>
            <action
                android:name="android.intent.action.MAIN" />
            <category
                android:name="android.intent.category.LAUNCHER" />
        </intent-filter>
        <intent-filter>
            <action
                android:name="android.appwidget.action.APPWIDGET_CONFIGURE" />
        </intent-filter>
    </activity>
    <receiver
        android:name="Widget">
        <intent-filter>
            <action
                android:name="android.appwidget.action.APPWIDGET_UPDATE" />
        </intent-filter>
        <meta-data
            android:name="android.appwidget.provider"
            android:resource="@xml/imageswidget_info" />
    </receiver>

</application>
 
Back
Top Bottom