0
我想在谷歌播放中上传Android应用程序(.apk),是否需要在付费应用程序中拥有(.apk)的许可证密钥。如果是,为什么需要它?关于Google Play中的Android应用程序
MyLicenseCheckerCallback抛出它应该实现的错误,然后超类型的方法。 它说允许()必须通过一个整数参数,哪个参数应该通过 你可以建议我一些帮助。
private class MyLicenseCheckerCallback implements LicenseCheckerCallback {
@Override
public void allow() {
if (isFinishing()) {
// Don't update UI if Activity is finishing.
return;
}
// Should allow user access.
startMainActivity();
}
@Override
public void applicationError(ApplicationErrorCode errorCode) {
if (isFinishing()) {
// Don't update UI if Activity is finishing.
return;
}
// This is a polite way of saying the developer made a mistake
// while setting up or calling the license checker library.
// Please examine the error code and fix the error.
toast("Error: " + errorCode.name());
startMainActivity();
}
@Override
public void dontAllow() {
if (isFinishing()) {
// Don't update UI if Activity is finishing.
return;
}
// Should not allow access. In most cases, the app should assume
// the user has access unless it encounters this. If it does,
// the app should inform the user of their unlicensed ways
// and then either shut down the app or limit the user to a
// restricted set of features.
// In this example, we show a dialogue that takes the user to Market.
showDialog(0);
}
}
如何在(.apk)中添加许可证密钥? –
hai Gaddiel请查看我更新的答案!!!!!! 1 – AndroidEnthusiastic
请确认上述内容。 –