mirror of
https://gitlab.linphone.org/BC/public/linphone-iphone.git
synced 2026-01-17 11:08:06 +00:00
Merge branch 'master' of git.linphone.org:linphone-iphone
Conflicts: submodules/linphone
This commit is contained in:
commit
81db655956
10 changed files with 237 additions and 208 deletions
|
|
@ -20,52 +20,45 @@
|
|||
#import "linphonecore.h"
|
||||
#import "PhoneViewController.h"
|
||||
#import <AddressBookUI/ABPeoplePickerNavigationController.h>
|
||||
#include "UILinphone.h"
|
||||
|
||||
|
||||
@interface IncallViewController : UIViewController <ABPeoplePickerNavigationControllerDelegate> {
|
||||
LinphoneCore* myLinphoneCore;
|
||||
id<PhoneViewControllerDelegate> phoneviewDelegate;
|
||||
NSTimer *durationRefreasher;
|
||||
@interface IncallViewController : UIViewController <ABPeoplePickerNavigationControllerDelegate,LinphoneUICallDelegate> {
|
||||
|
||||
|
||||
UIView* controlSubView;
|
||||
UIView* padSubView;
|
||||
|
||||
UILabel* peerName;
|
||||
UILabel* peerNumber;
|
||||
UILabel* callDuration;
|
||||
UIDuration* callDuration;
|
||||
UILabel* status;
|
||||
UIButton* end;
|
||||
UIHangUpButton* end;
|
||||
UIButton* dialer;
|
||||
UIButton* mute;
|
||||
UIButton* speaker;
|
||||
UIMuteButton* mute;
|
||||
UISpeakerButton* speaker;
|
||||
UIButton* contacts;
|
||||
|
||||
|
||||
//key pad
|
||||
UIButton* one;
|
||||
UIButton* two;
|
||||
UIButton* three;
|
||||
UIButton* four;
|
||||
UIButton* five;
|
||||
UIButton* six;
|
||||
UIButton* seven;
|
||||
UIButton* eight;
|
||||
UIButton* nine;
|
||||
UIButton* star;
|
||||
UIButton* zero;
|
||||
UIButton* hash;
|
||||
|
||||
|
||||
UIView* padSubView;
|
||||
UIDigitButton* one;
|
||||
UIDigitButton* two;
|
||||
UIDigitButton* three;
|
||||
UIDigitButton* four;
|
||||
UIDigitButton* five;
|
||||
UIDigitButton* six;
|
||||
UIDigitButton* seven;
|
||||
UIDigitButton* eight;
|
||||
UIDigitButton* nine;
|
||||
UIDigitButton* star;
|
||||
UIDigitButton* zero;
|
||||
UIDigitButton* hash;
|
||||
UIButton* close;
|
||||
|
||||
bool isMuted;
|
||||
bool isSpeaker;
|
||||
|
||||
ABPeoplePickerNavigationController* myPeoplePickerController;
|
||||
}
|
||||
|
||||
-(void) setLinphoneCore:(LinphoneCore*) lc;
|
||||
-(void) startCall;
|
||||
|
||||
-(void)displayStatus:(NSString*) message;
|
||||
|
||||
- (IBAction)doAction:(id)sender;
|
||||
|
|
@ -98,5 +91,4 @@
|
|||
@property (nonatomic, retain) IBOutlet UIButton* hash;
|
||||
@property (nonatomic, retain) IBOutlet UIButton* close;
|
||||
|
||||
@property (nonatomic, retain) id<PhoneViewControllerDelegate> phoneviewDelegate;
|
||||
@end
|
||||
|
|
|
|||
|
|
@ -23,7 +23,7 @@
|
|||
|
||||
|
||||
@implementation IncallViewController
|
||||
@synthesize phoneviewDelegate;
|
||||
|
||||
|
||||
@synthesize controlSubView;
|
||||
@synthesize padSubView;
|
||||
|
|
@ -68,104 +68,60 @@
|
|||
// Implement viewDidLoad to do additional setup after loading the view, typically from a nib.
|
||||
- (void)viewDidLoad {
|
||||
[super viewDidLoad];
|
||||
isMuted = false;
|
||||
isSpeaker = false;
|
||||
//Controls
|
||||
[mute initWithOnImage:[UIImage imageNamed:@"mic_muted.png"] offImage:[UIImage imageNamed:@"mic_active.png"] ];
|
||||
[speaker initWithOnImage:[UIImage imageNamed:@"Speaker-32-on.png"] offImage:[UIImage imageNamed:@"Speaker-32-off.png"] ];
|
||||
|
||||
//Dialer init
|
||||
[zero initWithNumber:'0'];
|
||||
[one initWithNumber:'1'];
|
||||
[two initWithNumber:'2'];
|
||||
[three initWithNumber:'3'];
|
||||
[four initWithNumber:'4'];
|
||||
[five initWithNumber:'5'];
|
||||
[six initWithNumber:'6'];
|
||||
[seven initWithNumber:'7'];
|
||||
[eight initWithNumber:'8'];
|
||||
[nine initWithNumber:'9'];
|
||||
[star initWithNumber:'*'];
|
||||
[hash initWithNumber:'#'];
|
||||
|
||||
|
||||
}
|
||||
|
||||
|
||||
/*
|
||||
// Override to allow orientations other than the default portrait orientation.
|
||||
- (BOOL)shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)interfaceOrientation {
|
||||
// Return YES for supported orientations
|
||||
return (interfaceOrientation == UIInterfaceOrientationPortrait);
|
||||
}
|
||||
*/
|
||||
|
||||
- (void)didReceiveMemoryWarning {
|
||||
// Releases the view if it doesn't have a superview.
|
||||
[super didReceiveMemoryWarning];
|
||||
|
||||
// Release any cached data, images, etc that aren't in use.
|
||||
}
|
||||
|
||||
- (void)viewDidUnload {
|
||||
// Release any retained subviews of the main view.
|
||||
// e.g. self.myOutlet = nil;
|
||||
if (durationRefreasher != nil) {
|
||||
[ durationRefreasher invalidate];
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
-(void) setLinphoneCore:(LinphoneCore*) lc {
|
||||
myLinphoneCore = lc;
|
||||
}
|
||||
|
||||
-(void)displayStatus:(NSString*) message {
|
||||
-(void) displayStatus:(NSString*) message; {
|
||||
[status setText:message];
|
||||
}
|
||||
|
||||
-(void) startCall {
|
||||
const LinphoneAddress* address = linphone_core_get_remote_uri(myLinphoneCore);
|
||||
const char* displayName = linphone_address_get_display_name(address)?linphone_address_get_display_name(address):"";
|
||||
[peerName setText:[NSString stringWithCString:displayName length:strlen(displayName)]];
|
||||
|
||||
const char* username = linphone_address_get_username(address)!=0?linphone_address_get_username(address):"";
|
||||
[peerNumber setText:[NSString stringWithCString:username length:strlen(username)]];
|
||||
// start scheduler
|
||||
durationRefreasher = [NSTimer scheduledTimerWithTimeInterval:1
|
||||
target:self
|
||||
selector:@selector(updateCallDuration)
|
||||
userInfo:nil
|
||||
repeats:YES];
|
||||
|
||||
}
|
||||
|
||||
-(void)updateCallDuration {
|
||||
int lDuration = linphone_core_get_current_call_duration(myLinphoneCore);
|
||||
if (lDuration < 60) {
|
||||
[callDuration setText:[NSString stringWithFormat: @"%i s", lDuration]];
|
||||
-(void) displayCallInProgressFromUI:(UIViewController*) viewCtrl forUser:(NSString*) username withDisplayName:(NSString*) displayName {
|
||||
if (displayName && [displayName length]>0) {
|
||||
[peerName setText:displayName];
|
||||
[peerNumber setText:username];
|
||||
} else {
|
||||
[callDuration setText:[NSString stringWithFormat: @"%i:%i", lDuration/60,lDuration - 60 *(lDuration/60)]];
|
||||
[peerName setText:username];
|
||||
[peerNumber setText:@""];
|
||||
}
|
||||
[callDuration setText:@"Calling"];
|
||||
}
|
||||
|
||||
-(void) displayIncallFromUI:(UIViewController*) viewCtrl forUser:(NSString*) username withDisplayName:(NSString*) displayName {
|
||||
[callDuration start];
|
||||
}
|
||||
-(void) displayDialerFromUI:(UIViewController*) viewCtrl forUser:(NSString*) username withDisplayName:(NSString*) displayName {
|
||||
[callDuration stop];
|
||||
[self dismissModalViewControllerAnimated:true];
|
||||
}
|
||||
- (IBAction)doAction:(id)sender {
|
||||
|
||||
if (linphone_core_in_call(myLinphoneCore)) {
|
||||
//incall behavior
|
||||
if (sender == one) {
|
||||
linphone_core_send_dtmf(myLinphoneCore,'1');
|
||||
} else if (sender == two) {
|
||||
linphone_core_send_dtmf(myLinphoneCore,'2');
|
||||
} else if (sender == three) {
|
||||
linphone_core_send_dtmf(myLinphoneCore,'3');
|
||||
} else if (sender == four) {
|
||||
linphone_core_send_dtmf(myLinphoneCore,'4');
|
||||
} else if (sender == five) {
|
||||
linphone_core_send_dtmf(myLinphoneCore,'5');
|
||||
} else if (sender == six) {
|
||||
linphone_core_send_dtmf(myLinphoneCore,'6');
|
||||
} else if (sender == seven) {
|
||||
linphone_core_send_dtmf(myLinphoneCore,'7');
|
||||
} else if (sender == eight) {
|
||||
linphone_core_send_dtmf(myLinphoneCore,'8');
|
||||
} else if (sender == nine) {
|
||||
linphone_core_send_dtmf(myLinphoneCore,'9');
|
||||
} else if (sender == star) {
|
||||
linphone_core_send_dtmf(myLinphoneCore,'*');
|
||||
} else if (sender == zero) {
|
||||
linphone_core_send_dtmf(myLinphoneCore,'0');
|
||||
} else if (sender == hash) {
|
||||
linphone_core_send_dtmf(myLinphoneCore,'#');
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
if (sender == end) {
|
||||
linphone_core_terminate_call(myLinphoneCore,NULL);
|
||||
} else if (sender == dialer) {
|
||||
if (sender == dialer) {
|
||||
[controlSubView setHidden:true];
|
||||
[padSubView setHidden:false];
|
||||
|
||||
|
|
@ -173,43 +129,12 @@
|
|||
// start people picker
|
||||
myPeoplePickerController = [[[ABPeoplePickerNavigationController alloc] init] autorelease];
|
||||
[myPeoplePickerController setPeoplePickerDelegate:self];
|
||||
|
||||
|
||||
[self presentModalViewController: myPeoplePickerController animated:true];
|
||||
} else if (sender == close) {
|
||||
[controlSubView setHidden:false];
|
||||
[padSubView setHidden:true];
|
||||
} else if (sender == mute) {
|
||||
isMuted = isMuted?false:true;
|
||||
linphone_core_mute_mic(myLinphoneCore,isMuted);
|
||||
// swithc buttun state
|
||||
UIImage * tmpImage = [mute backgroundImageForState: UIControlStateNormal];
|
||||
[mute setBackgroundImage:[mute backgroundImageForState: UIControlStateHighlighted] forState:UIControlStateNormal];
|
||||
[mute setBackgroundImage:tmpImage forState:UIControlStateHighlighted];
|
||||
|
||||
} else if (sender == speaker) {
|
||||
isSpeaker = isSpeaker?false:true;
|
||||
if (isSpeaker) {
|
||||
//redirect audio to speaker
|
||||
UInt32 audioRouteOverride = kAudioSessionOverrideAudioRoute_Speaker;
|
||||
AudioSessionSetProperty (kAudioSessionProperty_OverrideAudioRoute
|
||||
, sizeof (audioRouteOverride)
|
||||
, &audioRouteOverride);
|
||||
} else {
|
||||
//Cancel audio route redirection
|
||||
UInt32 audioRouteOverride = kAudioSessionOverrideAudioRoute_None;
|
||||
AudioSessionSetProperty (kAudioSessionProperty_OverrideAudioRoute
|
||||
, sizeof (audioRouteOverride)
|
||||
, &audioRouteOverride);
|
||||
}
|
||||
// switch button state
|
||||
UIImage * tmpImage = [speaker backgroundImageForState: UIControlStateNormal];
|
||||
[speaker setBackgroundImage:[speaker backgroundImageForState: UIControlStateHighlighted] forState:UIControlStateNormal];
|
||||
[speaker setBackgroundImage:tmpImage forState:UIControlStateHighlighted];
|
||||
|
||||
}else {
|
||||
NSLog(@"unknown event from incall view");
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
// handle people picker behavior
|
||||
|
|
|
|||
|
|
@ -12,7 +12,7 @@
|
|||
</object>
|
||||
<object class="NSMutableArray" key="IBDocument.EditedObjectIDs">
|
||||
<bool key="EncodedWithXMLCoder">YES</bool>
|
||||
<integer value="9"/>
|
||||
<integer value="26"/>
|
||||
</object>
|
||||
<object class="NSArray" key="IBDocument.PluginDependencies">
|
||||
<bool key="EncodedWithXMLCoder">YES</bool>
|
||||
|
|
@ -43,18 +43,6 @@
|
|||
<int key="NSvFlags">274</int>
|
||||
<object class="NSMutableArray" key="NSSubviews">
|
||||
<bool key="EncodedWithXMLCoder">YES</bool>
|
||||
<object class="IBUIActivityIndicatorView" id="275734970">
|
||||
<reference key="NSNextResponder" ref="858247959"/>
|
||||
<int key="NSvFlags">292</int>
|
||||
<string key="NSFrame">{{150, 220}, {20, 20}}</string>
|
||||
<reference key="NSSuperview" ref="858247959"/>
|
||||
<bool key="IBUIOpaque">NO</bool>
|
||||
<bool key="IBUIClearsContextBeforeDrawing">NO</bool>
|
||||
<bool key="IBUIUserInteractionEnabled">NO</bool>
|
||||
<string key="targetRuntimeIdentifier">IBCocoaTouchFramework</string>
|
||||
<bool key="IBUIHidesWhenStopped">NO</bool>
|
||||
<int key="IBUIStyle">2</int>
|
||||
</object>
|
||||
<object class="IBUILabel" id="357639611">
|
||||
<reference key="NSNextResponder" ref="858247959"/>
|
||||
<int key="NSvFlags">292</int>
|
||||
|
|
@ -155,12 +143,12 @@
|
|||
<string key="NSClassName">NSImage</string>
|
||||
<string key="NSResourceName">mic_active.png</string>
|
||||
</object>
|
||||
<reference key="IBUINormalImage" ref="436895690"/>
|
||||
<object class="NSCustomResource" key="IBUIHighlightedBackgroundImage" id="132679557">
|
||||
<string key="NSClassName">NSImage</string>
|
||||
<string key="NSResourceName">mic_muted.png</string>
|
||||
</object>
|
||||
<reference key="IBUISelectedBackgroundImage" ref="132679557"/>
|
||||
<reference key="IBUINormalBackgroundImage" ref="436895690"/>
|
||||
</object>
|
||||
<object class="IBUIButton" id="953411930">
|
||||
<reference key="NSNextResponder" ref="585669622"/>
|
||||
|
|
@ -196,15 +184,13 @@
|
|||
<int key="IBUIContentHorizontalAlignment">0</int>
|
||||
<int key="IBUIContentVerticalAlignment">0</int>
|
||||
<reference key="IBUIFont" ref="755582794"/>
|
||||
<int key="IBUIButtonType">1</int>
|
||||
<string key="IBUINormalTitle">Contacts</string>
|
||||
<reference key="IBUIHighlightedTitleColor" ref="816037173"/>
|
||||
<object class="NSColor" key="IBUINormalTitleColor">
|
||||
<int key="NSColorSpace">1</int>
|
||||
<bytes key="NSRGB">MC4xOTYwNzg0MyAwLjMwOTgwMzkzIDAuNTIxNTY4NjYAA</bytes>
|
||||
</object>
|
||||
<reference key="IBUINormalTitleShadowColor" ref="785445938"/>
|
||||
<object class="NSCustomResource" key="IBUINormalBackgroundImage">
|
||||
<object class="NSCustomResource" key="IBUINormalImage">
|
||||
<string key="NSClassName">NSImage</string>
|
||||
<string key="NSResourceName">contact-orange.png</string>
|
||||
</object>
|
||||
|
|
@ -220,8 +206,6 @@
|
|||
<int key="IBUIContentHorizontalAlignment">0</int>
|
||||
<int key="IBUIContentVerticalAlignment">0</int>
|
||||
<reference key="IBUIFont" ref="755582794"/>
|
||||
<int key="IBUIButtonType">1</int>
|
||||
<string key="IBUINormalTitle">Dialer</string>
|
||||
<reference key="IBUIHighlightedTitleColor" ref="816037173"/>
|
||||
<object class="NSColor" key="IBUINormalTitleColor">
|
||||
<int key="NSColorSpace">1</int>
|
||||
|
|
@ -244,8 +228,6 @@
|
|||
<int key="IBUIContentHorizontalAlignment">0</int>
|
||||
<int key="IBUIContentVerticalAlignment">0</int>
|
||||
<reference key="IBUIFont" ref="755582794"/>
|
||||
<int key="IBUIButtonType">1</int>
|
||||
<string key="IBUINormalTitle">Spk</string>
|
||||
<reference key="IBUIHighlightedTitleColor" ref="816037173"/>
|
||||
<object class="NSColor" key="IBUINormalTitleColor">
|
||||
<int key="NSColorSpace">1</int>
|
||||
|
|
@ -556,7 +538,7 @@
|
|||
<reference key="IBUINormalTitleShadowColor" ref="785445938"/>
|
||||
</object>
|
||||
</object>
|
||||
<string key="NSFrame">{{25, 110}, {270, 317}}</string>
|
||||
<string key="NSFrame">{{400, 110}, {270, 317}}</string>
|
||||
<reference key="NSSuperview" ref="858247959"/>
|
||||
<object class="NSColor" key="IBUIBackgroundColor">
|
||||
<int key="NSColorSpace">3</int>
|
||||
|
|
@ -918,15 +900,6 @@
|
|||
</object>
|
||||
<int key="connectionID">84</int>
|
||||
</object>
|
||||
<object class="IBConnectionRecord">
|
||||
<object class="IBCocoaTouchEventConnection" key="connection">
|
||||
<string key="label">doAction:</string>
|
||||
<reference key="source" ref="478667533"/>
|
||||
<reference key="destination" ref="841351856"/>
|
||||
<int key="IBEventType">7</int>
|
||||
</object>
|
||||
<int key="connectionID">85</int>
|
||||
</object>
|
||||
<object class="IBConnectionRecord">
|
||||
<object class="IBCocoaTouchOutletConnection" key="connection">
|
||||
<string key="label">peerName</string>
|
||||
|
|
@ -999,7 +972,6 @@
|
|||
<reference ref="357639611"/>
|
||||
<reference ref="671407802"/>
|
||||
<reference ref="983423469"/>
|
||||
<reference ref="275734970"/>
|
||||
<reference ref="620882994"/>
|
||||
</object>
|
||||
<reference key="parent" ref="981679694"/>
|
||||
|
|
@ -1173,11 +1145,6 @@
|
|||
<reference key="parent" ref="759087764"/>
|
||||
<string key="objectName">0</string>
|
||||
</object>
|
||||
<object class="IBObjectRecord">
|
||||
<int key="objectID">92</int>
|
||||
<reference key="object" ref="275734970"/>
|
||||
<reference key="parent" ref="858247959"/>
|
||||
</object>
|
||||
<object class="IBObjectRecord">
|
||||
<int key="objectID">93</int>
|
||||
<reference key="object" ref="620882994"/>
|
||||
|
|
@ -1194,32 +1161,48 @@
|
|||
<string>-2.CustomClassName</string>
|
||||
<string>10.IBPluginDependency</string>
|
||||
<string>11.IBPluginDependency</string>
|
||||
<string>12.CustomClassName</string>
|
||||
<string>12.IBPluginDependency</string>
|
||||
<string>13.CustomClassName</string>
|
||||
<string>13.IBPluginDependency</string>
|
||||
<string>15.IBPluginDependency</string>
|
||||
<string>16.CustomClassName</string>
|
||||
<string>16.IBPluginDependency</string>
|
||||
<string>17.IBPluginDependency</string>
|
||||
<string>18.CustomClassName</string>
|
||||
<string>18.IBPluginDependency</string>
|
||||
<string>2.IBEditorWindowLastContentRect</string>
|
||||
<string>2.IBPluginDependency</string>
|
||||
<string>26.IBPluginDependency</string>
|
||||
<string>27.IBPluginDependency</string>
|
||||
<string>28.CustomClassName</string>
|
||||
<string>28.IBPluginDependency</string>
|
||||
<string>29.IBPluginDependency</string>
|
||||
<string>30.CustomClassName</string>
|
||||
<string>30.IBPluginDependency</string>
|
||||
<string>31.CustomClassName</string>
|
||||
<string>31.IBPluginDependency</string>
|
||||
<string>32.CustomClassName</string>
|
||||
<string>32.IBPluginDependency</string>
|
||||
<string>33.CustomClassName</string>
|
||||
<string>33.IBPluginDependency</string>
|
||||
<string>34.CustomClassName</string>
|
||||
<string>34.IBPluginDependency</string>
|
||||
<string>35.CustomClassName</string>
|
||||
<string>35.IBPluginDependency</string>
|
||||
<string>36.CustomClassName</string>
|
||||
<string>36.IBPluginDependency</string>
|
||||
<string>37.CustomClassName</string>
|
||||
<string>37.IBPluginDependency</string>
|
||||
<string>38.CustomClassName</string>
|
||||
<string>38.IBPluginDependency</string>
|
||||
<string>39.CustomClassName</string>
|
||||
<string>39.IBPluginDependency</string>
|
||||
<string>40.CustomClassName</string>
|
||||
<string>40.IBPluginDependency</string>
|
||||
<string>41.CustomClassName</string>
|
||||
<string>41.IBPluginDependency</string>
|
||||
<string>9.IBPluginDependency</string>
|
||||
<string>92.IBPluginDependency</string>
|
||||
<string>93.IBPluginDependency</string>
|
||||
</object>
|
||||
<object class="NSMutableArray" key="dict.values">
|
||||
|
|
@ -1228,30 +1211,46 @@
|
|||
<string>UIResponder</string>
|
||||
<string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string>
|
||||
<string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string>
|
||||
<string>UIDuration</string>
|
||||
<string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string>
|
||||
<string>UISpeakerButton</string>
|
||||
<string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string>
|
||||
<string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string>
|
||||
<string>UIMuteButton</string>
|
||||
<string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string>
|
||||
<string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string>
|
||||
<string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string>
|
||||
<string>UIHangUpButton</string>
|
||||
<string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string>
|
||||
<string>{{14, 634}, {320, 480}}</string>
|
||||
<string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string>
|
||||
<string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string>
|
||||
<string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string>
|
||||
<string>UIHangUpButton</string>
|
||||
<string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string>
|
||||
<string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string>
|
||||
<string>UIDigitButton</string>
|
||||
<string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string>
|
||||
<string>UIDigitButton</string>
|
||||
<string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string>
|
||||
<string>UIDigitButton</string>
|
||||
<string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string>
|
||||
<string>UIDigitButton</string>
|
||||
<string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string>
|
||||
<string>UIDigitButton</string>
|
||||
<string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string>
|
||||
<string>UIDigitButton</string>
|
||||
<string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string>
|
||||
<string>UIDigitButton</string>
|
||||
<string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string>
|
||||
<string>UIDigitButton</string>
|
||||
<string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string>
|
||||
<string>UIDigitButton</string>
|
||||
<string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string>
|
||||
<string>UIDigitButton</string>
|
||||
<string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string>
|
||||
<string>UIDigitButton</string>
|
||||
<string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string>
|
||||
<string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string>
|
||||
<string>UIDigitButton</string>
|
||||
<string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string>
|
||||
<string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string>
|
||||
<string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string>
|
||||
|
|
@ -1312,7 +1311,6 @@
|
|||
<string>padSubView</string>
|
||||
<string>peerName</string>
|
||||
<string>peerNumber</string>
|
||||
<string>phoneviewDelegate</string>
|
||||
<string>seven</string>
|
||||
<string>six</string>
|
||||
<string>speaker</string>
|
||||
|
|
@ -1340,7 +1338,6 @@
|
|||
<string>UIView</string>
|
||||
<string>UILabel</string>
|
||||
<string>UILabel</string>
|
||||
<string>id</string>
|
||||
<string>UIButton</string>
|
||||
<string>UIButton</string>
|
||||
<string>UIButton</string>
|
||||
|
|
@ -1371,7 +1368,6 @@
|
|||
<string>padSubView</string>
|
||||
<string>peerName</string>
|
||||
<string>peerNumber</string>
|
||||
<string>phoneviewDelegate</string>
|
||||
<string>seven</string>
|
||||
<string>six</string>
|
||||
<string>speaker</string>
|
||||
|
|
@ -1447,10 +1443,6 @@
|
|||
<string key="name">peerNumber</string>
|
||||
<string key="candidateClassName">UILabel</string>
|
||||
</object>
|
||||
<object class="IBToOneOutletInfo">
|
||||
<string key="name">phoneviewDelegate</string>
|
||||
<string key="candidateClassName">id</string>
|
||||
</object>
|
||||
<object class="IBToOneOutletInfo">
|
||||
<string key="name">seven</string>
|
||||
<string key="candidateClassName">UIButton</string>
|
||||
|
|
@ -1490,6 +1482,65 @@
|
|||
<string key="minorKey">Classes/IncallViewController.h</string>
|
||||
</object>
|
||||
</object>
|
||||
<object class="IBPartialClassDescription">
|
||||
<string key="className">UIDigitButton</string>
|
||||
<string key="superclassName">UIButton</string>
|
||||
<object class="IBClassDescriptionSource" key="sourceIdentifier">
|
||||
<string key="majorKey">IBProjectSource</string>
|
||||
<string key="minorKey">Classes/LinphoneUI/UIDigitButton.h</string>
|
||||
</object>
|
||||
</object>
|
||||
<object class="IBPartialClassDescription">
|
||||
<string key="className">UIDuration</string>
|
||||
<string key="superclassName">UILabel</string>
|
||||
<object class="IBClassDescriptionSource" key="sourceIdentifier">
|
||||
<string key="majorKey">IBProjectSource</string>
|
||||
<string key="minorKey">Classes/LinphoneUI/UIDuration.h</string>
|
||||
</object>
|
||||
</object>
|
||||
<object class="IBPartialClassDescription">
|
||||
<string key="className">UIHangUpButton</string>
|
||||
<string key="superclassName">UIButton</string>
|
||||
<object class="IBClassDescriptionSource" key="sourceIdentifier">
|
||||
<string key="majorKey">IBProjectSource</string>
|
||||
<string key="minorKey">Classes/LinphoneUI/UIHangUpButton.h</string>
|
||||
</object>
|
||||
</object>
|
||||
<object class="IBPartialClassDescription">
|
||||
<string key="className">UIMuteButton</string>
|
||||
<string key="superclassName">UIToggleButton</string>
|
||||
<object class="IBClassDescriptionSource" key="sourceIdentifier">
|
||||
<string key="majorKey">IBProjectSource</string>
|
||||
<string key="minorKey">Classes/LinphoneUI/UIMuteButton.h</string>
|
||||
</object>
|
||||
</object>
|
||||
<object class="IBPartialClassDescription">
|
||||
<string key="className">UISpeakerButton</string>
|
||||
<string key="superclassName">UIToggleButton</string>
|
||||
<object class="IBClassDescriptionSource" key="sourceIdentifier">
|
||||
<string key="majorKey">IBProjectSource</string>
|
||||
<string key="minorKey">Classes/LinphoneUI/UISpeakerButton.h</string>
|
||||
</object>
|
||||
</object>
|
||||
<object class="IBPartialClassDescription">
|
||||
<string key="className">UIToggleButton</string>
|
||||
<string key="superclassName">UIButton</string>
|
||||
<object class="NSMutableDictionary" key="outlets">
|
||||
<string key="NS.key.0">mActionHandler</string>
|
||||
<string key="NS.object.0">id</string>
|
||||
</object>
|
||||
<object class="NSMutableDictionary" key="toOneOutletInfosByName">
|
||||
<string key="NS.key.0">mActionHandler</string>
|
||||
<object class="IBToOneOutletInfo" key="NS.object.0">
|
||||
<string key="name">mActionHandler</string>
|
||||
<string key="candidateClassName">id</string>
|
||||
</object>
|
||||
</object>
|
||||
<object class="IBClassDescriptionSource" key="sourceIdentifier">
|
||||
<string key="majorKey">IBProjectSource</string>
|
||||
<string key="minorKey">Classes/LinphoneUI/UIToggleButton.h</string>
|
||||
</object>
|
||||
</object>
|
||||
</object>
|
||||
<object class="NSMutableArray" key="referencedPartialClassDescriptionsV3.2+">
|
||||
<bool key="EncodedWithXMLCoder">YES</bool>
|
||||
|
|
@ -1584,14 +1635,6 @@
|
|||
<string key="minorKey">UIKit.framework/Headers/UIResponder.h</string>
|
||||
</object>
|
||||
</object>
|
||||
<object class="IBPartialClassDescription">
|
||||
<string key="className">UIActivityIndicatorView</string>
|
||||
<string key="superclassName">UIView</string>
|
||||
<object class="IBClassDescriptionSource" key="sourceIdentifier">
|
||||
<string key="majorKey">IBFrameworkSource</string>
|
||||
<string key="minorKey">UIKit.framework/Headers/UIActivityIndicatorView.h</string>
|
||||
</object>
|
||||
</object>
|
||||
<object class="IBPartialClassDescription">
|
||||
<string key="className">UIButton</string>
|
||||
<string key="superclassName">UIControl</string>
|
||||
|
|
|
|||
|
|
@ -44,7 +44,8 @@ extern void libmsilbc_init();
|
|||
}
|
||||
|
||||
-(void) onCall:(LinphoneCall*) currentCall StateChanged: (LinphoneCallState) new_state withMessage: (const char *) message {
|
||||
NSString* lUserName = [[NSString alloc] initWithCString:linphone_address_get_username(linphone_call_get_remote_address(currentCall))];
|
||||
const char* lUserNameChars=linphone_address_get_username(linphone_call_get_remote_address(currentCall));
|
||||
NSString* lUserName = lUserNameChars?[[NSString alloc] initWithCString:lUserNameChars]:@"Unknown";
|
||||
const char* lDisplayNameChars = linphone_address_get_display_name(linphone_call_get_remote_address(currentCall));
|
||||
NSString* lDisplayName = lDisplayNameChars?[[NSString alloc] initWithCString:lDisplayNameChars]:@"";
|
||||
|
||||
|
|
|
|||
|
|
@ -25,6 +25,7 @@
|
|||
UITextField* mAddress;
|
||||
|
||||
}
|
||||
-(void) initWithNumber:(char)digit ;
|
||||
-(void) initWithNumber:(char)digit addressField:(UITextField*) address;
|
||||
|
||||
@end
|
||||
|
|
|
|||
|
|
@ -27,7 +27,7 @@
|
|||
|
||||
|
||||
-(void) touchDown:(id) sender {
|
||||
if (!linphone_core_in_call([LinphoneManager getLc])) {
|
||||
if (mAddress && !linphone_core_in_call([LinphoneManager getLc])) {
|
||||
NSString* newAddress = [NSString stringWithFormat:@"%@%c",mAddress.text,mDigit];
|
||||
[mAddress setText:newAddress];
|
||||
linphone_core_play_dtmf([LinphoneManager getLc], mDigit, -1);
|
||||
|
|
@ -58,9 +58,12 @@
|
|||
|
||||
}
|
||||
|
||||
-(void) initWithNumber:(char)digit {
|
||||
[self initWithNumber:digit addressField:nil];
|
||||
}
|
||||
-(void) initWithNumber:(char)digit addressField:(UITextField*) address{
|
||||
mDigit=digit ;
|
||||
mAddress=[address retain];
|
||||
mAddress=address?[address retain]:nil;
|
||||
[self addTarget:self action:@selector(touchDown:) forControlEvents:UIControlEventTouchDown];
|
||||
[self addTarget:self action:@selector(touchUp:) forControlEvents:UIControlEventTouchUpInside|UIControlEventTouchUpOutside];
|
||||
}
|
||||
|
|
|
|||
|
|
@ -61,7 +61,7 @@
|
|||
UIButton* back;
|
||||
|
||||
UITabBarController* myTabBarController;
|
||||
IncallViewController *myIncallViewController;
|
||||
|
||||
UIActionSheet *mIncomingCallActionSheet;
|
||||
FirstLoginViewController* myFirstLoginViewController;
|
||||
NSTimer *dtmf_warmup;
|
||||
|
|
|
|||
|
|
@ -241,9 +241,6 @@
|
|||
//status reporting
|
||||
-(void) displayStatus:(NSString*) message {
|
||||
[status setText:message];
|
||||
if (myIncallViewController != nil) {
|
||||
[myIncallViewController displayStatus:message];
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
|
@ -282,10 +279,7 @@
|
|||
}
|
||||
mIncomingCallActionSheet = nil;
|
||||
}
|
||||
-(void) displayFirstLoginUI:(UIWindow *) window {
|
||||
|
||||
|
||||
}
|
||||
- (void)dealloc {
|
||||
[address dealloc];
|
||||
[ mDisplayName dealloc];
|
||||
|
|
@ -311,7 +305,6 @@
|
|||
[hash dealloc];
|
||||
[back dealloc];
|
||||
[myTabBarController release];
|
||||
[myIncallViewController release];
|
||||
[super dealloc];
|
||||
}
|
||||
|
||||
|
|
|
|||
|
Before Width: | Height: | Size: 24 KiB After Width: | Height: | Size: 24 KiB |
|
|
@ -57,6 +57,7 @@
|
|||
227BCDC210D4004600FBFD76 /* CallHistoryTableViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 227BCDC010D4004600FBFD76 /* CallHistoryTableViewController.m */; };
|
||||
227BCDC310D4004600FBFD76 /* CallHistoryTableViewController.xib in Resources */ = {isa = PBXBuildFile; fileRef = 227BCDC110D4004600FBFD76 /* CallHistoryTableViewController.xib */; };
|
||||
228697C411AC29B800E9E0CA /* CFNetwork.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 228697C311AC29B800E9E0CA /* CFNetwork.framework */; };
|
||||
228B19AF130290C500F154D3 /* iTunesArtwork in Resources */ = {isa = PBXBuildFile; fileRef = 228B19AE130290C500F154D3 /* iTunesArtwork */; };
|
||||
22968A5F12F875C600588287 /* UISpeakerButton.m in Sources */ = {isa = PBXBuildFile; fileRef = 22968A5E12F875C600588287 /* UISpeakerButton.m */; };
|
||||
22968A8812F87C2000588287 /* UIDuration.m in Sources */ = {isa = PBXBuildFile; fileRef = 22968A8712F87C2000588287 /* UIDuration.m */; };
|
||||
22A10F3B11F8960300373793 /* libortp.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 220FAD2C10765B400068D98F /* libortp.a */; };
|
||||
|
|
@ -274,6 +275,7 @@
|
|||
227BCDC010D4004600FBFD76 /* CallHistoryTableViewController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = CallHistoryTableViewController.m; sourceTree = "<group>"; };
|
||||
227BCDC110D4004600FBFD76 /* CallHistoryTableViewController.xib */ = {isa = PBXFileReference; lastKnownFileType = file.xib; path = CallHistoryTableViewController.xib; sourceTree = "<group>"; };
|
||||
228697C311AC29B800E9E0CA /* CFNetwork.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = CFNetwork.framework; path = System/Library/Frameworks/CFNetwork.framework; sourceTree = SDKROOT; };
|
||||
228B19AE130290C500F154D3 /* iTunesArtwork */ = {isa = PBXFileReference; lastKnownFileType = file; name = iTunesArtwork; path = Resources/iTunesArtwork; sourceTree = "<group>"; };
|
||||
22968A5D12F875C600588287 /* UISpeakerButton.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UISpeakerButton.h; sourceTree = "<group>"; };
|
||||
22968A5E12F875C600588287 /* UISpeakerButton.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UISpeakerButton.m; sourceTree = "<group>"; };
|
||||
22968A8612F87C2000588287 /* UIDuration.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UIDuration.h; sourceTree = "<group>"; };
|
||||
|
|
@ -645,6 +647,7 @@
|
|||
29B97317FDCFA39411CA2CEA /* Resources */ = {
|
||||
isa = PBXGroup;
|
||||
children = (
|
||||
228B19AE130290C500F154D3 /* iTunesArtwork */,
|
||||
2242E312125235120061DDCE /* oldphone-mono-30s.caf */,
|
||||
225CB2F911ABB76400628906 /* linphone-banner.png */,
|
||||
225CB2ED11ABB65D00628906 /* clavier-01-160px.png */,
|
||||
|
|
@ -776,6 +779,7 @@
|
|||
2242E313125235120061DDCE /* oldphone-mono-30s.caf in Resources */,
|
||||
222A483412F7176F0075F07F /* IncallViewController.xib in Resources */,
|
||||
2218A92612FBE1340088A667 /* FirstLoginViewController.xib in Resources */,
|
||||
228B19AF130290C500F154D3 /* iTunesArtwork in Resources */,
|
||||
);
|
||||
runOnlyForDeploymentPostprocessing = 0;
|
||||
};
|
||||
|
|
@ -896,6 +900,71 @@
|
|||
};
|
||||
name = Release;
|
||||
};
|
||||
228B19A61302902F00F154D3 /* Distribution adhoc */ = {
|
||||
isa = XCBuildConfiguration;
|
||||
buildSettings = {
|
||||
ARCHS = "$(ARCHS_STANDARD_32_BIT)";
|
||||
"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Distribution: jehan monnier";
|
||||
GCC_C_LANGUAGE_STANDARD = c99;
|
||||
GCC_WARN_ABOUT_RETURN_TYPE = YES;
|
||||
GCC_WARN_UNUSED_VARIABLE = YES;
|
||||
HEADER_SEARCH_PATHS = "";
|
||||
IPHONEOS_DEPLOYMENT_TARGET = 3.1;
|
||||
LIBRARY_SEARCH_PATHS = "";
|
||||
LINK_WITH_STANDARD_LIBRARIES = YES;
|
||||
PREBINDING = NO;
|
||||
"PROVISIONING_PROFILE[sdk=iphoneos*]" = "5B8A949D-21D7-4FB1-B7C0-6438B7297840";
|
||||
SDKROOT = iphoneos;
|
||||
};
|
||||
name = "Distribution adhoc";
|
||||
};
|
||||
228B19A71302902F00F154D3 /* Distribution adhoc */ = {
|
||||
isa = XCBuildConfiguration;
|
||||
buildSettings = {
|
||||
ALWAYS_SEARCH_USER_PATHS = NO;
|
||||
CODE_SIGN_ENTITLEMENTS = untitled.plist;
|
||||
"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Distribution";
|
||||
COPY_PHASE_STRIP = NO;
|
||||
FRAMEWORK_SEARCH_PATHS = "";
|
||||
GCC_DYNAMIC_NO_PIC = NO;
|
||||
GCC_OPTIMIZATION_LEVEL = 0;
|
||||
GCC_PRECOMPILE_PREFIX_HEADER = YES;
|
||||
GCC_PREFIX_HEADER = linphone_Prefix.pch;
|
||||
GCC_PREPROCESSOR_DEFINITIONS = IN_LINPHONE;
|
||||
HEADER_SEARCH_PATHS = (
|
||||
submodules/linphone/coreapi,
|
||||
submodules/linphone/mediastreamer2/include,
|
||||
submodules/linphone/mediastreamer2/include,
|
||||
submodules/linphone/oRTP/include,
|
||||
submodules/externals/gsm/,
|
||||
submodules/externals/osip/include,
|
||||
submodules/externals/exosip/include,
|
||||
submodules/externals/speex/include,
|
||||
);
|
||||
INFOPLIST_FILE = "linphone-Info.plist";
|
||||
LIBRARY_SEARCH_PATHS = (
|
||||
"\"$(SRCROOT)/liblinphone-sdk/apple-darwin/lib\"",
|
||||
"\"$(SRCROOT)/liblinphone-sdk/apple-darwin/lib/mediastreamer/plugins\"",
|
||||
);
|
||||
"LIBRARY_SEARCH_PATHS[sdk=iphoneos*][arch=*]" = (
|
||||
"\"$(SRCROOT)/submodules/build/$(CONFIGURATION)-iphoneos\"",
|
||||
"$(inherited)",
|
||||
);
|
||||
"LIBRARY_SEARCH_PATHS[sdk=iphonesimulator*][arch=*]" = (
|
||||
"\"$(SRCROOT)/submodules/build/$(CONFIGURATION)-iphonesimulator\"",
|
||||
"$(inherited)",
|
||||
);
|
||||
OTHER_LDFLAGS = (
|
||||
"-l",
|
||||
linphone,
|
||||
);
|
||||
PRODUCT_NAME = linphone;
|
||||
"PROVISIONING_PROFILE[sdk=iphoneos*]" = "";
|
||||
SDKROOT = iphoneos;
|
||||
STANDARD_C_PLUS_PLUS_LIBRARY_TYPE = dynamic;
|
||||
};
|
||||
name = "Distribution adhoc";
|
||||
};
|
||||
22F51EE7107FA53D00F98953 /* Distribution */ = {
|
||||
isa = XCBuildConfiguration;
|
||||
buildSettings = {
|
||||
|
|
@ -1000,6 +1069,7 @@
|
|||
buildConfigurations = (
|
||||
1D6058940D05DD3E006BFB54 /* Debug */,
|
||||
22F51EE8107FA53D00F98953 /* Distribution */,
|
||||
228B19A71302902F00F154D3 /* Distribution adhoc */,
|
||||
1D6058950D05DD3E006BFB54 /* Release */,
|
||||
);
|
||||
defaultConfigurationIsVisible = 0;
|
||||
|
|
@ -1010,6 +1080,7 @@
|
|||
buildConfigurations = (
|
||||
C01FCF4F08A954540054247B /* Debug */,
|
||||
22F51EE7107FA53D00F98953 /* Distribution */,
|
||||
228B19A61302902F00F154D3 /* Distribution adhoc */,
|
||||
C01FCF5008A954540054247B /* Release */,
|
||||
);
|
||||
defaultConfigurationIsVisible = 0;
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue