forked from masuidrive/TiStoreKit
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
d215b77
commit cc730fe
Showing
5 changed files
with
134 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
/** | ||
* Appcelerator Titanium Mobile | ||
* Copyright (c) 2009-2010 by Appcelerator, Inc. All Rights Reserved. | ||
* Licensed under the terms of the Apache Public License | ||
* Please see the LICENSE included with this distribution for details. | ||
*/ | ||
#import "TiProxy.h" | ||
#import <StoreKit/StoreKit.h> | ||
|
||
@interface Product : TiProxy { | ||
|
||
@private | ||
SKProduct* product; | ||
} | ||
|
||
-(id)_initWithPageContext:(id<TiEvaluator>)context product:(SKProduct*)product_; | ||
|
||
|
||
@end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,55 @@ | ||
/** | ||
* Appcelerator Titanium Mobile | ||
* Copyright (c) 2009-2010 by Appcelerator, Inc. All Rights Reserved. | ||
* Licensed under the terms of the Apache Public License | ||
* Please see the LICENSE included with this distribution for details. | ||
*/ | ||
|
||
#import "Product.h" | ||
|
||
#import "TiUtils.h" | ||
|
||
@implementation Product | ||
|
||
-(id)_initWithPageContext:(id<TiEvaluator>)context | ||
product:(SKProduct*)product_ | ||
{ | ||
if (self = [super _initWithPageContext:context]) { | ||
product = [product_ retain]; | ||
} | ||
return self; | ||
} | ||
|
||
-(void)dealloc | ||
{ | ||
[product release]; | ||
[super dealloc]; | ||
} | ||
|
||
-(id)productIdentifier | ||
{ | ||
return [[[product productIdentifier] retain] autorelease]; | ||
} | ||
|
||
-(id)localizedDescription | ||
{ | ||
return [[[product localizedDescription] retain] autorelease]; | ||
} | ||
|
||
-(id)price | ||
{ | ||
return [[[product price] retain] autorelease]; | ||
} | ||
|
||
-(id)localizedTitle | ||
{ | ||
return [[[product localizedTitle] retain] autorelease]; | ||
} | ||
|
||
-(id)priceLocale | ||
{ | ||
return [[[[product priceLocale] localeIdentifier] retain] autorelease]; | ||
} | ||
|
||
|
||
@end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters