Skip to content

Commit 6cbf1f1

Browse files
CrystalSpiresucclz123
authored andcommitted
init
0 parents  commit 6cbf1f1

135 files changed

Lines changed: 8877 additions & 0 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.gitignore

Lines changed: 49 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,49 @@
1+
.gradle
2+
build/
3+
!gradle/wrapper/gradle-wrapper.jar
4+
!**/src/main/**/build/
5+
!**/src/test/**/build/
6+
7+
### IntelliJ IDEA ###
8+
.idea/modules.xml
9+
.idea/jarRepositories.xml
10+
.idea/compiler.xml
11+
.idea/libraries/
12+
*.iws
13+
*.iml
14+
*.ipr
15+
out/
16+
!**/src/main/**/out/
17+
!**/src/test/**/out/
18+
19+
### Eclipse ###
20+
.apt_generated
21+
.classpath
22+
.factorypath
23+
.project
24+
.settings
25+
.springBeans
26+
.sts4-cache
27+
bin/
28+
!**/src/main/**/bin/
29+
!**/src/test/**/bin/
30+
31+
### NetBeans ###
32+
/nbproject/private/
33+
/nbbuild/
34+
/dist/
35+
/nbdist/
36+
/.nb-gradle/
37+
38+
### VS Code ###
39+
.vscode/
40+
41+
### Mac OS ###
42+
.DS_Store
43+
44+
jcef-bundle
45+
imageCache
46+
file-download
47+
.idea/
48+
49+
local.properties

README.md

Lines changed: 47 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,47 @@
1+
# AcFun Client Multiplatform
2+
3+
这是一个旨在使用 Compose 技术来构建一个多平台的在线流媒体客户端, 同时支持 Android Phone,Android Pad, Android TV, Windows, Mac OS, Linux,目标达到 90% UI 代码的通用率,包括接口请求和弹幕显示等。
4+
5+
# Download
6+
7+
https://github.com/succlz123/AcFun-Client-Multiplatform/releases
8+
9+
# Feature
10+
11+
- 首页展示
12+
- 分区内容展示
13+
- 视频详情展示
14+
- UP主投稿视频查看
15+
- 视频播放
16+
- 直播
17+
- 搜索
18+
- 支持播放多清晰度选择
19+
- 播放功能增强,变速,音量调节等
20+
- 分区支持筛选排序
21+
- 弹幕 (简易弹幕-实验/Experimental)
22+
- Android Phone, Android Pad,Desktop 适配
23+
- 下载
24+
25+
# Todo
26+
27+
- 支持播放选集功能
28+
- Android TV 适配
29+
- DLNA 投屏
30+
- 番剧
31+
- 文章区
32+
33+
# Screenshot
34+
35+
## 桌面和平板
36+
37+
<img src="https://github.com/succlz123/AcFun-Client-Multiplatform/blob/master/screenshot/1.png?raw=true" width="750" height="500"/><br/>
38+
39+
## 手机
40+
<img src="https://github.com/succlz123/AcFun-Client-Multiplatform/blob/master/screenshot/9.png?raw=true" width="360" height="800"/><br/>
41+
42+
## 下载
43+
44+
<img src="https://github.com/succlz123/AcFun-Client-Multiplatform/blob/master/screenshot/15.png?raw=true" width="750" height="500"/><br/>
45+
46+
## 播放和弹幕
47+
<img src="https://github.com/succlz123/AcFun-Client-Multiplatform/blob/master/screenshot/12.png?raw=true" width="750" height="500"/><br/>

android/.idea/.gitignore

Lines changed: 3 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

android/.idea/gradle.xml

Lines changed: 17 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

android/.idea/misc.xml

Lines changed: 4 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

android/.idea/vcs.xml

Lines changed: 6 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

android/build.gradle.kts

