Skip to content

Commit

Permalink
Add files via upload
Browse files Browse the repository at this point in the history
  • Loading branch information
Soviet-Ball authored Apr 6, 2024
1 parent f7b0f10 commit 1af6ee1
Show file tree
Hide file tree
Showing 80 changed files with 11,206 additions and 0 deletions.
59 changes: 59 additions & 0 deletions MediaPlayer/MediaPlayer.pro
Original file line number Diff line number Diff line change
@@ -0,0 +1,59 @@
QT += core gui multimedia multimediawidgets core-private gui-private multimedia-private concurrent
greaterThan(QT_MAJOR_VERSION, 4): QT += widgets
CONFIG += resources_big
DEFINES += QT_MESSAGELOGCONTEXT
msvc {
QMAKE_CFLAGS += /utf-8
QMAKE_CXXFLAGS += /utf-8
}
windows {
RC_ICONS = player.ico
RESOURCES += resource_common.qrc
}
linux {
RESOURCES += \
resource_common.qrc
}
unix {
RESOURCES += \
resource_common.qrc
}
android {
LIBS += -ljnigraphics
DISTFILES += \
android/AndroidManifest.xml \
android/build.gradle \
android/gradle.properties \
android/gradle/wrapper/gradle-wrapper.jar \
android/gradle/wrapper/gradle-wrapper.properties \
android/gradlew \
android/gradlew.bat \
android/res/values/libs.xml \
android/src/com/MainActivity.java
}
CONFIG += c++17
SOURCES += \
main.cpp \
mediawidget.cpp \
myfiledialog.cpp \
playerwidget.cpp \
settingwidget.cpp \
widget.cpp
HEADERS += \
api.h \
mediawidget.h \
myfiledialog.h \
mytaskbarprogress.h \
playerwidget.h \
settingwidget.h \
widget.h
qnx: target.path = /tmp/$${TARGET}/bin
else: unix:!android: target.path = /opt/$${TARGET}/bin
!isEmpty(target.path): INSTALLS += target
contains(ANDROID_TARGET_ARCH,arm64-v8a) {
ANDROID_PACKAGE_SOURCE_DIR = \
$$PWD/android
}

DISTFILES += \
android/res/xml/filepaths.xml
1,601 changes: 1,601 additions & 0 deletions MediaPlayer/MediaPlayer.pro.user

Large diffs are not rendered by default.

31 changes: 31 additions & 0 deletions MediaPlayer/android/AndroidManifest.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
<?xml version="1.0"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android" package="com.sovietball.mediaplayer" android:installLocation="auto" android:versionCode="-- %%INSERT_VERSION_CODE%% --" android:versionName="-- %%INSERT_VERSION_NAME%% --">

<!-- %%INSERT_FEATURES -->
<supports-screens android:anyDensity="true" android:largeScreens="true" android:normalScreens="true" android:smallScreens="true"/>
<application android:name="org.qtproject.qt.android.bindings.QtApplication" android:hardwareAccelerated="true" android:label="-- %%INSERT_APP_NAME%% --" android:requestLegacyExternalStorage="true" android:allowNativeHeapPointerTagging="false" android:allowBackup="true" android:fullBackupOnly="false">
<activity android:name="com.MyActivity.MainActivity" android:configChanges="orientation|uiMode|screenLayout|screenSize|smallestScreenSize|layoutDirection|locale|fontScale|keyboard|keyboardHidden|navigation|mcc|mnc|density" android:label="-- %%INSERT_APP_NAME%% --" android:launchMode="singleTop" android:screenOrientation="unspecified" android:exported="true">
<intent-filter>
<action android:name="android.intent.action.MAIN"/>
<category android:name="android.intent.category.LAUNCHER"/>
</intent-filter>
<meta-data android:name="android.app.lib_name" android:value="-- %%INSERT_APP_LIB_NAME%% --"/>
<meta-data android:name="android.app.arguments" android:value="-- %%INSERT_APP_ARGUMENTS%% --"/>
<meta-data android:name="android.app.extract_android_style" android:value="minimal"/>
</activity>
</application>
<uses-permission android:name="android.permission.READ_EXTERNAL_STORAGE"/>
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE"/>
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE"/>
<uses-permission android:name="android.permission.INTERNET"/>
<uses-permission android:name="android.permission.ACCESS_NOTIFICATION_POLICY"/>
<uses-permission android:name="android.permission.MANAGE_EXTERNAL_STORAGE"/>
<uses-permission android:name="android.permission.GET_TASKS"/>
<uses-permission android:name="android.permission.CHANGE_CONFIGURATION"/>
<uses-permission android:name="android.permission.WRITE_INPUT_STATE"/>
<uses-permission android:name="android.permission.ACCESS_CHECKIN_PROPERTIES"/>
<uses-permission android:name="android.permission.INSTALL_PACKAGES"/>
<uses-permission android:name="android.permission.VIBRATE"/>
<uses-permission android:name="android.permission.POST_NOTIFICATIONS"/>
<!-- %%INSERT_PERMISSIONS -->
</manifest>
81 changes: 81 additions & 0 deletions MediaPlayer/android/build.gradle
Original file line number Diff line number Diff line change
@@ -0,0 +1,81 @@
buildscript {
repositories {
google()
mavenCentral()
}

dependencies {
classpath 'com.android.tools.build:gradle:7.0.2'
}
}

repositories {
google()
mavenCentral()
}

apply plugin: 'com.android.application'

dependencies {
implementation fileTree(dir: 'libs', include: ['*.jar', '*.aar'])
}

android {
/*******************************************************
* The following variables:
* - androidBuildToolsVersion,
* - androidCompileSdkVersion
* - qtAndroidDir - holds the path to qt android files
* needed to build any Qt application
* on Android.
*
* are defined in gradle.properties file. This file is
* updated by QtCreator and androiddeployqt tools.
* Changing them manually might break the compilation!
*******************************************************/

compileSdkVersion androidCompileSdkVersion.toInteger()
buildToolsVersion androidBuildToolsVersion
ndkVersion androidNdkVersion

// Extract native libraries from the APK
packagingOptions.jniLibs.useLegacyPackaging true

sourceSets {
main {
manifest.srcFile 'AndroidManifest.xml'
java.srcDirs = [qtAndroidDir + '/src', 'src', 'java']
aidl.srcDirs = [qtAndroidDir + '/src', 'src', 'aidl']
res.srcDirs = [qtAndroidDir + '/res', 'res']
resources.srcDirs = ['resources']
renderscript.srcDirs = ['src']
assets.srcDirs = ['assets']
jniLibs.srcDirs = ['libs']
}
}

tasks.withType(JavaCompile) {
options.incremental = true
}

compileOptions {
sourceCompatibility JavaVersion.VERSION_1_8
targetCompatibility JavaVersion.VERSION_1_8
}

lintOptions {
abortOnError false
}

// Do not compress Qt binary resources file
aaptOptions {
noCompress 'rcc'
}

defaultConfig {
resConfig "en"
minSdkVersion qtMinSdkVersion
targetSdkVersion qtTargetSdkVersion
ndk.abiFilters = qtTargetAbiList.split(",")
}
}
13 changes: 13 additions & 0 deletions MediaPlayer/android/gradle.properties
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
# Project-wide Gradle settings.
# For more details on how to configure your build environment visit
# http://www.gradle.org/docs/current/userguide/build_environment.html
# Specifies the JVM arguments used for the daemon process.
# The setting is particularly useful for tweaking memory settings.
org.gradle.jvmargs=-Xmx2500m -XX:MaxMetaspaceSize=512m -XX:+HeapDumpOnOutOfMemoryError -Dfile.encoding=UTF-8

# Enable building projects in parallel
org.gradle.parallel=true
# Gradle caching allows reusing the build artifacts from a previous
# build with the same inputs. However, over time, the cache size will
# grow. Uncomment the following line to enable it.
#org.gradle.caching=true
Binary file not shown.
5 changes: 5 additions & 0 deletions MediaPlayer/android/gradle/wrapper/gradle-wrapper.properties
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-7.4-bin.zip
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists
Loading

0 comments on commit 1af6ee1

Please sign in to comment.