2014-01-25 10:46:46 +01:00
|
|
|
#import "Toast.h"
|
2014-01-25 11:45:10 +01:00
|
|
|
#import "Toast+UIView.h"
|
|
|
|
#import <Cordova/CDV.h>
|
2014-01-25 10:46:46 +01:00
|
|
|
|
|
|
|
@implementation Toast
|
|
|
|
|
|
|
|
- (void)show:(CDVInvokedUrlCommand*)command {
|
|
|
|
|
|
|
|
// TODO pass in
|
|
|
|
NSString *message = @"Hi, this is a test Toast";
|
|
|
|
|
|
|
|
// TODO pass in
|
|
|
|
iToastGravity grv = iToastGravityCenter;
|
|
|
|
|
|
|
|
// TODO pass in
|
|
|
|
NSInteger drTime = iToastDurationShort;
|
|
|
|
|
2014-01-25 11:45:10 +01:00
|
|
|
[self.view makeToast:@"This is a piece of toast."];
|
|
|
|
|
|
|
|
// [[[[iToast makeText:NSLocalizedString(message, @"")]
|
|
|
|
// setGravity:grv offsetLeft:0 offsetTop:0] setDuration:drTime] show];
|
2014-01-25 10:46:46 +01:00
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
@end
|