Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    <p>You can achieve this by using <strong>AlertDialog.Builder</strong>, but instead of using standard dialog, you need to <em>inflate</em> your own xml to override the view.</p> <p><strong>update</strong></p> <p>or create an activity with dialog style:</p> <p>your custom <strong>style</strong>:</p> <pre><code>&lt;style name="styleActivityDialog" parent="@android:style/Theme.Light.NoTitleBar"&gt; &lt;item name="android:windowNoTitle"&gt;true&lt;/item&gt; &lt;item name="android:windowFrame"&gt;@null&lt;/item&gt; &lt;item name="android:windowIsFloating"&gt;true&lt;/item&gt; &lt;item name="android:windowContentOverlay"&gt;@null&lt;/item&gt; &lt;item name="android:colorBackgroundCacheHint"&gt;@android:color/transparent&lt;/item&gt; &lt;item name="android:windowAnimationStyle"&gt;@android:style/Animation.Dialog&lt;/item&gt; &lt;item name="android:windowSoftInputMode"&gt;stateUnspecified|adjustPan&lt;/item&gt; &lt;item name="android:windowBackground"&gt;@drawable/bg_activity_dialog&lt;/item&gt; &lt;/style&gt; </code></pre> <p>drawable <strong>bg_activity_dialog</strong>:</p> <pre><code> &lt;?xml version="1.0" encoding="utf-8"?&gt; &lt;shape xmlns:android="http://schemas.android.com/apk/res/android"&gt; &lt;stroke android:width="1dp" android:color="#C0C0C0" /&gt; &lt;solid android:color="#FFFFFF" /&gt; &lt;corners android:radius="5dp" /&gt; &lt;padding android:top="5dp" android:bottom="5dp" android:left="5dp" android:right="5dp"/&gt; &lt;/shape&gt; </code></pre> <p>your activity in <strong>AndroidManifest.xml</strong>:</p> <pre><code>&lt;activity android:name=".ActivityDialog" android:theme="@style/styleActivityDialog"&gt; &lt;/activity&gt; </code></pre> <p>now create any layout for your activity <strong>ActivityDialog</strong> and it should appear as a dialog window</p>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. VO
      singulars
      1. This table or related slice is empty.
    2. VO
      singulars
      1. This table or related slice is empty.
    3. VO
      singulars
      1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload