1
0
Fork 0
mirror of https://github.com/juce-framework/JUCE.git synced 2026-01-10 23:44:24 +00:00

Demos: Fix some build issues in demos with more warnings enabled

This commit is contained in:
reuk 2020-03-19 19:20:18 +00:00
parent 12765e3761
commit bbd2184e3b
13 changed files with 102 additions and 131 deletions

View file

@ -100,7 +100,7 @@ struct InAppPurchases::Pimpl : public SKDelegateAndPaymentObserver
[download retain];
}
~DownloadImpl()
~DownloadImpl() override
{
[download release];
}
@ -109,10 +109,10 @@ struct InAppPurchases::Pimpl : public SKDelegateAndPaymentObserver
String getContentVersion() const override { return nsStringToJuce (download.contentVersion); }
#if JUCE_IOS
int64 getContentLength() const override { return download.contentLength; }
int64 getContentLength() const override { return download.expectedContentLength; }
Status getStatus() const override { return SKDownloadStateToDownloadStatus (download.downloadState); }
#else
int64 getContentLength() const override { return [download.contentLength longLongValue]; }
int64 getContentLength() const override { return download.expectedContentLength; }
Status getStatus() const override { return SKDownloadStateToDownloadStatus (download.state); }
#endif
@ -180,7 +180,7 @@ struct InAppPurchases::Pimpl : public SKDelegateAndPaymentObserver
//==============================================================================
Pimpl (InAppPurchases& p) : owner (p) { [[SKPaymentQueue defaultQueue] addTransactionObserver: delegate.get()]; }
~Pimpl() noexcept { [[SKPaymentQueue defaultQueue] removeTransactionObserver: delegate.get()]; }
~Pimpl() noexcept override { [[SKPaymentQueue defaultQueue] removeTransactionObserver: delegate.get()]; }
//==============================================================================
bool isInAppPurchasesSupported() const { return true; }
@ -567,7 +567,8 @@ struct InAppPurchases::Pimpl : public SKDelegateAndPaymentObserver
#endif
// TODO: use juce URL here
auto storeRequest = [NSMutableURLRequest requestWithURL: [NSURL URLWithString: nsStringLiteral (storeURL)]];
auto* urlPtr = [NSURL URLWithString: nsStringLiteral (storeURL)];
auto storeRequest = [NSMutableURLRequest requestWithURL: urlPtr];
[storeRequest setHTTPMethod: nsStringLiteral ("POST")];
[storeRequest setHTTPBody: requestData];