This commit is contained in:
Dirk Hohndel 2025-01-21 11:26:31 +01:00 committed by GitHub
commit 1cabe8d4d6
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
3 changed files with 7 additions and 5 deletions

View file

@ -18,6 +18,7 @@
android:label="@string/app_name"
android:theme="@style/AppTheme"
android:launchMode="singleTop"
android:exported="true"
android:windowSoftInputMode="adjustResize"
android:screenOrientation="unspecified" >
<intent-filter>
@ -88,8 +89,8 @@
</provider>
</application>
<uses-sdk android:minSdkVersion="21"
android:targetSdkVersion="30" />
<uses-sdk android:minSdkVersion="26"
android:targetSdkVersion="34" />
<supports-screens
android:anyDensity="true"

View file

@ -1,5 +1,5 @@
/*******************************************************
* SPDX-License-Identifier: GPL-2.0
* SPDX-License-Identifier: GPL-2.0
* Subsurface-Mobile own Gradle build spec. Derived from
* the one supplied by Qt.
*******************************************************/
@ -29,7 +29,7 @@ apply plugin: 'com.android.application'
dependencies {
implementation fileTree(dir: 'libs', include: ['*.jar'])
implementation 'com.github.mik3y:usb-serial-for-android:3.8.1'
implementation 'com.android.support:support-v4:28.0.0'
implementation 'androidx.core:core:1.15.0'
}
android {

View file

@ -30,6 +30,7 @@ import android.content.pm.ResolveInfo;
import java.util.ArrayList;
import java.util.Collections;
import java.util.Comparator;
import androidx.core.content.ContextCompat;
// this is the main class that will be run at start
public class SubsurfaceMobileActivity extends QtActivity
@ -129,7 +130,7 @@ public class SubsurfaceMobileActivity extends QtActivity
// Register the usb permission intent filter.
IntentFilter filter = new IntentFilter("org.subsurfacedivelog.mobile.USB_PERMISSION");
registerReceiver(usbReceiver, filter);
ContextCompat.registerReceiver(usbReceiver, filter, ContextCompat.RECEIVER_EXPORTED);
} // onCreate