Improved space usage of title area in episode dialog
This commit is contained in:
parent
640b36912a
commit
0d1803413c
|
@ -5,10 +5,25 @@
|
|||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent">
|
||||
|
||||
<TextView
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_margin="16dp"
|
||||
android:id="@+id/txtvTitle"
|
||||
android:layout_alignParentTop="true"
|
||||
style="@style/AntennaPod.Dialog.Title"/>
|
||||
|
||||
<View
|
||||
android:id="@+id/title_divider"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="2dp"
|
||||
android:layout_below="@id/txtvTitle"
|
||||
android:background="@color/bright_blue"/>
|
||||
|
||||
<LinearLayout
|
||||
android:id="@+id/header"
|
||||
android:orientation="horizontal"
|
||||
android:layout_alignParentTop="true"
|
||||
android:layout_below="@id/title_divider"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content">
|
||||
|
||||
|
@ -41,7 +56,7 @@
|
|||
<View
|
||||
android:id="@+id/divider"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="3dp"
|
||||
android:layout_height="2dp"
|
||||
android:layout_below="@id/header"
|
||||
android:background="@color/bright_blue"/>
|
||||
|
||||
|
|
|
@ -6,4 +6,12 @@
|
|||
<item name="android:textColor">?android:attr/textColorPrimary</item>
|
||||
<item name="android:fontFamily">sans-serif-light</item>
|
||||
</style>
|
||||
|
||||
<style name="AntennaPod.Dialog.Title" parent="@android:style/TextAppearance.Medium">
|
||||
<item name="android:textSize">@dimen/text_size_medium</item>
|
||||
<item name="android:textColor">@color/bright_blue</item>
|
||||
<item name="android:maxLines">2</item>
|
||||
<item name="android:ellipsize">end</item>
|
||||
<item name="android:fontFamily">sans-serif-light</item>
|
||||
</style>
|
||||
</resources>
|
|
@ -132,4 +132,11 @@
|
|||
<item name="android:lines">2</item>
|
||||
<item name="android:ellipsize">end</item>
|
||||
</style>
|
||||
|
||||
<style name="AntennaPod.Dialog.Title" parent="@android:style/TextAppearance.Medium">
|
||||
<item name="android:textSize">@dimen/text_size_medium</item>
|
||||
<item name="android:textColor">?android:attr/textColorPrimary</item>
|
||||
<item name="android:maxLines">2</item>
|
||||
<item name="android:ellipsize">end</item>
|
||||
</style>
|
||||
</resources>
|
||||
|
|
|
@ -14,10 +14,12 @@ import android.util.Log;
|
|||
import android.util.TypedValue;
|
||||
import android.view.MenuItem;
|
||||
import android.view.View;
|
||||
import android.view.Window;
|
||||
import android.webkit.WebSettings;
|
||||
import android.webkit.WebView;
|
||||
import android.webkit.WebViewClient;
|
||||
import android.widget.ImageButton;
|
||||
import android.widget.TextView;
|
||||
import android.widget.Toast;
|
||||
import de.danoeh.antennapod.BuildConfig;
|
||||
import de.danoeh.antennapod.R;
|
||||
|
@ -48,6 +50,7 @@ public class FeedItemDialog extends Dialog {
|
|||
private QueueAccess queue;
|
||||
|
||||
private View header;
|
||||
private TextView txtvTitle;
|
||||
private WebView webvDescription;
|
||||
private ImageButton butAction1;
|
||||
private ImageButton butAction2;
|
||||
|
@ -95,8 +98,10 @@ public class FeedItemDialog extends Dialog {
|
|||
@Override
|
||||
protected void onCreate(Bundle savedInstanceState) {
|
||||
super.onCreate(savedInstanceState);
|
||||
requestWindowFeature(Window.FEATURE_NO_TITLE);
|
||||
setContentView(R.layout.feeditem_dialog);
|
||||
|
||||
txtvTitle = (TextView) findViewById(R.id.txtvTitle);
|
||||
header = findViewById(R.id.header);
|
||||
webvDescription = (WebView) findViewById(R.id.webview);
|
||||
butAction1 = (ImageButton) findViewById(R.id.butAction1);
|
||||
|
@ -105,7 +110,7 @@ public class FeedItemDialog extends Dialog {
|
|||
popupMenu = new PopupMenu(getContext(), butMore);
|
||||
|
||||
webvDescription.setWebViewClient(new WebViewClient());
|
||||
setTitle(item.getTitle());
|
||||
txtvTitle.setText(item.getTitle());
|
||||
|
||||
if (UserPreferences.getTheme() == R.style.Theme_AntennaPod_Dark) {
|
||||
if (Build.VERSION.SDK_INT >= 11
|
||||
|
|
Loading…
Reference in New Issue