-
Notifications
You must be signed in to change notification settings - Fork 2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Integrate the Google Play Billing Library into engine #17836
Conversation
|
* 这个字段已经废弃。 | ||
* 看看SERVICE_UNAVAILABLE将使用哪一个来代替此代码。 | ||
*/ | ||
SERVICE_TIMEOUT = -3, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This field is marked as deprecated in the google docs, does it need to be removed?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yep, i think should remove it. But it is better to listen to the google guys' opinions too.
export class GooglePlayBilling { | ||
private _eventTarget: EventTarget = new EventTarget(); | ||
constructor () { | ||
if (!JSB || !jsb.billing) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Return if non-JSB or jsb.billing is null, only in android platform jsb.billing is not null
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should only work on google play build target.
2. Adjust the file name
@cocos-robot run test cases |
cocos/native-binding/index.ts
Outdated
*/ | ||
readonly signature: string; | ||
|
||
readonly toStr: string; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The name should be toString, but ts has an internal toString, so it's changed to toStr.
jintArray result = env->NewIntArray(size); | ||
jint* buf = new jint[size]; | ||
for (int i = 0; i < size; ++i) { | ||
buf[i] = productDetailsList[i]->hashCode; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Finding objects in Java using hashCode
cocos/native-binding/index.ts
Outdated
* @en Represents the available purchase plans to buy a subscription product. | ||
* @zh 代表一次性购买产品的报价详情。 | ||
*/ | ||
readonly hashCode: number; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is the comment for hashCode
wrong?
cocos/native-binding/index.ts
Outdated
*/ | ||
readonly title: string; | ||
|
||
readonly toStr: string; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Missing API comment for toStr
|
||
bool jsb_register_all_billing(se::Object* obj) { // NOLINT | ||
se::Value nsVal; | ||
if (!obj->getProperty("jsb", &nsVal, true)) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should use another namespace, like gp
or googleplay
* fix TypedArray set * Fix TypedArrayTemp::set function templates
* [v3.8.5] Remove unused baidu platform adapter. * Update minigame/README.md
* feat: add flags config * feat: update doc
…) (cocos#17851) Co-authored-by: cocos-robot <[email protected]>
…) (cocos#17850) Co-authored-by: cocos-robot <[email protected]>
…cos#17849) Co-authored-by: lbq <[email protected]>
… INT format. (cocos#17858) * setInstancedAttribute * Add copyTypedArray * Fix Model::setInstancedAttribute and SubModule::setInstancedAttribute. --------- Co-authored-by: James Chen <[email protected]>
* [v3.8.5] Mangle private properties in touch-manager.ts * Fix eslint errors in mouse-input.ts
…l help treeshaking. (cocos#17853)
…World _animatedBodies container if its type was changed. (cocos#17873)
* Improvement of openharmony's editbox (cocos#17042) * Improvement of openharmony's editbox * Remove redundant header file --------- Co-authored-by: qiuguohua <[email protected]> # Conflicts: # templates/openharmony/entry/src/main/cpp/types/libcocos/index.d.ts # templates/openharmony/entry/src/main/ets/components/EditBoxDialog.ets # templates/openharmony/entry/src/main/ets/pages/index.ets # templates/openharmony/entry/src/main/ets/workers/cocos_worker.ts * Upgrade the openharmony API to 12 * Remove debugging information * Fix some bugs in the ark engine Fix some issues with jsvm * Release module_info * Fix std::any_of return value not being used --------- Co-authored-by: qiuguohua <[email protected]>
2. add vendor module 3. Fix some problems of google play.
Re: #
https://developer.android.com/google/play/billing/integrate
https://developer.android.com/reference/com/android/billingclient/api/BillingClient?_gl=1*11tcdon*_up*MQ..*_ga*MjcyNzYxMzIuMTczMTM3NTA0MQ..*_ga_6HH9YJMN9M*MTczMTM3NTA0MS4xLjAuMTczMTM3NTA0MS4wLjAuNzA1NTQwMDMy
Changelog
Continuous Integration
This pull request:
Compatibility Check
This pull request: