Skip to content

Commit 4cd97c3

Browse files
Merge pull request #477 from TakayukiHoshi1984/modify_scoped_strage
Android10のScopedStorageにあわせた修正
2 parents ebdbe5f + 15f8dd4 commit 4cd97c3

File tree

61 files changed

+286
-250
lines changed

Some content is hidden

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

61 files changed

+286
-250
lines changed

.gitignore

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@
55
*.apk
66
*.ap_
77
.externalNativeBuild
8+
.cxx/
89

910
# Files for the Dalvik VM
1011
*.dex
@@ -108,7 +109,7 @@ local.properties
108109
# PDT-specific
109110
.buildpath
110111

111-
# sbteclipse plugin
112+
# sbteclipse plugin
112113
.target
113114

114115
# TeXlipse plugin
@@ -301,4 +302,4 @@ DerivedData
301302
ant.properties
302303
build.xml
303304
HVCW.jar
304-
RobotLibrary.jar
305+
RobotLibrary.jar

dConnectDevicePlugin/dConnectDeviceAndroidWear/app/build.gradle

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ repositories {
88

99
dependencies {
1010
implementation fileTree(include: '*.jar', dir: 'libs')
11-
implementation 'org.deviceconnect:dconnect-device-plugin-sdk:2.5.2'
11+
implementation 'org.deviceconnect:dconnect-device-plugin-sdk:2.8.0'
1212
implementation 'com.android.support:multidex:1.0.3'
1313
implementation 'com.google.android.gms:play-services-wearable:15.0.1'
1414

@@ -17,7 +17,7 @@ dependencies {
1717

1818
android {
1919

20-
compileSdkVersion 28
20+
compileSdkVersion 29
2121

2222
def getVersionName = { ->
2323
def version
@@ -33,7 +33,7 @@ android {
3333
defaultConfig {
3434
applicationId "org.deviceconnect.android.deviceplugin.wear"
3535
minSdkVersion 23
36-
targetSdkVersion 28
36+
targetSdkVersion 29
3737
versionCode 1
3838
versionName getVersionName()
3939
multiDexEnabled true
@@ -69,4 +69,8 @@ android {
6969
checkReleaseBuilds false
7070
abortOnError false
7171
}
72+
compileOptions {
73+
sourceCompatibility JavaVersion.VERSION_1_8
74+
targetCompatibility JavaVersion.VERSION_1_8
75+
}
7276
}

dConnectDevicePlugin/dConnectDeviceAndroidWear/wear-app/build.gradle

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,11 +2,11 @@ apply plugin: 'com.android.application'
22

33

44
android {
5-
compileSdkVersion 28
5+
compileSdkVersion 29
66
defaultConfig {
77
applicationId "org.deviceconnect.android.deviceplugin.wear"
88
minSdkVersion 23
9-
targetSdkVersion 28
9+
targetSdkVersion 29
1010
versionCode 1
1111
versionName '2.0.0'
1212
}
@@ -34,7 +34,10 @@ android {
3434
checkReleaseBuilds false
3535
abortOnError false
3636
}
37-
37+
compileOptions {
38+
sourceCompatibility JavaVersion.VERSION_1_8
39+
targetCompatibility JavaVersion.VERSION_1_8
40+
}
3841
}
3942

4043
dependencies {

dConnectDevicePlugin/dConnectDeviceChromeCast/app/build.gradle

Lines changed: 9 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
apply plugin: 'com.android.application'
22

33
android {
4-
compileSdkVersion 26
4+
compileSdkVersion 28
55

66
def getVersionName = { ->
77
def version
@@ -17,7 +17,7 @@ android {
1717
defaultConfig {
1818
applicationId "org.deviceconnect.android.deviceplugin.chromecast"
1919
minSdkVersion 14
20-
targetSdkVersion 26
20+
targetSdkVersion 28
2121
versionCode 1
2222
versionName getVersionName()
2323
}
@@ -48,6 +48,10 @@ android {
4848
tasks.withType(JavaCompile) {
4949
options.encoding = 'UTF-8'
5050
}
51+
compileOptions {
52+
sourceCompatibility JavaVersion.VERSION_1_8
53+
targetCompatibility JavaVersion.VERSION_1_8
54+
}
5155
}
5256

5357
repositories {
@@ -59,9 +63,9 @@ repositories {
5963

6064
dependencies {
6165
implementation fileTree(include: '*.jar', dir: 'libs')
62-
implementation 'org.deviceconnect:dconnect-device-plugin-sdk:2.5.1'
63-
implementation 'com.android.support:appcompat-v7:26.1.0'
64-
implementation 'com.android.support:mediarouter-v7:26.1.0'
66+
implementation 'org.deviceconnect:dconnect-device-plugin-sdk:2.8.0'
67+
implementation 'com.android.support:appcompat-v7:28.0.0'
68+
implementation 'com.android.support:mediarouter-v7:28.0.0'
6569
implementation 'com.google.android.gms:play-services-cast-framework:11.8.0'
6670
}
6771

dConnectDevicePlugin/dConnectDeviceFaBo/app/build.gradle

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
apply plugin: 'com.android.library'
22

33
android {
4-
compileSdkVersion 26
4+
compileSdkVersion 29
55

66
def getVersionName = { ->
77
def version
@@ -16,7 +16,7 @@ android {
1616

1717
defaultConfig {
1818
minSdkVersion 16
19-
targetSdkVersion 26
19+
targetSdkVersion 29
2020
versionCode 1
2121
versionName getVersionName()
2222
}
@@ -41,6 +41,10 @@ android {
4141
tasks.withType(JavaCompile) {
4242
options.encoding = 'UTF-8'
4343
}
44+
compileOptions {
45+
sourceCompatibility JavaVersion.VERSION_1_8
46+
targetCompatibility JavaVersion.VERSION_1_8
47+
}
4448
}
4549

4650
repositories {
@@ -52,7 +56,7 @@ repositories {
5256

5357
dependencies {
5458
implementation fileTree(include: '*.jar', dir: 'libs')
55-
api 'org.deviceconnect:dconnect-device-plugin-sdk:2.5.2'
59+
api 'org.deviceconnect:dconnect-device-plugin-sdk:2.8.0'
5660
androidTestImplementation 'com.android.support.test:testing-support-lib:0.1'
5761
androidTestImplementation 'org.hamcrest:hamcrest-library:1.3'
5862
}

dConnectDevicePlugin/dConnectDeviceFaBo/app/src/main/java/org/deviceconnect/android/deviceplugin/fabo/FaBoDeviceService.java

Lines changed: 2 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,8 @@
2727
import org.deviceconnect.android.message.DConnectMessageService;
2828
import org.deviceconnect.android.profile.DConnectProfile;
2929
import org.deviceconnect.android.profile.SystemProfile;
30-
import org.deviceconnect.android.profile.spec.DConnectProfileSpec;
30+
import org.deviceconnect.android.profile.spec.DConnectServiceSpec;
31+
import org.deviceconnect.android.profile.spec.models.Swagger;
3132
import org.deviceconnect.android.service.DConnectService;
3233

3334
import java.util.ArrayList;
@@ -269,12 +270,6 @@ public VirtualService updateServiceData(final ServiceData serviceData) {
269270
DConnectProfile profile = VirtualServiceFactory.createProfile(p);
270271
if (profile != null) {
271272
service.addProfile(profile);
272-
273-
DConnectProfileSpec profileSpec =
274-
getPluginSpec().findProfileSpec(profile.getProfileName().toLowerCase());
275-
if (profileSpec != null) {
276-
profile.setProfileSpec(profileSpec);
277-
}
278273
profile.setContext(this);
279274
}
280275
}

dConnectDevicePlugin/dConnectDeviceFaBo/plugin/build.gradle

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
apply plugin: 'com.android.application'
22

33
android {
4-
compileSdkVersion 26
4+
compileSdkVersion 29
55

66
def getVersionName = { ->
77
def version
@@ -17,7 +17,7 @@ android {
1717
defaultConfig {
1818
applicationId "org.deviceconnect.android.deviceplugin.fabo"
1919
minSdkVersion 16
20-
targetSdkVersion 26
20+
targetSdkVersion 29
2121
versionCode 1
2222
versionName getVersionName()
2323

@@ -44,6 +44,10 @@ android {
4444
tasks.withType(JavaCompile) {
4545
options.encoding = 'UTF-8'
4646
}
47+
compileOptions {
48+
sourceCompatibility JavaVersion.VERSION_1_8
49+
targetCompatibility JavaVersion.VERSION_1_8
50+
}
4751
}
4852

4953
repositories {

dConnectDevicePlugin/dConnectDeviceFaBo/things-plugin/build.gradle

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
apply plugin: 'com.android.application'
22

33
android {
4-
compileSdkVersion 26
4+
compileSdkVersion 29
55

66
def getVersionName = { ->
77
def version
@@ -17,7 +17,7 @@ android {
1717
defaultConfig {
1818
applicationId "org.deviceconnect.android.deviceplugin.fabo"
1919
minSdkVersion 16
20-
targetSdkVersion 26
20+
targetSdkVersion 29
2121
versionCode 1
2222
versionName getVersionName()
2323

@@ -44,6 +44,10 @@ android {
4444
tasks.withType(JavaCompile) {
4545
options.encoding = 'UTF-8'
4646
}
47+
compileOptions {
48+
sourceCompatibility JavaVersion.VERSION_1_8
49+
targetCompatibility JavaVersion.VERSION_1_8
50+
}
4751
}
4852
repositories {
4953
maven { url 'https://raw.githubusercontent.com/DeviceConnect/DeviceConnect-Android/master/dConnectSDK/dConnectSDKForAndroid/repository/' }
@@ -55,5 +59,5 @@ repositories {
5559
dependencies {
5660
implementation fileTree(dir: 'libs', include: ['*.jar'])
5761
implementation project(':app')
58-
compileOnly 'com.google.android.things:androidthings:0.4-devpreview'
62+
compileOnly 'com.google.android.things:androidthings:1.0'
5963
}

dConnectDevicePlugin/dConnectDeviceFaBo/things-plugin/src/main/java/org/deviceconnect/android/deviceplugin/fabo/device/things/FaBoThingsDeviceControl.java

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
import com.google.android.things.pio.Gpio;
88
import com.google.android.things.pio.GpioCallback;
99
import com.google.android.things.pio.I2cDevice;
10-
import com.google.android.things.pio.PeripheralManagerService;
10+
import com.google.android.things.pio.PeripheralManager;
1111

1212
import org.deviceconnect.android.deviceplugin.fabo.BuildConfig;
1313
import org.deviceconnect.android.deviceplugin.fabo.device.FaBoDeviceControl;
@@ -113,7 +113,7 @@ public class FaBoThingsDeviceControl implements FaBoDeviceControl {
113113
/**
114114
* GPIO,I2cなどのデバイスを管理するクラス.
115115
*/
116-
private PeripheralManagerService mManagerService;
116+
private PeripheralManager mManagerService;
117117

118118
/**
119119
* GPIOの処理を行うハンドラ.
@@ -132,7 +132,7 @@ public void initialize() {
132132
Log.i(TAG, "FaBoThingsDeviceControl::initialize");
133133
}
134134

135-
mManagerService = new PeripheralManagerService();
135+
mManagerService = PeripheralManager.getInstance();
136136

137137
initGpio();
138138
}

dConnectDevicePlugin/dConnectDeviceHOGP/plugin/build.gradle

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ apply plugin: 'com.android.application'
22

33
dependencies {
44
implementation fileTree(include: '*.jar', dir: 'libs')
5-
implementation 'org.deviceconnect:dconnect-device-plugin-sdk:2.5.1'
5+
implementation 'org.deviceconnect:dconnect-device-plugin-sdk:2.8.0'
66
}
77

88
repositories {
@@ -14,12 +14,12 @@ repositories {
1414

1515
android {
1616

17-
compileSdkVersion 28
17+
compileSdkVersion 29
1818

1919
defaultConfig {
2020
applicationId "org.deviceconnect.android.deviceplugin.hogp"
2121
minSdkVersion 14
22-
targetSdkVersion 28
22+
targetSdkVersion 29
2323
versionCode 1
2424
versionName '1.0.0'
2525
}
@@ -51,4 +51,9 @@ android {
5151
tasks.withType(JavaCompile) {
5252
options.encoding = 'UTF-8'
5353
}
54+
compileOptions {
55+
sourceCompatibility JavaVersion.VERSION_1_8
56+
targetCompatibility JavaVersion.VERSION_1_8
57+
}
58+
5459
}

0 commit comments

Comments
 (0)