[mobile] support more

pull/123/head
FongMi 3 years ago
parent eb20c5c52e
commit 5ca76ea7e7
  1. 10
      app/src/mobile/java/com/fongmi/android/tv/ui/activity/DetailActivity.java
  2. 14
      app/src/mobile/res/layout/activity_detail.xml
  3. 6
      app/src/mobile/res/layout/fragment_site.xml
  4. 4
      app/src/mobile/res/values-zh-rCN/strings.xml
  5. 4
      app/src/mobile/res/values-zh-rTW/strings.xml
  6. 4
      app/src/mobile/res/values/strings.xml

@ -172,8 +172,8 @@ public class DetailActivity extends BaseActivity implements FlagAdapter.OnClickL
@SuppressLint("ClickableViewAccessibility")
protected void initEvent() {
mBinding.control.seek.setListener(mPlayers);
/*mBinding.desc.setOnClickListener(view -> onDesc());
mBinding.keep.setOnClickListener(view -> onKeep());
mBinding.more.setOnClickListener(view -> onMore());
/*mBinding.keep.setOnClickListener(view -> onKeep());
mBinding.video.setOnClickListener(view -> onVideo());
mBinding.control.text.setOnClickListener(this::onTrack);
mBinding.control.audio.setOnClickListener(this::onTrack);
@ -384,6 +384,12 @@ public class DetailActivity extends BaseActivity implements FlagAdapter.OnClickL
hideInfo();
}
private void onMore() {
boolean more = getString(R.string.vod_content_expand).equals(mBinding.more.getText().toString());
mBinding.more.setText(more ? R.string.vod_content_collapse : R.string.vod_content_expand);
mBinding.content.setMaxLines(more ? Integer.MAX_VALUE : 4);
}
private void showProgress() {
mBinding.widget.progress.setVisibility(View.VISIBLE);
App.post(mR2, 0);

@ -61,6 +61,8 @@
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_below="@+id/video"
android:clipChildren="false"
android:clipToPadding="false"
android:fillViewport="true"
android:paddingTop="16dp"
android:paddingBottom="16dp">
@ -236,6 +238,18 @@
android:textSize="14sp"
tools:text="一個身世神秘的少年范閒(張若昀飾),因對自身身世的好奇而離開故鄉澹州,前赴南慶京都。范閒在京中各大勢力之間遊走,以探查自己屢遭刺殺的原因。其間結識靖王世子、二皇子,與太子、長公主等人對抗,並遊歷四方、闖蕩江湖,卻意外發現這世界隱藏著的秘密。本劇第一季上半部主要描述范閒在南慶京都追查刺殺的幕後黑手,京中各式人等對范閒繼承內庫的態度和應對,以及監察院院長陳萍萍希望范閒接掌監察院所做的一切舉動。下半部劇情發生在北齊上京。南慶駐北齊上京諜報首領言冰雲被北齊官方抓獲,慶帝與陳萍萍同意用已被關在監察院大牢多年的前北魏諜報首領肖恩交換言冰雲,並派范閒親率南慶使團負責此事。" />
<TextView
android:id="@+id/more"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="end"
android:layout_marginTop="8dp"
android:layout_marginEnd="16dp"
android:text="@string/vod_content_expand"
android:textColor="@color/white"
android:textSize="12sp"
android:textStyle="bold" />
</LinearLayout>
</androidx.core.widget.NestedScrollView>
</com.fongmi.android.tv.ui.custom.ProgressLayout>

@ -16,7 +16,8 @@
android:layout_marginEnd="16dp"
android:text="@string/home_history"
android:textColor="@color/white"
android:textSize="18sp" />
android:textSize="18sp"
android:textStyle="bold" />
<androidx.recyclerview.widget.RecyclerView
android:id="@+id/history"
@ -34,7 +35,8 @@
android:layout_marginEnd="16dp"
android:text="@string/home_recommend"
android:textColor="@color/white"
android:textSize="18sp" />
android:textSize="18sp"
android:textStyle="bold" />
<com.fongmi.android.tv.ui.custom.ProgressLayout
android:id="@+id/progressLayout"

@ -9,4 +9,8 @@
<string name="home_history">最近观看</string>
<string name="home_recommend">更新推荐</string>
<!-- VOD -->
<string name="vod_content_expand">展开</string>
<string name="vod_content_collapse">收起</string>
</resources>

@ -9,4 +9,8 @@
<string name="home_history">最近觀看</string>
<string name="home_recommend">更新推薦</string>
<!-- VOD -->
<string name="vod_content_expand">展開</string>
<string name="vod_content_collapse">收起</string>
</resources>

@ -9,4 +9,8 @@
<string name="home_history">History</string>
<string name="home_recommend">Recommend</string>
<!-- VOD -->
<string name="vod_content_expand">Expand</string>
<string name="vod_content_collapse">Collapse</string>
</resources>
Loading…
Cancel
Save