2016-06-24 6 views
0

Ich habe ein Problem. Ich habe eine activity und ich zeige es als dialog siehe das Bild.Aktivität, die als Dialog angezeigt wird, haben eine Symbolleiste

This image.

In diesem Bild gibt es ein dialog, die ein kleines schwarzen toolbar Ich denke haben, wie es zu entfernen.

Ich benutze diesen Stil für die Aktivität

style name="MyAlertDialogStyle" parent="Theme.AppCompat.Dialog.Alert" 

Dies ist Manifest-Datei:

<?xml version="1.0" encoding="utf-8"?> 

<application 
    android:allowBackup="true" 
    android:icon="@mipmap/ic_launcher" 
    android:label="@string/app_name" 
    android:supportsRtl="true" 
    android:theme="@style/AppTheme" > 
    <activity android:name=".MainActivity" 
       android:configChanges="orientation|screenSize"> 
     <intent-filter> 
      <action android:name="android.intent.action.MAIN" /> 

      <category android:name="android.intent.category.LAUNCHER" /> 
     </intent-filter> 
    </activity> 

    /////////////// 
    <activity android:name=".Activity2" 
     /> 

    ////////////////////////////// 
    <activity android:name=".events.Wedding_Ceremony"/> 

    ///////////////// 

    <activity android:name=".events.GalleryView"/> 
    ///////////////////// 

    <activity android:name=".events.SingleViewActivity"/> 

    ///////////// this is my Dialog 
    <activity android:name=".downloadDialog.MainDialog" 
     android:theme="@style/Theme.AppCompat.Dialog.Alert" 
     /> 
</application> 

Antwort

0

Try this:

<style name="MyAlertDialogStyle" parent="Theme.AppCompat.Dialog.Alert"> 
    <item name="windowNoTitle">true</item> 
    <item name="windowActionBar">false</item> 
</style> 

sollten Sie zu Ihrem Stil-Datei verweisen:

<activity android:name=".downloadDialog.MainDialog" 
    android:theme="@style/MyAlertDialogStyle" 
/> 
+0

Thnkx für die reply.but es das Problem nicht lösen hat. –

+0

Versuchen Sie mit dem Update, windowNoTitle sollte mit AppCompatActivity – lubilis

+0

ich aktualisieren meine que funktionieren. Überprüfen Sie die Manifest-Datei –