Skip to content
This repository has been archived by the owner on Apr 28, 2022. It is now read-only.

Commit

Permalink
Update Amazon In-App version. fix #456
Browse files Browse the repository at this point in the history
  • Loading branch information
RomanZhilich committed Mar 2, 2015
1 parent 055abf0 commit a052fad
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 24 deletions.
4 changes: 2 additions & 2 deletions library/build.gradle
Expand Up @@ -26,7 +26,7 @@ android {
minSdkVersion project.minSdkVersion
targetSdkVersion project.targetSdkVersion
versionCode 10
versionName '0.9.8.5-SNAPSHOT'
versionName '0.9.8.6'
}

lintOptions {
Expand All @@ -49,7 +49,7 @@ android {
dependencies {
compile fileTree(dir: 'libs', include: '*.jar')
compile 'com.intellij:annotations:12.0'
provided 'com.amazon:in-app-purchasing:2.0.1'
provided 'com.amazon:in-app-purchasing:2.0.61'
provided 'com.braintree:fortumo-in-app:9.1.2'

androidTestCompile 'org.robolectric:robolectric:2.3'
Expand Down
22 changes: 1 addition & 21 deletions library/src/main/java/org/onepf/oms/OpenIabHelper.java
Expand Up @@ -275,27 +275,7 @@ public Appstore get() {
@NotNull
@Override
public Appstore get() {
return new AmazonAppstore(new ContextWrapper(context.getApplicationContext()){
@Override
public Context getApplicationContext() {
return this;
}

@Override
public ComponentName startService(final Intent intent) {
final List<ResolveInfo> infos = getPackageManager().queryIntentServices(intent, 0);
if (CollectionUtils.isEmpty(infos)) {
return super.startService(intent);
}
final ResolveInfo serviceInfo = infos.get(0);
final String packageName = serviceInfo.serviceInfo.packageName;
final String className = serviceInfo.serviceInfo.name;
final ComponentName component = new ComponentName(packageName, className);
final Intent explicitIntent = new Intent(intent);
explicitIntent.setComponent(component);
return super.startService(explicitIntent);
}
});
return new AmazonAppstore(context);
}
});

Expand Down
2 changes: 1 addition & 1 deletion samples/trivialdrive/build.gradle
Expand Up @@ -42,5 +42,5 @@ dependencies {
compile project(':OpenIab Library')
// compile 'org.onepf:openiab:0.9.8.1'
compile 'com.braintree:fortumo-in-app:9.1.2'
compile 'com.amazon:in-app-purchasing:2.0.1'
compile 'com.amazon:in-app-purchasing:2.0.61'
}

0 comments on commit a052fad

Please sign in to comment.