Lines changed: 73 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,73 @@
1+
plugins {
2+
id("org.jetbrains.compose")
3+
id("com.android.application")
4+
kotlin("android")
5+
}
6+
7+
group = "io.github.succlz123"
8+
version = "1.0.3"
9+
10+
repositories {
11+
mavenCentral()
12+
google()
13+
google()
14+
maven("https://jitpack.io")
15+
}
16+
17+
dependencies {
18+
implementation(project(":shared"))
19+
implementation("androidx.activity:activity-compose:1.6.0")
20+
implementation("androidx.compose.material:material:1.2.1")
21+
implementation("androidx.compose.foundation:foundation:1.2.1")
22+
}
23+
24+
android {
25+
compileSdk = 33
26+
defaultConfig {
27+
applicationId = "org.succlz123.app.acfun"
28+
minSdk = 24
29+
targetSdk = 30
30+
versionCode = 3
31+
versionName = "1.0.3"
32+
33+
// resourceConfigurations += ["en", "zh"]
34+
}
35+
compileOptions {
36+
sourceCompatibility = JavaVersion.VERSION_1_8
37+
targetCompatibility = JavaVersion.VERSION_1_8
38+
}
39+
kotlinOptions {
40+
jvmTarget = "1.8"
41+
}
42+
43+
signingConfigs {
44+
getByName("debug") {
45+
storeFile = file("${project.rootDir}/security/android-debug.keystore")
46+
storePassword = "android"
47+
keyAlias = "key"
48+
keyPassword = "android"
49+
}
50+
register("release") {
51+
storeFile = file("${project.rootDir}/security/android-debug.keystore")
52+
storePassword = "android"
53+
keyAlias = "key"
54+
keyPassword = "android"
55+
}
56+
}
57+
buildTypes {
58+
getByName("debug") {
59+
applicationIdSuffix = ".debug"
60+
signingConfig = signingConfigs.getByName("debug")
61+
isMinifyEnabled = false
62+
}
63+
getByName("release") {
64+
isMinifyEnabled = false
65+
isDebuggable = false
66+
ndk {
67+
abiFilters += "arm64-v8a"
68+
}
69+
signingConfig = signingConfigs.getByName("release")
70+
proguardFiles(getDefaultProguardFile("proguard-android.txt"), "proguard-rules.txt")
71+
}
72+
}
73+
}
Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
<?xml version="1.0" encoding="utf-8"?>
2+
<manifest xmlns:android="http://schemas.android.com/apk/res/android" package="org.succlz123.app.acfun">
3+
4+
<uses-permission android:name="android.permission.INTERNET"/>
5+
<uses-permission android:name="android.permission.ACCESS_WIFI_STATE"/>
6+
<uses-permission android:name="android.permission.READ_EXTERNAL_STORAGE"/>
7+
<uses-permission android:name="android.permission.REQUEST_INSTALL_PACKAGES"/>
8+
9+
<application
10+
android:allowBackup="false"
11+
android:supportsRtl="true"
12+
android:name="org.succlz123.app.acfun.MainApplication"
13+
android:label="AcFun"
14+
android:icon="@mipmap/ic_launcher_round"
15+
android:largeHeap="true"
16+
android:theme="@style/Theme.AppCompat.Light.NoActionBar">
17+
<activity android:name="org.succlz123.app.acfun.MainActivity" android:exported="true">
18+
<intent-filter>
19+
<action android:name="android.intent.action.MAIN"/>
20+
<category android:name="android.intent.category.LAUNCHER"/>
21+
</intent-filter>
22+
</activity>
23+
</application>
24+
</manifest>
Lines changed: 36 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,36 @@
1+
package org.succlz123.app.acfun
2+
3+
import android.os.Build
4+
import android.os.Bundle
5+
import android.view.MotionEvent
6+
import android.view.WindowManager
7+
import androidx.activity.compose.setContent
8+
import androidx.appcompat.app.AppCompatActivity
9+
import org.succlz123.lib.screen.ScreenContainer
10+
11+
class MainActivity : AppCompatActivity() {
12+
13+
override fun onCreate(savedInstanceState: Bundle?) {
14+
super.onCreate(savedInstanceState)
15+
16+
window.addFlags(WindowManager.LayoutParams.FLAG_KEEP_SCREEN_ON)
17+
window.setFlags(WindowManager.LayoutParams.FLAG_FULLSCREEN, WindowManager.LayoutParams.FLAG_FULLSCREEN)
18+
val decorView = window.decorView
19+
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.P) {
20+
window.attributes.layoutInDisplayCutoutMode =
21+
WindowManager.LayoutParams.LAYOUT_IN_DISPLAY_CUTOUT_MODE_SHORT_EDGES
22+
}
23+
toggleHideBar(decorView)
24+
25+
setContent {
26+
ScreenContainer(this, this, this, this) {
27+
SharedMainContent()
28+
}
29+
}
30+
}
31+
32+
override fun onTouchEvent(event: MotionEvent?): Boolean {
33+
return super.onTouchEvent(event)
34+
}
35+
}
36+
Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
package org.succlz123.app.acfun
2+
3+
import android.app.Application
4+
import org.succlz123.hohoplayer.config.PlayerConfig
5+
import org.succlz123.hohoplayer.core.player.ext.exo.ExoMediaPlayer
6+
import org.succlz123.lib.app.AppContentHolder
7+
8+
class MainApplication : Application() {
9+
10+
override fun onCreate() {
11+
super.onCreate()
12+
AppContentHolder.init(this)
13+
ExoMediaPlayer.addThis(true)
14+
PlayerConfig.init(this, true)
15+
PlayerConfig.isUseDefaultNetworkEventProducer = true
16+
}
17+
}

0 commit comments

Comments
 (0)