release
jhengazuki 7 months ago
parent 35d2070345
commit 8a41328d65
  1. 1
      app/build.gradle
  2. 6
      app/src/leanback/AndroidManifest.xml
  3. 8
      app/src/leanback/java/com/fongmi/android/tv/ui/activity/HomeActivity.java
  4. 2
      app/src/leanback/res/drawable/shape_vod_name.xml
  5. 8
      app/src/leanback/res/values-v27/styles.xml
  6. 30
      app/src/leanback/res/values/styles.xml
  7. 2
      app/src/main/AndroidManifest.xml
  8. BIN
      app/src/main/res/drawable-nodpi/ic_splash.png
  9. 6
      app/src/mobile/AndroidManifest.xml
  10. 7
      app/src/mobile/java/com/fongmi/android/tv/ui/activity/HomeActivity.java
  11. 10
      app/src/mobile/res/drawable/ic_action_close.xml
  12. 2
      app/src/mobile/res/drawable/shape_vod_name.xml
  13. 18
      app/src/mobile/res/layout/activity_collect.xml
  14. 2
      app/src/mobile/res/values-v27/styles.xml
  15. 2
      app/src/mobile/res/values-v35/styles.xml
  16. 31
      app/src/mobile/res/values/styles.xml

@ -97,6 +97,7 @@ dependencies {
implementation project(':chaquo')
implementation project(':quickjs')
implementation 'androidx.appcompat:appcompat:1.7.1'
implementation 'androidx.core:core-splashscreen:1.0.1'
implementation 'androidx.media:media:1.7.1'
implementation 'androidx.room:room-runtime:2.8.0'
implementation 'cat.ereza:customactivityoncrash:2.4.0'

@ -30,7 +30,8 @@
android:name=".ui.activity.HomeActivity"
android:configChanges="screenSize|smallestScreenSize|screenLayout|orientation"
android:exported="true"
android:screenOrientation="sensorLandscape">
android:screenOrientation="sensorLandscape"
android:theme="@style/Theme.Splash">
<intent-filter>
<action android:name="android.intent.action.MAIN" />
@ -104,8 +105,7 @@
android:configChanges="screenSize|smallestScreenSize|screenLayout|orientation"
android:exported="true"
android:launchMode="singleTop"
android:screenOrientation="sensorLandscape"
android:theme="@style/AppTheme.Live" />
android:screenOrientation="sensorLandscape" />
<activity
android:name=".ui.activity.VideoActivity"

@ -1,11 +1,13 @@
package com.fongmi.android.tv.ui.activity;
import android.content.Intent;
import android.os.Bundle;
import android.view.KeyEvent;
import android.view.View;
import androidx.annotation.NonNull;
import androidx.annotation.Nullable;
import androidx.core.splashscreen.SplashScreen;
import androidx.leanback.widget.ArrayObjectAdapter;
import androidx.leanback.widget.ItemBridgeAdapter;
import androidx.leanback.widget.ListRow;
@ -92,6 +94,12 @@ public class HomeActivity extends BaseActivity implements CustomTitleView.Listen
checkAction(intent);
}
@Override
protected void onCreate(Bundle savedInstanceState) {
SplashScreen.installSplashScreen(this);
super.onCreate(savedInstanceState);
}
@Override
protected void initView() {
mClock = Clock.create(mBinding.clock).format("HH:mm:ss");

@ -6,6 +6,6 @@
android:bottomLeftRadius="8dp"
android:bottomRightRadius="8dp" />
<solid android:color="@color/black_30" />
<solid android:color="@color/black_20" />
</shape>

@ -1,8 +0,0 @@
<resources>
<style name="AppTheme" parent="BaseTheme">
<item name="android:windowTranslucentStatus">true</item>
<item name="android:windowLayoutInDisplayCutoutMode">shortEdges</item>
</style>
</resources>

@ -1,24 +1,30 @@
<resources>
<style name="AppTheme" parent="BaseTheme" />
<style name="AppTheme.Live" parent="AppTheme">
<item name="android:windowBackground">@color/black</item>
</style>
<style name="BaseTheme" parent="Theme.MaterialComponents.Light.NoActionBar">
<style name="Theme.Base" parent="Theme.MaterialComponents.Light.NoActionBar">
<item name="colorPrimary">@color/primary</item>
<item name="colorPrimaryDark">@color/primaryDark</item>
<item name="colorAccent">@color/accent</item>
<item name="android:windowFullscreen">true</item>
<item name="android:windowBackground">@null</item>
<item name="android:windowDisablePreview">true</item>
<item name="android:windowAnimationStyle">@null</item>
<item name="android:windowTranslucentStatus">true</item>
<item name="android:windowTranslucentNavigation">true</item>
<item name="android:windowAnimationStyle">@style/NoAnim</item>
<item name="bottomSheetDialogTheme">@style/BottomSheetDialog</item>
</style>
<style name="Theme.Splash" parent="Theme.SplashScreen">
<item name="postSplashScreenTheme">@style/Theme.App</item>
<item name="windowSplashScreenBackground">@color/white</item>
<item name="windowSplashScreenIconBackgroundColor">@color/white</item>
<item name="windowSplashScreenAnimatedIcon">@drawable/ic_splash</item>
</style>
<style name="Theme.App" parent="Theme.Base" />
<style name="NoAnim">
<item name="android:activityOpenEnterAnimation">@null</item>
<item name="android:activityOpenExitAnimation">@null</item>
<item name="android:activityCloseEnterAnimation">@null</item>
<item name="android:activityCloseExitAnimation">@null</item>
</style>
<style name="ModalBottomSheetDialog" parent="Widget.Design.BottomSheet.Modal">
<item name="android:background">@drawable/shape_bottom_sheet</item>
</style>

@ -41,7 +41,7 @@
android:requestLegacyExternalStorage="true"
android:roundIcon="@mipmap/ic_launcher_round"
android:supportsRtl="true"
android:theme="@style/AppTheme"
android:theme="@style/Theme.App"
android:usesCleartextTraffic="true"
tools:replace="android:allowBackup">

Binary file not shown.

After

Width:  |  Height:  |  Size: 24 KiB

@ -15,6 +15,7 @@
android:configChanges="screenSize|smallestScreenSize|screenLayout|uiMode|orientation"
android:exported="true"
android:screenOrientation="fullUser"
android:theme="@style/Theme.Splash"
android:windowSoftInputMode="adjustPan">
<intent-filter>
<action android:name="android.intent.action.MAIN" />
@ -98,8 +99,7 @@
android:launchMode="singleTop"
android:resizeableActivity="true"
android:screenOrientation="sensorLandscape"
android:supportsPictureInPicture="true"
android:theme="@style/AppTheme.Live" />
android:supportsPictureInPicture="true" />
<activity
android:name=".ui.activity.ScanActivity"
@ -113,7 +113,7 @@
android:resizeableActivity="true"
android:screenOrientation="fullUser"
android:supportsPictureInPicture="true"
android:theme="@style/AppTheme.Video" />
android:theme="@style/Theme.Video" />
<receiver
android:name=".receiver.ShortcutReceiver"

@ -11,6 +11,7 @@ import androidx.annotation.NonNull;
import androidx.core.content.pm.ShortcutInfoCompat;
import androidx.core.content.pm.ShortcutManagerCompat;
import androidx.core.graphics.drawable.IconCompat;
import androidx.core.splashscreen.SplashScreen;
import androidx.fragment.app.Fragment;
import androidx.viewbinding.ViewBinding;
@ -64,6 +65,12 @@ public class HomeActivity extends BaseActivity implements NavigationBarView.OnIt
checkAction(intent);
}
@Override
protected void onCreate(Bundle savedInstanceState) {
SplashScreen.installSplashScreen(this);
super.onCreate(savedInstanceState);
}
@Override
protected void initView(Bundle savedInstanceState) {
orientation = getResources().getConfiguration().orientation;

@ -0,0 +1,10 @@
<vector xmlns:android="http://schemas.android.com/apk/res/android"
android:width="24dp"
android:height="24dp"
android:tint="#FFFFFF"
android:viewportWidth="960"
android:viewportHeight="960">
<path
android:fillColor="@android:color/white"
android:pathData="M480,536L284,732Q273,743 256,743Q239,743 228,732Q217,721 217,704Q217,687 228,676L424,480L228,284Q217,273 217,256Q217,239 228,228Q239,217 256,217Q273,217 284,228L480,424L676,228Q687,217 704,217Q721,217 732,228Q743,239 743,256Q743,273 732,284L536,480L732,676Q743,687 743,704Q743,721 732,732Q721,743 704,743Q687,743 676,732L480,536Z" />
</vector>

@ -6,7 +6,7 @@
android:bottomLeftRadius="8dp"
android:bottomRightRadius="8dp" />
<solid android:color="@color/black_30" />
<solid android:color="@color/black_20" />
<padding
android:bottom="6dp"

@ -8,6 +8,24 @@
android:fitsSystemWindows="true"
android:orientation="vertical">
<com.google.android.material.appbar.AppBarLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:background="@color/transparent"
android:elevation="0dp"
app:elevation="0dp"
app:liftOnScrollColor="@color/transparent">
<com.google.android.material.appbar.MaterialToolbar
android:id="@+id/toolbar"
android:layout_width="match_parent"
android:layout_height="?attr/actionBarSize"
app:layout_scrollFlags="scroll|enterAlways"
app:navigationIconTint="@android:color/white"
app:titleTextColor="@android:color/white" />
</com.google.android.material.appbar.AppBarLayout>
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"

@ -1,6 +1,6 @@
<resources>
<style name="AppTheme" parent="BaseTheme">
<style name="Theme.App" parent="Theme.Base">
<item name="android:windowTranslucentStatus">true</item>
<item name="android:windowLayoutInDisplayCutoutMode">shortEdges</item>
</style>

@ -1,6 +1,6 @@
<resources>
<style name="AppTheme" parent="BaseTheme">
<style name="Theme.App" parent="Theme.Base">
<item name="android:windowTranslucentStatus">true</item>
<item name="android:windowOptOutEdgeToEdgeEnforcement">true</item>
<item name="android:windowLayoutInDisplayCutoutMode">shortEdges</item>

@ -1,26 +1,27 @@
<resources>
<style name="AppTheme" parent="BaseTheme">
<item name="android:windowTranslucentStatus">true</item>
<style name="Theme.Base" parent="Theme.Material3.DayNight.NoActionBar">
<item name="colorPrimary">@color/primary</item>
<item name="colorPrimaryDark">@color/primaryDark</item>
<item name="colorAccent">@color/accent</item>
<item name="android:navigationBarColor">@color/transparent</item>
<item name="bottomSheetDialogTheme">@style/BottomSheetDialog</item>
</style>
<style name="AppTheme.Live" parent="AppTheme">
<item name="android:windowBackground">@color/black</item>
<style name="Theme.Splash" parent="Theme.SplashScreen">
<item name="postSplashScreenTheme">@style/Theme.App</item>
<item name="windowSplashScreenBackground">@color/white</item>
<item name="windowSplashScreenIconBackgroundColor">@color/white</item>
<item name="windowSplashScreenAnimatedIcon">@drawable/ic_splash</item>
</style>
<style name="AppTheme.Video" parent="AppTheme">
<item name="android:statusBarColor">@color/black</item>
<item name="android:windowTranslucentStatus">false</item>
<style name="Theme.App" parent="Theme.Base">
<item name="android:windowTranslucentStatus">true</item>
</style>
<style name="BaseTheme" parent="Theme.Material3.DayNight.NoActionBar">
<item name="colorPrimary">@color/primary</item>
<item name="colorPrimaryDark">@color/primaryDark</item>
<item name="colorAccent">@color/accent</item>
<item name="android:windowBackground">@null</item>
<item name="android:windowDisablePreview">true</item>
<item name="android:navigationBarColor">@color/transparent</item>
<item name="bottomSheetDialogTheme">@style/BottomSheetDialog</item>
<style name="Theme.Video" parent="Theme.App">
<item name="android:statusBarColor">@color/black</item>
<item name="android:windowTranslucentStatus">false</item>
</style>
<style name="Control" />

Loading…
Cancel
Save