Added support for iPhone to MGMFFmpeg. Updated settings in Theme Tester. Updated settings in VoiceMac for the Theme Manager. Added the ability to hide icons in themes. Added the ability to change the font in themes. Fixed issue in MGMAddressBook where getting group members is not accurate. Made it so SIP addresses and Email addresses would not be recognized as phone numbers. Added support for 2 step verification. Added the ability to reload the user phone numbers. Added the ability to place the next message at any point in the previous message. Added the ability to do css based on the class of the message view with %MESSAGECLASSES%. Added the ability to get the codecs available and change the top codec in MGMSIP. Made it stop ring back before hanging up. Added initWithRootElement: to MGMXMLDocument. Added initWithName: and initWithName:stringValue: to MGMXMLElement. Added initWithKind:, setStringValue:, and fixed issues with reading attributes value. Made MGMVoiceUser support 2 step verification API, reload the user phones when it becomes active, and display a message if there is no phone numbers in Google Voice. Fixed issue where Google Chat will not appear in the User Phones list. Added a 2 Step Verification Dialog. Added Codec selection in MGMSIPPane. Fixed issues with MGMMultiSMS where it wouldn't alert the user if the message was blank and it wouldn't make the text field non editable. Added support for new SMS protocol to MGMSMSMessageView. Added support in the FFmpeg install script to build for iOS. Added ability to compile for the Simulator only in the PJProject build script. Made iOS and Mac OS final path go to 2 different folders. Updated to Revision 3466 of PJProject.

This commit is contained in:
GRMrGecko 2011-03-21 07:43:56 -05:00
parent 6c767c3082
commit 62734d7fef
86 changed files with 4359 additions and 2989 deletions

View File

@ -176,7 +176,13 @@ typedef struct AVInputFile {
int nb_streams; /* nb streams we are aware of */
} AVInputFile;
@interface MGMFFmpeg : NSObject <NSApplicationDelegate> {
@interface MGMFFmpeg : NSObject
#if !TARGET_OS_IPHONE
#if (MAC_OS_X_VERSION_MAX_ALLOWED >= 1060)
<NSApplicationDelegate>
#endif
#endif
{
id<MGMFFmpegDelegate> delegate;
char **opt_names;
@ -340,7 +346,9 @@ typedef struct AVInputFile {
double previousTime;
BOOL stopConverting;
#if !TARGET_OS_IPHONE
BOOL stoppedByQuit;
#endif
BOOL isConverting;
OptionDef options[102];
@ -361,5 +369,9 @@ typedef struct AVInputFile {
- (void)setInputFile:(NSString *)theFile;
- (void)setInputHandle:(NSFileHandle *)theHandle;
- (void)startConverting;
#if !TARGET_OS_IPHONE
- (NSApplicationTerminateReply)applicationShouldTerminate:(NSApplication *)sender;
#endif
@end
#endif

View File

@ -181,7 +181,9 @@ static BOOL FFmpegRegistered = NO;
input_tmp = NULL;
stopConverting = NO;
#if !TARGET_OS_IPHONE
stoppedByQuit = NO;
#endif
isConverting = NO;
options[0] = (OptionDef){ "f", HAS_ARG, {@selector(opt_format:)}, "force format", "fmt" };
@ -3963,6 +3965,7 @@ fail:
return ret;
}
#if !TARGET_OS_IPHONE
- (NSApplicationTerminateReply)applicationShouldTerminate:(NSApplication *)sender {
if (isConverting) {
stopConverting = YES;
@ -3971,6 +3974,7 @@ fail:
}
return NSTerminateNow;
}
#endif
- (void)startConverting {
[NSThread detachNewThreadSelector:@selector(startConvertingBackground) toTarget:self withObject:nil];
@ -4007,8 +4011,10 @@ fail:
cleanup:
isConverting = NO;
stopConverting = NO;
#if !TARGET_OS_IPHONE
if (stoppedByQuit)
[[NSApplication sharedApplication] replyToApplicationShouldTerminate:YES];
#endif
if ([delegate respondsToSelector:@selector(conversionFinished)])
[delegate conversionFinished];
[pool drain];

View File

@ -21,7 +21,11 @@
@class WebView, MGMThemeManager;
@interface MGMThemeTesterController : NSObject {
@interface MGMThemeTesterController : NSObject
#if (MAC_OS_X_VERSION_MAX_ALLOWED >= 1060)
<NSWindowDelegate>
#endif
{
NSPipe *errorPipe;
IBOutlet NSTextView *errorConsole;
IBOutlet NSWindow *errorConsoleWindow;
@ -41,6 +45,10 @@
IBOutlet NSTextField *IDField;
IBOutlet NSTextField *messageField;
IBOutlet NSPopUpButton *variantsButton;
IBOutlet NSTextField *fontPreview;
IBOutlet NSButton *headerButton;
IBOutlet NSButton *footerButton;
IBOutlet NSButton *iconsButton;
}
- (IBAction)open:(id)sender;
- (IBAction)save:(id)sender;
@ -50,6 +58,11 @@
- (IBAction)chooseYPhoto:(id)sender;
- (IBAction)chooseTPhoto:(id)sender;
- (IBAction)selectFont:(id)sender;
- (IBAction)header:(id)sender;
- (IBAction)footer:(id)sender;
- (IBAction)icons:(id)sender;
- (IBAction)rebuild:(id)sender;
- (IBAction)incoming:(id)sender;
- (IBAction)outgoing:(id)sender;

View File

@ -48,12 +48,21 @@
[messages addObject:[NSDictionary dictionaryWithObjectsAndKeys:@"That sounds good.", MGMIText, @"6:06 PM", MGMITime, [NSNumber numberWithBool:YES], MGMIYou, nil]];
[messages addObject:[NSDictionary dictionaryWithObjectsAndKeys:@"Great, meet you then.", MGMIText, @"6:07 PM", MGMITime, [NSNumber numberWithBool:NO], MGMIYou, nil]];
[[SMSView mainFrame] loadHTMLString:@"<div style=\"text-align: center; font-size: 14pt; font-weight: bold;\">Please open a theme to preview it.</div>" baseURL:nil];
themeManager = [MGMThemeManager new];
NSUserDefaults *defaults = [NSUserDefaults standardUserDefaults];
NSFont *font = [NSFont fontWithName:[defaults objectForKey:MGMTFontName] size:[defaults integerForKey:MGMTFontSize]];
[fontPreview setFont:font];
[fontPreview setStringValue:[NSString stringWithFormat:@"%@ %d", [font fontName], (int)[font pointSize]]];
[headerButton setState:([defaults boolForKey:MGMTShowHeader] ? NSOnState : NSOffState)];
[footerButton setState:([defaults boolForKey:MGMTShowFooter] ? NSOnState : NSOffState)];
[iconsButton setState:([defaults boolForKey:MGMTShowIcons] ? NSOnState : NSOffState)];
[mainWindow makeKeyAndOrderFront:self];
}
- (IBAction)open:(id)sender {
NSOpenPanel *panel = [NSOpenPanel openPanel];
[panel setCanChooseFiles:YES];
[panel setCanChooseDirectories:NO];
[panel setCanChooseDirectories:YES];
[panel setResolvesAliases:YES];
[panel setAllowsMultipleSelection:NO];
[panel setAllowedFileTypes:[NSArray arrayWithObject:@"vmt"]];
@ -64,7 +73,7 @@
[defaults setObject:[[[panel URL] path] stringByDeletingLastPathComponent] forKey:MGMTCurrentThemePath];
[defaults setObject:[[[panel URL] path] lastPathComponent] forKey:MGMTCurrentThemeName];
[defaults setObject:[NSNumber numberWithInt:0] forKey:MGMTCurrentThemeVariant];
if (themeManager!=nil) [themeManager release];
[themeManager release];
NSLog(@"Loading Theme Manager");
themeManager = [MGMThemeManager new];
if (themeManager!=nil) {
@ -157,6 +166,42 @@
}
}
- (IBAction)selectFont:(id)sender {
NSUserDefaults *defaults = [NSUserDefaults standardUserDefaults];
NSFontManager *fontManager = [NSFontManager sharedFontManager];
NSFontPanel *fontPanel = [fontManager fontPanel:YES];
[fontPanel setDelegate:self];
[fontPanel setPanelFont:[NSFont fontWithName:[defaults objectForKey:MGMTFontName] size:[defaults integerForKey:MGMTFontSize]] isMultiple:NO];
[fontPanel makeKeyAndOrderFront:self];
}
- (void)changeFont:(id)sender {
NSUserDefaults *defaults = [NSUserDefaults standardUserDefaults];
NSFont *font = [sender convertFont:[NSFont fontWithName:[defaults objectForKey:MGMTFontName] size:[defaults integerForKey:MGMTFontSize]]];
[defaults setObject:[font fontName] forKey:MGMTFontName];
[defaults setInteger:(int)[font pointSize] forKey:MGMTFontSize];
[fontPreview setFont:font];
[fontPreview setStringValue:[NSString stringWithFormat:@"%@ %d", [font fontName], (int)[font pointSize]]];
}
- (void)windowWillClose:(NSNotification *)notification {
[self rebuild:self];
}
- (void)windowDidResignKey:(NSNotification *)notification {
[[notification object] close];
}
- (IBAction)header:(id)sender {
[[NSUserDefaults standardUserDefaults] setBool:([headerButton state]==NSOnState) forKey:MGMTShowHeader];
[self rebuild:self];
}
- (IBAction)footer:(id)sender {
[[NSUserDefaults standardUserDefaults] setBool:([footerButton state]==NSOnState) forKey:MGMTShowFooter];
[self rebuild:self];
}
- (IBAction)icons:(id)sender {
[[NSUserDefaults standardUserDefaults] setBool:([iconsButton state]==NSOnState) forKey:MGMTShowIcons];
[self rebuild:self];
}
- (IBAction)rebuild:(id)sender {
if (themeManager!=nil) {
[themeManager setVariant:[variantsButton titleOfSelectedItem]];
@ -181,23 +226,33 @@
tPhotoPath = [[tPhotoField stringValue] filePath];
NSMutableDictionary *message = [NSMutableDictionary dictionaryWithDictionary:theMessage];
[message setObject:[[NSNumber numberWithInt:[messages count]-1] stringValue] forKey:MGMIID];
NSMutableArray *classes = [NSMutableArray array];
int type = 1;
if ([[message objectForKey:MGMIYou] boolValue]) {
[classes addObject:MGMTCOutgoing];
type = ([[[messages objectAtIndex:[[message objectForKey:MGMIID] intValue]-1] objectForKey:MGMIYou] boolValue] ? 2 : 1);
if (type==2)
[classes addObject:MGMTCNext];
NSLog(@"Adding Outgoing %@", (type==1 ? @"Content" : @"Next Content"));
[message setObject:yPhotoPath forKey:MGMTPhoto];
[message setObject:NSFullUserName() forKey:MGMTName];
[message setObject:[messageInfo objectForKey:MGMTUserNumber] forKey:MGMIPhoneNumber];
} else {
[classes addObject:MGMTCIncoming];
type = ([[[messages objectAtIndex:[[message objectForKey:MGMIID] intValue]-1] objectForKey:MGMIYou] boolValue] ? 3 : 4);
if (type==4)
[classes addObject:MGMTCNext];
NSLog(@"Adding Incoming %@", (type==3 ? @"Content" : @"Next Content"));
[message setObject:tPhotoPath forKey:MGMTPhoto];
[message setObject:[messageInfo objectForKey:MGMTInName] forKey:MGMTName];
[message setObject:[messageInfo objectForKey:MGMIPhoneNumber] forKey:MGMIPhoneNumber];
}
[classes addObject:MGMTCMessage];
if (![[NSUserDefaults standardUserDefaults] boolForKey:MGMTShowIcons])
[classes addObject:MGMTCHideIcons];
NSDateFormatter *formatter = [[NSDateFormatter new] autorelease];
[formatter setDateFormat:[[themeManager variant] objectForKey:MGMTDate]];
[SMSView stringByEvaluatingJavaScriptFromString:[NSString stringWithFormat:@"newMessage('%@', '%@', '%@', %@, '%@', '%@', '%@', %d);", [[message objectForKey:MGMIText] javascriptEscape], [[message objectForKey:MGMTPhoto] javascriptEscape], [[message objectForKey:MGMITime] javascriptEscape], [message objectForKey:MGMIID], [[message objectForKey:MGMTName] javascriptEscape], [[[message objectForKey:MGMIPhoneNumber] readableNumber] javascriptEscape], [formatter stringFromDate:[messageInfo objectForKey:MGMITime]], type]];
[SMSView stringByEvaluatingJavaScriptFromString:[NSString stringWithFormat:@"newMessage('%@', '%@', '%@', %@, '%@', '%@', '%@', %d, '%@');", [[themeManager htmlTextFromMessage:message] javascriptEscape], [[message objectForKey:MGMTPhoto] javascriptEscape], [[message objectForKey:MGMITime] javascriptEscape], [message objectForKey:MGMIID], [[message objectForKey:MGMTName] javascriptEscape], [[[message objectForKey:MGMIPhoneNumber] readableNumber] javascriptEscape], [formatter stringFromDate:[messageInfo objectForKey:MGMITime]], type, [classes componentsJoinedByString:@" "]]];
[SMSView stringByEvaluatingJavaScriptFromString:@"scrollToBottom();"];
}
- (IBAction)incoming:(id)sender {

View File

@ -17,11 +17,9 @@
// ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
//
#import <Foundation/Foundation.h>
#if TARGET_OS_IPHONE
#import <UIKit/UIKit.h>
#import <AddressBook/ABAddressBook.h>
#else
#import <Cocoa/Cocoa.h>
#endif
@protocol MGMContactsDelegate, MGMContactsOwnerDelegate;

View File

@ -212,9 +212,9 @@
NSString *name = [(NSString *)ABRecordCopyValue(abGroup, kABGroupNameProperty) autorelease];
NSArray *people = [(NSArray *)ABGroupCopyArrayOfAllMembers(abGroup) autorelease];
NSMutableArray *groupMembers = [NSMutableArray array];
for (unsigned int p=0; p<[people count]; p++) {
for (unsigned int m=0; m<[people count]; m++) {
if (shouldStop) break;
ABRecordRef person = [people objectAtIndex:i];
ABRecordRef person = [people objectAtIndex:m];
ABMultiValueRef phones = ABRecordCopyValue(person, kABPersonPhoneProperty);
if (phones!=NULL) {
if (shouldStop) break;
@ -239,9 +239,9 @@
NSString *name = [abGroup valueForProperty:kABGroupNameProperty];
NSArray *people = [abGroup members];
NSMutableArray *groupMembers = [NSMutableArray array];
for (unsigned int p=0; p<[people count]; p++) {
for (unsigned int m=0; m<[people count]; m++) {
if (shouldStop) break;
ABPerson *person = [people objectAtIndex:p];
ABPerson *person = [people objectAtIndex:m];
if ([person valueForProperty:kABPhoneProperty]!=nil) {
ABMultiValue *phones = [person valueForProperty:kABPhoneProperty];
for (int p=0; p<[phones count]; p++) {

View File

@ -17,11 +17,7 @@
// ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
//
#if TARGET_OS_IPHONE
#import <UIKit/UIKit.h>
#else
#import <Cocoa/Cocoa.h>
#endif
#import <Foundation/Foundation.h>
@protocol MGMContactsProtocol, MGMContactsOwnerDelegate;
@class MGMUser, MGMLiteConnection;

View File

@ -17,11 +17,7 @@
// ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
//
#if TARGET_OS_IPHONE
#import <UIKit/UIKit.h>
#else
#import <Cocoa/Cocoa.h>
#endif
#import <Foundation/Foundation.h>
extern NSString * const MGMCRecallError;
extern NSString * const MGMCRecallSender;

View File

@ -17,11 +17,7 @@
// ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
//
#if TARGET_OS_IPHONE
#import <UIKit/UIKit.h>
#else
#import <Cocoa/Cocoa.h>
#endif
#import <Foundation/Foundation.h>
@class MGMUser, MGMURLConnectionManager;
@protocol MGMContactsDelegate, MGMContactsOwnerDelegate;

View File

@ -17,11 +17,7 @@
// ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
//
#if TARGET_OS_IPHONE
#import <UIKit/UIKit.h>
#else
#import <Cocoa/Cocoa.h>
#endif
#import <Foundation/Foundation.h>
#if MGMSIPENABLED
#import <pjsua-lib/pjsua.h>
#endif

View File

@ -217,6 +217,8 @@
return number;
}
- (NSString *)readableNumber {
if ([self rangeOfString:@"@"].location!=NSNotFound)
return self;
NSString *number = [[self removePhoneWhiteSpace] littersToNumbers];
if (![number hasPrefix:@"011"]) {
if ([number length]==10) {

View File

@ -17,11 +17,7 @@
// ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
//
#if TARGET_OS_IPHONE
#import <UIKit/UIKit.h>
#else
#import <Cocoa/Cocoa.h>
#endif
#import <Foundation/Foundation.h>
@class MGMDelegateInfo, MGMInstance, MGMURLConnectionManager;

View File

@ -17,11 +17,7 @@
// ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
//
#if TARGET_OS_IPHONE
#import <UIKit/UIKit.h>
#else
#import <Cocoa/Cocoa.h>
#endif
#import <Foundation/Foundation.h>
@class MGMInstance, MGMUser, MGMHTTPCookieStorage, MGMURLConnectionManager, MGMWhitePages, MGMInbox, MGMContacts;
@ -29,10 +25,12 @@
extern NSString * const MGMVoiceIndexURL;
extern NSString * const MGMLoginURL;
extern NSString * const MGMLoginVerifyURL;
extern NSString * const MGMLoginBody;
extern NSString * const MGMXPCPath;
extern NSString * const MGMCheckPath;
extern NSString * const MGMCreditURL;
extern NSString * const MGMPhonesURL;
extern NSString * const MGMCallURL;
extern NSString * const MGMCallCancelURL;
@ -63,12 +61,14 @@ extern NSString * const MGMUCVoicemail;
@protocol MGMInstanceDelegate <NSObject>
- (void)loginError:(NSError *)theError;
- (void)loginVerificationRequested;
- (void)loginSuccessful;
- (void)updatedContacts;
- (void)updatedUserPhones;
- (void)updateUnreadCount:(int)theCount;
- (void)updateVoicemail;
- (void)updateSMS;
- (void)updateCredit:(NSString *)credit;
- (void)updateCredit:(NSString *)theCredit;
@end
@interface MGMInstance : NSObject {
@ -81,6 +81,7 @@ extern NSString * const MGMUCVoicemail;
int webLoginTries;
BOOL loggedIn;
NSMutableDictionary *verificationParameters;
NSString *XPCURL;
NSString *XPCCD;
@ -123,7 +124,11 @@ extern NSString * const MGMUCVoicemail;
- (NSArray *)userPhoneNumbers;
- (NSDictionary *)unreadCounts;
- (void)cancelVerification;
- (void)verifyWithCode:(NSString *)theCode;
- (BOOL)isLoggedIn;
- (void)checkPhones;
- (void)parseUserPhones:(NSDictionary *)thePhones;
- (void)checkTimer;
- (void)creditTimer;

View File

@ -23,15 +23,18 @@
#import "MGMContacts.h"
#import "MGMAddressBook.h"
#import "MGMAddons.h"
#import "MGMXML.h"
#import <MGMUsers/MGMUsers.h>
NSString * const MGMVoiceBaseCopyright = @"Copyright (c) 2011 Mr. Gecko's Media (James Coleman). http://mrgeckosmedia.com/";
NSString * const MGMVoiceIndexURL = @"https://www.google.com/voice/#inbox";
NSString * const MGMLoginURL = @"https://www.google.com/accounts/ServiceLoginAuth";
NSString * const MGMLoginVerifyURL = @"https://www.google.com/accounts/SmsAuth?persistent=yes";
NSString * const MGMXPCPath = @"/voice/xpc/?xpc=%7B%22cn%22%3A%22i70avDIMsA%22%2C%22tp%22%3Anull%2C%22pru%22%3A%22https%3A%2F%2Fwww.google.com%2Fvoice%2Fxpc%2Frelay%22%2C%22ppu%22%3A%22https%3A%2F%2Fwww.google.com%2Fvoice%2Fxpc%2Fblank%2F%22%2C%22lpu%22%3A%22https%3A%2F%2Fclients4.google.com%2Fvoice%2Fxpc%2Fblank%2F%22%7D";
NSString * const MGMCheckPath = @"/voice/xpc/checkMessages?r=%@";
NSString * const MGMCreditURL = @"https://www.google.com/voice/settings/billingcredit/";
NSString * const MGMPhonesURL = @"https://www.google.com/voice/settings/tab/phones";
NSString * const MGMCallURL = @"https://www.google.com/voice/call/connect/";
NSString * const MGMCallCancelURL = @"https://www.google.com/voice/call/cancel/";
@ -234,6 +237,122 @@ const BOOL MGMInstanceInvisible = YES;
[handler setFinish:@selector(indexDidFinish:)];
[handler setInvisible:MGMInstanceInvisible];
[connectionManager addHandler:handler];
} else if ([returnedString containsString:@"Enter verification code"]) {
[verificationParameters release];
verificationParameters = [NSMutableDictionary new];
[verificationParameters setObject:@"yes" forKey:@"PersistentCookie"];
NSString *nameValue = @"name=\"%@\"";
NSString *valueStart = @"value=\"";
NSString *valueEnd = @"\"";
NSString *valueStartQ = @"value='";
NSString *valueEndQ = @"'";
NSArray *names = [NSArray arrayWithObjects:@"timeStmp", @"secTok", @"smsToken", @"email", nil];
for (int i=0; i<[names count]; i++) {
NSAutoreleasePool *pool = [NSAutoreleasePool new];
NSString *nameString = [NSString stringWithFormat:nameValue, [names objectAtIndex:i]];
NSRange range = [returnedString rangeOfString:nameString];
if (range.location==NSNotFound) {
nameString = [nameString replace:@"\"" with:@"'"];
range = [returnedString rangeOfString:nameString];
}
if (range.location==NSNotFound) {
NSLog(@"Unable to find %@", [names objectAtIndex:i]);
} else {
NSString *string = [returnedString substringFromIndex:range.location+range.length];
range = [string rangeOfString:valueStart];
if (range.location==NSNotFound) {
range = [string rangeOfString:valueStartQ];
if (range.location==NSNotFound) {
NSLog(@"Unable to find value for %@", [names objectAtIndex:i]);
[pool drain];
continue;
}
string = [string substringFromIndex:range.location+range.length];
range = [string rangeOfString:valueEndQ];
} else {
string = [string substringFromIndex:range.location+range.length];
range = [string rangeOfString:valueEnd];
}
if (range.location==NSNotFound) NSLog(@"failed 532");
[verificationParameters setObject:[[[string substringWithRange:NSMakeRange(0, range.location)] copy] autorelease] forKey:[names objectAtIndex:i]];
}
[pool drain];
}
if ([delegate respondsToSelector:@selector(loginVerificationRequested)]) {
#if MGMInstanceDebug
NSLog(@"%@", verificationParameters);
#endif
[delegate loginVerificationRequested];
} else {
NSError *error = [NSError errorWithDomain:@"com.MrGeckosMedia.MGMInstance.Login" code:54 userInfo:[NSDictionary dictionaryWithObject:@"Unable to login. The application does not implument with 2 step verification." forKey:NSLocalizedDescriptionKey]];
if (delegate!=nil && [delegate respondsToSelector:@selector(loginError:)]) {
[delegate loginError:error];
} else {
NSLog(@"Login Error: %@", error);
}
return;
}
} else if ([returnedString containsString:@"onload=\"autoSubmit()\""]) {
NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:MGMLoginURL]];
[request setHTTPMethod:MGMPostMethod];
[request setValue:MGMURLForm forHTTPHeaderField:MGMContentType];
NSMutableDictionary *parameters = [NSMutableDictionary dictionary];
NSString *nameValue = @"name=\"%@\"";
NSString *valueStart = @"value=\"";
NSString *valueEnd = @"\"";
NSString *valueStartQ = @"value='";
NSString *valueEndQ = @"'";
NSArray *names = [NSArray arrayWithObjects:@"dsh", @"smsToken", @"followup", @"continue", @"PersistentCookie", @"service", @"rmShown", @"GALX", @"ltmpl", nil];
for (int i=0; i<[names count]; i++) {
NSAutoreleasePool *pool = [NSAutoreleasePool new];
NSString *nameString = [NSString stringWithFormat:nameValue, [names objectAtIndex:i]];
NSRange range = [returnedString rangeOfString:nameString];
if (range.location==NSNotFound) {
nameString = [nameString replace:@"\"" with:@"'"];
range = [returnedString rangeOfString:nameString];
}
if (range.location==NSNotFound) {
NSLog(@"Unable to find %@", [names objectAtIndex:i]);
} else {
NSString *string = [returnedString substringFromIndex:range.location+range.length];
range = [string rangeOfString:valueStart];
if (range.location==NSNotFound) {
range = [string rangeOfString:valueStartQ];
if (range.location==NSNotFound) {
NSLog(@"Unable to find value for %@", [names objectAtIndex:i]);
[pool drain];
continue;
}
string = [string substringFromIndex:range.location+range.length];
range = [string rangeOfString:valueEndQ];
} else {
string = [string substringFromIndex:range.location+range.length];
range = [string rangeOfString:valueEnd];
}
if (range.location==NSNotFound) NSLog(@"failed 532");
[parameters setObject:[[[string substringWithRange:NSMakeRange(0, range.location)] copy] autorelease] forKey:[names objectAtIndex:i]];
}
[pool drain];
}
#if MGMInstanceDebug
NSLog(@"%@", parameters);
#endif
NSArray *parametersKeys = [parameters allKeys];
NSMutableString *bodyString = [NSMutableString string];
for (int i=0; i<[parametersKeys count]; i++) {
if (i!=0)
[bodyString appendString:@"&"];
[bodyString appendFormat:@"%@=%@", [[parametersKeys objectAtIndex:i] addPercentEscapes], [[parameters objectForKey:[parametersKeys objectAtIndex:i]] addPercentEscapes]];
}
[request setHTTPBody:[bodyString dataUsingEncoding:NSUTF8StringEncoding]];
MGMURLBasicHandler *handler = [MGMURLBasicHandler handlerWithRequest:request delegate:self];
[handler setFailWithError:@selector(index:didFailWithError:)];
[handler setFinish:@selector(indexDidFinish:)];
[handler setInvisible:MGMInstanceInvisible];
[connectionManager addHandler:handler];
} else if ([returnedString containsString:@"<div id=\"gaia_loginbox\">"]) {
if (webLoginTries>2) {
NSError *error = [NSError errorWithDomain:@"com.MrGeckosMedia.MGMInstance.Login" code:1 userInfo:[NSDictionary dictionaryWithObject:@"Unable to login. Please check your Credentials." forKey:NSLocalizedDescriptionKey]];
@ -440,21 +559,7 @@ const BOOL MGMInstanceInvisible = YES;
phonesInfo = [string substringWithRange:NSMakeRange(0, range.location)];
}
}
NSDictionary *phones = [phonesInfo parseJSON];
//NSLog(@"%@", phones);
NSArray *phoneKeys = [phones allKeys];
[userPhoneNumbers release];
userPhoneNumbers = [NSMutableArray new];
for (int i=0; i<[phoneKeys count]; i++) {
NSDictionary *phoneInfo = [phones objectForKey:[phoneKeys objectAtIndex:i]];
if ([[phoneInfo objectForKey:@"telephonyVerified"] intValue]==1) {
NSMutableDictionary *phone = [NSMutableDictionary dictionary];
[phone setObject:[[phoneInfo objectForKey:MGMPhoneNumber] phoneFormat] forKey:MGMPhoneNumber];
[phone setObject:[[phoneInfo objectForKey:MGMName] flattenHTML] forKey:MGMName];
[phone setObject:[phoneInfo objectForKey:MGMType] forKey:MGMType];
[userPhoneNumbers addObject:phone];
}
}
[self parseUserPhones:[phonesInfo parseJSON]];
#if MGMInstanceDebug
NSLog(@"User Phones = %@", userPhoneNumbers);
NSLog(@"Parsing XPCURL");
@ -489,10 +594,72 @@ const BOOL MGMInstanceInvisible = YES;
}
}
}
- (void)cancelVerification {
[verificationParameters release];
verificationParameters = nil;
NSError *error = [NSError errorWithDomain:@"com.MrGeckosMedia.MGMInstance.Login" code:54 userInfo:[NSDictionary dictionaryWithObject:@"Unable to login. Verification was canceled." forKey:NSLocalizedDescriptionKey]];
if (delegate!=nil && [delegate respondsToSelector:@selector(loginError:)]) {
[delegate loginError:error];
} else {
NSLog(@"Login Error: %@", error);
}
}
- (void)verifyWithCode:(NSString *)theCode {
NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:MGMLoginVerifyURL]];
[request setHTTPMethod:MGMPostMethod];
[request setValue:MGMURLForm forHTTPHeaderField:MGMContentType];
[verificationParameters setObject:theCode forKey:@"smsUserPin"];
NSArray *parametersKeys = [verificationParameters allKeys];
NSMutableString *bodyString = [NSMutableString string];
for (int i=0; i<[parametersKeys count]; i++) {
if (i!=0)
[bodyString appendString:@"&"];
[bodyString appendFormat:@"%@=%@", [[parametersKeys objectAtIndex:i] addPercentEscapes], [[verificationParameters objectForKey:[parametersKeys objectAtIndex:i]] addPercentEscapes]];
}
[request setHTTPBody:[bodyString dataUsingEncoding:NSUTF8StringEncoding]];
MGMURLBasicHandler *handler = [MGMURLBasicHandler handlerWithRequest:request delegate:self];
[handler setFailWithError:@selector(index:didFailWithError:)];
[handler setFinish:@selector(indexDidFinish:)];
[handler setInvisible:MGMInstanceInvisible];
[connectionManager addHandler:handler];
[verificationParameters release];
verificationParameters = nil;
}
- (BOOL)isLoggedIn {
return loggedIn;
}
- (void)checkPhones {
MGMURLBasicHandler *handler = [MGMURLBasicHandler handlerWithRequest:[NSURLRequest requestWithURL:[NSURL URLWithString:MGMPhonesURL]] delegate:self];
[handler setFinish:@selector(phonesFinished:)];
[handler setInvisible:MGMInstanceInvisible];
[connectionManager addHandler:handler];
}
- (void)phonesFinished:(MGMURLBasicHandler *)theHandler {
MGMXMLElement *XML = [(MGMXMLDocument *)[[[MGMXMLDocument alloc] initWithData:[theHandler data] options:MGMXMLDocumentTidyXML error:nil] autorelease] rootElement];
NSDictionary *info = [[[[XML elementsForName:@"json"] objectAtIndex:0] stringValue] parseJSON];
[self parseUserPhones:[info objectForKey:@"phones"]];
if ([delegate respondsToSelector:@selector(updatedUserPhones)]) [delegate updatedUserPhones];
}
- (void)parseUserPhones:(NSDictionary *)thePhones {
if (thePhones==nil)
return;
NSArray *phones = [thePhones allKeys];
[userPhoneNumbers release];
userPhoneNumbers = [NSMutableArray new];
for (int i=0; i<[phones count]; i++) {
NSDictionary *phoneInfo = [thePhones objectForKey:[phones objectAtIndex:i]];
if ([[phoneInfo objectForKey:@"verified"] intValue]==1) {
NSMutableDictionary *phone = [NSMutableDictionary dictionary];
[phone setObject:[[phoneInfo objectForKey:MGMPhoneNumber] phoneFormat] forKey:MGMPhoneNumber];
[phone setObject:[[phoneInfo objectForKey:MGMName] flattenHTML] forKey:MGMName];
[phone setObject:[phoneInfo objectForKey:MGMType] forKey:MGMType];
[userPhoneNumbers addObject:phone];
}
}
}
- (void)xpcFinished:(MGMURLBasicHandler *)theHandler {
NSString *returnedString = [theHandler string];
NSRange range = [returnedString rangeOfString:@"new _cd('"];

View File

@ -17,11 +17,9 @@
// ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
//
#import <Foundation/Foundation.h>
#if TARGET_OS_IPHONE
#import <UIKit/UIKit.h>
#import <AVFoundation/AVFoundation.h>
#else
#import <Cocoa/Cocoa.h>
#endif
@class MGMSound;
@ -33,7 +31,7 @@
@interface MGMSound : NSObject
#if TARGET_OS_IPHONE
<AVAudioPlayerDelegate>
#else
#elif (MAC_OS_X_VERSION_MAX_ALLOWED >= 1060)
<NSSoundDelegate>
#endif
{

View File

@ -17,11 +17,7 @@
// ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
//
#if TARGET_OS_IPHONE
#import <UIKit/UIKit.h>
#else
#import <Cocoa/Cocoa.h>
#endif
#import <Foundation/Foundation.h>
#define MGMThemeManagerDebug 0
@ -35,6 +31,9 @@ extern NSString * const MGMTCurrentThemePath;
extern NSString * const MGMTCurrentThemeVariant;
extern NSString * const MGMTShowHeader;
extern NSString * const MGMTShowFooter;
extern NSString * const MGMTShowIcons;
extern NSString * const MGMTFontName;
extern NSString * const MGMTFontSize;
extern NSString * const MGMTInfoPlist;
extern NSString * const MGMTThemePath;
@ -56,6 +55,12 @@ extern NSString * const MGMTInName;
extern NSString * const MGMTInNumber;
extern NSString * const MGMTPhoto;
extern NSString * const MGMTCOutgoing;
extern NSString * const MGMTCIncoming;
extern NSString * const MGMTCNext;
extern NSString * const MGMTCMessage;
extern NSString * const MGMTCHideIcons;
extern NSString * const MGMTSoundChangedNotification;
extern NSString * const MGMTCallSoundsFolder;
@ -116,6 +121,7 @@ extern NSString * const MGMCAFExt;
- (NSString *)incomingIconPath;
- (NSString *)outgoingIconPath;
- (NSString *)htmlTextFromMessage:(NSDictionary *)theMessage;
- (NSString *)replace:(NSString *)theHTML messageInfo:(NSDictionary *)theMessageInfo;
- (NSString *)replace:(NSString *)theHTML message:(NSDictionary *)theMessage;
- (NSString *)buildHTMLWithMessages:(NSArray *)theMessages messageInfo:(NSDictionary *)theMessageInfo;

View File

@ -21,6 +21,7 @@
#import "MGMInbox.h"
#import "MGMAddons.h"
#import "MGMSound.h"
#import "MGMXML.h"
#import <MGMUsers/MGMUsers.h>
NSString * const MGMTThemeChangedNotification = @"MGMTThemeChangedNotification";
@ -33,6 +34,9 @@ NSString * const MGMTCurrentThemePath = @"MGMTCurrentThemePath";
NSString * const MGMTCurrentThemeVariant = @"MGMTCurrentThemeVariant";
NSString * const MGMTShowHeader = @"MGMTShowHeader";
NSString * const MGMTShowFooter = @"MGMTShowFooter";
NSString * const MGMTShowIcons = @"MGMTShowIcons";
NSString * const MGMTFontName = @"MGMTFontName";
NSString * const MGMTFontSize = @"MGMTFontSize";
NSString * const MGMTInfoPlist = @"Info.plist";
NSString * const MGMTPResource = @"%RESOURCE%";
@ -65,10 +69,20 @@ NSString * const MGMTContextName = @"context.html";
NSString * const MGMTNextContentName = @"nextContent.html";
NSString * const MGMTNextContextName = @"nextContext.html";
NSString * const MGMTInsertDIV = @"<div id=\"insert\"></div>";
NSString * const MGMTUserNumber = @"userNumber";
NSString * const MGMTInName = @"inName";
NSString * const MGMTPhoto = @"photo";
NSString * const MGMTCOutgoing = @"outgoing";
NSString * const MGMTCIncoming = @"incoming";
NSString * const MGMTCNext = @"next";
NSString * const MGMTCMessage = @"message";
NSString * const MGMTCHideIcons = @"hideIcons";
NSString * const MGMTRFontStyle = @"%FONTSTYLE%";
NSString * const MGMTRMessageClasses = @"%MESSAGECLASSES%";
NSString * const MGMTRHeader = @"%HEADER%";
NSString * const MGMTRFooter = @"%FOOTER%";
NSString * const MGMTRResource = @"%RESOURCE%";
@ -151,6 +165,9 @@ NSString * const MGMCAFExt = @"caf";
[defaults setObject:[NSNumber numberWithInt:0] forKey:MGMTCurrentThemeVariant];
[defaults setObject:[NSNumber numberWithBool:YES] forKey:MGMTShowHeader];
[defaults setObject:[NSNumber numberWithBool:YES] forKey:MGMTShowFooter];
[defaults setObject:[NSNumber numberWithBool:YES] forKey:MGMTShowIcons];
[defaults setObject:@"HelveticaNeue" forKey:MGMTFontName];
[defaults setObject:[NSNumber numberWithInt:12] forKey:MGMTFontSize];
[defaults setObject:[MGMTPResource stringByAppendingString:MGMTSDefaultPath] forKey:[MGMTSPath stringByAppendingString:MGMTSSMSMessage]];
[defaults setObject:MGMTSDefaultSMSMessageName forKey:[MGMTSName stringByAppendingString:MGMTSSMSMessage]];
[defaults setObject:[MGMTPResource stringByAppendingString:MGMTSDefaultPath] forKey:[MGMTSPath stringByAppendingString:MGMTSVoicemail]];
@ -528,8 +545,18 @@ NSString * const MGMCAFExt = @"caf";
return photoPath;
}
- (NSString *)htmlTextFromMessage:(NSDictionary *)theMessage {
MGMXMLElement *span = [[[MGMXMLElement alloc] initWithName:@"span"] autorelease];
MGMXMLNode *style = [[(MGMXMLNode *)[MGMXMLNode alloc] initWithKind:MGMXMLAttributeKind] autorelease];
[style setName:@"style"];
[style setStringValue:[NSString stringWithFormat:@"font-family: '%@'; font-size: %dpt;", [[NSUserDefaults standardUserDefaults] objectForKey:MGMTFontName], [[NSUserDefaults standardUserDefaults] integerForKey:MGMTFontSize]]];
[span addAttribute:style];
[span setStringValue:[theMessage objectForKey:MGMIText]];
return [span XMLString];
}
- (NSString *)replace:(NSString *)theHTML messageInfo:(NSDictionary *)theMessageInfo {
NSString *HTML = [theHTML replace:MGMTRResource with:[[[NSBundle mainBundle] resourcePath] filePath]];
NSString *HTML = [theHTML replace:MGMTRFontStyle with:[NSString stringWithFormat:@"font-family: '%@'; font-size: %dpt;", [[NSUserDefaults standardUserDefaults] objectForKey:MGMTFontName], [[NSUserDefaults standardUserDefaults] integerForKey:MGMTFontSize]]];
HTML = [HTML replace:MGMTRResource with:[[[NSBundle mainBundle] resourcePath] filePath]];
HTML = [HTML replace:MGMTRTheme with:[[self currentThemeVariantPath] filePath]];
HTML = [HTML replace:MGMTRThemes with:[[currentTheme objectForKey:MGMTThemePath] filePath]];
HTML = [HTML replace:MGMTRUserName with:NSFullUserName()];
@ -543,7 +570,7 @@ NSString * const MGMCAFExt = @"caf";
return HTML;
}
- (NSString *)replace:(NSString *)theHTML message:(NSDictionary *)theMessage {
NSString *HTML = [theHTML replace:MGMTRText with:[theMessage objectForKey:MGMIText]];
NSString *HTML = [theHTML replace:MGMTRText with:[self htmlTextFromMessage:theMessage]];
HTML = [HTML replace:MGMTRPhoto with:[theMessage objectForKey:MGMTPhoto]];
HTML = [HTML replace:MGMTRTime with:[theMessage objectForKey:MGMITime]];
HTML = [HTML replace:MGMTRMessageID with:[theMessage objectForKey:MGMIID]];
@ -603,12 +630,15 @@ NSString * const MGMCAFExt = @"caf";
[html appendString:themeHeader];
[pool drain];
}
NSString *messages = [@"" retain];
NSDictionary *lastMessage = nil;
for (unsigned int i=0; i<[theMessages count]; i++) {
NSAutoreleasePool *pool = [NSAutoreleasePool new];
NSDictionary *message = [theMessages objectAtIndex:i];
NSString *messageHTML = nil;
NSMutableArray *classes = [NSMutableArray array];
if ([[message objectForKey:MGMIYou] boolValue]) {
[classes addObject:MGMTCOutgoing];
if (lastMessage==nil || ![[lastMessage objectForKey:MGMIYou] boolValue]) {
#if MGMThemeManagerDebug
NSLog(@"Adding Message for Outgoing Content");
@ -636,6 +666,7 @@ NSString * const MGMCAFExt = @"caf";
return nil;
}
} else {
[classes addObject:MGMTCNext];
#if MGMThemeManagerDebug
NSLog(@"Adding Message for Outgoing Next Content");
#endif
@ -663,6 +694,7 @@ NSString * const MGMCAFExt = @"caf";
}
}
} else {
[classes addObject:MGMTCIncoming];
if (lastMessage==nil || [[lastMessage objectForKey:MGMIYou] boolValue]) {
#if MGMThemeManagerDebug
NSLog(@"Adding Message for Incoming Content");
@ -690,6 +722,7 @@ NSString * const MGMCAFExt = @"caf";
return nil;
}
} else {
[classes addObject:MGMTCNext];
#if MGMThemeManagerDebug
NSLog(@"Adding Message for Incoming Next Content");
#endif
@ -717,12 +750,25 @@ NSString * const MGMCAFExt = @"caf";
}
}
}
[classes addObject:MGMTCMessage];
if (![[NSUserDefaults standardUserDefaults] boolForKey:MGMTShowIcons])
[classes addObject:MGMTCHideIcons];
messageHTML = [self replace:messageHTML messageInfo:theMessageInfo];
messageHTML = [self replace:messageHTML message:message];
[html appendString:messageHTML];
messageHTML = [messageHTML replace:MGMTRMessageClasses with:[classes componentsJoinedByString:@" "]];
if ((([[message objectForKey:MGMIYou] boolValue] && [[lastMessage objectForKey:MGMIYou] boolValue]) || (![[message objectForKey:MGMIYou] boolValue] && ![[lastMessage objectForKey:MGMIYou] boolValue])) && lastMessage!=nil && [messages containsString:MGMTInsertDIV]) {
[messages autorelease];
messages = [[messages replace:MGMTInsertDIV with:messageHTML] retain];
} else {
[messages autorelease];
messages = [messages replace:MGMTInsertDIV with:@""];
messages = [[messages stringByAppendingString:messageHTML] retain];
}
lastMessage = message;
[pool drain];
}
[html appendString:messages];
[messages release];
if ([manager fileExistsAtPath:[variantPath stringByAppendingPathComponent:MGMTThemeFooterName]]) {
#if MGMThemeManagerDebug
NSLog(@"Loading Theme Footer");

View File

@ -18,10 +18,8 @@
//
#if MGMSIPENABLED
#if TARGET_OS_IPHONE
#import <UIKit/UIKit.h>
#else
#import <Cocoa/Cocoa.h>
#import <Foundation/Foundation.h>
#if !TARGET_OS_IPHONE
#import <SystemConfiguration/SystemConfiguration.h>
#endif
#import <pjsua-lib/pjsua.h>
@ -42,6 +40,7 @@ extern NSString * const MGMSIPEchoCacnellationEnabled;
extern NSString * const MGMSIPPort;
extern NSString * const MGMSIPPublicAddress;
extern NSString * const MGMSIPUserAgent;
extern NSString * const MGMSIPCodec;
extern NSString * const MGMNetworkConnectedNotification;
extern NSString * const MGMNetworkDisconnectedNotification;
@ -114,6 +113,9 @@ typedef enum {
BOOL shouldRestart;
NSTimer *restartTimer;
unsigned int codecOriginalPriority;
NSMutableDictionary *codecsInfo;
NSMutableArray *accounts;
NSMutableArray *restartAccounts;
#if !TARGET_OS_IPHONE
@ -163,6 +165,10 @@ typedef enum {
- (void)registerThread:(pj_thread_desc *)thePJThreadDesc;
- (void)setTopCodec:(NSString *)theCodec;
- (void)setPriority:(unsigned int)thePriority forCodec:(NSString *)theCodec;
- (NSDictionary *)codecs;
- (void)loginToAccount:(MGMSIPAccount *)theAccount;
- (void)logoutOfAccount:(MGMSIPAccount *)theAccount;

View File

@ -23,7 +23,7 @@
#import "MGMSIPCall.h"
#import "MGMSIPURL.h"
#import "MGMAddons.h"
#include <pjsua-lib/pjsua_internal.h>
#import <pjsua-lib/pjsua_internal.h>
#import <SystemConfiguration/SystemConfiguration.h>
#if !TARGET_OS_IPHONE
#import <CoreAudio/CoreAudio.h>
@ -50,6 +50,7 @@ NSString * const MGMSIPEchoCacnellationEnabled = @"MGMSIPEchoCacnellationEnabled
NSString * const MGMSIPPort = @"MGMSIPPort";
NSString * const MGMSIPPublicAddress = @"MGMSIPPublicAddress";
NSString * const MGMSIPUserAgent = @"MGMSIPUserAgent";
NSString * const MGMSIPCodec = @"MGMSIPCodec";
NSString * const MGMNetworkConnectedNotification = @"MGMNetworkConnectedNotification";
NSString * const MGMNetworkDisconnectedNotification = @"MGMNetworkDisconnectedNotification";
@ -291,12 +292,14 @@ static OSStatus MGMAudioDevicesChanged(AudioHardwarePropertyID propertyID, void
#endif
shouldRestart = NO;
codecsInfo = [NSMutableDictionary new];
#if !TARGET_OS_IPHONE
store = SCDynamicStoreCreate(kCFAllocatorDefault, CFBundleGetIdentifier(CFBundleGetMainBundle()), (SCDynamicStoreCallBack)MGMNetworkNotification, NULL);
if (!store) {
NSLog(@"Unable to create store for system configuration %s", SCErrorString(SCError()));
} else {
NSArray *keys = [NSArray arrayWithObjects:@"State:/Network/Global/IPv4", nil];
NSArray *keys = [NSArray arrayWithObjects:@"State:/Network/Global/IPv4", @"State:/Network/Global/IPv6", nil];
if (!SCDynamicStoreSetNotificationKeys(store, (CFArrayRef)keys, NULL)) {
NSLog(@"Faild to set the store for notifications %s", SCErrorString(SCError()));
CFRelease(store);
@ -324,7 +327,9 @@ static OSStatus MGMAudioDevicesChanged(AudioHardwarePropertyID propertyID, void
CFRelease(store);
#endif
[lock release];
[codecsInfo release];
[accounts release];
[restartAccounts release];
[super dealloc];
}
@ -337,6 +342,7 @@ static OSStatus MGMAudioDevicesChanged(AudioHardwarePropertyID propertyID, void
[defaults setObject:[NSNumber numberWithBool:NO] forKey:MGMSIPNameServersEnabled];
[defaults setObject:[NSNumber numberWithBool:YES] forKey:MGMSIPEchoCacnellationEnabled];
[defaults setObject:[NSNumber numberWithInt:0] forKey:MGMSIPPort];
[defaults setObject:@"speex/16000" forKey:MGMSIPCodec];
[defaults setObject:[NSNumber numberWithFloat:1.0] forKey:MGMSIPVolume];
[defaults setObject:[NSNumber numberWithFloat:1.0] forKey:MGMSIPMicVolume];
[defaults setObject:MGMSIPASystemDefault forKey:MGMSIPACurrentInputDevice];
@ -568,6 +574,23 @@ static OSStatus MGMAudioDevicesChanged(AudioHardwarePropertyID propertyID, void
return;
}
if (pjsua_var.med_endpt!=NULL) {
pjmedia_codec_info codecs[PJMEDIA_CODEC_MGR_MAX_CODECS];
unsigned int prio[PJMEDIA_CODEC_MGR_MAX_CODECS];
unsigned int count = PJ_ARRAY_SIZE(codecs);
status = pjmedia_codec_mgr_enum_codecs(pjmedia_endpt_get_codec_mgr(pjsua_var.med_endpt), &count, codecs, prio);
if (status==PJ_SUCCESS) {
for (int i=0; i<count; i++) {
[codecsInfo setObject:[NSNumber numberWithUnsignedInt:prio[i]] forKey:[NSString stringWithFormat:@"%@/%u", [NSString stringWithPJString:codecs[i].encoding_name], codecs[i].clock_rate]];
}
}
codecOriginalPriority = [[codecsInfo objectForKey:[defaults objectForKey:MGMSIPCodec]] unsignedIntValue];
[self setPriority:PJMEDIA_CODEC_PRIO_NEXT_HIGHER forCodec:[defaults objectForKey:MGMSIPCodec]];
} else {
NSLog(@"pjsua_var.med_endpt was NULL");
}
state = MGMSIPStartedState;
[accounts makeObjectsPerformSelector:@selector(login)];
@ -712,6 +735,26 @@ static OSStatus MGMAudioDevicesChanged(AudioHardwarePropertyID propertyID, void
}
}
- (void)setTopCodec:(NSString *)theCodec {
NSUserDefaults *defaults = [NSUserDefaults standardUserDefaults];
[self setPriority:codecOriginalPriority forCodec:[defaults objectForKey:MGMSIPCodec]];
[defaults setObject:theCodec forKey:MGMSIPCodec];
codecOriginalPriority = [[codecsInfo objectForKey:theCodec] unsignedIntValue];
[self setPriority:PJMEDIA_CODEC_PRIO_NEXT_HIGHER forCodec:theCodec];
}
- (void)setPriority:(unsigned int)thePriority forCodec:(NSString *)theCodec {
if ([codecsInfo objectForKey:theCodec]!=nil) {
pj_str_t codec = [theCodec PJString];
pj_status_t status = pjmedia_codec_mgr_set_codec_priority(pjmedia_endpt_get_codec_mgr(pjsua_var.med_endpt), &codec, thePriority);
[codecsInfo setObject:[NSNumber numberWithUnsignedInt:thePriority] forKey:theCodec];
if (status!=PJ_SUCCESS)
NSLog(@"Error changing priority of codec %@ to %u: %d", theCodec, thePriority, status);
}
}
- (NSDictionary *)codecs {
return codecsInfo;
}
- (void)loginToAccount:(MGMSIPAccount *)theAccount {
NSAutoreleasePool *pool = [NSAutoreleasePool new];
if (![theAccount informationComplete]) {

View File

@ -18,11 +18,7 @@
//
#if MGMSIPENABLED
#if TARGET_OS_IPHONE
#import <UIKit/UIKit.h>
#else
#import <Cocoa/Cocoa.h>
#endif
#import <Foundation/Foundation.h>
#import <pjsua-lib/pjsua.h>
extern NSString * const MGMSIPAccountFullName;

View File

@ -18,11 +18,7 @@
//
#if MGMSIPENABLED
#if TARGET_OS_IPHONE
#import <UIKit/UIKit.h>
#else
#import <Cocoa/Cocoa.h>
#endif
#import <Foundation/Foundation.h>
#import <pjsua-lib/pjsua.h>
@class MGMSIPCall, MGMSIPAccount, MGMSIPURL;

View File

@ -261,6 +261,9 @@
if (identifier==PJSUA_INVALID_ID || state==MGMSIPCallDisconnectedState)
return;
if (isRingbackOn)
[self stopRingback];
pj_thread_desc PJThreadDesc;
[[MGMSIP sharedSIP] registerThread:&PJThreadDesc];

View File

@ -18,11 +18,7 @@
//
#if MGMSIPENABLED
#if TARGET_OS_IPHONE
#import <UIKit/UIKit.h>
#else
#import <Cocoa/Cocoa.h>
#endif
#import <Foundation/Foundation.h>
@interface MGMSIPURL : NSObject {
NSString *fullName;

View File

@ -17,11 +17,7 @@
// ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
//
#if TARGET_OS_IPHONE
#import <UIKit/UIKit.h>
#else
#import <Cocoa/Cocoa.h>
#endif
#import <Foundation/Foundation.h>
#import <libxml/parser.h>
#import <libxml/tree.h>

View File

@ -17,11 +17,7 @@
// ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
//
#if TARGET_OS_IPHONE
#import <UIKit/UIKit.h>
#else
#import <Cocoa/Cocoa.h>
#endif
#import <Foundation/Foundation.h>
#import <VoiceBase/MGMXMLNode.h>
@interface MGMXMLDTD : MGMXMLNode {

View File

@ -17,11 +17,7 @@
// ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
//
#if TARGET_OS_IPHONE
#import <UIKit/UIKit.h>
#else
#import <Cocoa/Cocoa.h>
#endif
#import <Foundation/Foundation.h>
#import <VoiceBase/MGMXMLNode.h>
@interface MGMXMLDTDNode : MGMXMLNode {

View File

@ -17,11 +17,7 @@
// ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
//
#if TARGET_OS_IPHONE
#import <UIKit/UIKit.h>
#else
#import <Cocoa/Cocoa.h>
#endif
#import <Foundation/Foundation.h>
#import <VoiceBase/MGMXMLNode.h>
#define MGMXMLDocPtr (xmlDocPtr)commonXML
@ -32,7 +28,7 @@
- (id)initWithXMLString:(NSString *)string options:(NSUInteger)mask error:(NSError **)error;
- (id)initWithContentsOfURL:(NSURL *)url options:(NSUInteger)mask error:(NSError **)error;
- (id)initWithData:(NSData *)data options:(NSUInteger)mask error:(NSError **)error; //primitive
//- (id)initWithRootElement:(MGMXMLElement *)element;
- (id)initWithRootElement:(MGMXMLElement *)element;
//+ (Class)replacementClassForClass:(Class)cls;
//- (void)setCharacterEncoding:(NSString *)encoding; //primitive

View File

@ -22,6 +22,10 @@
#import <libxml/HTMLtree.h>
#import <libxml/HTMLparser.h>
@interface MGMXMLNode (MGMPrivate)
- (void)setDocument:(MGMXMLDocument *)theDocument;
@end
@implementation MGMXMLDocument
- (id)initWithXMLString:(NSString *)string options:(NSUInteger)mask error:(NSError **)error {
NSData *data = [string dataUsingEncoding:NSUTF8StringEncoding];
@ -57,6 +61,17 @@
}
return self;
}
- (id)initWithRootElement:(MGMXMLElement *)element {
if ((self = [super init])) {
xmlDocPtr document = xmlNewDoc(NULL);
if (element!=nil) {
xmlDocSetRootElement(document, (xmlNodePtr)[element commonXML]);
[element setDocument:self];
}
[self setTypeXMLPtr:(xmlTypPtr)document];
}
return self;
}
- (void)setRootElement:(MGMXMLNode *)root {
if ([root kind]==MGMXMLNamespaceKind)

View File

@ -17,19 +17,15 @@
// ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
//
#if TARGET_OS_IPHONE
#import <UIKit/UIKit.h>
#else
#import <Cocoa/Cocoa.h>
#endif
#import <Foundation/Foundation.h>
#import <VoiceBase/MGMXMLNode.h>
@interface MGMXMLElement : MGMXMLNode {
}
//- (id)initWithName:(NSString *)name;
- (id)initWithName:(NSString *)name;
//- (id)initWithName:(NSString *)name URI:(NSString *)URI; //primitive
//- (id)initWithName:(NSString *)name stringValue:(NSString *)string;
- (id)initWithName:(NSString *)name stringValue:(NSString *)string;
- (id)initWithXMLString:(NSString *)string error:(NSError **)error;
- (NSArray *)elementsForName:(NSString *)name;

View File

@ -22,6 +22,18 @@
#import "MGMXMLAddons.h"
@implementation MGMXMLElement
- (id)initWithName:(NSString *)name {
return [self initWithName:name stringValue:nil];
}
- (id)initWithName:(NSString *)name stringValue:(NSString *)string {
if ((self = [super init])) {
xmlNodePtr node = xmlNewNode(NULL, [name xmlString]);
if (string!=nil)
xmlNodeSetContent(node, [string xmlString]);
[self setTypeXMLPtr:(xmlTypPtr)node];
}
return self;
}
- (id)initWithXMLString:(NSString *)string error:(NSError **)error {
[super release];
MGMXMLDocument *document = [[MGMXMLDocument alloc] initWithXMLString:string options:0 error:error];
@ -88,10 +100,9 @@
}
- (void)addAttribute:(MGMXMLNode *)attribute {
if ([attribute kind]==MGMXMLAttributeKind && [attribute commonXML]->parent!=NULL) {
if ([attribute kind]==MGMXMLAttributeKind && [attribute commonXML]->parent!=NULL)
[self removeAttributeForName:[attribute name]];
xmlAddChild(MGMXMLNodePtr, (xmlNodePtr)[attribute commonXML]);
}
xmlAddChild(MGMXMLNodePtr, (xmlNodePtr)[attribute commonXML]);
}
- (void)removeAttributeForName:(NSString *)name {
xmlAttrPtr attribute = MGMXMLNodePtr->properties;

View File

@ -17,11 +17,7 @@
// ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
//
#if TARGET_OS_IPHONE
#import <UIKit/UIKit.h>
#else
#import <Cocoa/Cocoa.h>
#endif
#import <Foundation/Foundation.h>
#import <VoiceBase/MGMXMLNodeOptions.h>
#import <libxml/parser.h>
#import <libxml/tree.h>
@ -98,7 +94,7 @@ struct _xmlCom {
- (BOOL)isNode;
+ (NSError *)lastError;
- (NSError *)lastError;
//- (id)initWithKind:(MGMXMLNodeKind)kind;
- (id)initWithKind:(MGMXMLNodeKind)kind;
//- (id)initWithKind:(MGMXMLNodeKind)kind options:(NSUInteger)options; //primitive
//+ (id)document;
//+ (id)documentWithRootElement:(MGMXMLElement *)element;
@ -121,7 +117,7 @@ struct _xmlCom {
- (NSString *)name;
//- (void)setObjectValue:(id)value; //primitive
//- (id)objectValue; //primitive
//- (void)setStringValue:(NSString *)string;
- (void)setStringValue:(NSString *)string;
//- (void)setStringValue:(NSString *)string resolvingEntities:(BOOL)resolve; //primitive
- (NSString *)stringValue; //primitive

View File

@ -63,22 +63,28 @@ static void MGMXMLErrorHandler(void *userData, xmlErrorPtr error) {
}
- (id)initWithTypeXMLPtr:(xmlTypPtr)theXMLPtr {
if ((self = [self init])) {
if (theXMLPtr->type==MGMXMLNamespaceKind) {
xmlNsPtr xmlPtr = (xmlNsPtr)theXMLPtr;
if (xmlPtr->_private!=NULL) {
[self release];
self = nil;
return [(MGMXMLNode *)xmlPtr->_private retain];
}
if (theXMLPtr==NULL) {
//NSLog(@"NULL XMLPtr");
[self release];
self = nil;
} else {
xmlComPtr comXML = (xmlComPtr)theXMLPtr;
if (comXML->_private!=NULL) {
[self release];
self = nil;
return [(MGMXMLNode *)comXML->_private retain];
if (theXMLPtr->type==MGMXMLNamespaceKind) {
xmlNsPtr xmlPtr = (xmlNsPtr)theXMLPtr;
if (xmlPtr->_private!=NULL) {
[self release];
self = nil;
return [(MGMXMLNode *)xmlPtr->_private retain];
}
} else {
xmlComPtr comXML = (xmlComPtr)theXMLPtr;
if (comXML->_private!=NULL) {
[self release];
self = nil;
return [(MGMXMLNode *)comXML->_private retain];
}
}
[self setTypeXMLPtr:theXMLPtr];
}
[self setTypeXMLPtr:theXMLPtr];
}
return self;
}
@ -239,6 +245,10 @@ static void MGMXMLErrorHandler(void *userData, xmlErrorPtr error) {
documentNode = [[MGMXMLDocument alloc] initWithTypeXMLPtr:(xmlTypPtr)commonXML->doc];
}
}
- (void)setDocument:(MGMXMLDocument *)theDocument {
[documentNode release];
documentNode = [theDocument retain];
}
- (void)releaseDocument {
[documentNode release];
documentNode = nil;
@ -272,6 +282,27 @@ static void MGMXMLErrorHandler(void *userData, xmlErrorPtr error) {
return [[self class] lastError];
}
- (id)initWithKind:(MGMXMLNodeKind)kind {
if (kind==MGMXMLDocumentKind) {
[self release];
return [[MGMXMLDocument alloc] initWithRootElement:nil];
} else if (kind==MGMXMLElementKind) {
return [self initWithTypeXMLPtr:(xmlTypPtr)xmlNewNode(NULL, NULL)];
} else if (kind==MGMXMLAttributeKind) {
return [self initWithTypeXMLPtr:(xmlTypPtr)xmlNewProp(NULL, (const xmlChar *)"", NULL)];
} else if (kind==MGMXMLNamespaceKind) {
return [self initWithTypeXMLPtr:(xmlTypPtr)xmlNewNs(NULL, NULL, NULL)];
} else if (kind==MGMXMLProcessingInstructionKind) {
return [self initWithTypeXMLPtr:(xmlTypPtr)xmlNewPI(NULL, NULL)];
} else if (kind==MGMXMLCommentKind) {
return [self initWithTypeXMLPtr:(xmlTypPtr)xmlNewComment(NULL)];
} else if (kind==MGMXMLTextKind) {
return [self initWithTypeXMLPtr:(xmlTypPtr)xmlNewText(NULL)];
}
[self release];
return nil;
}
- (MGMXMLNodeKind)kind {
return type;
}
@ -300,13 +331,19 @@ static void MGMXMLErrorHandler(void *userData, xmlErrorPtr error) {
}
return nil;
}
- (void)setStringValue:(NSString *)string {
if (type==MGMXMLNamespaceKind) {
namespaceXML->href = [string xmlString];
} else if ([self isNode] || type==MGMXMLAttributeKind) {
xmlChar *contentString = xmlEncodeEntitiesReentrant(commonXML->doc, [string xmlString]);
xmlNodeSetContent(MGMXMLNodePtr, contentString);
xmlFree(contentString);
}
}
- (NSString *)stringValue {
if (type==MGMXMLNamespaceKind) {
return [NSString stringWithXMLString:namespaceXML->href];
} else if (type==MGMXMLAttributeKind) {
if (MGMXMLAttrPtr->children!=NULL)
return [NSString stringWithXMLString:MGMXMLAttrPtr->children->content];
} else if ([self isNode]) {
} else if ([self isNode] || type==MGMXMLAttributeKind) {
xmlChar *contentString = xmlNodeGetContent(MGMXMLNodePtr);
NSString *stringValue = [NSString stringWithXMLString:contentString];
xmlFree(contentString);

View File

@ -21,7 +21,11 @@
@class MGMInstance, MGMURLConnectionManager, QTMovieView;
@interface MGMInboxPlayWindow : NSWindow <NSWindowDelegate> {
@interface MGMInboxPlayWindow : NSWindow
#if (MAC_OS_X_VERSION_MAX_ALLOWED >= 1060)
<NSWindowDelegate>
#endif
{
MGMInstance *instance;
MGMURLConnectionManager *connectionManager;
IBOutlet NSView *view;

View File

@ -438,12 +438,22 @@ NSString * const MGMSID = @"id";
[self markRead:self];
}
- (float)splitView:(NSSplitView *)sender constrainMinCoordinate:(float)proposedMin ofSubviewAt:(int)offset {
#if (MAC_OS_X_VERSION_MAX_ALLOWED >= 1060)
- (float)splitView:(NSSplitView *)sender constrainMinCoordinate:(float)proposedMin ofSubviewAt:(int)offset
#else
- (CGFloat)splitView:(NSSplitView *)sender constrainMinCoordinate:(CGFloat)proposedMin ofSubviewAt:(NSInteger)offset
#endif
{
leftMax = [[[sender subviews] objectAtIndex:0] frame].size.width;
rightMax = [[[sender subviews] objectAtIndex:1] frame].size.width;
return 0.0;
}
- (float)splitView:(NSSplitView *)sender constrainMaxCoordinate:(float)proposedMax ofSubviewAt:(int)offset{
#if (MAC_OS_X_VERSION_MAX_ALLOWED >= 1060)
- (float)splitView:(NSSplitView *)sender constrainMaxCoordinate:(float)proposedMax ofSubviewAt:(int)offset
#else
- (CGFloat)splitView:(NSSplitView *)sender constrainMaxCoordinate:(CGFloat)proposedMax ofSubviewAt:(NSInteger)offset
#endif
{
leftMax = [[[sender subviews] objectAtIndex:0] frame].size.width;
rightMax = [[[sender subviews] objectAtIndex:1] frame].size.width;
return proposedMax - 250.0;

View File

@ -23,7 +23,11 @@
extern NSString *MGMContactsWindowOpen;
@interface MGMContactsController : NSObject <NSTextFieldDelegate> {
@interface MGMContactsController : NSObject
#if (MAC_OS_X_VERSION_MAX_ALLOWED >= 1060)
<NSTextFieldDelegate>
#endif
{
MGMController *controller;
IBOutlet NSWindow *contactsWindow;
BOOL closingWindow;

View File

@ -525,7 +525,6 @@ NSString * const MGMLoading = @"Loading...";
NSBeep();
return;
}
connectionManager = [MGMURLConnectionManager new];
MGMWhitePagesHandler *handler = [MGMWhitePagesHandler reverseLookup:phoneNumber delegate:self];
[connectionManager addHandler:handler];
[RLName setStringValue:MGMLoading];
@ -535,7 +534,7 @@ NSString * const MGMLoading = @"Loading...";
[RLPhoneNumber setStringValue:MGMLoading];
[RLWindow orderFront:self];
}
- (void)reverseLookup:(NSDictionary *)theInfo didFailWithError:(NSError *)theError {
- (void)reverseLookup:(MGMWhitePagesHandler *)theHandler didFailWithError:(NSError *)theError {
NSAlert *alert = [[NSAlert new] autorelease];
[alert setMessageText:@"Reverse Lookup Failed"];
[alert setInformativeText:[theError localizedDescription]];
@ -557,12 +556,12 @@ NSString * const MGMLoading = @"Loading...";
} else {
[RLCityState setStringValue:@""];
}
if ([theHandler zip]) {
if ([theHandler zip]!=nil) {
[RLZipCode setStringValue:[theHandler zip]];
} else {
[RLZipCode setStringValue:@""];
}
if ([theHandler phoneNumber]) {
if ([theHandler phoneNumber]!=nil) {
[RLPhoneNumber setStringValue:[[theHandler phoneNumber] readableNumber]];
} else {
[RLPhoneNumber setStringValue:@""];

View File

@ -20,15 +20,21 @@
#import <Cocoa/Cocoa.h>
#import "MGMContactsController.h"
extern NSString *MGMLastUserPhoneKey;
extern NSString * const MGMLastUserPhoneKey;
@class MGMController, MGMUser, MGMInstance, MGMInboxWindow, MGMProgressView, MGMPhoneField, MGMPhoneFieldView, MGMContactsTableView;
@class MGMController, MGMUser, MGMInstance, MGMInboxWindow, MGMVoiceVerify, MGMProgressView, MGMPhoneField, MGMPhoneFieldView, MGMContactsTableView;
@interface MGMVoiceUser : MGMContactsController <NSAnimationDelegate> {
@interface MGMVoiceUser : MGMContactsController
#if (MAC_OS_X_VERSION_MAX_ALLOWED >= 1060)
<NSAnimationDelegate>
#endif
{
MGMInstance *instance;
MGMUser *user;
MGMInboxWindow *inboxWindow;
MGMVoiceVerify *verifyWindow;
MGMProgressView *progressView;
NSViewAnimation *progressFadeAnimation;
IBOutlet NSTextField *creditField;
@ -53,6 +59,8 @@ extern NSString *MGMLastUserPhoneKey;
- (void)loginSuccessful;
- (void)setInstanceInfo;
- (void)updatedUserPhones;
- (BOOL)isPlacingCall;
- (void)donePlacingCall;

View File

@ -19,6 +19,7 @@
#import "MGMVoiceUser.h"
#import "MGMController.h"
#import "MGMVoiceVerify.h"
#import "MGMProgressView.h"
#import "MGMContactView.h"
#import "MGMPhoneFeild.h"
@ -27,7 +28,7 @@
#import <VoiceBase/VoiceBase.h>
#import <MGMUsers/MGMUsers.h>
NSString *MGMLastUserPhoneKey = @"MGMLastUserPhone";
NSString * const MGMLastUserPhoneKey = @"MGMLastUserPhone";
@implementation MGMVoiceUser
+ (id)voiceUser:(MGMUser *)theUser controller:(MGMController *)theController {
@ -74,7 +75,6 @@ NSString *MGMLastUserPhoneKey = @"MGMLastUserPhone";
[progressFadeAnimation stopAnimation];
[progressFadeAnimation release];
progressFadeAnimation = nil;
[super dealloc];
[inboxWindow closeWindow];
[inboxWindow release];
[instance setDelegate:nil];
@ -85,6 +85,8 @@ NSString *MGMLastUserPhoneKey = @"MGMLastUserPhone";
[callTimer invalidate];
[callTimer release];
[user release];
[[NSNotificationCenter defaultCenter] removeObserver:self];
[super dealloc];
}
- (void)registerSettings {
@ -123,12 +125,20 @@ NSString *MGMLastUserPhoneKey = @"MGMLastUserPhone";
[theAlert setInformativeText:[theError localizedDescription]];
[theAlert runModal];
[verifyWindow release];
verifyWindow = nil;
[progressView stopProgess];
[progressView removeFromSuperview];
[progressView release];
progressView = nil;
}
- (void)loginVerificationRequested {
[verifyWindow release];
verifyWindow = [[MGMVoiceVerify verifyWithInstance:instance] retain];
}
- (void)loginSuccessful {
[verifyWindow release];
verifyWindow = nil;
[progressView stopProgess];
[progressView display];
@ -145,17 +155,11 @@ NSString *MGMLastUserPhoneKey = @"MGMLastUserPhone";
}
}
- (void)setInstanceInfo {
[[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(becameActive) name:NSApplicationDidBecomeActiveNotification object:nil];
if (contactsWindow==nil) return;
if ([instance isLoggedIn]) {
[userNumberButton setTitle:[[instance userNumber] readableNumber]];
[userPhonesButton removeAllItems];
NSArray *phones = [instance userPhoneNumbers];
for (int i=0; i<[phones count]; i++) {
NSDictionary *phone = [phones objectAtIndex:i];
[userPhonesButton addItemWithTitle:[NSString stringWithFormat:@"%@ [%@]", [[phone objectForKey:MGMPhoneNumber] readableNumber], [phone objectForKey:MGMName]]];
[userPhonesButton selectItemAtIndex:0];
}
[userPhonesButton selectItemAtIndex:[[user settingForKey:MGMLastUserPhoneKey] intValue]];
[self updatedUserPhones];
}
}
- (void)animationDidEnd:(NSAnimation *)animation {
@ -175,6 +179,24 @@ NSString *MGMLastUserPhoneKey = @"MGMLastUserPhone";
[progressView display];
}
- (void)becameActive {
[instance checkPhones];
}
- (void)updatedUserPhones {
[userPhonesButton removeAllItems];
NSArray *phones = [instance userPhoneNumbers];
for (int i=0; i<[phones count]; i++) {
NSDictionary *phone = [phones objectAtIndex:i];
[userPhonesButton addItemWithTitle:[NSString stringWithFormat:@"%@ [%@]", [[phone objectForKey:MGMPhoneNumber] readableNumber], [phone objectForKey:MGMName]]];
[userPhonesButton selectItemAtIndex:0];
}
if ([[instance userPhoneNumbers] count]>=1) {
if ([[instance userPhoneNumbers] count]<([[user settingForKey:MGMLastUserPhoneKey] intValue]+1))
[user setSetting:[NSNumber numberWithInt:0] forKey:MGMLastUserPhoneKey];
[userPhonesButton selectItemAtIndex:[[user settingForKey:MGMLastUserPhoneKey] intValue]];
}
}
- (NSString *)areaCode {
if (![instance isLoggedIn])
return nil;
@ -212,12 +234,12 @@ NSString *MGMLastUserPhoneKey = @"MGMLastUserPhone";
[[instance connectionManager] cancelAll];
[callButton setImage:[NSImage imageNamed:@"placeCall"]];
[instance cancelCallWithDelegate:self];
} else if ([[instance userPhoneNumbers] count]<=0) {
NSAlert *alert = [[NSAlert new] autorelease];
[alert setMessageText:@"Call Failed"];
[alert setInformativeText:@"You need to have a phone number setup with your Google Voice account. To add one, click your Google Voice number at the bottom left of your Contacts window and add a phone number. Once you got a phone number setup with Google Voice, reopen VoiceMac."];
[alert runModal];
} else {
if ([userPhonesButton indexOfSelectedItem]==-1) {
NSBeep();
return;
}
NSString *phoneNumber = [controller currentPhoneNumber];
if (phoneNumber==nil || [phoneNumber isEqual:@""]) {
NSBeep();
@ -276,8 +298,8 @@ NSString *MGMLastUserPhoneKey = @"MGMLastUserPhone";
- (void)updateSMS {
[[controller SMSManager] checkSMSMessagesForInstance:instance];
}
- (void)updateCredit:(NSString *)credit {
[creditField setStringValue:credit];
- (void)updateCredit:(NSString *)theCredit {
[creditField setStringValue:theCredit];
}
- (IBAction)viewSettings:(id)sender {

View File

@ -0,0 +1,35 @@
//
// MGMVoiceVerify.h
// VoiceMac
//
// Created by James on 3/17/11.
// Copyright (c) 2011 Mr. Gecko's Media (James Coleman). http://mrgeckosmedia.com/
//
// Permission to use, copy, modify, and/or distribute this software for any purpose
// with or without fee is hereby granted, provided that the above copyright notice
// and this permission notice appear in all copies.
//
// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
// REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND
// FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT,
// OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE,
// DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS
// ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
//
#import <Cocoa/Cocoa.h>
@class MGMInstance;
@interface MGMVoiceVerify : NSObject {
MGMInstance *instance;
IBOutlet NSWindow *window;
IBOutlet NSTextField *codeField;
}
+ (id)verifyWithInstance:(MGMInstance *)theInstance;
- (id)initWithInstance:(MGMInstance *)theInstance;
- (IBAction)verify:(id)sender;
- (IBAction)cancel:(id)sender;
@end

View File

@ -0,0 +1,54 @@
//
// MGMVoiceVerify.m
// VoiceMac
//
// Created by James on 3/17/11.
// Copyright (c) 2011 Mr. Gecko's Media (James Coleman). http://mrgeckosmedia.com/
//
// Permission to use, copy, modify, and/or distribute this software for any purpose
// with or without fee is hereby granted, provided that the above copyright notice
// and this permission notice appear in all copies.
//
// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
// REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND
// FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT,
// OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE,
// DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS
// ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
//
#import "MGMVoiceVerify.h"
#import <VoiceBase/VoiceBase.h>
@implementation MGMVoiceVerify
+ (id)verifyWithInstance:(MGMInstance *)theInstance {
return [[[self alloc] initWithInstance:theInstance] autorelease];
}
- (id)initWithInstance:(MGMInstance *)theInstance {
if ((self = [super init])) {
if (![NSBundle loadNibNamed:@"VoiceVerify" owner:self]) {
NSLog(@"Unable to load Voice Verification.");
[theInstance cancelVerification];
[self release];
self = nil;
} else {
instance = theInstance;
[window makeKeyAndOrderFront:self];
}
}
return self;
}
- (void)dealloc {
[window release];
[super dealloc];
}
- (IBAction)verify:(id)sender {
[window close];
[instance verifyWithCode:[codeField stringValue]];
}
- (IBAction)cancel:(id)sender {
[window close];
[instance cancelVerification];
}
@end

View File

@ -49,6 +49,7 @@
IBOutlet NSTextField *consoleLogLevelField;
IBOutlet NSTextField *publicAddressField;
IBOutlet NSTextField *userAgentField;
IBOutlet NSPopUpButton *codecPopUp;
}
- (id)initWithPreferences:(MGMPreferences *)thePreferences;
+ (void)setUpToolbarItem:(NSToolbarItem *)theItem;
@ -79,5 +80,6 @@
- (IBAction)consoleLogLevel:(id)sender;
- (IBAction)publicAddress:(id)sender;
- (IBAction)userAgent:(id)sender;
- (IBAction)codec:(id)sender;
@end
#endif

View File

@ -62,6 +62,15 @@
[publicAddressField setStringValue:[defaults objectForKey:MGMSIPPublicAddress]];
if ([defaults objectForKey:MGMSIPUserAgent]!=nil)
[userAgentField setStringValue:[defaults objectForKey:MGMSIPUserAgent]];
NSArray *codecs = [[[MGMSIP sharedSIP] codecs] allKeys];
codecs = [codecs sortedArrayUsingSelector:@selector(compare:)];
int currentCodecIndex = 0;
for (int i=0; i<[codecs count]; i++) {
if ([[codecs objectAtIndex:i] isEqual:[defaults objectForKey:MGMSIPCodec]])
currentCodecIndex = i;
[codecPopUp addItemWithTitle:[codecs objectAtIndex:i]];
}
[codecPopUp selectItemAtIndex:currentCodecIndex];
NSNotificationCenter *notificationCenter = [NSNotificationCenter defaultCenter];
[notificationCenter addObserver:self selector:@selector(volumeChanged:) name:MGMSIPVolumeChangedNotification object:nil];
@ -244,5 +253,8 @@
[[NSUserDefaults standardUserDefaults] setObject:[userAgentField stringValue] forKey:MGMSIPUserAgent];
shouldRestart = YES;
}
- (IBAction)codec:(id)sender {
[[MGMSIP sharedSIP] setTopCodec:[[codecPopUp selectedItem] title]];
}
@end
#endif

View File

@ -32,9 +32,14 @@
IBOutlet NSPopUpButton *themePopUp;
IBOutlet NSPopUpButton *variantPopUp;
IBOutlet NSButton *authorButton;
IBOutlet NSTextField *fontPreview;
IBOutlet NSButton *headerButton;
IBOutlet NSButton *footerButton;
IBOutlet NSButton *iconsButton;
IBOutlet NSWindow *browserWindow;
IBOutlet WebView *browser;
NSButton *selectFont;
}
- (id)initWithPreferences:(MGMPreferences *)thePreferences;
+ (void)setUpToolbarItem:(NSToolbarItem *)theItem;
@ -47,6 +52,10 @@
- (IBAction)changeTheme:(id)sender;
- (IBAction)changeVariant:(id)sender;
- (IBAction)authorSite:(id)sender;
- (IBAction)selectFont:(id)sender;
- (IBAction)header:(id)sender;
- (IBAction)footer:(id)sender;
- (IBAction)icons:(id)sender;
- (IBAction)showBrowser:(id)sender;
@end

View File

@ -55,6 +55,14 @@ NSString * const MGMTestTTPhoto = @"tPhoto";
[testMessageInfo setObject:@"+17204325686" forKey:MGMTUserNumber];
[testMessageInfo setObject:@"673bd22599231d1a9ba78760f2df085a7237b4b3" forKey:MGMIID];
[SMSView setResourceLoadDelegate:self];
NSUserDefaults *defaults = [NSUserDefaults standardUserDefaults];
NSFont *font = [NSFont fontWithName:[defaults objectForKey:MGMTFontName] size:[defaults integerForKey:MGMTFontSize]];
[fontPreview setFont:font];
[fontPreview setStringValue:[NSString stringWithFormat:@"%@ %d", [font fontName], (int)[font pointSize]]];
[headerButton setState:([defaults boolForKey:MGMTShowHeader] ? NSOnState : NSOffState)];
[footerButton setState:([defaults boolForKey:MGMTShowFooter] ? NSOnState : NSOffState)];
[iconsButton setState:([defaults boolForKey:MGMTShowIcons] ? NSOnState : NSOffState)];
[self reload:self];
}
}
@ -138,6 +146,46 @@ NSString * const MGMTestTTPhoto = @"tPhoto";
if ([[themeManager theme] objectForKey:MGMTSite]!=nil)
[[NSWorkspace sharedWorkspace] openURL:[NSURL URLWithString:[[themeManager theme] objectForKey:MGMTSite]]];
}
- (IBAction)selectFont:(id)sender {
NSUserDefaults *defaults = [NSUserDefaults standardUserDefaults];
NSFontManager *fontManager = [NSFontManager sharedFontManager];
NSFontPanel *fontPanel = [fontManager fontPanel:YES];
[fontPanel setDelegate:self];
[fontPanel setPanelFont:[NSFont fontWithName:[defaults objectForKey:MGMTFontName] size:[defaults integerForKey:MGMTFontSize]] isMultiple:NO];
[fontPanel makeKeyAndOrderFront:self];
}
- (void)changeFont:(id)sender {
NSUserDefaults *defaults = [NSUserDefaults standardUserDefaults];
NSFont *font = [sender convertFont:[NSFont fontWithName:[defaults objectForKey:MGMTFontName] size:[defaults integerForKey:MGMTFontSize]]];
[defaults setObject:[font fontName] forKey:MGMTFontName];
[defaults setInteger:(int)[font pointSize] forKey:MGMTFontSize];
[fontPreview setFont:font];
[fontPreview setStringValue:[NSString stringWithFormat:@"%@ %d", [font fontName], (int)[font pointSize]]];
}
- (void)windowWillClose:(NSNotification *)notification {
[self reload:self];
[[NSNotificationCenter defaultCenter] postNotificationName:MGMTUpdatedSMSThemeNotification object:self];
}
- (void)windowDidResignKey:(NSNotification *)notification {
[[notification object] close];
}
- (IBAction)header:(id)sender {
[[NSUserDefaults standardUserDefaults] setBool:([headerButton state]==NSOnState) forKey:MGMTShowHeader];
[self reload:self];
[[NSNotificationCenter defaultCenter] postNotificationName:MGMTUpdatedSMSThemeNotification object:self];
}
- (IBAction)footer:(id)sender {
[[NSUserDefaults standardUserDefaults] setBool:([footerButton state]==NSOnState) forKey:MGMTShowFooter];
[self reload:self];
[[NSNotificationCenter defaultCenter] postNotificationName:MGMTUpdatedSMSThemeNotification object:self];
}
- (IBAction)icons:(id)sender {
[[NSUserDefaults standardUserDefaults] setBool:([iconsButton state]==NSOnState) forKey:MGMTShowIcons];
[self reload:self];
[[NSNotificationCenter defaultCenter] postNotificationName:MGMTUpdatedSMSThemeNotification object:self];
}
- (IBAction)showBrowser:(id)sender {
[[browser mainFrame] loadRequest:[NSURLRequest requestWithURL:[NSURL URLWithString:@"http://mrgeckosmedia.com/voicemac/themes/"]]];
[browserWindow makeKeyAndOrderFront:self];

View File

@ -25,7 +25,11 @@
extern NSString * const MGMSIPUserAreaCode;
@interface MGMSIPUser : MGMContactsController <NSAnimationDelegate> {
@interface MGMSIPUser : MGMContactsController
#if (MAC_OS_X_VERSION_MAX_ALLOWED >= 1060)
<NSAnimationDelegate>
#endif
{
MGMUser *user;
MGMSIPAccount *account;
NSMutableArray *calls;

View File

@ -82,7 +82,6 @@ NSString * const MGMSIPUserAreaCode = @"MGMVSIPUserAreaCode";
[progressView release];
[SIPRegistrationTimeout invalidate];
[SIPRegistrationTimeout release];
[super dealloc];
[calls removeAllObjects];
[calls release];
[account logout];
@ -90,6 +89,7 @@ NSString * const MGMSIPUserAreaCode = @"MGMVSIPUserAreaCode";
[contacts stop];
[contacts release];
[user release];
[super dealloc];
}
- (void)registerSettings {

View File

@ -117,9 +117,13 @@
[theAlert setMessageText:@"Error sending a SMS Message"];
[theAlert setInformativeText:@"You need to at least have 1 contact to send to."];
[theAlert runModal];
} else if ([[SMSTextView string] isEqual:@""]) {
NSAlert *theAlert = [[NSAlert new] autorelease];
[theAlert setMessageText:@"Error sending a SMS Message"];
[theAlert setInformativeText:@"Message is blank."];
[theAlert runModal];
} else {
if ([[SMSTextView string] isEqual:@""])
return;
[SMSTextView setEditable:NO];
sendingMessage = YES;
[sendButton setTitle:@"Sending..."];
[sendButton setEnabled:NO];

View File

@ -98,19 +98,39 @@ const float updateTimeInterval = 300.0;
[[[messagesTable subviews] lastObject] removeFromSuperviewWithoutNeedingDisplay];
[messagesTable reloadData];
}
- (int)numberOfRowsInTableView:(NSTableView *)tableView {
#if (MAC_OS_X_VERSION_MAX_ALLOWED >= 1060)
- (int)numberOfRowsInTableView:(NSTableView *)theTableView
#else
- (NSInteger)numberOfRowsInTableView:(NSTableView *)theTableView
#endif
{
return [SMSMessages count];
}
- (id)tableView:(NSTableView *)tableView objectValueForTableColumn:(NSTableColumn *)tableColumn row:(int)row {
#if (MAC_OS_X_VERSION_MAX_ALLOWED >= 1060)
- (id)tableView:(NSTableView *)theTableView objectValueForTableColumn:(NSTableColumn *)theTableColumn row:(int)theRow
#else
- (id)tableView:(NSTableView *)theTableView objectValueForTableColumn:(NSTableColumn *)theTableColumn row:(NSInteger)theRow
#endif
{
return nil;
}
- (void)tableView:(NSTableView *)tableView willDisplayCell:(id)cell forTableColumn:(NSTableColumn *)tableColumn row:(int)row {
[(MGMViewCell *)cell addSubview:[[SMSMessages objectAtIndex:row] view]];
#if (MAC_OS_X_VERSION_MAX_ALLOWED >= 1060)
- (void)tableView:(NSTableView *)theTableView willDisplayCell:(id)cell forTableColumn:(NSTableColumn *)theTableColumn row:(int)theRow
#else
- (void)tableView:(NSTableView *)theTableView willDisplayCell:(id)cell forTableColumn:(NSTableColumn *)theTableColumn row:(NSInteger)theRow
#endif
{
[(MGMViewCell *)cell addSubview:[[SMSMessages objectAtIndex:theRow] view]];
}
- (BOOL)tableView:(NSTableView *)tableView shouldSelectRow:(int)row {
#if (MAC_OS_X_VERSION_MAX_ALLOWED >= 1060)
- (BOOL)tableView:(NSTableView *)theTableView shouldSelectRow:(int)theRow
#else
- (BOOL)tableView:(NSTableView *)theTableView shouldSelectRow:(NSInteger)theRow
#endif
{
while ([[messageView subviews] count]>0)
[[[messageView subviews] lastObject] removeFromSuperviewWithoutNeedingDisplay];
MGMSMSMessageView *message = [SMSMessages objectAtIndex:row];
MGMSMSMessageView *message = [SMSMessages objectAtIndex:theRow];
[[message SMSSplitView] setFrame:NSMakeRect(0, 0, [messageView frame].size.width, [messageView frame].size.height)];
[messageView addSubview:[message SMSSplitView]];
[SMSWindow makeFirstResponder:[message SMSTextField]];
@ -243,12 +263,22 @@ const float updateTimeInterval = 300.0;
return [[[SMSMessages objectAtIndex:[messagesTable selectedRow]] messageInfo] objectForKey:MGMIPhoneNumber];
}
- (float)splitView:(NSSplitView *)sender constrainMinCoordinate:(float)proposedMin ofSubviewAt:(int)offset {
#if (MAC_OS_X_VERSION_MAX_ALLOWED >= 1060)
- (float)splitView:(NSSplitView *)sender constrainMinCoordinate:(float)proposedMin ofSubviewAt:(int)offset
#else
- (CGFloat)splitView:(NSSplitView *)sender constrainMinCoordinate:(CGFloat)proposedMin ofSubviewAt:(NSInteger)offset
#endif
{
leftMax = [[[sender subviews] objectAtIndex:0] frame].size.width;
rightMax = [[[sender subviews] objectAtIndex:1] frame].size.width;
return 0.0;
}
- (float)splitView:(NSSplitView *)sender constrainMaxCoordinate:(float)proposedMax ofSubviewAt:(int)offset{
#if (MAC_OS_X_VERSION_MAX_ALLOWED >= 1060)
- (float)splitView:(NSSplitView *)sender constrainMaxCoordinate:(float)proposedMax ofSubviewAt:(int)offset
#else
- (CGFloat)splitView:(NSSplitView *)sender constrainMaxCoordinate:(CGFloat)proposedMax ofSubviewAt:(NSInteger)offset
#endif
{
leftMax = [[[sender subviews] objectAtIndex:0] frame].size.width;
rightMax = [[[sender subviews] objectAtIndex:1] frame].size.width;
return proposedMax - 150.0;

View File

@ -173,21 +173,31 @@
tPhotoPath = [[[manager themeManager] incomingIconPath] filePath];
NSMutableDictionary *message = [NSMutableDictionary dictionaryWithDictionary:theMessage];
[message setObject:[[NSNumber numberWithInt:[messages count]-1] stringValue] forKey:MGMIID];
NSMutableArray *classes = [NSMutableArray array];
int type = 1;
if ([[message objectForKey:MGMIYou] boolValue]) {
[classes addObject:MGMTCOutgoing];
type = (([[message objectForKey:MGMIID] intValue]==0 || ![[[messages objectAtIndex:[[message objectForKey:MGMIID] intValue]-1] objectForKey:MGMIYou] boolValue]) ? 1 : 2);
if (type==2)
[classes addObject:MGMTCNext];
[message setObject:yPhotoPath forKey:MGMTPhoto];
[message setObject:NSFullUserName() forKey:MGMTName];
[message setObject:[messageInfo objectForKey:MGMTUserNumber] forKey:MGMIPhoneNumber];
} else {
[classes addObject:MGMTCIncoming];
type = (([[message objectForKey:MGMIID] intValue]==0 || [[[messages objectAtIndex:[[message objectForKey:MGMIID] intValue]-1] objectForKey:MGMIYou] boolValue]) ? 3 : 4);
if (type==4)
[classes addObject:MGMTCNext];
[message setObject:tPhotoPath forKey:MGMTPhoto];
[message setObject:[messageInfo objectForKey:MGMTInName] forKey:MGMTName];
[message setObject:[messageInfo objectForKey:MGMIPhoneNumber] forKey:MGMIPhoneNumber];
}
[classes addObject:MGMTCMessage];
if (![[NSUserDefaults standardUserDefaults] boolForKey:MGMTShowIcons])
[classes addObject:MGMTCHideIcons];
NSDateFormatter *formatter = [[NSDateFormatter new] autorelease];
[formatter setDateFormat:[[[manager themeManager] variant] objectForKey:MGMTDate]];
[SMSView stringByEvaluatingJavaScriptFromString:[NSString stringWithFormat:@"newMessage('%@', '%@', '%@', %@, '%@', '%@', '%@', %d);", [[message objectForKey:MGMIText] javascriptEscape], [[message objectForKey:MGMTPhoto] javascriptEscape], [[message objectForKey:MGMITime] javascriptEscape], [message objectForKey:MGMIID], [[message objectForKey:MGMTName] javascriptEscape], [[[message objectForKey:MGMIPhoneNumber] readableNumber] javascriptEscape], [formatter stringFromDate:[messageInfo objectForKey:MGMITime]], type]];
[SMSView stringByEvaluatingJavaScriptFromString:[NSString stringWithFormat:@"newMessage('%@', '%@', '%@', %@, '%@', '%@', '%@', %d, '%@');", [[[manager themeManager] htmlTextFromMessage:message] javascriptEscape], [[message objectForKey:MGMTPhoto] javascriptEscape], [[message objectForKey:MGMITime] javascriptEscape], [message objectForKey:MGMIID], [[message objectForKey:MGMTName] javascriptEscape], [[[message objectForKey:MGMIPhoneNumber] readableNumber] javascriptEscape], [formatter stringFromDate:[messageInfo objectForKey:MGMITime]], type, [classes componentsJoinedByString:@" "]]];
[SMSView stringByEvaluatingJavaScriptFromString:@"scrollToBottom();"];
}
@ -266,11 +276,21 @@
[self close:self];
}
- (float)splitView:(NSSplitView *)sender constrainMinCoordinate:(float)proposedMin ofSubviewAt:(int)offset {
#if (MAC_OS_X_VERSION_MAX_ALLOWED >= 1060)
- (float)splitView:(NSSplitView *)sender constrainMinCoordinate:(float)proposedMin ofSubviewAt:(int)offset
#else
- (CGFloat)splitView:(NSSplitView *)sender constrainMinCoordinate:(CGFloat)proposedMin ofSubviewAt:(NSInteger)offset
#endif
{
bottomMax = [[[sender subviews] objectAtIndex:1] frame].size.height;
return 50.0;
}
- (float)splitView:(NSSplitView *)sender constrainMaxCoordinate:(float)proposedMax ofSubviewAt:(int)offset{
#if (MAC_OS_X_VERSION_MAX_ALLOWED >= 1060)
- (float)splitView:(NSSplitView *)sender constrainMaxCoordinate:(float)proposedMax ofSubviewAt:(int)offset
#else
- (CGFloat)splitView:(NSSplitView *)sender constrainMaxCoordinate:(CGFloat)proposedMax ofSubviewAt:(NSInteger)offset
#endif
{
bottomMax = [[[sender subviews] objectAtIndex:1] frame].size.height;
return proposedMax - 33.0;
}

View File

@ -1,28 +1,161 @@
#!/bin/bash
#PPCFLAGS="-isysroot /Developer/SDKs/MacOSX10.4u.sdk -mmacosx-version-min=10.4 -arch ppc"
PPCFLAGS="-isysroot /Developer/SDKs/MacOSX10.5.sdk -mmacosx-version-min=10.4 -arch ppc"
#PPCFLAGS="-isysroot /Developer/SDKs/MacOSX10.4u.sdk -mmacosx-version-min=10.4 -arch ppc"
PPCFLAGS="-isysroot /Developer/SDKs/MacOSX10.5.sdk -mmacosx-version-min=10.4 -arch ppc"
PPCCC="/usr/bin/gcc-4.0"
PPCCXX="/usr/bin/g++-4.0"
PPCHOST="ppc-apple-darwin8"
PPCPATH="${PWD}/opt-ppc"
PPCLDFLAGS="-arch ppc"
PPCLDFLAGS="${PPCFLAGS}"
#I386FLAGS="-isysroot /Developer/SDKs/MacOSX10.4u.sdk -mmacosx-version-min=10.4 -arch i386"
I386FLAGS="-isysroot /Developer/SDKs/MacOSX10.5.sdk -mmacosx-version-min=10.4 -arch i386"
#I386FLAGS="-isysroot /Developer/SDKs/MacOSX10.4u.sdk -mmacosx-version-min=10.4 -arch i386"
I386FLAGS="-isysroot /Developer/SDKs/MacOSX10.5.sdk -mmacosx-version-min=10.4 -arch i386"
I386CC="/usr/bin/gcc-4.0"
I386CXX="/usr/bin/g++-4.0"
I386HOST="i386-apple-darwin8"
I386PATH="${PWD}/opt-i386"
I386LDFLAGS="-arch i386"
I386LDFLAGS="${I386FLAGS}"
#X86_64FLAGS="-isysroot /Developer/SDKs/MacOSX10.4u.sdk -mmacosx-version-min=10.5 -arch x86_64"
X86_64FLAGS="-isysroot /Developer/SDKs/MacOSX10.5.sdk -mmacosx-version-min=10.5 -arch x86_64"
#X86_64FLAGS="-isysroot /Developer/SDKs/MacOSX10.4u.sdk -mmacosx-version-min=10.5 -arch x86_64"
X86_64FLAGS="-isysroot /Developer/SDKs/MacOSX10.5.sdk -mmacosx-version-min=10.5 -arch x86_64"
X86_64CC="/usr/bin/gcc-4.0"
X86_64CXX="/usr/bin/g++-4.0"
X86_64HOST="x86_64-apple-darwin9"
X86_64PATH="${PWD}/opt-x86_64"
X86_64LDFLAGS="-arch x86_64"
X86_64LDFLAGS="${X86_64FLAGS}"
STANDARD="--disable-bzlib --enable-pthreads --disable-network --enable-small --disable-ffprobe --disable-ffplay --disable-ffserver --disable-decoder=atrac3 --disable-shared --enable-static \
--disable-decoders \
--enable-decoder=aac \
--enable-decoder=theora \
--enable-decoder=vorbis \
--enable-decoder=wmavoice \
--enable-decoder=wmav2 \
--enable-decoder=wmav1 \
--enable-decoder=wmapro \
--enable-decoder=wavpack \
--enable-decoder=mp3on4 \
--enable-decoder=mp3adu \
--enable-decoder=mp3 \
--enable-decoder=mp2 \
--enable-decoder=mp1 \
--enable-decoder=pcm_zork \
--enable-decoder=pcm_u8 \
--enable-decoder=pcm_u32le \
--enable-decoder=pcm_u32be \
--enable-decoder=pcm_u24le \
--enable-decoder=pcm_u24be \
--enable-decoder=pcm_u16le \
--enable-decoder=pcm_u16be \
--enable-decoder=pcm_s8 \
--enable-decoder=pcm_s32le \
--enable-decoder=pcm_s32be \
--enable-decoder=pcm_s24le \
--enable-decoder=pcm_s24daud \
--enable-decoder=pcm_s24be \
--enable-decoder=pcm_s16le_planar \
--enable-decoder=pcm_s16le \
--enable-decoder=pcm_s16be \
--enable-decoder=pcm_mulaw \
--enable-decoder=pcm_f64le \
--enable-decoder=pcm_f64be \
--enable-decoder=pcm_f32le \
--enable-decoder=pcm_f32be \
--enable-decoder=pcm_dvd \
--enable-decoder=pcm_bluray \
--enable-decoder=pcm_alaw \
--enable-decoder=flac \
--disable-encoders \
--enable-encoder=aac \
--enable-encoder=flac \
--enable-encoder=pcm_alaw \
--enable-encoder=pcm_f32be \
--enable-encoder=pcm_f32le \
--enable-encoder=pcm_f64be \
--enable-encoder=pcm_f64le \
--enable-encoder=pcm_mulaw \
--enable-encoder=pcm_s16be \
--enable-encoder=pcm_s16le \
--enable-encoder=pcm_s24be \
--enable-encoder=pcm_s24daud \
--enable-encoder=pcm_s24le \
--enable-encoder=pcm_s32be \
--enable-encoder=pcm_s32le \
--enable-encoder=pcm_s8 \
--enable-encoder=pcm_u16be \
--enable-encoder=pcm_u16le \
--enable-encoder=pcm_u24be \
--enable-encoder=pcm_u24le \
--enable-encoder=pcm_u32be \
--enable-encoder=pcm_u32le \
--enable-encoder=pcm_u8 \
--enable-encoder=pcm_zork \
--enable-encoder=wmav1 \
--enable-encoder=wmav2 \
--disable-demuxers \
--enable-demuxer=aac \
--enable-demuxer=ac3 \
--enable-demuxer=aiff \
--enable-demuxer=au \
--enable-demuxer=caf \
--enable-demuxer=flac \
--enable-demuxer=mp3 \
--enable-demuxer=ogg \
--enable-demuxer=pcm_alaw \
--enable-demuxer=pcm_f32be \
--enable-demuxer=pcm_f32le \
--enable-demuxer=pcm_f64be \
--enable-demuxer=pcm_f64le \
--enable-demuxer=pcm_mulaw \
--enable-demuxer=pcm_s16be \
--enable-demuxer=pcm_s16le \
--enable-demuxer=pcm_s24be \
--enable-demuxer=pcm_s24le \
--enable-demuxer=pcm_s32be \
--enable-demuxer=pcm_s32le \
--enable-demuxer=pcm_s8 \
--enable-demuxer=pcm_u16be \
--enable-demuxer=pcm_u16le \
--enable-demuxer=pcm_u24be \
--enable-demuxer=pcm_u24le \
--enable-demuxer=pcm_u32be \
--enable-demuxer=pcm_u32le \
--enable-demuxer=pcm_u8 \
--enable-demuxer=wav \
--disable-muxers \
--enable-muxer=ac3 \
--enable-muxer=aiff \
--enable-muxer=au \
--enable-muxer=flac \
--enable-muxer=matroska_audio \
--enable-muxer=mp3 \
--enable-muxer=ogg \
--enable-muxer=pcm_alaw \
--enable-muxer=pcm_f32be \
--enable-muxer=pcm_f32le \
--enable-muxer=pcm_f64be \
--enable-muxer=pcm_f64le \
--enable-muxer=pcm_mulaw \
--enable-muxer=pcm_s16be \
--enable-muxer=pcm_s16le \
--enable-muxer=pcm_s24be \
--enable-muxer=pcm_s24le \
--enable-muxer=pcm_s32be \
--enable-muxer=pcm_s32le \
--enable-muxer=pcm_s8 \
--enable-muxer=pcm_u16be \
--enable-muxer=pcm_u16le \
--enable-muxer=pcm_u24be \
--enable-muxer=pcm_u24le \
--enable-muxer=pcm_u32be \
--enable-muxer=pcm_u32le \
--enable-muxer=pcm_u8 \
--enable-muxer=voc \
--enable-muxer=wav \
--disable-filters \
--enable-filter=format \
--enable-filter=noformat \
--enable-filter=null \
--enable-filter=nullsink \
--enable-filter=nullsrc \
--enable-filter=slicify"
FFMPEGNAME="ffmpeg"
@ -34,6 +167,71 @@ if [ "$1" = "clean" ]; then
rm -fR opt-i386 opt-x86_64 opt-ppc
rm -fR opt
fi
if [ "$1" = "ios" ]; then
IOS6FLAGS="-isysroot /Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS4.2.sdk -miphoneos-version-min=3.1 -arch armv6"
IOS6CC="/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/gcc-4.2"
IOS6HOST="arm-apple-darwin10"
IOS6PATH="${PWD}/opt-ios6"
IOS6LDFLAGS="${IOS6FLAGS}"
IOS7FLAGS="-isysroot /Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS4.2.sdk -miphoneos-version-min=3.1 -arch armv7"
IOS7CC="/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/gcc-4.2"
IOS7HOST="arm-apple-darwin10"
IOS7PATH="${PWD}/opt-ios7"
IOS7LDFLAGS="${IOS7FLAGS}"
SIMULATORFLAGS="-isysroot /Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator4.2.sdk -miphoneos-version-min=3.1"
SIMULATORCC="/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/gcc-4.2"
SIMULATORHOST="i686-apple-darwin10"
SIMULATORPATH="${PWD}/opt-simulator"
SIMULATORLDFLAGS="${SIMULATORFLAGS}"
echo "Copying FFmpeg"
cp -R ${FFMPEGNAME} ${FFMPEGNAME}-ios6
cp -R ${FFMPEGNAME}-ios6 ${FFMPEGNAME}-ios7
cp -R ${FFMPEGNAME}-ios6 ${FFMPEGNAME}-simulator
echo "Configuring FFmpeg"
cd ${FFMPEGNAME}-ios6
LDFLAGS="${IOS6LDFLAGS} -L${IOS6PATH}/lib" CFLAGS="${IOS6FLAGS} -I${IOS6PATH}/include -mdynamic-no-pic" CC="${IOS6CC}" ./configure --prefix="${IOS6PATH}" --arch=armv6 --cc="${IOS6CC}" --disable-mmx --disable-iwmmxt --disable-armvfp --disable-armv5te --enable-armv6 --disable-asm --enable-cross-compile --target-os=darwin ${STANDARD}
cd ../${FFMPEGNAME}-ios7
LDFLAGS="${IOS7LDFLAGS} -L${IOS7PATH}/lib" CFLAGS="${IOS7FLAGS} -I${IOS7PATH}/include -mdynamic-no-pic" CC="${IOS7CC}" ./configure --prefix="${IOS7PATH}" --arch=armv7 --cc="${IOS7CC}" --disable-mmx --disable-iwmmxt --disable-armvfp --disable-armv5te --enable-armv6 --disable-asm --enable-cross-compile --target-os=darwin ${STANDARD}
cd ../${FFMPEGNAME}-simulator
LDFLAGS="${SIMULATORLDFLAGS} -L${SIMULATORPATH}/lib" CFLAGS="${SIMULATORFLAGS} -I${SIMULATORPATH}/include -mdynamic-no-pic" CC="${SIMULATORCC}" ./configure --prefix="${SIMULATORPATH}" --cc="${SIMULATORCC}" --disable-asm ${STANDARD}
echo "Compiling FFmpeg"
cd ../${FFMPEGNAME}-ios6
make
cd ../${FFMPEGNAME}-ios7
make
cd ../${FFMPEGNAME}-simulator
make
echo "Installing FFmpeg"
cd ../${FFMPEGNAME}-ios6
make install
cd ../${FFMPEGNAME}-ios7
make install
cd ../${FFMPEGNAME}-simulator
make install
echo "Making FFmpeg Universal"
cd ../
mkdir -p ./opt/bin
mkdir -p ./opt/lib
cp -R "${IOS6PATH}/include" ./opt/include
cp ./${FFMPEGNAME}-ios6/libavcodec/audioconvert.h ./opt/include/libavcodec/audioconvert.h
cp ./${FFMPEGNAME}-ios6/libavcodec/colorspace.h ./opt/include/libavcodec/colorspace.h
cp ./${FFMPEGNAME}-ios6/config.h ./opt/include/ffconfig.h
lipo -create "${IOS6PATH}/lib/libavcodec.a" "${IOS7PATH}/lib/libavcodec.a" "${SIMULATORPATH}/lib/libavcodec.a" -output ./opt/lib/libavcodec-ios.a
lipo -create "${IOS6PATH}/lib/libavdevice.a" "${IOS7PATH}/lib/libavdevice.a" "${SIMULATORPATH}/lib/libavdevice.a" -output ./opt/lib/libavdevice-ios.a
lipo -create "${IOS6PATH}/lib/libavformat.a" "${IOS7PATH}/lib/libavformat.a" "${SIMULATORPATH}/lib/libavformat.a" -output ./opt/lib/libavformat-ios.a
lipo -create "${IOS6PATH}/lib/libavutil.a" "${IOS7PATH}/lib/libavutil.a" "${SIMULATORPATH}/lib/libavutil.a" -output ./opt/lib/libavutil-ios.a
lipo -create "${IOS6PATH}/lib/libswscale.a" "${IOS7PATH}/lib/libswscale.a" "${SIMULATORPATH}/lib/libswscale.a" -output ./opt/lib/libswscale-ios.a
lipo -create "${IOS6PATH}/bin/ffmpeg" "${IOS7PATH}/bin/ffmpeg" "${SIMULATORPATH}/bin/ffmpeg" -output ./opt/bin/ffmpeg-ios
fi
if [ "$1" = "" ]; then
echo "Copying FFmpeg"
cp -R ${FFMPEGNAME} ${FFMPEGNAME}-ppc
@ -42,413 +240,11 @@ if [ "$1" = "" ]; then
echo "Configuring FFmpeg"
cd ${FFMPEGNAME}-ppc
LDFLAGS="${PPCLDFLAGS} -L${PPCPATH}/lib" CFLAGS="${PPCFLAGS} -I${PPCPATH}/include -mdynamic-no-pic" CXXFLAGS="${PPCFLAGS} -I${PPCPATH}/include -mdynamic-no-pic" CC="${PPCCC}" CXX="${PPCCXX}" ./configure --prefix="${PPCPATH}" --arch=ppc --disable-bzlib --enable-pthreads --disable-network --enable-small --disable-ffprobe --disable-ffplay --disable-ffserver --disable-decoder=atrac3 --disable-shared --enable-static \
--disable-decoders \
--enable-decoder=aac \
--enable-decoder=theora \
--enable-decoder=vorbis \
--enable-decoder=wmavoice \
--enable-decoder=wmav2 \
--enable-decoder=wmav1 \
--enable-decoder=wmapro \
--enable-decoder=wavpack \
--enable-decoder=mp3on4 \
--enable-decoder=mp3adu \
--enable-decoder=mp3 \
--enable-decoder=mp2 \
--enable-decoder=mp1 \
--enable-decoder=pcm_zork \
--enable-decoder=pcm_u8 \
--enable-decoder=pcm_u32le \
--enable-decoder=pcm_u32be \
--enable-decoder=pcm_u24le \
--enable-decoder=pcm_u24be \
--enable-decoder=pcm_u16le \
--enable-decoder=pcm_u16be \
--enable-decoder=pcm_s8 \
--enable-decoder=pcm_s32le \
--enable-decoder=pcm_s32be \
--enable-decoder=pcm_s24le \
--enable-decoder=pcm_s24daud \
--enable-decoder=pcm_s24be \
--enable-decoder=pcm_s16le_planar \
--enable-decoder=pcm_s16le \
--enable-decoder=pcm_s16be \
--enable-decoder=pcm_mulaw \
--enable-decoder=pcm_f64le \
--enable-decoder=pcm_f64be \
--enable-decoder=pcm_f32le \
--enable-decoder=pcm_f32be \
--enable-decoder=pcm_dvd \
--enable-decoder=pcm_bluray \
--enable-decoder=pcm_alaw \
--enable-decoder=flac \
--disable-encoders \
--enable-encoder=aac \
--enable-encoder=flac \
--enable-encoder=pcm_alaw \
--enable-encoder=pcm_f32be \
--enable-encoder=pcm_f32le \
--enable-encoder=pcm_f64be \
--enable-encoder=pcm_f64le \
--enable-encoder=pcm_mulaw \
--enable-encoder=pcm_s16be \
--enable-encoder=pcm_s16le \
--enable-encoder=pcm_s24be \
--enable-encoder=pcm_s24daud \
--enable-encoder=pcm_s24le \
--enable-encoder=pcm_s32be \
--enable-encoder=pcm_s32le \
--enable-encoder=pcm_s8 \
--enable-encoder=pcm_u16be \
--enable-encoder=pcm_u16le \
--enable-encoder=pcm_u24be \
--enable-encoder=pcm_u24le \
--enable-encoder=pcm_u32be \
--enable-encoder=pcm_u32le \
--enable-encoder=pcm_u8 \
--enable-encoder=pcm_zork \
--enable-encoder=wmav1 \
--enable-encoder=wmav2 \
--disable-demuxers \
--enable-demuxer=aac \
--enable-demuxer=ac3 \
--enable-demuxer=aiff \
--enable-demuxer=au \
--enable-demuxer=caf \
--enable-demuxer=flac \
--enable-demuxer=mp3 \
--enable-demuxer=ogg \
--enable-demuxer=pcm_alaw \
--enable-demuxer=pcm_f32be \
--enable-demuxer=pcm_f32le \
--enable-demuxer=pcm_f64be \
--enable-demuxer=pcm_f64le \
--enable-demuxer=pcm_mulaw \
--enable-demuxer=pcm_s16be \
--enable-demuxer=pcm_s16le \
--enable-demuxer=pcm_s24be \
--enable-demuxer=pcm_s24le \
--enable-demuxer=pcm_s32be \
--enable-demuxer=pcm_s32le \
--enable-demuxer=pcm_s8 \
--enable-demuxer=pcm_u16be \
--enable-demuxer=pcm_u16le \
--enable-demuxer=pcm_u24be \
--enable-demuxer=pcm_u24le \
--enable-demuxer=pcm_u32be \
--enable-demuxer=pcm_u32le \
--enable-demuxer=pcm_u8 \
--enable-demuxer=wav \
--disable-muxers \
--enable-muxer=ac3 \
--enable-muxer=aiff \
--enable-muxer=au \
--enable-muxer=flac \
--enable-muxer=matroska_audio \
--enable-muxer=mp3 \
--enable-muxer=ogg \
--enable-muxer=pcm_alaw \
--enable-muxer=pcm_f32be \
--enable-muxer=pcm_f32le \
--enable-muxer=pcm_f64be \
--enable-muxer=pcm_f64le \
--enable-muxer=pcm_mulaw \
--enable-muxer=pcm_s16be \
--enable-muxer=pcm_s16le \
--enable-muxer=pcm_s24be \
--enable-muxer=pcm_s24le \
--enable-muxer=pcm_s32be \
--enable-muxer=pcm_s32le \
--enable-muxer=pcm_s8 \
--enable-muxer=pcm_u16be \
--enable-muxer=pcm_u16le \
--enable-muxer=pcm_u24be \
--enable-muxer=pcm_u24le \
--enable-muxer=pcm_u32be \
--enable-muxer=pcm_u32le \
--enable-muxer=pcm_u8 \
--enable-muxer=voc \
--enable-muxer=wav \
--disable-filters \
--enable-filter=format \
--enable-filter=noformat \
--enable-filter=null \
--enable-filter=nullsink \
--enable-filter=nullsrc \
--enable-filter=slicify
LDFLAGS="${PPCLDFLAGS} -L${PPCPATH}/lib" CFLAGS="${PPCFLAGS} -I${PPCPATH}/include -mdynamic-no-pic" CC="${PPCCC}" ./configure --prefix="${PPCPATH}" --arch=ppc ${STANDARD}
cd ../${FFMPEGNAME}-i386
LDFLAGS="${I386LDFLAGS} -L${I386PATH}/lib" CFLAGS="${I386FLAGS} -I${I386PATH}/include -mdynamic-no-pic" CXXFLAGS="${I386FLAGS} -I${I386PATH}/include -mdynamic-no-pic" CC="${I386CC}" CXX="${I386CXX}" ./configure --prefix="${I386PATH}" --arch=i386 --disable-bzlib --enable-pthreads --disable-network --enable-small --disable-yasm --disable-ffprobe --disable-ffplay --disable-ffserver --disable-decoder=atrac3 --disable-shared --enable-static \
--disable-decoders \
--enable-decoder=aac \
--enable-decoder=theora \
--enable-decoder=vorbis \
--enable-decoder=wmavoice \
--enable-decoder=wmav2 \
--enable-decoder=wmav1 \
--enable-decoder=wmapro \
--enable-decoder=wavpack \
--enable-decoder=mp3on4 \
--enable-decoder=mp3adu \
--enable-decoder=mp3 \
--enable-decoder=mp2 \
--enable-decoder=mp1 \
--enable-decoder=pcm_zork \
--enable-decoder=pcm_u8 \
--enable-decoder=pcm_u32le \
--enable-decoder=pcm_u32be \
--enable-decoder=pcm_u24le \
--enable-decoder=pcm_u24be \
--enable-decoder=pcm_u16le \
--enable-decoder=pcm_u16be \
--enable-decoder=pcm_s8 \
--enable-decoder=pcm_s32le \
--enable-decoder=pcm_s32be \
--enable-decoder=pcm_s24le \
--enable-decoder=pcm_s24daud \
--enable-decoder=pcm_s24be \
--enable-decoder=pcm_s16le_planar \
--enable-decoder=pcm_s16le \
--enable-decoder=pcm_s16be \
--enable-decoder=pcm_mulaw \
--enable-decoder=pcm_f64le \
--enable-decoder=pcm_f64be \
--enable-decoder=pcm_f32le \
--enable-decoder=pcm_f32be \
--enable-decoder=pcm_dvd \
--enable-decoder=pcm_bluray \
--enable-decoder=pcm_alaw \
--enable-decoder=flac \
--disable-encoders \
--enable-encoder=aac \
--enable-encoder=flac \
--enable-encoder=pcm_alaw \
--enable-encoder=pcm_f32be \
--enable-encoder=pcm_f32le \
--enable-encoder=pcm_f64be \
--enable-encoder=pcm_f64le \
--enable-encoder=pcm_mulaw \
--enable-encoder=pcm_s16be \
--enable-encoder=pcm_s16le \
--enable-encoder=pcm_s24be \
--enable-encoder=pcm_s24daud \
--enable-encoder=pcm_s24le \
--enable-encoder=pcm_s32be \
--enable-encoder=pcm_s32le \
--enable-encoder=pcm_s8 \
--enable-encoder=pcm_u16be \
--enable-encoder=pcm_u16le \
--enable-encoder=pcm_u24be \
--enable-encoder=pcm_u24le \
--enable-encoder=pcm_u32be \
--enable-encoder=pcm_u32le \
--enable-encoder=pcm_u8 \
--enable-encoder=pcm_zork \
--enable-encoder=wmav1 \
--enable-encoder=wmav2 \
--disable-demuxers \
--enable-demuxer=aac \
--enable-demuxer=ac3 \
--enable-demuxer=aiff \
--enable-demuxer=au \
--enable-demuxer=caf \
--enable-demuxer=flac \
--enable-demuxer=mp3 \
--enable-demuxer=ogg \
--enable-demuxer=pcm_alaw \
--enable-demuxer=pcm_f32be \
--enable-demuxer=pcm_f32le \
--enable-demuxer=pcm_f64be \
--enable-demuxer=pcm_f64le \
--enable-demuxer=pcm_mulaw \
--enable-demuxer=pcm_s16be \
--enable-demuxer=pcm_s16le \
--enable-demuxer=pcm_s24be \
--enable-demuxer=pcm_s24le \
--enable-demuxer=pcm_s32be \
--enable-demuxer=pcm_s32le \
--enable-demuxer=pcm_s8 \
--enable-demuxer=pcm_u16be \
--enable-demuxer=pcm_u16le \
--enable-demuxer=pcm_u24be \
--enable-demuxer=pcm_u24le \
--enable-demuxer=pcm_u32be \
--enable-demuxer=pcm_u32le \
--enable-demuxer=pcm_u8 \
--enable-demuxer=wav \
--disable-muxers \
--enable-muxer=ac3 \
--enable-muxer=aiff \
--enable-muxer=au \
--enable-muxer=flac \
--enable-muxer=matroska_audio \
--enable-muxer=mp3 \
--enable-muxer=ogg \
--enable-muxer=pcm_alaw \
--enable-muxer=pcm_f32be \
--enable-muxer=pcm_f32le \
--enable-muxer=pcm_f64be \
--enable-muxer=pcm_f64le \
--enable-muxer=pcm_mulaw \
--enable-muxer=pcm_s16be \
--enable-muxer=pcm_s16le \
--enable-muxer=pcm_s24be \
--enable-muxer=pcm_s24le \
--enable-muxer=pcm_s32be \
--enable-muxer=pcm_s32le \
--enable-muxer=pcm_s8 \
--enable-muxer=pcm_u16be \
--enable-muxer=pcm_u16le \
--enable-muxer=pcm_u24be \
--enable-muxer=pcm_u24le \
--enable-muxer=pcm_u32be \
--enable-muxer=pcm_u32le \
--enable-muxer=pcm_u8 \
--enable-muxer=voc \
--enable-muxer=wav \
--disable-filters \
--enable-filter=format \
--enable-filter=noformat \
--enable-filter=null \
--enable-filter=nullsink \
--enable-filter=nullsrc \
--enable-filter=slicify
LDFLAGS="${I386LDFLAGS} -L${I386PATH}/lib" CFLAGS="${I386FLAGS} -I${I386PATH}/include -mdynamic-no-pic" CC="${I386CC}" ./configure --prefix="${I386PATH}" --arch=i386 ${STANDARD}
cd ../${FFMPEGNAME}-x86_64
LDFLAGS="${X86_64LDFLAGS} -L${X86_64PATH}/lib" CFLAGS="${X86_64FLAGS} -I${X86_64PATH}/include -mdynamic-no-pic" CXXFLAGS="${X86_64FLAGS} -I${X86_64PATH}/include -mdynamic-no-pic" CC="${X86_64CC}" CXX="${X86_64CXX}" ./configure --prefix="${X86_64PATH}" --target-os=darwin --arch=x86_64 --disable-bzlib --enable-pthreads --disable-network --enable-small --disable-yasm --disable-ffprobe --disable-ffplay --disable-ffserver --disable-decoder=atrac3 --disable-shared --enable-static --enable-cross-compile \
--disable-decoders \
--enable-decoder=aac \
--enable-decoder=theora \
--enable-decoder=vorbis \
--enable-decoder=wmavoice \
--enable-decoder=wmav2 \
--enable-decoder=wmav1 \
--enable-decoder=wmapro \
--enable-decoder=wavpack \
--enable-decoder=mp3on4 \
--enable-decoder=mp3adu \
--enable-decoder=mp3 \
--enable-decoder=mp2 \
--enable-decoder=mp1 \
--enable-decoder=pcm_zork \
--enable-decoder=pcm_u8 \
--enable-decoder=pcm_u32le \
--enable-decoder=pcm_u32be \
--enable-decoder=pcm_u24le \
--enable-decoder=pcm_u24be \
--enable-decoder=pcm_u16le \
--enable-decoder=pcm_u16be \
--enable-decoder=pcm_s8 \
--enable-decoder=pcm_s32le \
--enable-decoder=pcm_s32be \
--enable-decoder=pcm_s24le \
--enable-decoder=pcm_s24daud \
--enable-decoder=pcm_s24be \
--enable-decoder=pcm_s16le_planar \
--enable-decoder=pcm_s16le \
--enable-decoder=pcm_s16be \
--enable-decoder=pcm_mulaw \
--enable-decoder=pcm_f64le \
--enable-decoder=pcm_f64be \
--enable-decoder=pcm_f32le \
--enable-decoder=pcm_f32be \
--enable-decoder=pcm_dvd \
--enable-decoder=pcm_bluray \
--enable-decoder=pcm_alaw \
--enable-decoder=flac \
--disable-encoders \
--enable-encoder=aac \
--enable-encoder=flac \
--enable-encoder=pcm_alaw \
--enable-encoder=pcm_f32be \
--enable-encoder=pcm_f32le \
--enable-encoder=pcm_f64be \
--enable-encoder=pcm_f64le \
--enable-encoder=pcm_mulaw \
--enable-encoder=pcm_s16be \
--enable-encoder=pcm_s16le \
--enable-encoder=pcm_s24be \
--enable-encoder=pcm_s24daud \
--enable-encoder=pcm_s24le \
--enable-encoder=pcm_s32be \
--enable-encoder=pcm_s32le \
--enable-encoder=pcm_s8 \
--enable-encoder=pcm_u16be \
--enable-encoder=pcm_u16le \
--enable-encoder=pcm_u24be \
--enable-encoder=pcm_u24le \
--enable-encoder=pcm_u32be \
--enable-encoder=pcm_u32le \
--enable-encoder=pcm_u8 \
--enable-encoder=pcm_zork \
--enable-encoder=wmav1 \
--enable-encoder=wmav2 \
--disable-demuxers \
--enable-demuxer=aac \
--enable-demuxer=ac3 \
--enable-demuxer=aiff \
--enable-demuxer=au \
--enable-demuxer=caf \
--enable-demuxer=flac \
--enable-demuxer=mp3 \
--enable-demuxer=ogg \
--enable-demuxer=pcm_alaw \
--enable-demuxer=pcm_f32be \
--enable-demuxer=pcm_f32le \
--enable-demuxer=pcm_f64be \
--enable-demuxer=pcm_f64le \
--enable-demuxer=pcm_mulaw \
--enable-demuxer=pcm_s16be \
--enable-demuxer=pcm_s16le \
--enable-demuxer=pcm_s24be \
--enable-demuxer=pcm_s24le \
--enable-demuxer=pcm_s32be \
--enable-demuxer=pcm_s32le \
--enable-demuxer=pcm_s8 \
--enable-demuxer=pcm_u16be \
--enable-demuxer=pcm_u16le \
--enable-demuxer=pcm_u24be \
--enable-demuxer=pcm_u24le \
--enable-demuxer=pcm_u32be \
--enable-demuxer=pcm_u32le \
--enable-demuxer=pcm_u8 \
--enable-demuxer=wav \
--disable-muxers \
--enable-muxer=ac3 \
--enable-muxer=aiff \
--enable-muxer=au \
--enable-muxer=flac \
--enable-muxer=matroska_audio \
--enable-muxer=mp3 \
--enable-muxer=ogg \
--enable-muxer=pcm_alaw \
--enable-muxer=pcm_f32be \
--enable-muxer=pcm_f32le \
--enable-muxer=pcm_f64be \
--enable-muxer=pcm_f64le \
--enable-muxer=pcm_mulaw \
--enable-muxer=pcm_s16be \
--enable-muxer=pcm_s16le \
--enable-muxer=pcm_s24be \
--enable-muxer=pcm_s24le \
--enable-muxer=pcm_s32be \
--enable-muxer=pcm_s32le \
--enable-muxer=pcm_s8 \
--enable-muxer=pcm_u16be \
--enable-muxer=pcm_u16le \
--enable-muxer=pcm_u24be \
--enable-muxer=pcm_u24le \
--enable-muxer=pcm_u32be \
--enable-muxer=pcm_u32le \
--enable-muxer=pcm_u8 \
--enable-muxer=voc \
--enable-muxer=wav \
--disable-filters \
--enable-filter=format \
--enable-filter=noformat \
--enable-filter=null \
--enable-filter=nullsink \
--enable-filter=nullsrc \
--enable-filter=slicify
LDFLAGS="${X86_64LDFLAGS} -L${X86_64PATH}/lib" CFLAGS="${X86_64FLAGS} -I${X86_64PATH}/include -mdynamic-no-pic" CC="${X86_64CC}" ./configure --prefix="${X86_64PATH}" --enable-cross-compile --target-os=darwin --arch=x86_64 ${STANDARD}
echo "Compiling FFmpeg"
cd ../${FFMPEGNAME}-ppc

View File

@ -10,7 +10,11 @@
@class MGMPreferencesPane;
@interface MGMPreferences : NSObject <NSWindowDelegate, NSToolbarDelegate> {
@interface MGMPreferences : NSObject
#if (MAC_OS_X_VERSION_MAX_ALLOWED >= 1060)
<NSWindowDelegate, NSToolbarDelegate>
#endif
{
@private
NSWindow *preferencesWindow;
NSMutableArray *preferencesPanes;

File diff suppressed because it is too large Load Diff

View File

@ -4,6 +4,8 @@
<dict>
<key>CFBundleDevelopmentRegion</key>
<string>English</string>
<key>CFBundleDocumentTypes</key>
<array/>
<key>CFBundleExecutable</key>
<string>${EXECUTABLE_NAME}</string>
<key>CFBundleIdentifier</key>
@ -16,13 +18,23 @@
<string>0.1</string>
<key>CFBundleSignature</key>
<string>????</string>
<key>CFBundleURLTypes</key>
<array/>
<key>CFBundleVersion</key>
<string>0.1</string>
<key>LSMinimumSystemVersion</key>
<string>${MACOSX_DEPLOYMENT_TARGET}</string>
<key>NSHumanReadableCopyright</key>
<string>Copyright (c) 2011 Mr. Gecko's Media (James Coleman). http://mrgeckosmedia.com/</string>
<key>NSMainNibFile</key>
<string>MainMenu</string>
<key>NSPrincipalClass</key>
<string>NSApplication</string>
<key>NSServices</key>
<array/>
<key>UTExportedTypeDeclarations</key>
<array/>
<key>UTImportedTypeDeclarations</key>
<array/>
</dict>
</plist>

View File

@ -10,8 +10,6 @@
<string></string>
<key>CFBundleIdentifier</key>
<string>com.MrGeckosMedia.${PRODUCT_NAME:rfc1034Identifier}</string>
<key>NSHumanReadableCopyright</key>
<string>Copyright (c) 2010 Mr. Gecko&apos;s Media (James Coleman). All rights reserved. http://mrgeckosmedia.com/</string>
<key>CFBundleInfoDictionaryVersion</key>
<string>6.0</string>
<key>CFBundleName</key>
@ -24,6 +22,8 @@
<string>????</string>
<key>CFBundleVersion</key>
<string>1</string>
<key>NSHumanReadableCopyright</key>
<string>Copyright (c) 2011 Mr. Gecko&apos;s Media (James Coleman). http://mrgeckosmedia.com/</string>
<key>NSPrincipalClass</key>
<string></string>
</dict>

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

View File

@ -1,7 +1,7 @@
<div class="inContent">
<div class="%MESSAGECLASSES%">
<table border="0" cellpadding="0" cellspacing="0" width="100%">
<tr>
<td valign="bottom" class="pname" width="50"><img src="%PHOTO%" width="45" height="45" /><br />%TIME%</td>
<td valign="bottom" class="pname" width="50"><img src="%PHOTO%" width="45" height="45" /><br /><span class="time">%TIME%</span></td>
<td align="left"><table border="0" cellpadding="0" cellspacing="0">
<tr><td class="ttl">&nbsp;</td><td class="ttm">&nbsp;</td><td class="ttr">&nbsp;</td></tr>
<tr><td class="tml">&nbsp;</td>
@ -11,4 +11,6 @@
</table></td>
</tr>
</table>
<div class="time hideIcon">%TIME%</div>
<div id="insert"></div>
</div>

View File

@ -1,7 +1,8 @@
<div id="inContext">
<div class="%MESSAGECLASSES%">
<table border="0" cellpadding="0" cellspacing="0" width="100%">
<tr>
<td valign="bottom" class="pname" width="50"><img src="%PHOTO%" width="45" height="45" /><br />%TIME%</td>
<td valign="bottom" class="pname" width="50"><img src="%PHOTO%" width="45" height="45" /><br /><span class="time">%TIME%</span></td>
<td align="left"><table border="0" cellpadding="0" cellspacing="0">
<tr><td class="ttl">&nbsp;</td><td class="ttm">&nbsp;</td><td class="ttr">&nbsp;</td></tr>
<tr><td class="tml">&nbsp;</td>
@ -11,4 +12,7 @@
</table></td>
</tr>
</table>
<div class="time hideIcon">%TIME%</div>
<div id="insert"></div>
</div>
</div>

View File

@ -1,7 +1,7 @@
<div class="inNextContent">
<div class="%MESSAGECLASSES%">
<table border="0" cellpadding="0" cellspacing="0" width="100%">
<tr>
<td valign="bottom" class="pname" width="50"><img src="%PHOTO%" width="45" height="45" /><br />%TIME%</td>
<td valign="bottom" class="pname" width="50"><img src="%PHOTO%" width="45" height="45" /><br /><span class="time">%TIME%</span></td>
<td align="left"><table border="0" cellpadding="0" cellspacing="0">
<tr><td class="ttl">&nbsp;</td><td class="ttm">&nbsp;</td><td class="ttr">&nbsp;</td></tr>
<tr><td class="tml">&nbsp;</td>
@ -11,4 +11,6 @@
</table></td>
</tr>
</table>
<div class="time hideIcon">%TIME%</div>
<div id="insert"></div>
</div>

View File

@ -1,7 +1,8 @@
<div id="inNextContext">
<div class="%MESSAGECLASSES%">
<table border="0" cellpadding="0" cellspacing="0" width="100%">
<tr>
<td valign="bottom" class="pname" width="50"><img src="%PHOTO%" width="45" height="45" /><br />%TIME%</td>
<td valign="bottom" class="pname" width="50"><img src="%PHOTO%" width="45" height="45" /><br /><span class="time">%TIME%</span></td>
<td align="left"><table border="0" cellpadding="0" cellspacing="0">
<tr><td class="ttl">&nbsp;</td><td class="ttm">&nbsp;</td><td class="ttr">&nbsp;</td></tr>
<tr><td class="tml">&nbsp;</td>
@ -11,4 +12,7 @@
</table></td>
</tr>
</table>
<div class="time hideIcon">%TIME%</div>
<div id="insert"></div>
</div>
</div>

View File

@ -1,4 +1,4 @@
<div class="outContext">
<div class="%MESSAGECLASSES%">
<table border="0" cellpadding="0" cellspacing="0" width="100%">
<tr>
<td align="right"><table border="0" cellpadding="0" cellspacing="0">
@ -8,7 +8,9 @@
<td class="umr">&nbsp;</td></tr>
<tr><td class="ubl">&nbsp;</td><td class="ubm">&nbsp;</td><td class="ubr">&nbsp;</td></tr>
</table></td>
<td valign="bottom" class="pname" width="50"><img src="%PHOTO%" width="45" height="45" /><br />%TIME%</td>
<td valign="bottom" class="pname" width="50"><img src="%PHOTO%" width="45" height="45" /><br /><span class="time">%TIME%</span></td>
</tr>
</table>
<div class="time hideIcon">%TIME%</div>
<div id="insert"></div>
</div>

View File

@ -1,4 +1,5 @@
<div id="outContext">
<div class="%MESSAGECLASSES%">
<table border="0" cellpadding="0" cellspacing="0" width="100%">
<tr>
<td align="right"><table border="0" cellpadding="0" cellspacing="0">
@ -8,7 +9,10 @@
<td class="umr">&nbsp;</td></tr>
<tr><td class="ubl">&nbsp;</td><td class="ubm">&nbsp;</td><td class="ubr">&nbsp;</td></tr>
</table></td>
<td valign="bottom" class="pname" width="50"><img src="%PHOTO%" width="45" height="45" /><br />%TIME%</td>
<td valign="bottom" class="pname" width="50"><img src="%PHOTO%" width="45" height="45" /><br /><span class="time">%TIME%</span></td>
</tr>
</table>
<div class="time hideIcon">%TIME%</div>
<div id="insert"></div>
</div>
</div>

View File

@ -1,4 +1,4 @@
<div class="outNextContent">
<div class="%MESSAGECLASSES%">
<table border="0" cellpadding="0" cellspacing="0" width="100%">
<tr>
<td align="right"><table border="0" cellpadding="0" cellspacing="0">
@ -8,7 +8,9 @@
<td class="umr">&nbsp;</td></tr>
<tr><td class="ubl">&nbsp;</td><td class="ubm">&nbsp;</td><td class="ubr">&nbsp;</td></tr>
</table></td>
<td valign="bottom" class="pname" width="50"><img src="%PHOTO%" width="45" height="45" /><br />%TIME%</td>
<td valign="bottom" class="pname" width="50"><img src="%PHOTO%" width="45" height="45" /><br /><span class="time">%TIME%</span></td>
</tr>
</table>
<div class="time hideIcon">%TIME%</div>
<div id="insert"></div>
</div>

View File

@ -1,4 +1,5 @@
<div id="outNextContext">
<div class="%MESSAGECLASSES%">
<table border="0" cellpadding="0" cellspacing="0" width="100%">
<tr>
<td align="right"><table border="0" cellpadding="0" cellspacing="0">
@ -8,7 +9,10 @@
<td class="umr">&nbsp;</td></tr>
<tr><td class="ubl">&nbsp;</td><td class="ubm">&nbsp;</td><td class="ubr">&nbsp;</td></tr>
</table></td>
<td valign="bottom" class="pname" width="50"><img src="%PHOTO%" width="45" height="45" /><br />%TIME%</td>
<td valign="bottom" class="pname" width="50"><img src="%PHOTO%" width="45" height="45" /><br /><span class="time">%TIME%</span></td>
</tr>
</table>
<div class="time hideIcon">%TIME%</div>
<div id="insert"></div>
</div>
</div>

View File

@ -1,6 +1,11 @@
<html>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
<style type="text/css">
body {
%FONTSTYLE%
}
.ttl {
background: url("%THEME%/images/ttl.png") no-repeat top left;
width:21px;
@ -103,11 +108,25 @@
height:14px;
font-size:0pt;
}
td.pname {
.time {
font-size:9pt;
color:#999999;
text-align:center;
}
.hideIcons .pname {
display: none;
}
.hideIcon {
display: none;
}
.hideIcons.outgoing .hideIcon {
display: block;
float: right;
}
.hideIcons.incoming .hideIcon {
display: block;
float: left;
}
#inContext {
display: none;
@ -126,7 +145,24 @@ td.pname {
}
</style>
<script type="text/javascript">
function newMessage(text, photourl, time, id, name, number, lastdate, type) {
function findInsert(node) {
var result = null;
if (node.getAttribute("id")=="insert")
return node;
for (var i=0; i<node.childNodes.length; i++) {
if (node.childNodes[i].nodeType==1) {
result = findInsert(node.childNodes[i]);
if (result!=null)
return result;
}
}
return null;
}
var shouldScroll = true;
function newMessage(text, photourl, time, id, name, number, lastdate, type, classes) {
shouldScroll = nearBottom();
var content = document.getElementById("content");
var insert = findInsert(content);
var template = null;
if (type==1) {
template = document.getElementById("outContext").cloneNode(true);
@ -141,17 +177,28 @@ function newMessage(text, photourl, time, id, name, number, lastdate, type) {
template = document.getElementById("inNextContext").cloneNode(true);
template.setAttribute("class", "inNextContent");
}
template.removeAttribute("id");
template.innerHTML = template.innerHTML.replace(/%TEXT%/g, text);
template.innerHTML = template.innerHTML.replace(/%PHOTO%/g, photourl);
template.innerHTML = template.innerHTML.replace(/%TIME%/g, time);
template.innerHTML = template.innerHTML.replace(/%MESSAGEID%/g, id);
template.innerHTML = template.innerHTML.replace(/%NAME%/g, name);
template.innerHTML = template.innerHTML.replace(/%NUMBER%/g, number);
document.getElementById("content").appendChild(template);
template.innerHTML = template.innerHTML.replace(/%MESSAGECLASSES%/g, classes);
template = template.childNodes[1];
if ((type==2 || type==4) && insert!=null) {
insert.parentNode.replaceChild(template, insert);
} else {
if (insert!=null)
insert.parentNode.removeChild(insert);
content.appendChild(template);
}
}
function nearBottom() {
return (document.body.scrollTop >= (document.body.offsetHeight - (window.innerHeight * 1.2)));
}
function scrollToBottom() {
window.scrollTo(0, document.body.scrollHeight);
if (shouldScroll)
document.body.scrollTop = document.body.offsetHeight;
}
</script>
</head>

File diff suppressed because it is too large Load Diff

View File

@ -1,7 +1,7 @@
<div class="inContent">
<div class="%MESSAGECLASSES%">
<table border="0" cellpadding="0" cellspacing="0" width="100%">
<tr>
<td valign="bottom" class="pname" width="50"><img src="%PHOTO%" width="45" height="45" /><br />%TIME%</td>
<td valign="bottom" class="pname" width="50"><img src="%PHOTO%" width="45" height="45" /><br /><span class="time">%TIME%</span></td>
<td align="left"><table border="0" cellpadding="0" cellspacing="0">
<tr><td class="ttl">&nbsp;</td><td class="ttm">&nbsp;</td><td class="ttr">&nbsp;</td></tr>
<tr><td class="tml">&nbsp;</td>
@ -11,4 +11,6 @@
</table></td>
</tr>
</table>
<div class="time hideIcon">%TIME%</div>
<div id="insert"></div>
</div>

View File

@ -1,7 +1,8 @@
<div id="inContext">
<div class="%MESSAGECLASSES%">
<table border="0" cellpadding="0" cellspacing="0" width="100%">
<tr>
<td valign="bottom" class="pname" width="50"><img src="%PHOTO%" width="45" height="45" /><br />%TIME%</td>
<td valign="bottom" class="pname" width="50"><img src="%PHOTO%" width="45" height="45" /><br /><span class="time">%TIME%</span></td>
<td align="left"><table border="0" cellpadding="0" cellspacing="0">
<tr><td class="ttl">&nbsp;</td><td class="ttm">&nbsp;</td><td class="ttr">&nbsp;</td></tr>
<tr><td class="tml">&nbsp;</td>
@ -11,4 +12,7 @@
</table></td>
</tr>
</table>
<div class="time hideIcon">%TIME%</div>
<div id="insert"></div>
</div>
</div>

View File

@ -1,7 +1,7 @@
<div class="inNextContent">
<div class="%MESSAGECLASSES%">
<table border="0" cellpadding="0" cellspacing="0" width="100%">
<tr>
<td valign="bottom" class="pname" width="50"><img src="%PHOTO%" width="45" height="45" /><br />%TIME%</td>
<td valign="bottom" class="pname" width="50"><img src="%PHOTO%" width="45" height="45" /><br /><span class="time">%TIME%</span></td>
<td align="left"><table border="0" cellpadding="0" cellspacing="0">
<tr><td class="ttl">&nbsp;</td><td class="ttm">&nbsp;</td><td class="ttr">&nbsp;</td></tr>
<tr><td class="tml">&nbsp;</td>
@ -11,4 +11,6 @@
</table></td>
</tr>
</table>
<div class="time hideIcon">%TIME%</div>
<div id="insert"></div>
</div>

View File

@ -1,7 +1,8 @@
<div id="inNextContext">
<div class="%MESSAGECLASSES%">
<table border="0" cellpadding="0" cellspacing="0" width="100%">
<tr>
<td valign="bottom" class="pname" width="50"><img src="%PHOTO%" width="45" height="45" /><br />%TIME%</td>
<td valign="bottom" class="pname" width="50"><img src="%PHOTO%" width="45" height="45" /><br /><span class="time">%TIME%</span></td>
<td align="left"><table border="0" cellpadding="0" cellspacing="0">
<tr><td class="ttl">&nbsp;</td><td class="ttm">&nbsp;</td><td class="ttr">&nbsp;</td></tr>
<tr><td class="tml">&nbsp;</td>
@ -11,4 +12,7 @@
</table></td>
</tr>
</table>
<div class="time hideIcon">%TIME%</div>
<div id="insert"></div>
</div>
</div>

View File

@ -1,4 +1,4 @@
<div class="outContext">
<div class="%MESSAGECLASSES%">
<table border="0" cellpadding="0" cellspacing="0" width="100%">
<tr>
<td align="right"><table border="0" cellpadding="0" cellspacing="0">
@ -8,7 +8,9 @@
<td class="umr">&nbsp;</td></tr>
<tr><td class="ubl">&nbsp;</td><td class="ubm">&nbsp;</td><td class="ubr">&nbsp;</td></tr>
</table></td>
<td valign="bottom" class="pname" width="50"><img src="%PHOTO%" width="45" height="45" /><br />%TIME%</td>
<td valign="bottom" class="pname" width="50"><img src="%PHOTO%" width="45" height="45" /><br /><span class="time">%TIME%</span></td>
</tr>
</table>
<div class="time hideIcon">%TIME%</div>
<div id="insert"></div>
</div>

View File

@ -1,4 +1,5 @@
<div id="outContext">
<div class="%MESSAGECLASSES%">
<table border="0" cellpadding="0" cellspacing="0" width="100%">
<tr>
<td align="right"><table border="0" cellpadding="0" cellspacing="0">
@ -8,7 +9,10 @@
<td class="umr">&nbsp;</td></tr>
<tr><td class="ubl">&nbsp;</td><td class="ubm">&nbsp;</td><td class="ubr">&nbsp;</td></tr>
</table></td>
<td valign="bottom" class="pname" width="50"><img src="%PHOTO%" width="45" height="45" /><br />%TIME%</td>
<td valign="bottom" class="pname" width="50"><img src="%PHOTO%" width="45" height="45" /><br /><span class="time">%TIME%</span></td>
</tr>
</table>
<div class="time hideIcon">%TIME%</div>
<div id="insert"></div>
</div>
</div>

View File

@ -1,4 +1,4 @@
<div class="outNextContent">
<div class="%MESSAGECLASSES%">
<table border="0" cellpadding="0" cellspacing="0" width="100%">
<tr>
<td align="right"><table border="0" cellpadding="0" cellspacing="0">
@ -8,7 +8,9 @@
<td class="umr">&nbsp;</td></tr>
<tr><td class="ubl">&nbsp;</td><td class="ubm">&nbsp;</td><td class="ubr">&nbsp;</td></tr>
</table></td>
<td valign="bottom" class="pname" width="50"><img src="%PHOTO%" width="45" height="45" /><br />%TIME%</td>
<td valign="bottom" class="pname" width="50"><img src="%PHOTO%" width="45" height="45" /><br /><span class="time">%TIME%</span></td>
</tr>
</table>
<div class="time hideIcon">%TIME%</div>
<div id="insert"></div>
</div>

View File

@ -1,4 +1,5 @@
<div id="outNextContext">
<div class="%MESSAGECLASSES%">
<table border="0" cellpadding="0" cellspacing="0" width="100%">
<tr>
<td align="right"><table border="0" cellpadding="0" cellspacing="0">
@ -8,7 +9,10 @@
<td class="umr">&nbsp;</td></tr>
<tr><td class="ubl">&nbsp;</td><td class="ubm">&nbsp;</td><td class="ubr">&nbsp;</td></tr>
</table></td>
<td valign="bottom" class="pname" width="50"><img src="%PHOTO%" width="45" height="45" /><br />%TIME%</td>
<td valign="bottom" class="pname" width="50"><img src="%PHOTO%" width="45" height="45" /><br /><span class="time">%TIME%</span></td>
</tr>
</table>
<div class="time hideIcon">%TIME%</div>
<div id="insert"></div>
</div>
</div>

View File

@ -1,6 +1,11 @@
<html>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
<style type="text/css">
body {
%FONTSTYLE%
}
.ttl {
background: url("%THEME%/images/ttl.png") no-repeat top left;
width:21px;
@ -103,11 +108,25 @@
height:14px;
font-size:0pt;
}
td.pname {
.time {
font-size:9pt;
color:#999999;
text-align:center;
}
.hideIcons .pname {
display: none;
}
.hideIcon {
display: none;
}
.hideIcons.outgoing .hideIcon {
display: block;
float: right;
}
.hideIcons.incoming .hideIcon {
display: block;
float: left;
}
#inContext {
display: none;
@ -126,7 +145,24 @@ td.pname {
}
</style>
<script type="text/javascript">
function newMessage(text, photourl, time, id, name, number, lastdate, type) {
function findInsert(node) {
var result = null;
if (node.getAttribute("id")=="insert")
return node;
for (var i=0; i<node.childNodes.length; i++) {
if (node.childNodes[i].nodeType==1) {
result = findInsert(node.childNodes[i]);
if (result!=null)
return result;
}
}
return null;
}
var shouldScroll = true;
function newMessage(text, photourl, time, id, name, number, lastdate, type, classes) {
shouldScroll = nearBottom();
var content = document.getElementById("content");
var insert = findInsert(content);
var template = null;
if (type==1) {
template = document.getElementById("outContext").cloneNode(true);
@ -141,17 +177,28 @@ function newMessage(text, photourl, time, id, name, number, lastdate, type) {
template = document.getElementById("inNextContext").cloneNode(true);
template.setAttribute("class", "inNextContent");
}
template.removeAttribute("id");
template.innerHTML = template.innerHTML.replace(/%TEXT%/g, text);
template.innerHTML = template.innerHTML.replace(/%PHOTO%/g, photourl);
template.innerHTML = template.innerHTML.replace(/%TIME%/g, time);
template.innerHTML = template.innerHTML.replace(/%MESSAGEID%/g, id);
template.innerHTML = template.innerHTML.replace(/%NAME%/g, name);
template.innerHTML = template.innerHTML.replace(/%NUMBER%/g, number);
document.getElementById("content").appendChild(template);
template.innerHTML = template.innerHTML.replace(/%MESSAGECLASSES%/g, classes);
template = template.childNodes[1];
if ((type==2 || type==4) && insert!=null) {
insert.parentNode.replaceChild(template, insert);
} else {
if (insert!=null)
insert.parentNode.removeChild(insert);
content.appendChild(template);
}
}
function nearBottom() {
return (document.body.scrollTop >= (document.body.offsetHeight - (window.innerHeight * 1.2)));
}
function scrollToBottom() {
window.scrollTo(0, document.body.scrollHeight);
if (shouldScroll)
document.body.scrollTop = document.body.offsetHeight;
}
</script>
</head>

View File

@ -21,13 +21,12 @@ X86_64HOST="x86_64-apple-darwin9"
X86_64PATH="${PWD}/opt-x86_64"
X86_64LDFLAGS="-arch x86_64"
FINALPATH="${PWD}/opt"
if [ "$1" = "clean" ]; then
echo "Cleaning PJProject"
rm -fR pjproject-i386 pjproject-x86_64 pjproject-ppc pjproject-ios pjproject-simulator
fi
if [ "$1" = "ios" ]; then
FINALPATH="${PWD}/opt-ios"
IOSCFLAGS="-miphoneos-version-min=3.1"
IOS6PATH="${PWD}/opt-ios6"
IOS7PATH="${PWD}/opt-ios7"
@ -38,6 +37,9 @@ if [ "$1" = "ios" ]; then
cp -R ${PJPROJECTNAME} ${PJPROJECTNAME}-ios6
echo "#define PJ_CONFIG_IPHONE 1" > ${PJPROJECTNAME}-ios6/pjlib/include/pj/config_site.h
echo "#include <pj/config_site_sample.h>" >> ${PJPROJECTNAME}-ios6/pjlib/include/pj/config_site.h
echo "#define PJMEDIA_AUDIO_DEV_HAS_PORTAUDIO 0" >> ${PJPROJECTNAME}-ios6/pjlib/include/pj/config_site.h
echo "#define PJMEDIA_AUDIO_DEV_HAS_COREAUDIO 1" >> ${PJPROJECTNAME}-ios6/pjlib/include/pj/config_site.h
echo "#define PJMEDIA_HAS_G722_CODEC 2" >> ${PJPROJECTNAME}-ios6/pjlib/include/pj/config_site.h
OLDDIR="${PWD}"
cd ${PJPROJECTNAME}-ios6
@ -45,7 +47,6 @@ if [ "$1" = "ios" ]; then
cd "${OLDDIR}"
cp -R ${PJPROJECTNAME}-ios6 ${PJPROJECTNAME}-ios7
cp -R ${PJPROJECTNAME}-ios6 ${PJPROJECTNAME}-simulator
echo "Configuring PJProject"
cd ${PJPROJECTNAME}-ios6
CC="/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/gcc-4.2 -arch armv6" CFLAGS="${IOSCFLAGS}" ./configure-iphone --prefix="${IOS6PATH}"
@ -78,7 +79,7 @@ if [ "$1" = "ios" ]; then
echo "Making PJProject Universal"
mkdir -p "${FINALPATH}/lib/pkgconfig"
cp -R "${PPCPATH}/include" "${FINALPATH}/include"
cp -R "${IOS6PATH}/include" "${FINALPATH}"
lipo -create "${IOS6PATH}/lib/libg7221codec-arm-apple-darwin9.a" "${IOS7PATH}/lib/libg7221codec-arm-apple-darwin9.a" "${SIMULATORPATH}/lib/libg7221codec-arm-apple-darwin9.a" -output "${FINALPATH}/lib/libg7221codec-ios.a"
lipo -create "${IOS6PATH}/lib/libgsmcodec-arm-apple-darwin9.a" "${IOS7PATH}/lib/libgsmcodec-arm-apple-darwin9.a" "${SIMULATORPATH}/lib/libgsmcodec-arm-apple-darwin9.a" -output "${FINALPATH}/lib/libgsmcodec-ios.a"
lipo -create "${IOS6PATH}/lib/libilbccodec-arm-apple-darwin9.a" "${IOS7PATH}/lib/libilbccodec-arm-apple-darwin9.a" "${SIMULATORPATH}/lib/libilbccodec-arm-apple-darwin9.a" -output "${FINALPATH}/lib/libilbccodec-ios.a"
@ -97,7 +98,63 @@ if [ "$1" = "ios" ]; then
lipo -create "${IOS6PATH}/lib/libspeex-arm-apple-darwin9.a" "${IOS7PATH}/lib/libspeex-arm-apple-darwin9.a" "${SIMULATORPATH}/lib/libspeex-arm-apple-darwin9.a" -output "${FINALPATH}/lib/libspeex-ios.a"
lipo -create "${IOS6PATH}/lib/libsrtp-arm-apple-darwin9.a" "${IOS7PATH}/lib/libsrtp-arm-apple-darwin9.a" "${SIMULATORPATH}/lib/libsrtp-arm-apple-darwin9.a" -output "${FINALPATH}/lib/libsrtp-ios.a"
fi
if [ "$1" = "simulator" ]; then
FINALPATH="${PWD}/opt-ios"
IOSCFLAGS="-miphoneos-version-min=3.1"
SIMULATORPATH="${PWD}/opt-simulator"
echo "Copying PJProject"
PJPROJECTNAME="pjproject"
cp -R ${PJPROJECTNAME} ${PJPROJECTNAME}-simulator
echo "#define PJ_CONFIG_IPHONE 1" > ${PJPROJECTNAME}-simulator/pjlib/include/pj/config_site.h
echo "#include <pj/config_site_sample.h>" >> ${PJPROJECTNAME}-simulator/pjlib/include/pj/config_site.h
echo "#define PJMEDIA_AUDIO_DEV_HAS_PORTAUDIO 0" >> ${PJPROJECTNAME}-simulator/pjlib/include/pj/config_site.h
echo "#define PJMEDIA_AUDIO_DEV_HAS_COREAUDIO 1" >> ${PJPROJECTNAME}-simulator/pjlib/include/pj/config_site.h
echo "#define PJMEDIA_HAS_G722_CODEC 2" >> ${PJPROJECTNAME}-simulator/pjlib/include/pj/config_site.h
OLDDIR="${PWD}"
cd ${PJPROJECTNAME}-simulator
patch -p0 < "${OLDDIR}/mips_test.patch"
cd "${OLDDIR}"
echo "Configuring PJProject"
cd ${PJPROJECTNAME}-simulator
DEVPATH="/Developer/Platforms/iPhoneSimulator.platform/Developer" CC="/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/gcc-4.2" CFLAGS="${IOSCFLAGS}" ./configure-iphone --prefix="${SIMULATORPATH}"
cd ../
echo "Compiling PJProject"
cd ${PJPROJECTNAME}-simulator
make dep
make
cd ../
echo "Installing PJProject"
cd ${PJPROJECTNAME}-simulator
make install
cd ../
echo "Making PJProject Universal"
mkdir -p "${FINALPATH}/lib/pkgconfig"
cp -R "${SIMULATORPATH}/include" "${FINALPATH}"
mv "${SIMULATORPATH}/lib/libg7221codec-arm-apple-darwin9.a" "${FINALPATH}/lib/libg7221codec-ios.a"
mv "${SIMULATORPATH}/lib/libgsmcodec-arm-apple-darwin9.a" "${FINALPATH}/lib/libgsmcodec-ios.a"
mv "${SIMULATORPATH}/lib/libilbccodec-arm-apple-darwin9.a" "${FINALPATH}/lib/libilbccodec-ios.a"
mv "${SIMULATORPATH}/lib/libmilenage-arm-apple-darwin9.a" "${FINALPATH}/lib/libmilenage-ios.a"
mv "${SIMULATORPATH}/lib/libpj-arm-apple-darwin9.a" "${FINALPATH}/lib/libpj-ios.a"
mv "${SIMULATORPATH}/lib/libpjlib-util-arm-apple-darwin9.a" "${FINALPATH}/lib/libpjlib-util-ios.a"
mv "${SIMULATORPATH}/lib/libpjmedia-arm-apple-darwin9.a" "${FINALPATH}/lib/libpjmedia-ios.a"
mv "${SIMULATORPATH}/lib/libpjmedia-audiodev-arm-apple-darwin9.a" "${FINALPATH}/lib/libpjmedia-audiodev-ios.a"
mv "${SIMULATORPATH}/lib/libpjmedia-codec-arm-apple-darwin9.a" "${FINALPATH}/lib/libpjmedia-codec-ios.a"
mv "${SIMULATORPATH}/lib/libpjnath-arm-apple-darwin9.a" "${FINALPATH}/lib/libpjnath-ios.a"
mv "${SIMULATORPATH}/lib/libpjsip-arm-apple-darwin9.a" "${FINALPATH}/lib/libpjsip-ios.a"
mv "${SIMULATORPATH}/lib/libpjsip-simple-arm-apple-darwin9.a" "${FINALPATH}/lib/libpjsip-simple-ios.a"
mv "${SIMULATORPATH}/lib/libpjsip-ua-arm-apple-darwin9.a" "${FINALPATH}/lib/libpjsip-ua-ios.a"
mv "${SIMULATORPATH}/lib/libpjsua-arm-apple-darwin9.a" "${FINALPATH}/lib/libpjsua-ios.a"
mv "${SIMULATORPATH}/lib/libresample-arm-apple-darwin9.a" "${FINALPATH}/lib/libresample-ios.a"
mv "${SIMULATORPATH}/lib/libspeex-arm-apple-darwin9.a" "${FINALPATH}/lib/libspeex-ios.a"
mv "${SIMULATORPATH}/lib/libsrtp-arm-apple-darwin9.a" "${FINALPATH}/lib/libsrtp-ios.a"
fi
if [ "$1" = "" ]; then
FINALPATH="${PWD}/opt"
echo "Copying PJProject"
PJPROJECTNAME="pjproject"
cp -R ${PJPROJECTNAME} ${PJPROJECTNAME}-ppc
@ -138,7 +195,7 @@ if [ "$1" = "" ]; then
echo "Making PJProject Universal"
mkdir -p "${FINALPATH}/lib/pkgconfig"
cp -R "${PPCPATH}/include" "${FINALPATH}/include"
cp -R "${PPCPATH}/include" "${FINALPATH}"
lipo -create "${PPCPATH}/lib/libg7221codec-powerpc-apple-darwin8.a" "${I386PATH}/lib/libg7221codec-i386-apple-darwin8.a" "${X86_64PATH}/lib/libg7221codec-x86_64-apple-darwin9.a" -output "${FINALPATH}/lib/libg7221codec.a"
lipo -create "${PPCPATH}/lib/libgsmcodec-powerpc-apple-darwin8.a" "${I386PATH}/lib/libgsmcodec-i386-apple-darwin8.a" "${X86_64PATH}/lib/libgsmcodec-x86_64-apple-darwin9.a" -output "${FINALPATH}/lib/libgsmcodec.a"
lipo -create "${PPCPATH}/lib/libilbccodec-powerpc-apple-darwin8.a" "${I386PATH}/lib/libilbccodec-i386-apple-darwin8.a" "${X86_64PATH}/lib/libilbccodec-x86_64-apple-darwin9.a" -output "${FINALPATH}/lib/libilbccodec.a"

View File

@ -3,7 +3,7 @@ To get the latest source to PJProject, run the command below.
svn checkout http://svn.pjsip.org/repos/pjproject/trunk pjproject
To get the revision that I am using in VoiceMac and VoiceMob, run the command below.
svn checkout -r 3436 http://svn.pjsip.org/repos/pjproject/trunk pjproject
svn checkout -r 3466 http://svn.pjsip.org/repos/pjproject/trunk pjproject
Building.
To build for VoiceMac, run the command below.

Binary file not shown.

View File

@ -64,11 +64,11 @@
13E42FB307B3F0F600E4EEF1 /* CoreData.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = CoreData.framework; path = /System/Library/Frameworks/CoreData.framework; sourceTree = "<absolute>"; };
29B97324FDCFA39411CA2CEA /* AppKit.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = AppKit.framework; path = /System/Library/Frameworks/AppKit.framework; sourceTree = "<absolute>"; };
29B97325FDCFA39411CA2CEA /* Foundation.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Foundation.framework; path = /System/Library/Frameworks/Foundation.framework; sourceTree = "<absolute>"; };
2A033E2A13310AF300E9070B /* prefix.pch */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = prefix.pch; path = "Classes/Theme Tester/prefix.pch"; sourceTree = "<group>"; };
2A19272512B7BD0F00B065ED /* blankicon.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = blankicon.png; sourceTree = "<group>"; };
2A6D4DF012470DC0009C4029 /* main.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = main.m; path = "Classes/Theme Tester/main.m"; sourceTree = "<group>"; };
2A6D4DF112470DC0009C4029 /* MGMThemeTesterController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MGMThemeTesterController.h; sourceTree = "<group>"; };
2A6D4DF212470DC0009C4029 /* MGMThemeTesterController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = MGMThemeTesterController.m; sourceTree = "<group>"; };
2A6D4DF312470DC0009C4029 /* Theme Tester_Prefix.pch */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = "Theme Tester_Prefix.pch"; path = "Classes/Theme Tester/Theme Tester_Prefix.pch"; sourceTree = "<group>"; };
2A6D4DF912470E0A009C4029 /* English */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.strings; name = English; path = English.lproj/InfoPlist.strings; sourceTree = "<group>"; };
2A6D4DFA12470E0A009C4029 /* English */ = {isa = PBXFileReference; lastKnownFileType = file.xib; name = English; path = English.lproj/MainMenu.xib; sourceTree = "<group>"; };
2A6D4DFB12470E0A009C4029 /* Info.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = "<group>"; };
@ -138,7 +138,7 @@
isa = PBXGroup;
children = (
2A6D4DF012470DC0009C4029 /* main.m */,
2A6D4DF312470DC0009C4029 /* Theme Tester_Prefix.pch */,
2A033E2A13310AF300E9070B /* prefix.pch */,
);
name = "Other Sources";
sourceTree = "<group>";
@ -317,7 +317,7 @@
GCC_MODEL_TUNING = G5;
GCC_OPTIMIZATION_LEVEL = 0;
GCC_PRECOMPILE_PREFIX_HEADER = YES;
GCC_PREFIX_HEADER = "Classes/Theme Tester/Theme Tester_Prefix.pch";
GCC_PREFIX_HEADER = "Classes/Theme Tester/prefix.pch";
INFOPLIST_FILE = "Resources/Theme Tester/Info.plist";
INSTALL_PATH = "$(HOME)/Applications";
PRODUCT_NAME = "Theme Tester";
@ -335,8 +335,8 @@
);
GCC_MODEL_TUNING = G5;
GCC_PRECOMPILE_PREFIX_HEADER = YES;
GCC_PREFIX_HEADER = Theme_Tester_Prefix.pch;
INFOPLIST_FILE = "Theme_Tester-Info.plist";
GCC_PREFIX_HEADER = "Classes/Theme Tester/prefix.pch";
INFOPLIST_FILE = "Resources/Theme Tester/Info.plist";
INSTALL_PATH = "$(HOME)/Applications";
PRODUCT_NAME = "Theme Tester";
};
@ -345,14 +345,9 @@
C01FCF4F08A954540054247B /* Debug */ = {
isa = XCBuildConfiguration;
buildSettings = {
ARCHS = (
ppc,
i386,
x86_64,
);
ARCHS = "$(ARCHS_STANDARD_32_64_BIT)";
GCC_C_LANGUAGE_STANDARD = gnu99;
GCC_OPTIMIZATION_LEVEL = 0;
GCC_VERSION = 4.2;
GCC_WARN_ABOUT_RETURN_TYPE = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
HEADER_SEARCH_PATHS = /usr/include/libxml2;
@ -360,21 +355,15 @@
"MACOSX_DEPLOYMENT_TARGET[arch=x86_64]" = 10.5;
ONLY_ACTIVE_ARCH = YES;
PREBINDING = NO;
SDKROOT = macosx10.6;
VALID_ARCHS = "ppc i386 x86_64";
SDKROOT = macosx10.5;
};
name = Debug;
};
C01FCF5008A954540054247B /* Release */ = {
isa = XCBuildConfiguration;
buildSettings = {
ARCHS = (
ppc,
i386,
x86_64,
);
ARCHS = "$(ARCHS_STANDARD_32_64_BIT)";
GCC_C_LANGUAGE_STANDARD = gnu99;
GCC_VERSION = 4.2;
GCC_WARN_ABOUT_RETURN_TYPE = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
HEADER_SEARCH_PATHS = /usr/include/libxml2;
@ -382,7 +371,6 @@
"MACOSX_DEPLOYMENT_TARGET[arch=x86_64]" = 10.5;
PREBINDING = NO;
SDKROOT = macosx10.6;
VALID_ARCHS = "ppc i386 x86_64";
};
name = Release;
};

View File

@ -91,8 +91,6 @@
2A771344124C4F9A00D68042 /* AVFoundation.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 2A771343124C4F9A00D68042 /* AVFoundation.framework */; };
2A7713BD124C6A4900D68042 /* MGMSound.m in Sources */ = {isa = PBXBuildFile; fileRef = 2A77133B124C4CE200D68042 /* MGMSound.m */; };
2A7713BF124C6A5B00D68042 /* MGMSound.h in Headers */ = {isa = PBXBuildFile; fileRef = 2A77133A124C4CE200D68042 /* MGMSound.h */; settings = {ATTRIBUTES = (Public, ); }; };
2AB13633130AB39C00F2B0E8 /* libxml2.2.dylib in Frameworks */ = {isa = PBXBuildFile; fileRef = 2AB13632130AB39C00F2B0E8 /* libxml2.2.dylib */; };
2AB13634130AB39C00F2B0E8 /* libxml2.2.dylib in Frameworks */ = {isa = PBXBuildFile; fileRef = 2AB13632130AB39C00F2B0E8 /* libxml2.2.dylib */; };
2AE6EE621249DA790006B5AC /* MGMAddressBook.m in Sources */ = {isa = PBXBuildFile; fileRef = 2A1171A61245676A00D119B5 /* MGMAddressBook.m */; };
2AE6EE631249DA790006B5AC /* MGMContacts.m in Sources */ = {isa = PBXBuildFile; fileRef = 2A1171A81245676A00D119B5 /* MGMContacts.m */; };
2AE6EE641249DA790006B5AC /* MGMContactsProtocol.m in Sources */ = {isa = PBXBuildFile; fileRef = 2A1171AA1245676A00D119B5 /* MGMContactsProtocol.m */; };
@ -108,10 +106,9 @@
2AE6EE701249DA870006B5AC /* libMGMUsers.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 2AE6EE0F1249D70F0006B5AC /* libMGMUsers.a */; };
2AE6EE761249DB2F0006B5AC /* CoreGraphics.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 2AE6EE751249DB2F0006B5AC /* CoreGraphics.framework */; };
2AE6EE7A1249DB2F0006B5AC /* UIKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 2AE6EE791249DB2F0006B5AC /* UIKit.framework */; };
2AE8D44B1309EFF500D0104B /* libcrypto.0.9.7.dylib in Frameworks */ = {isa = PBXBuildFile; fileRef = 2AE8D44A1309EFF500D0104B /* libcrypto.0.9.7.dylib */; };
2AE8D44C1309EFF500D0104B /* libcrypto.0.9.7.dylib in Frameworks */ = {isa = PBXBuildFile; fileRef = 2AE8D44A1309EFF500D0104B /* libcrypto.0.9.7.dylib */; };
2AE8D44E1309F00200D0104B /* libssl.0.9.7.dylib in Frameworks */ = {isa = PBXBuildFile; fileRef = 2AE8D44D1309F00200D0104B /* libssl.0.9.7.dylib */; };
2AE8D44F1309F00200D0104B /* libssl.0.9.7.dylib in Frameworks */ = {isa = PBXBuildFile; fileRef = 2AE8D44D1309F00200D0104B /* libssl.0.9.7.dylib */; };
2AF3A2721327B2B1003D0507 /* libssl.dylib in Frameworks */ = {isa = PBXBuildFile; fileRef = 2AF3A2711327B2B1003D0507 /* libssl.dylib */; };
2AF3A2741327B2BD003D0507 /* libcrypto.dylib in Frameworks */ = {isa = PBXBuildFile; fileRef = 2AF3A2731327B2BD003D0507 /* libcrypto.dylib */; };
2AF3A2761327B2CB003D0507 /* libxml2.dylib in Frameworks */ = {isa = PBXBuildFile; fileRef = 2AF3A2751327B2CB003D0507 /* libxml2.dylib */; };
8DC2EF570486A6940098B216 /* Cocoa.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 1058C7B1FEA5585E11CA2CBB /* Cocoa.framework */; };
/* End PBXBuildFile section */
@ -179,7 +176,6 @@
2A1171BC1245676A00D119B5 /* MGMSIPURL.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MGMSIPURL.h; sourceTree = "<group>"; };
2A1171BD1245676A00D119B5 /* MGMSIPURL.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = MGMSIPURL.m; sourceTree = "<group>"; };
2A1171BE1245676A00D119B5 /* VoiceBase.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = VoiceBase.h; sourceTree = "<group>"; };
2A1171BF1245676A00D119B5 /* VoiceBase_Prefix.pch */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = VoiceBase_Prefix.pch; path = Classes/VoiceBase/VoiceBase_Prefix.pch; sourceTree = "<group>"; };
2A1171DC1245678600D119B5 /* English */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.strings; name = English; path = English.lproj/InfoPlist.strings; sourceTree = "<group>"; };
2A1171DD1245678600D119B5 /* Info.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = "<group>"; };
2A1172981245684600D119B5 /* MGMUsers.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = MGMUsers.framework; path = Frameworks/MGMUsers.framework; sourceTree = "<group>"; };
@ -206,20 +202,21 @@
2A487CAE124BE0C400E8EE4E /* MGMXML.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MGMXML.h; sourceTree = "<group>"; };
2A50699A1315726C003CACD5 /* MGMDelegateInfo.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MGMDelegateInfo.h; sourceTree = "<group>"; };
2A50699B1315726D003CACD5 /* MGMDelegateInfo.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = MGMDelegateInfo.m; sourceTree = "<group>"; };
2A5B70CE13310E9100F89B56 /* prefix.pch */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = prefix.pch; path = Classes/VoiceBase/prefix.pch; sourceTree = "<group>"; };
2A5B70CF13310E9100F89B56 /* touch_prefix.pch */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = touch_prefix.pch; path = Classes/VoiceBase/touch_prefix.pch; sourceTree = "<group>"; };
2A77133A124C4CE200D68042 /* MGMSound.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MGMSound.h; sourceTree = "<group>"; };
2A77133B124C4CE200D68042 /* MGMSound.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = MGMSound.m; sourceTree = "<group>"; };
2A77133F124C4D2800D68042 /* AudioToolbox.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = AudioToolbox.framework; path = System/Library/Frameworks/AudioToolbox.framework; sourceTree = SDKROOT; };
2A771343124C4F9A00D68042 /* AVFoundation.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = AVFoundation.framework; path = System/Library/Frameworks/AVFoundation.framework; sourceTree = SDKROOT; };
2AB13632130AB39C00F2B0E8 /* libxml2.2.dylib */ = {isa = PBXFileReference; lastKnownFileType = "compiled.mach-o.dylib"; name = libxml2.2.dylib; path = usr/lib/libxml2.2.dylib; sourceTree = SDKROOT; };
2AE6EE0F1249D70F0006B5AC /* libMGMUsers.a */ = {isa = PBXFileReference; lastKnownFileType = archive.ar; name = libMGMUsers.a; path = Libraries/lib/libMGMUsers.a; sourceTree = "<group>"; };
2AE6EE531249DA0B0006B5AC /* libVoiceBase.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = libVoiceBase.a; sourceTree = BUILT_PRODUCTS_DIR; };
2AE6EE731249DB2F0006B5AC /* CoreData.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = CoreData.framework; path = System/Library/Frameworks/CoreData.framework; sourceTree = SDKROOT; };
2AE6EE751249DB2F0006B5AC /* CoreGraphics.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = CoreGraphics.framework; path = System/Library/Frameworks/CoreGraphics.framework; sourceTree = SDKROOT; };
2AE6EE771249DB2F0006B5AC /* Foundation.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Foundation.framework; path = System/Library/Frameworks/Foundation.framework; sourceTree = SDKROOT; };
2AE6EE791249DB2F0006B5AC /* UIKit.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = UIKit.framework; path = System/Library/Frameworks/UIKit.framework; sourceTree = SDKROOT; };
2AE6EF191249DBA70006B5AC /* VoiceBaseTouch_Prefix.pch */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = VoiceBaseTouch_Prefix.pch; path = Classes/VoiceBase/VoiceBaseTouch_Prefix.pch; sourceTree = "<group>"; };
2AE8D44A1309EFF500D0104B /* libcrypto.0.9.7.dylib */ = {isa = PBXFileReference; lastKnownFileType = "compiled.mach-o.dylib"; name = libcrypto.0.9.7.dylib; path = usr/lib/libcrypto.0.9.7.dylib; sourceTree = SDKROOT; };
2AE8D44D1309F00200D0104B /* libssl.0.9.7.dylib */ = {isa = PBXFileReference; lastKnownFileType = "compiled.mach-o.dylib"; name = libssl.0.9.7.dylib; path = usr/lib/libssl.0.9.7.dylib; sourceTree = SDKROOT; };
2AF3A2711327B2B1003D0507 /* libssl.dylib */ = {isa = PBXFileReference; lastKnownFileType = "compiled.mach-o.dylib"; name = libssl.dylib; path = usr/lib/libssl.dylib; sourceTree = SDKROOT; };
2AF3A2731327B2BD003D0507 /* libcrypto.dylib */ = {isa = PBXFileReference; lastKnownFileType = "compiled.mach-o.dylib"; name = libcrypto.dylib; path = usr/lib/libcrypto.dylib; sourceTree = SDKROOT; };
2AF3A2751327B2CB003D0507 /* libxml2.dylib */ = {isa = PBXFileReference; lastKnownFileType = "compiled.mach-o.dylib"; name = libxml2.dylib; path = usr/lib/libxml2.dylib; sourceTree = SDKROOT; };
8DC2EF5B0486A6940098B216 /* VoiceBase.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = VoiceBase.framework; sourceTree = BUILT_PRODUCTS_DIR; };
D2F7E79907B2D74100F64583 /* CoreData.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = CoreData.framework; path = /System/Library/Frameworks/CoreData.framework; sourceTree = "<absolute>"; };
/* End PBXFileReference section */
@ -236,9 +233,6 @@
2A771344124C4F9A00D68042 /* AVFoundation.framework in Frameworks */,
2A1E9723124D174200D3BEAE /* CoreAudio.framework in Frameworks */,
2A1E9754124D187500D3BEAE /* SystemConfiguration.framework in Frameworks */,
2AE8D44C1309EFF500D0104B /* libcrypto.0.9.7.dylib in Frameworks */,
2AE8D44F1309F00200D0104B /* libssl.0.9.7.dylib in Frameworks */,
2AB13634130AB39C00F2B0E8 /* libxml2.2.dylib in Frameworks */,
);
runOnlyForDeploymentPostprocessing = 0;
};
@ -246,6 +240,9 @@
isa = PBXFrameworksBuildPhase;
buildActionMask = 2147483647;
files = (
2AF3A2721327B2B1003D0507 /* libssl.dylib in Frameworks */,
2AF3A2741327B2BD003D0507 /* libcrypto.dylib in Frameworks */,
2AF3A2761327B2CB003D0507 /* libxml2.dylib in Frameworks */,
8DC2EF570486A6940098B216 /* Cocoa.framework in Frameworks */,
2A1172991245684600D119B5 /* MGMUsers.framework in Frameworks */,
2A1172BB124569AC00D119B5 /* AddressBook.framework in Frameworks */,
@ -253,9 +250,6 @@
2A11730912456C4F00D119B5 /* AudioToolbox.framework in Frameworks */,
2A11730D12456C5F00D119B5 /* AudioUnit.framework in Frameworks */,
2A11731112456C6D00D119B5 /* SystemConfiguration.framework in Frameworks */,
2AE8D44B1309EFF500D0104B /* libcrypto.0.9.7.dylib in Frameworks */,
2AE8D44E1309F00200D0104B /* libssl.0.9.7.dylib in Frameworks */,
2AB13633130AB39C00F2B0E8 /* libxml2.2.dylib in Frameworks */,
);
runOnlyForDeploymentPostprocessing = 0;
};
@ -287,9 +281,9 @@
isa = PBXGroup;
children = (
2AE6EC281249C2C70006B5AC /* Linked Libraries Touch */,
2AF3A2AD1327B314003D0507 /* Linled Libraries */,
2AE6EC2A1249C2D50006B5AC /* Linked Frameworks Touch */,
2AE6EC2B1249C2E20006B5AC /* Other Frameworks Touch */,
2A1172F612456C0600D119B5 /* Linked Libraries */,
1058C7B0FEA5585E11CA2CBB /* Linked Frameworks */,
1058C7B2FEA5585E11CA2CBB /* Other Frameworks */,
);
@ -384,16 +378,6 @@
path = Resources/VoiceBase;
sourceTree = "<group>";
};
2A1172F612456C0600D119B5 /* Linked Libraries */ = {
isa = PBXGroup;
children = (
2AE8D44D1309F00200D0104B /* libssl.0.9.7.dylib */,
2AE8D44A1309EFF500D0104B /* libcrypto.0.9.7.dylib */,
2AB13632130AB39C00F2B0E8 /* libxml2.2.dylib */,
);
name = "Linked Libraries";
sourceTree = "<group>";
};
2A487C92124BE0AB00E8EE4E /* XML */ = {
isa = PBXGroup;
children = (
@ -445,11 +429,21 @@
name = "Other Frameworks Touch";
sourceTree = "<group>";
};
2AF3A2AD1327B314003D0507 /* Linled Libraries */ = {
isa = PBXGroup;
children = (
2AF3A2711327B2B1003D0507 /* libssl.dylib */,
2AF3A2731327B2BD003D0507 /* libcrypto.dylib */,
2AF3A2751327B2CB003D0507 /* libxml2.dylib */,
);
name = "Linled Libraries";
sourceTree = "<group>";
};
32C88DFF0371C24200C91783 /* Other Sources */ = {
isa = PBXGroup;
children = (
2AE6EF191249DBA70006B5AC /* VoiceBaseTouch_Prefix.pch */,
2A1171BF1245676A00D119B5 /* VoiceBase_Prefix.pch */,
2A5B70CE13310E9100F89B56 /* prefix.pch */,
2A5B70CF13310E9100F89B56 /* touch_prefix.pch */,
);
name = "Other Sources";
sourceTree = "<group>";
@ -646,12 +640,12 @@
GCC_MODEL_TUNING = G5;
GCC_OPTIMIZATION_LEVEL = 0;
GCC_PRECOMPILE_PREFIX_HEADER = YES;
GCC_PREFIX_HEADER = Classes/VoiceBase/VoiceBase_Prefix.pch;
GCC_PREFIX_HEADER = Classes/VoiceBase/prefix.pch;
HEADER_SEARCH_PATHS = "$(inherited)";
INFOPLIST_FILE = Resources/VoiceBase/Info.plist;
INSTALL_PATH = "@executable_path/../Frameworks";
LIBRARY_SEARCH_PATHS = "$(inherited)";
OTHER_LDFLAGS = "";
OTHER_LDFLAGS = "$(inherited)";
PRODUCT_NAME = VoiceBase;
WRAPPER_EXTENSION = framework;
};
@ -672,12 +666,12 @@
GCC_DYNAMIC_NO_PIC = NO;
GCC_MODEL_TUNING = G5;
GCC_PRECOMPILE_PREFIX_HEADER = YES;
GCC_PREFIX_HEADER = Classes/VoiceBase/VoiceBase_Prefix.pch;
GCC_PREFIX_HEADER = Classes/VoiceBase/prefix.pch;
HEADER_SEARCH_PATHS = "$(inherited)";
INFOPLIST_FILE = Resources/VoiceBase/Info.plist;
INSTALL_PATH = "@executable_path/../Frameworks";
LIBRARY_SEARCH_PATHS = "$(inherited)";
OTHER_LDFLAGS = "";
OTHER_LDFLAGS = "$(inherited)";
PRODUCT_NAME = VoiceBase;
WRAPPER_EXTENSION = framework;
};
@ -686,14 +680,9 @@
1DEB91B208733DA50010E9CD /* Debug */ = {
isa = XCBuildConfiguration;
buildSettings = {
ARCHS = (
ppc,
i386,
x86_64,
);
ARCHS = "$(ARCHS_STANDARD_32_64_BIT)";
GCC_C_LANGUAGE_STANDARD = gnu99;
GCC_OPTIMIZATION_LEVEL = 0;
GCC_VERSION = 4.2;
GCC_WARN_ABOUT_RETURN_TYPE = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
HEADER_SEARCH_PATHS = /usr/include/libxml2;
@ -701,52 +690,39 @@
MACOSX_DEPLOYMENT_TARGET = 10.4;
"MACOSX_DEPLOYMENT_TARGET[arch=x86_64]" = 10.5;
ONLY_ACTIVE_ARCH = YES;
OTHER_LDFLAGS = "";
PREBINDING = NO;
SDKROOT = macosx10.6;
VALID_ARCHS = "ppc i386 x86_64";
SDKROOT = macosx10.5;
};
name = Debug;
};
1DEB91B308733DA50010E9CD /* Release */ = {
isa = XCBuildConfiguration;
buildSettings = {
ARCHS = (
ppc,
i386,
x86_64,
);
ARCHS = "$(ARCHS_STANDARD_32_64_BIT)";
GCC_C_LANGUAGE_STANDARD = gnu99;
GCC_VERSION = 4.2;
GCC_WARN_ABOUT_RETURN_TYPE = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
HEADER_SEARCH_PATHS = /usr/include/libxml2;
LIBRARY_SEARCH_PATHS = "";
MACOSX_DEPLOYMENT_TARGET = 10.4;
"MACOSX_DEPLOYMENT_TARGET[arch=x86_64]" = 10.5;
OTHER_LDFLAGS = "";
PREBINDING = NO;
SDKROOT = macosx10.6;
VALID_ARCHS = "ppc i386 x86_64";
SDKROOT = macosx10.5;
};
name = Release;
};
2A1172E612456A6700D119B5 /* Debug SIP */ = {
isa = XCBuildConfiguration;
buildSettings = {
ARCHS = (
ppc,
i386,
x86_64,
);
ARCHS = "$(ARCHS_STANDARD_32_64_BIT)";
GCC_C_LANGUAGE_STANDARD = gnu99;
GCC_OPTIMIZATION_LEVEL = 0;
GCC_VERSION = 4.2;
GCC_WARN_ABOUT_RETURN_TYPE = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
HEADER_SEARCH_PATHS = (
/usr/include/libxml2,
"\"$(SRCROOT)/SIP/opt/include\"",
);
LIBRARY_SEARCH_PATHS = "\"$(SRCROOT)/SIP/opt/lib\"";
HEADER_SEARCH_PATHS = /usr/include/libxml2;
LIBRARY_SEARCH_PATHS = "";
MACOSX_DEPLOYMENT_TARGET = 10.4;
"MACOSX_DEPLOYMENT_TARGET[arch=x86_64]" = 10.5;
ONLY_ACTIVE_ARCH = YES;
@ -755,9 +731,9 @@
"-DNDEBUG",
"-DMGMSIPENABLED=1",
);
OTHER_LDFLAGS = "";
PREBINDING = NO;
SDKROOT = macosx10.6;
VALID_ARCHS = "ppc i386 x86_64";
SDKROOT = macosx10.5;
};
name = "Debug SIP";
};
@ -778,12 +754,19 @@
GCC_MODEL_TUNING = G5;
GCC_OPTIMIZATION_LEVEL = 0;
GCC_PRECOMPILE_PREFIX_HEADER = YES;
GCC_PREFIX_HEADER = Classes/VoiceBase/VoiceBase_Prefix.pch;
HEADER_SEARCH_PATHS = "$(inherited)";
GCC_PREFIX_HEADER = Classes/VoiceBase/prefix.pch;
HEADER_SEARCH_PATHS = (
"$(inherited)",
"\"$(SRCROOT)/SIP/opt/include\"",
);
INFOPLIST_FILE = Resources/VoiceBase/Info.plist;
INSTALL_PATH = "@executable_path/../Frameworks";
LIBRARY_SEARCH_PATHS = "$(inherited)";
LIBRARY_SEARCH_PATHS = (
"$(inherited)",
"\"$(SRCROOT)/SIP/opt/lib\"",
);
OTHER_LDFLAGS = (
"$(inherited)",
"-lg7221codec",
"-lgsmcodec",
"-lilbccodec",
@ -811,20 +794,12 @@
2A1172E812456A6C00D119B5 /* Release SIP */ = {
isa = XCBuildConfiguration;
buildSettings = {
ARCHS = (
ppc,
i386,
x86_64,
);
ARCHS = "$(ARCHS_STANDARD_32_64_BIT)";
GCC_C_LANGUAGE_STANDARD = gnu99;
GCC_VERSION = 4.2;
GCC_WARN_ABOUT_RETURN_TYPE = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
HEADER_SEARCH_PATHS = (
/usr/include/libxml2,
"\"$(SRCROOT)/SIP/opt/include\"",
);
LIBRARY_SEARCH_PATHS = "\"$(SRCROOT)/SIP/opt/lib\"";
HEADER_SEARCH_PATHS = /usr/include/libxml2;
LIBRARY_SEARCH_PATHS = "";
MACOSX_DEPLOYMENT_TARGET = 10.4;
"MACOSX_DEPLOYMENT_TARGET[arch=x86_64]" = 10.5;
OTHER_CFLAGS = (
@ -832,9 +807,9 @@
"-DNDEBUG",
"-DMGMSIPENABLED=1",
);
OTHER_LDFLAGS = "";
PREBINDING = NO;
SDKROOT = macosx10.6;
VALID_ARCHS = "ppc i386 x86_64";
SDKROOT = macosx10.5;
};
name = "Release SIP";
};
@ -853,12 +828,19 @@
GCC_DYNAMIC_NO_PIC = NO;
GCC_MODEL_TUNING = G5;
GCC_PRECOMPILE_PREFIX_HEADER = YES;
GCC_PREFIX_HEADER = Classes/VoiceBase/VoiceBase_Prefix.pch;
HEADER_SEARCH_PATHS = "$(inherited)";
GCC_PREFIX_HEADER = Classes/VoiceBase/prefix.pch;
HEADER_SEARCH_PATHS = (
"$(inherited)",
"\"$(SRCROOT)/SIP/opt/include\"",
);
INFOPLIST_FILE = Resources/VoiceBase/Info.plist;
INSTALL_PATH = "@executable_path/../Frameworks";
LIBRARY_SEARCH_PATHS = "$(inherited)";
LIBRARY_SEARCH_PATHS = (
"$(inherited)",
"\"$(SRCROOT)/SIP/opt/lib\"",
);
OTHER_LDFLAGS = (
"$(inherited)",
"-lg7221codec",
"-lgsmcodec",
"-lilbccodec",
@ -891,7 +873,7 @@
COPY_PHASE_STRIP = NO;
GCC_DYNAMIC_NO_PIC = NO;
GCC_OPTIMIZATION_LEVEL = 0;
GCC_PREFIX_HEADER = Classes/VoiceBase/VoiceBaseTouch_Prefix.pch;
GCC_PREFIX_HEADER = Classes/VoiceBase/touch_prefix.pch;
GCC_VERSION = com.apple.compilers.llvm.clang.1_0;
HEADER_SEARCH_PATHS = (
"$(inherited)",
@ -904,12 +886,13 @@
);
OTHER_CFLAGS = "-fblocks";
OTHER_LDFLAGS = (
"$(inherited)",
"-ObjC",
"-all_load",
);
PREBINDING = NO;
PRODUCT_NAME = VoiceBase;
SDKROOT = iphoneos4.2;
SDKROOT = iphoneos4.3;
VALID_ARCHS = "i386 armv6 armv7";
};
name = Debug;
@ -919,16 +902,18 @@
buildSettings = {
ALWAYS_SEARCH_USER_PATHS = NO;
ARCHS = "$(ARCHS_STANDARD_32_BIT)";
GCC_PREFIX_HEADER = Classes/VoiceBase/VoiceBaseTouch_Prefix.pch;
GCC_PREFIX_HEADER = Classes/VoiceBase/touch_prefix.pch;
GCC_VERSION = com.apple.compilers.llvm.clang.1_0;
HEADER_SEARCH_PATHS = (
"$(inherited)",
"\"$(SRCROOT)/Libraries/include\"",
"\"$(SRCROOT)/SIP/opt-ios/include\"",
);
IPHONEOS_DEPLOYMENT_TARGET = 3.1;
LIBRARY_SEARCH_PATHS = (
"$(inherited)",
"\"$(SRCROOT)/Libraries/lib\"",
"\"$(SRCROOT)/SIP/opt-ios/lib\"",
);
OTHER_CFLAGS = (
"-fblocks",
@ -937,6 +922,7 @@
"-DMGMSIPENABLED=1",
);
OTHER_LDFLAGS = (
"$(inherited)",
"-lg7221codec-ios",
"-lgsmcodec-ios",
"-lilbccodec-ios",
@ -954,18 +940,12 @@
"-lresample-ios",
"-lspeex-ios",
"-lsrtp-ios",
"-lz",
"-lavcodec",
"-lavdevice",
"-lavformat",
"-lavutil",
"-lswscale",
"-ObjC",
"-all_load",
);
PREBINDING = NO;
PRODUCT_NAME = VoiceBase;
SDKROOT = iphoneos4.2;
SDKROOT = iphoneos4.3;
VALID_ARCHS = "i386 armv6 armv7";
};
name = "Debug SIP";
@ -978,7 +958,7 @@
COPY_PHASE_STRIP = YES;
DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym";
GCC_ENABLE_FIX_AND_CONTINUE = NO;
GCC_PREFIX_HEADER = Classes/VoiceBase/VoiceBaseTouch_Prefix.pch;
GCC_PREFIX_HEADER = Classes/VoiceBase/touch_prefix.pch;
GCC_VERSION = com.apple.compilers.llvm.clang.1_0;
HEADER_SEARCH_PATHS = (
"$(inherited)",
@ -991,12 +971,13 @@
);
OTHER_CFLAGS = "-fblocks";
OTHER_LDFLAGS = (
"$(inherited)",
"-ObjC",
"-all_load",
);
PREBINDING = NO;
PRODUCT_NAME = VoiceBase;
SDKROOT = iphoneos4.2;
SDKROOT = iphoneos4.3;
VALID_ARCHS = "i386 armv6 armv7";
ZERO_LINK = NO;
};
@ -1007,16 +988,18 @@
buildSettings = {
ALWAYS_SEARCH_USER_PATHS = NO;
ARCHS = "$(ARCHS_STANDARD_32_BIT)";
GCC_PREFIX_HEADER = Classes/VoiceBase/VoiceBaseTouch_Prefix.pch;
GCC_PREFIX_HEADER = Classes/VoiceBase/touch_prefix.pch;
GCC_VERSION = com.apple.compilers.llvm.clang.1_0;
HEADER_SEARCH_PATHS = (
"$(inherited)",
"\"$(SRCROOT)/Libraries/include\"",
"\"$(SRCROOT)/SIP/opt-ios/include\"",
);
IPHONEOS_DEPLOYMENT_TARGET = 3.1;
LIBRARY_SEARCH_PATHS = (
"$(inherited)",
"\"$(SRCROOT)/Libraries/lib\"",
"\"$(SRCROOT)/SIP/opt-ios/lib\"",
);
OTHER_CFLAGS = (
"-fblocks",
@ -1025,6 +1008,7 @@
"-DMGMSIPENABLED=1",
);
OTHER_LDFLAGS = (
"$(inherited)",
"-lg7221codec-ios",
"-lgsmcodec-ios",
"-lilbccodec-ios",
@ -1042,12 +1026,6 @@
"-lresample-ios",
"-lspeex-ios",
"-lsrtp-ios",
"-lz",
"-lavcodec",
"-lavdevice",
"-lavformat",
"-lavutil",
"-lswscale",
"-ObjC",
"-all_load",
);
@ -1055,7 +1033,7 @@
PRIVATE_HEADERS_FOLDER_PATH = /usr/local/include/VoiceBase;
PRODUCT_NAME = VoiceBase;
PUBLIC_HEADERS_FOLDER_PATH = /usr/local/include/VoiceBase;
SDKROOT = iphoneos4.2;
SDKROOT = iphoneos4.3;
VALID_ARCHS = "i386 armv6 armv7";
};
name = "Release SIP";

View File

@ -1,5 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<Workspace>
<Workspace
version = "1.0">
<FileRef
location = "self:VoiceBase.xcodeproj">
</FileRef>

View File

@ -130,6 +130,8 @@
2A11770412458C8A00D119B5 /* blankicon.png in Resources */ = {isa = PBXBuildFile; fileRef = 2A11770312458C8A00D119B5 /* blankicon.png */; };
2A1E9986124D69F300D3BEAE /* NumberOptions.xib in Resources */ = {isa = PBXBuildFile; fileRef = 2A1E9985124D69F300D3BEAE /* NumberOptions.xib */; };
2A91A3F61247D6B900013B43 /* AccountsPane.xib in Resources */ = {isa = PBXBuildFile; fileRef = 2A91A3F81247D6B900013B43 /* AccountsPane.xib */; };
2AF1EF461332D94100615DA3 /* VoiceVerify.xib in Resources */ = {isa = PBXBuildFile; fileRef = 2AF1EF451332D94100615DA3 /* VoiceVerify.xib */; };
2AF1EF4A1332DAB900615DA3 /* MGMVoiceVerify.m in Sources */ = {isa = PBXBuildFile; fileRef = 2AF1EF491332DAB900615DA3 /* MGMVoiceVerify.m */; };
8D11072F0486CEB800E47090 /* Cocoa.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 1058C7A1FEA54F0111CA2CBB /* Cocoa.framework */; };
/* End PBXBuildFile section */
@ -253,7 +255,6 @@
2A11737E12456E4300D119B5 /* MGMTranslucentTabView.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = MGMTranslucentTabView.m; sourceTree = "<group>"; };
2A11737F12456E4300D119B5 /* MGMViewCell.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MGMViewCell.h; sourceTree = "<group>"; };
2A11738012456E4300D119B5 /* MGMViewCell.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = MGMViewCell.m; sourceTree = "<group>"; };
2A11738112456E4300D119B5 /* VoiceMac_Prefix.pch */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = VoiceMac_Prefix.pch; path = Classes/VoiceMac/VoiceMac_Prefix.pch; sourceTree = "<group>"; };
2A1173AF12456F2400D119B5 /* English */ = {isa = PBXFileReference; lastKnownFileType = file.xib; name = English; path = English.lproj/AccountSetup.xib; sourceTree = "<group>"; };
2A1173B212456F2400D119B5 /* badge.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = badge.png; sourceTree = "<group>"; };
2A1173B312456F2400D119B5 /* badgel.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = badgel.png; sourceTree = "<group>"; };
@ -323,7 +324,11 @@
2A1176671245725B00D119B5 /* QuartzCore.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = QuartzCore.framework; path = System/Library/Frameworks/QuartzCore.framework; sourceTree = SDKROOT; };
2A117684124573D600D119B5 /* VoiceMac.icns */ = {isa = PBXFileReference; lastKnownFileType = image.icns; path = VoiceMac.icns; sourceTree = SOURCE_ROOT; };
2A11770312458C8A00D119B5 /* blankicon.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = blankicon.png; sourceTree = "<group>"; };
2A5B70D313310EA600F89B56 /* prefix.pch */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = prefix.pch; path = Classes/VoiceMac/prefix.pch; sourceTree = "<group>"; };
2A91A3F71247D6B900013B43 /* English */ = {isa = PBXFileReference; lastKnownFileType = file.xib; name = English; path = English.lproj/AccountsPane.xib; sourceTree = "<group>"; };
2AF1EF451332D94100615DA3 /* VoiceVerify.xib */ = {isa = PBXFileReference; lastKnownFileType = file.xib; path = VoiceVerify.xib; sourceTree = "<group>"; };
2AF1EF481332DAB900615DA3 /* MGMVoiceVerify.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MGMVoiceVerify.h; sourceTree = "<group>"; };
2AF1EF491332DAB900615DA3 /* MGMVoiceVerify.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = MGMVoiceVerify.m; sourceTree = "<group>"; };
8D1107320486CEB800E47090 /* VoiceMac.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = VoiceMac.app; sourceTree = BUILT_PRODUCTS_DIR; };
/* End PBXFileReference section */
@ -397,7 +402,7 @@
isa = PBXGroup;
children = (
2A11734412456E4300D119B5 /* main.m */,
2A11738112456E4300D119B5 /* VoiceMac_Prefix.pch */,
2A5B70D313310EA600F89B56 /* prefix.pch */,
);
name = "Other Sources";
sourceTree = "<group>";
@ -441,6 +446,8 @@
2A11735012456E4300D119B5 /* MGMVMAddons.m */,
2A11735112456E4300D119B5 /* MGMVoiceUser.h */,
2A11735212456E4300D119B5 /* MGMVoiceUser.m */,
2AF1EF481332DAB900615DA3 /* MGMVoiceVerify.h */,
2AF1EF491332DAB900615DA3 /* MGMVoiceVerify.m */,
2A11735312456E4300D119B5 /* Preferences */,
2A0F564313228C3E00046E86 /* FFmpeg */,
2A11735C12456E4300D119B5 /* SIP */,
@ -566,6 +573,7 @@
2A03CC851247D49300730F0C /* VoicemailView.xib */,
2A03CC871247D49800730F0C /* VoiceUser.xib */,
2A11746912456F2700D119B5 /* volume.png */,
2AF1EF451332D94100615DA3 /* VoiceVerify.xib */,
);
name = Resources;
path = Resources/VoiceMac;
@ -782,6 +790,7 @@
2A03CC8A1247D5B100730F0C /* License.txt in Resources */,
2A0C3698127F40EF00334471 /* dsa_pub.pem in Resources */,
2A0F564B132292EE00046E86 /* About.rtf in Resources */,
2AF1EF461332D94100615DA3 /* VoiceVerify.xib in Resources */,
);
runOnlyForDeploymentPostprocessing = 0;
};
@ -840,6 +849,7 @@
2A1173A012456E4300D119B5 /* MGMViewCell.m in Sources */,
2A0F564813228C3E00046E86 /* MGMConverter.m in Sources */,
2A0F564913228C3E00046E86 /* MGMFFmpeg.m in Sources */,
2AF1EF4A1332DAB900615DA3 /* MGMVoiceVerify.m in Sources */,
);
runOnlyForDeploymentPostprocessing = 0;
};
@ -1001,14 +1011,9 @@
2A117648124570C300D119B5 /* Debug SIP */ = {
isa = XCBuildConfiguration;
buildSettings = {
ARCHS = (
ppc,
i386,
x86_64,
);
ARCHS = "$(ARCHS_STANDARD_32_64_BIT)";
GCC_C_LANGUAGE_STANDARD = gnu99;
GCC_OPTIMIZATION_LEVEL = 0;
GCC_VERSION = 4.2;
GCC_WARN_ABOUT_RETURN_TYPE = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
HEADER_SEARCH_PATHS = (
@ -1037,8 +1042,7 @@
"-lswscale",
);
PREBINDING = NO;
SDKROOT = macosx10.6;
VALID_ARCHS = "ppc i386 x86_64";
SDKROOT = macosx10.5;
};
name = "Debug SIP";
};
@ -1056,7 +1060,7 @@
GCC_MODEL_TUNING = G5;
GCC_OPTIMIZATION_LEVEL = 0;
GCC_PRECOMPILE_PREFIX_HEADER = YES;
GCC_PREFIX_HEADER = Classes/VoiceMac/VoiceMac_Prefix.pch;
GCC_PREFIX_HEADER = Classes/VoiceMac/prefix.pch;
INFOPLIST_FILE = Resources/VoiceMac/Info.plist;
INSTALL_PATH = "$(HOME)/Applications";
PRODUCT_NAME = VoiceMac;
@ -1066,13 +1070,8 @@
2A11764A124570C800D119B5 /* Release SIP */ = {
isa = XCBuildConfiguration;
buildSettings = {
ARCHS = (
ppc,
i386,
x86_64,
);
ARCHS = "$(ARCHS_STANDARD_32_64_BIT)";
GCC_C_LANGUAGE_STANDARD = gnu99;
GCC_VERSION = 4.2;
GCC_WARN_ABOUT_RETURN_TYPE = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
HEADER_SEARCH_PATHS = (
@ -1100,8 +1099,7 @@
"-lswscale",
);
PREBINDING = NO;
SDKROOT = macosx10.6;
VALID_ARCHS = "ppc i386 x86_64";
SDKROOT = macosx10.5;
};
name = "Release SIP";
};
@ -1116,7 +1114,7 @@
);
GCC_MODEL_TUNING = G5;
GCC_PRECOMPILE_PREFIX_HEADER = YES;
GCC_PREFIX_HEADER = Classes/VoiceMac/VoiceMac_Prefix.pch;
GCC_PREFIX_HEADER = Classes/VoiceMac/prefix.pch;
INFOPLIST_FILE = Resources/VoiceMac/Info.plist;
INSTALL_PATH = "$(HOME)/Applications";
PRODUCT_NAME = VoiceMac;
@ -1165,7 +1163,7 @@
GCC_MODEL_TUNING = G5;
GCC_OPTIMIZATION_LEVEL = 0;
GCC_PRECOMPILE_PREFIX_HEADER = YES;
GCC_PREFIX_HEADER = Classes/VoiceMac/VoiceMac_Prefix.pch;
GCC_PREFIX_HEADER = Classes/VoiceMac/prefix.pch;
INFOPLIST_FILE = Resources/VoiceMac/Info.plist;
INSTALL_PATH = "$(HOME)/Applications";
PRODUCT_NAME = VoiceMac;
@ -1183,7 +1181,7 @@
);
GCC_MODEL_TUNING = G5;
GCC_PRECOMPILE_PREFIX_HEADER = YES;
GCC_PREFIX_HEADER = Classes/VoiceMac/VoiceMac_Prefix.pch;
GCC_PREFIX_HEADER = Classes/VoiceMac/prefix.pch;
INFOPLIST_FILE = Resources/VoiceMac/Info.plist;
INSTALL_PATH = "$(HOME)/Applications";
PRODUCT_NAME = VoiceMac;
@ -1193,60 +1191,34 @@
C01FCF4F08A954540054247B /* Debug */ = {
isa = XCBuildConfiguration;
buildSettings = {
ARCHS = (
ppc,
i386,
x86_64,
);
ARCHS = "$(ARCHS_STANDARD_32_64_BIT)";
GCC_C_LANGUAGE_STANDARD = gnu99;
GCC_OPTIMIZATION_LEVEL = 0;
GCC_VERSION = 4.2;
GCC_WARN_ABOUT_RETURN_TYPE = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
HEADER_SEARCH_PATHS = /usr/include/libxml2;
MACOSX_DEPLOYMENT_TARGET = 10.4;
"MACOSX_DEPLOYMENT_TARGET[arch=x86_64]" = 10.5;
ONLY_ACTIVE_ARCH = YES;
OTHER_LDFLAGS = (
"-lz",
"-lavformat",
"-lavcodec",
"-lavdevice",
"-lavutil",
"-lswscale",
);
OTHER_LDFLAGS = "";
PREBINDING = NO;
SDKROOT = macosx10.6;
VALID_ARCHS = "ppc i386 x86_64";
SDKROOT = macosx10.5;
};
name = Debug;
};
C01FCF5008A954540054247B /* Release */ = {
isa = XCBuildConfiguration;
buildSettings = {
ARCHS = (
ppc,
i386,
x86_64,
);
ARCHS = "$(ARCHS_STANDARD_32_64_BIT)";
GCC_C_LANGUAGE_STANDARD = gnu99;
GCC_VERSION = 4.2;
GCC_WARN_ABOUT_RETURN_TYPE = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
HEADER_SEARCH_PATHS = /usr/include/libxml2;
MACOSX_DEPLOYMENT_TARGET = 10.4;
"MACOSX_DEPLOYMENT_TARGET[arch=x86_64]" = 10.5;
OTHER_LDFLAGS = (
"-lz",
"-lavformat",
"-lavcodec",
"-lavdevice",
"-lavutil",
"-lswscale",
);
OTHER_LDFLAGS = "";
PREBINDING = NO;
SDKROOT = macosx10.6;
VALID_ARCHS = "ppc i386 x86_64";
SDKROOT = macosx10.5;
};
name = Release;
};