Rotate control buttons in video view (on device orientation change)

This commit is contained in:
Pierre-Eric Pelloux-Prayer 2012-03-12 13:45:51 +01:00
parent af92b0a7e0
commit 079b43b6be
17 changed files with 745 additions and 555 deletions

View file

@ -1,27 +1,46 @@
//
// CallDelegate.h
// linphone
//
// Created by Pierre-Eric Pelloux-Prayer on 03/11/11.
// Copyright (c) 2011 __MyCompanyName__. All rights reserved.
//
/* LinphoneManager.h
*
* Copyright (C) 2011 Belledonne Comunications, Grenoble, France
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
*/
#import <Foundation/Foundation.h>
#include "linphonecore.h"
enum CallDelegateType {
CD_UNDEFINED = 0,
CD_NEW_CALL,
CD_ZRTP,
CD_VIDEO_UPDATE
};
@protocol UIActionSheetCustomDelegate
- (void)actionSheet:(UIActionSheet *)actionSheet clickedButtonAtIndex:(NSInteger)buttonIndex withUserDatas:(void*) datas;
- (void)actionSheet:(UIActionSheet *)actionSheet ofType:(enum CallDelegateType) type clickedButtonAtIndex:(NSInteger)buttonIndex withUserDatas:(void*) datas;
@end
@interface CallDelegate : NSObject<UIActionSheetDelegate> {
enum CallDelegateType eventType;
LinphoneCall* call;
id<UIActionSheetCustomDelegate> delegate;
NSTimer* timeout;
}
@property (nonatomic) enum CallDelegateType eventType;
@property (nonatomic) LinphoneCall* call;
@property (nonatomic, retain) id delegate;
@property (nonatomic, retain) NSTimer* timeout;
@end

View file

@ -1,20 +1,62 @@
//
// CallDelegate.m
// linphone
//
// Created by Pierre-Eric Pelloux-Prayer on 03/11/11.
// Copyright (c) 2011 __MyCompanyName__. All rights reserved.
//
/* LinphoneManager.h
*
* Copyright (C) 2011 Belledonne Comunications, Grenoble, France
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
*/
#import "CallDelegate.h"
@implementation CallDelegate
@synthesize eventType;
@synthesize call;
@synthesize delegate;
@synthesize timeout;
-(void) actionSheet:(UIActionSheet *)actionSheet clickedButtonAtIndex:(NSInteger)buttonIndex {
[delegate actionSheet:actionSheet clickedButtonAtIndex:buttonIndex withUserDatas:call];
if (timeout) {
[timeout invalidate];
timeout = nil;
}
if (eventType == CD_UNDEFINED) {
ms_error("Incorrect usage of CallDelegate/ActionSheet: eventType must be set");
}
[delegate actionSheet:actionSheet ofType:eventType clickedButtonAtIndex:buttonIndex withUserDatas:call];
}
-(void) actionSheet:(UIActionSheet *)actionSheet didDismissWithButtonIndex:(NSInteger)buttonIndex {
if (timeout) {
[timeout invalidate];
timeout = nil;
}
if (eventType == CD_UNDEFINED) {
ms_error("Incorrect usage of CallDelegate/ActionSheet: eventType must be set");
}
[delegate actionSheet:actionSheet ofType:eventType clickedButtonAtIndex:buttonIndex withUserDatas:call];
}
-(void) actionSheetCancel:(UIActionSheet *)actionSheet {
if (timeout) {
[timeout invalidate];
timeout = nil;
}
if (eventType == CD_UNDEFINED) {
ms_error("Incorrect usage of CallDelegate/ActionSheet: eventType must be set");
}
[delegate actionSheet:actionSheet ofType:eventType clickedButtonAtIndex:actionSheet.cancelButtonIndex withUserDatas:call];
}
@end

View file

@ -11,10 +11,11 @@
<string key="NS.object.0">933</string>
</object>
<array key="IBDocument.IntegratedClassDependencies">
<string>IBUIImageView</string>
<string>IBUIViewController</string>
<string>IBUIButton</string>
<string>IBUIView</string>
<string>IBUITableView</string>
<string>IBUIView</string>
<string>IBUIButton</string>
<string>IBProxyObject</string>
</array>
<array key="IBDocument.PluginDependencies">
@ -44,12 +45,12 @@
<string key="NSFrameSize">{768, 805}</string>
<reference key="NSSuperview" ref="134115264"/>
<reference key="NSWindow"/>
<reference key="NSNextKeyView" ref="815826897"/>
<reference key="NSNextKeyView" ref="268077918"/>
<string key="NSReuseIdentifierKey">_NS:408</string>
<object class="NSColor" key="IBUIBackgroundColor">
<int key="NSColorSpace">3</int>
<bytes key="NSWhite">MSAwAA</bytes>
<object class="NSColorSpace" key="NSCustomColorSpace">
<object class="NSColorSpace" key="NSCustomColorSpace" id="351240345">
<int key="NSID">2</int>
</object>
</object>
@ -62,6 +63,99 @@
<float key="IBUISectionHeaderHeight">22</float>
<float key="IBUISectionFooterHeight">22</float>
</object>
<object class="IBUIView" id="268077918">
<reference key="NSNextResponder" ref="134115264"/>
<int key="NSvFlags">-2147483374</int>
<array class="NSMutableArray" key="NSSubviews">
<object class="IBUIImageView" id="202372206">
<reference key="NSNextResponder" ref="268077918"/>
<int key="NSvFlags">292</int>
<string key="NSFrameSize">{768, 1024}</string>
<reference key="NSSuperview" ref="268077918"/>
<reference key="NSWindow"/>
<reference key="NSNextKeyView" ref="1000324624"/>
<string key="NSReuseIdentifierKey">_NS:569</string>
<bool key="IBUIUserInteractionEnabled">NO</bool>
<string key="targetRuntimeIdentifier">IBIPadFramework</string>
</object>
<object class="IBUIImageView" id="70050671">
<reference key="NSNextResponder" ref="268077918"/>
<int key="NSvFlags">292</int>
<string key="NSFrame">{{20, 956}, {28, 28}}</string>
<reference key="NSSuperview" ref="268077918"/>
<reference key="NSWindow"/>
<reference key="NSNextKeyView" ref="1044210264"/>
<string key="NSReuseIdentifierKey">_NS:567</string>
<bool key="IBUIUserInteractionEnabled">NO</bool>
<string key="targetRuntimeIdentifier">IBIPadFramework</string>
</object>
<object class="IBUIView" id="1044210264">
<reference key="NSNextResponder" ref="268077918"/>
<int key="NSvFlags">292</int>
<string key="NSFrame">{{598, 799}, {170, 225}}</string>
<reference key="NSSuperview" ref="268077918"/>
<reference key="NSWindow"/>
<reference key="NSNextKeyView" ref="815826897"/>
<object class="NSColor" key="IBUIBackgroundColor">
<int key="NSColorSpace">3</int>
<bytes key="NSWhite">MQA</bytes>
<reference key="NSCustomColorSpace" ref="351240345"/>
</object>
<string key="targetRuntimeIdentifier">IBIPadFramework</string>
</object>
<object class="IBUIButton" id="1000324624">
<reference key="NSNextResponder" ref="268077918"/>
<int key="NSvFlags">292</int>
<string key="NSFrame">{{0, 962}, {108, 62}}</string>
<reference key="NSSuperview" ref="268077918"/>
<reference key="NSWindow"/>
<reference key="NSNextKeyView" ref="70050671"/>
<bool key="IBUIOpaque">NO</bool>
<string key="targetRuntimeIdentifier">IBIPadFramework</string>
<int key="IBUIContentHorizontalAlignment">0</int>
<int key="IBUIContentVerticalAlignment">0</int>
<int key="IBUIButtonType">1</int>
<string key="IBUINormalTitle">switch</string>
<object class="NSColor" key="IBUIHighlightedTitleColor" id="912196478">
<int key="NSColorSpace">3</int>
<bytes key="NSWhite">MQA</bytes>
</object>
<object class="NSColor" key="IBUINormalTitleColor">
<int key="NSColorSpace">1</int>
<bytes key="NSRGB">MC4xOTYwNzg0MzQ2IDAuMzA5ODAzOTMyOSAwLjUyMTU2ODY1NgA</bytes>
</object>
<object class="NSColor" key="IBUINormalTitleShadowColor" id="275823755">
<int key="NSColorSpace">3</int>
<bytes key="NSWhite">MC41AA</bytes>
</object>
<object class="NSCustomResource" key="IBUINormalBackgroundImage">
<string key="NSClassName">NSImage</string>
<string key="NSResourceName">clavier-01-108px.png</string>
</object>
<object class="IBUIFontDescription" key="IBUIFontDescription" id="42405739">
<string key="name">Helvetica-Bold</string>
<string key="family">Helvetica</string>
<int key="traits">2</int>
<double key="pointSize">15</double>
</object>
<object class="NSFont" key="IBUIFont" id="207151297">
<string key="NSName">Helvetica-Bold</string>
<double key="NSSize">15</double>
<int key="NSfFlags">16</int>
</object>
</object>
</array>
<string key="NSFrameSize">{768, 1024}</string>
<reference key="NSSuperview" ref="134115264"/>
<reference key="NSWindow"/>
<reference key="NSNextKeyView" ref="202372206"/>
<string key="NSReuseIdentifierKey">_NS:212</string>
<object class="NSColor" key="IBUIBackgroundColor" id="948655818">
<int key="NSColorSpace">3</int>
<bytes key="NSWhite">MC42NjY2NjY2NjY3AA</bytes>
</object>
<string key="targetRuntimeIdentifier">IBIPadFramework</string>
</object>
<object class="IBUIView" id="677109388">
<reference key="NSNextResponder" ref="134115264"/>
<int key="NSvFlags">292</int>
@ -82,18 +176,12 @@
<string key="targetRuntimeIdentifier">IBIPadFramework</string>
<int key="IBUIContentHorizontalAlignment">0</int>
<int key="IBUIContentVerticalAlignment">0</int>
<object class="NSColor" key="IBUIHighlightedTitleColor" id="912196478">
<int key="NSColorSpace">3</int>
<bytes key="NSWhite">MQA</bytes>
</object>
<reference key="IBUIHighlightedTitleColor" ref="912196478"/>
<object class="NSColor" key="IBUINormalTitleColor">
<int key="NSColorSpace">1</int>
<bytes key="NSRGB">MC4xOTYwNzg0MyAwLjMwOTgwMzkzIDAuNTIxNTY4NjYAA</bytes>
</object>
<object class="NSColor" key="IBUINormalTitleShadowColor" id="275823755">
<int key="NSColorSpace">3</int>
<bytes key="NSWhite">MC41AA</bytes>
</object>
<reference key="IBUINormalTitleShadowColor" ref="275823755"/>
<object class="NSCustomResource" key="IBUINormalImage">
<string key="NSClassName">NSImage</string>
<string key="NSResourceName">stopcall-red.png</string>
@ -102,17 +190,8 @@
<string key="NSClassName">NSImage</string>
<string key="NSResourceName">clavier-01-106px.png</string>
</object>
<object class="IBUIFontDescription" key="IBUIFontDescription" id="42405739">
<string key="name">Helvetica-Bold</string>
<string key="family">Helvetica</string>
<int key="traits">2</int>
<double key="pointSize">15</double>
</object>
<object class="NSFont" key="IBUIFont" id="650379803">
<string key="NSName">Helvetica-Bold</string>
<double key="NSSize">15</double>
<int key="NSfFlags">16</int>
</object>
<reference key="IBUIFontDescription" ref="42405739"/>
<reference key="IBUIFont" ref="207151297"/>
</object>
</array>
<string key="NSFrame">{{224, 937}, {320, 77}}</string>
@ -411,7 +490,7 @@
</object>
<reference key="IBUINormalTitleShadowColor" ref="275823755"/>
<reference key="IBUIFontDescription" ref="42405739"/>
<reference key="IBUIFont" ref="650379803"/>
<reference key="IBUIFont" ref="207151297"/>
</object>
<object class="IBUIButton" id="171697004">
<reference key="NSNextResponder" ref="815826897"/>
@ -420,10 +499,7 @@
<reference key="NSSuperview" ref="815826897"/>
<reference key="NSWindow"/>
<reference key="NSNextKeyView" ref="778910645"/>
<object class="NSColor" key="IBUIBackgroundColor" id="948655818">
<int key="NSColorSpace">3</int>
<bytes key="NSWhite">MC42NjY2NjY2NjY3AA</bytes>
</object>
<reference key="IBUIBackgroundColor" ref="948655818"/>
<bool key="IBUIOpaque">NO</bool>
<bool key="IBUIClearsContextBeforeDrawing">NO</bool>
<string key="targetRuntimeIdentifier">IBIPadFramework</string>
@ -437,7 +513,7 @@
</object>
<reference key="IBUINormalTitleShadowColor" ref="275823755"/>
<reference key="IBUIFontDescription" ref="42405739"/>
<reference key="IBUIFont" ref="650379803"/>
<reference key="IBUIFont" ref="207151297"/>
</object>
<object class="IBUIButton" id="855969656">
<reference key="NSNextResponder" ref="815826897"/>
@ -460,7 +536,7 @@
</object>
<reference key="IBUINormalTitleShadowColor" ref="275823755"/>
<reference key="IBUIFontDescription" ref="42405739"/>
<reference key="IBUIFont" ref="650379803"/>
<reference key="IBUIFont" ref="207151297"/>
</object>
<object class="IBUIButton" id="274639717">
<reference key="NSNextResponder" ref="815826897"/>
@ -480,7 +556,7 @@
<reference key="IBUINormalTitleColor" ref="1025442286"/>
<reference key="IBUINormalTitleShadowColor" ref="275823755"/>
<reference key="IBUIFontDescription" ref="42405739"/>
<reference key="IBUIFont" ref="650379803"/>
<reference key="IBUIFont" ref="207151297"/>
</object>
<object class="IBUIButton" id="167373992">
<reference key="NSNextResponder" ref="815826897"/>
@ -503,7 +579,7 @@
</object>
<reference key="IBUINormalTitleShadowColor" ref="275823755"/>
<reference key="IBUIFontDescription" ref="42405739"/>
<reference key="IBUIFont" ref="650379803"/>
<reference key="IBUIFont" ref="207151297"/>
</object>
<object class="IBUIButton" id="9029257">
<reference key="NSNextResponder" ref="815826897"/>
@ -526,7 +602,7 @@
</object>
<reference key="IBUINormalTitleShadowColor" ref="275823755"/>
<reference key="IBUIFontDescription" ref="42405739"/>
<reference key="IBUIFont" ref="650379803"/>
<reference key="IBUIFont" ref="207151297"/>
</object>
<object class="IBUIButton" id="46522822">
<reference key="NSNextResponder" ref="815826897"/>
@ -549,7 +625,7 @@
</object>
<reference key="IBUINormalTitleShadowColor" ref="275823755"/>
<reference key="IBUIFontDescription" ref="42405739"/>
<reference key="IBUIFont" ref="650379803"/>
<reference key="IBUIFont" ref="207151297"/>
</object>
<object class="IBUIButton" id="767525360">
<reference key="NSNextResponder" ref="815826897"/>
@ -572,7 +648,7 @@
</object>
<reference key="IBUINormalTitleShadowColor" ref="275823755"/>
<reference key="IBUIFontDescription" ref="42405739"/>
<reference key="IBUIFont" ref="650379803"/>
<reference key="IBUIFont" ref="207151297"/>
</object>
<object class="IBUIButton" id="686137646">
<reference key="NSNextResponder" ref="815826897"/>
@ -595,7 +671,7 @@
</object>
<reference key="IBUINormalTitleShadowColor" ref="275823755"/>
<reference key="IBUIFontDescription" ref="42405739"/>
<reference key="IBUIFont" ref="650379803"/>
<reference key="IBUIFont" ref="207151297"/>
</object>
<object class="IBUIButton" id="693786132">
<reference key="NSNextResponder" ref="815826897"/>
@ -618,7 +694,7 @@
</object>
<reference key="IBUINormalTitleShadowColor" ref="275823755"/>
<reference key="IBUIFontDescription" ref="42405739"/>
<reference key="IBUIFont" ref="650379803"/>
<reference key="IBUIFont" ref="207151297"/>
</object>
<object class="IBUIButton" id="713296002">
<reference key="NSNextResponder" ref="815826897"/>
@ -641,7 +717,7 @@
</object>
<reference key="IBUINormalTitleShadowColor" ref="275823755"/>
<reference key="IBUIFontDescription" ref="42405739"/>
<reference key="IBUIFont" ref="650379803"/>
<reference key="IBUIFont" ref="207151297"/>
</object>
<object class="IBUIButton" id="1017517001">
<reference key="NSNextResponder" ref="815826897"/>
@ -664,7 +740,7 @@
</object>
<reference key="IBUINormalTitleShadowColor" ref="275823755"/>
<reference key="IBUIFontDescription" ref="42405739"/>
<reference key="IBUIFont" ref="650379803"/>
<reference key="IBUIFont" ref="207151297"/>
</object>
<object class="IBUIButton" id="778910645">
<reference key="NSNextResponder" ref="815826897"/>
@ -687,7 +763,7 @@
</object>
<reference key="IBUINormalTitleShadowColor" ref="275823755"/>
<reference key="IBUIFontDescription" ref="42405739"/>
<reference key="IBUIFont" ref="650379803"/>
<reference key="IBUIFont" ref="207151297"/>
</object>
</array>
<string key="NSFrame">{{178, 146}, {320, 310}}</string>
@ -726,51 +802,11 @@
<array class="NSMutableArray" key="connectionRecords">
<object class="IBConnectionRecord">
<object class="IBCocoaTouchOutletConnection" key="connection">
<string key="label">addCall</string>
<string key="label">callTableView</string>
<reference key="source" ref="372490531"/>
<reference key="destination" ref="914839389"/>
<reference key="destination" ref="447519759"/>
</object>
<int key="connectionID">112</int>
</object>
<object class="IBConnectionRecord">
<object class="IBCocoaTouchOutletConnection" key="connection">
<string key="label">addVideo</string>
<reference key="source" ref="372490531"/>
<reference key="destination" ref="43602080"/>
</object>
<int key="connectionID">113</int>
</object>
<object class="IBConnectionRecord">
<object class="IBCocoaTouchOutletConnection" key="connection">
<string key="label">close</string>
<reference key="source" ref="372490531"/>
<reference key="destination" ref="19432561"/>
</object>
<int key="connectionID">115</int>
</object>
<object class="IBConnectionRecord">
<object class="IBCocoaTouchOutletConnection" key="connection">
<string key="label">contacts</string>
<reference key="source" ref="372490531"/>
<reference key="destination" ref="185207809"/>
</object>
<int key="connectionID">116</int>
</object>
<object class="IBConnectionRecord">
<object class="IBCocoaTouchOutletConnection" key="connection">
<string key="label">controlSubView</string>
<reference key="source" ref="372490531"/>
<reference key="destination" ref="331380355"/>
</object>
<int key="connectionID">117</int>
</object>
<object class="IBConnectionRecord">
<object class="IBCocoaTouchOutletConnection" key="connection">
<string key="label">eight</string>
<reference key="source" ref="372490531"/>
<reference key="destination" ref="693786132"/>
</object>
<int key="connectionID">118</int>
<int key="connectionID">114</int>
</object>
<object class="IBConnectionRecord">
<object class="IBCocoaTouchOutletConnection" key="connection">
@ -780,22 +816,6 @@
</object>
<int key="connectionID">119</int>
</object>
<object class="IBConnectionRecord">
<object class="IBCocoaTouchOutletConnection" key="connection">
<string key="label">five</string>
<reference key="source" ref="372490531"/>
<reference key="destination" ref="46522822"/>
</object>
<int key="connectionID">120</int>
</object>
<object class="IBConnectionRecord">
<object class="IBCocoaTouchOutletConnection" key="connection">
<string key="label">four</string>
<reference key="source" ref="372490531"/>
<reference key="destination" ref="9029257"/>
</object>
<int key="connectionID">121</int>
</object>
<object class="IBConnectionRecord">
<object class="IBCocoaTouchOutletConnection" key="connection">
<string key="label">hangUpView</string>
@ -806,19 +826,11 @@
</object>
<object class="IBConnectionRecord">
<object class="IBCocoaTouchOutletConnection" key="connection">
<string key="label">hash</string>
<string key="label">speaker</string>
<reference key="source" ref="372490531"/>
<reference key="destination" ref="778910645"/>
<reference key="destination" ref="1070839124"/>
</object>
<int key="connectionID">123</int>
</object>
<object class="IBConnectionRecord">
<object class="IBCocoaTouchOutletConnection" key="connection">
<string key="label">mergeCalls</string>
<reference key="source" ref="372490531"/>
<reference key="destination" ref="694322717"/>
</object>
<int key="connectionID">124</int>
<int key="connectionID">132</int>
</object>
<object class="IBConnectionRecord">
<object class="IBCocoaTouchOutletConnection" key="connection">
@ -830,27 +842,43 @@
</object>
<object class="IBConnectionRecord">
<object class="IBCocoaTouchOutletConnection" key="connection">
<string key="label">nine</string>
<string key="label">addVideo</string>
<reference key="source" ref="372490531"/>
<reference key="destination" ref="713296002"/>
<reference key="destination" ref="43602080"/>
</object>
<int key="connectionID">126</int>
<int key="connectionID">113</int>
</object>
<object class="IBConnectionRecord">
<object class="IBCocoaTouchOutletConnection" key="connection">
<string key="label">one</string>
<string key="label">mergeCalls</string>
<reference key="source" ref="372490531"/>
<reference key="destination" ref="855969656"/>
<reference key="destination" ref="694322717"/>
</object>
<int key="connectionID">127</int>
<int key="connectionID">124</int>
</object>
<object class="IBConnectionRecord">
<object class="IBCocoaTouchOutletConnection" key="connection">
<string key="label">padSubView</string>
<string key="label">addCall</string>
<reference key="source" ref="372490531"/>
<reference key="destination" ref="815826897"/>
<reference key="destination" ref="914839389"/>
</object>
<int key="connectionID">128</int>
<int key="connectionID">112</int>
</object>
<object class="IBConnectionRecord">
<object class="IBCocoaTouchOutletConnection" key="connection">
<string key="label">contacts</string>
<reference key="source" ref="372490531"/>
<reference key="destination" ref="185207809"/>
</object>
<int key="connectionID">116</int>
</object>
<object class="IBConnectionRecord">
<object class="IBCocoaTouchOutletConnection" key="connection">
<string key="label">dialer</string>
<reference key="source" ref="372490531"/>
<reference key="destination" ref="884236009"/>
</object>
<int key="connectionID">141</int>
</object>
<object class="IBConnectionRecord">
<object class="IBCocoaTouchOutletConnection" key="connection">
@ -860,6 +888,30 @@
</object>
<int key="connectionID">129</int>
</object>
<object class="IBConnectionRecord">
<object class="IBCocoaTouchOutletConnection" key="connection">
<string key="label">controlSubView</string>
<reference key="source" ref="372490531"/>
<reference key="destination" ref="331380355"/>
</object>
<int key="connectionID">117</int>
</object>
<object class="IBConnectionRecord">
<object class="IBCocoaTouchOutletConnection" key="connection">
<string key="label">five</string>
<reference key="source" ref="372490531"/>
<reference key="destination" ref="46522822"/>
</object>
<int key="connectionID">120</int>
</object>
<object class="IBConnectionRecord">
<object class="IBCocoaTouchOutletConnection" key="connection">
<string key="label">nine</string>
<reference key="source" ref="372490531"/>
<reference key="destination" ref="713296002"/>
</object>
<int key="connectionID">126</int>
</object>
<object class="IBConnectionRecord">
<object class="IBCocoaTouchOutletConnection" key="connection">
<string key="label">seven</string>
@ -878,19 +930,11 @@
</object>
<object class="IBConnectionRecord">
<object class="IBCocoaTouchOutletConnection" key="connection">
<string key="label">speaker</string>
<string key="label">four</string>
<reference key="source" ref="372490531"/>
<reference key="destination" ref="1070839124"/>
<reference key="destination" ref="9029257"/>
</object>
<int key="connectionID">132</int>
</object>
<object class="IBConnectionRecord">
<object class="IBCocoaTouchOutletConnection" key="connection">
<string key="label">star</string>
<reference key="source" ref="372490531"/>
<reference key="destination" ref="1017517001"/>
</object>
<int key="connectionID">133</int>
<int key="connectionID">121</int>
</object>
<object class="IBConnectionRecord">
<object class="IBCocoaTouchOutletConnection" key="connection">
@ -900,6 +944,14 @@
</object>
<int key="connectionID">134</int>
</object>
<object class="IBConnectionRecord">
<object class="IBCocoaTouchOutletConnection" key="connection">
<string key="label">zero</string>
<reference key="source" ref="372490531"/>
<reference key="destination" ref="171697004"/>
</object>
<int key="connectionID">137</int>
</object>
<object class="IBConnectionRecord">
<object class="IBCocoaTouchOutletConnection" key="connection">
<string key="label">two</string>
@ -908,6 +960,54 @@
</object>
<int key="connectionID">135</int>
</object>
<object class="IBConnectionRecord">
<object class="IBCocoaTouchOutletConnection" key="connection">
<string key="label">close</string>
<reference key="source" ref="372490531"/>
<reference key="destination" ref="19432561"/>
</object>
<int key="connectionID">115</int>
</object>
<object class="IBConnectionRecord">
<object class="IBCocoaTouchOutletConnection" key="connection">
<string key="label">hash</string>
<reference key="source" ref="372490531"/>
<reference key="destination" ref="778910645"/>
</object>
<int key="connectionID">123</int>
</object>
<object class="IBConnectionRecord">
<object class="IBCocoaTouchOutletConnection" key="connection">
<string key="label">eight</string>
<reference key="source" ref="372490531"/>
<reference key="destination" ref="693786132"/>
</object>
<int key="connectionID">118</int>
</object>
<object class="IBConnectionRecord">
<object class="IBCocoaTouchOutletConnection" key="connection">
<string key="label">one</string>
<reference key="source" ref="372490531"/>
<reference key="destination" ref="855969656"/>
</object>
<int key="connectionID">127</int>
</object>
<object class="IBConnectionRecord">
<object class="IBCocoaTouchOutletConnection" key="connection">
<string key="label">star</string>
<reference key="source" ref="372490531"/>
<reference key="destination" ref="1017517001"/>
</object>
<int key="connectionID">133</int>
</object>
<object class="IBConnectionRecord">
<object class="IBCocoaTouchOutletConnection" key="connection">
<string key="label">padSubView</string>
<reference key="source" ref="372490531"/>
<reference key="destination" ref="815826897"/>
</object>
<int key="connectionID">128</int>
</object>
<object class="IBConnectionRecord">
<object class="IBCocoaTouchOutletConnection" key="connection">
<string key="label">view</string>
@ -918,27 +1018,27 @@
</object>
<object class="IBConnectionRecord">
<object class="IBCocoaTouchOutletConnection" key="connection">
<string key="label">zero</string>
<string key="label">videoGroup</string>
<reference key="source" ref="372490531"/>
<reference key="destination" ref="171697004"/>
<reference key="destination" ref="268077918"/>
</object>
<int key="connectionID">137</int>
<int key="connectionID">159</int>
</object>
<object class="IBConnectionRecord">
<object class="IBCocoaTouchOutletConnection" key="connection">
<string key="label">callTableView</string>
<string key="label">videoView</string>
<reference key="source" ref="372490531"/>
<reference key="destination" ref="447519759"/>
<reference key="destination" ref="202372206"/>
</object>
<int key="connectionID">114</int>
<int key="connectionID">161</int>
</object>
<object class="IBConnectionRecord">
<object class="IBCocoaTouchOutletConnection" key="connection">
<string key="label">dialer</string>
<string key="label">videoPreview</string>
<reference key="source" ref="372490531"/>
<reference key="destination" ref="884236009"/>
<reference key="destination" ref="1044210264"/>
</object>
<int key="connectionID">141</int>
<int key="connectionID">162</int>
</object>
<object class="IBConnectionRecord">
<object class="IBCocoaTouchOutletConnection" key="connection">
@ -1019,9 +1119,29 @@
<reference ref="331380355"/>
<reference ref="677109388"/>
<reference ref="447519759"/>
<reference ref="268077918"/>
</array>
<reference key="parent" ref="903665573"/>
</object>
<object class="IBObjectRecord">
<int key="objectID">61</int>
<reference key="object" ref="447519759"/>
<reference key="parent" ref="134115264"/>
</object>
<object class="IBObjectRecord">
<int key="objectID">88</int>
<reference key="object" ref="677109388"/>
<array class="NSMutableArray" key="children">
<reference ref="1019514465"/>
</array>
<reference key="parent" ref="134115264"/>
</object>
<object class="IBObjectRecord">
<int key="objectID">98</int>
<reference key="object" ref="1019514465"/>
<reference key="parent" ref="677109388"/>
<string key="objectName">end</string>
</object>
<object class="IBObjectRecord">
<int key="objectID">89</int>
<reference key="object" ref="331380355"/>
@ -1038,48 +1158,18 @@
<reference key="parent" ref="134115264"/>
<string key="objectName">controls</string>
</object>
<object class="IBObjectRecord">
<int key="objectID">97</int>
<reference key="object" ref="551654695"/>
<reference key="parent" ref="331380355"/>
<string key="objectName">pauseresume</string>
</object>
<object class="IBObjectRecord">
<int key="objectID">96</int>
<reference key="object" ref="1070839124"/>
<reference key="parent" ref="331380355"/>
<string key="objectName">speaker</string>
</object>
<object class="IBObjectRecord">
<int key="objectID">95</int>
<reference key="object" ref="884236009"/>
<reference key="parent" ref="331380355"/>
<string key="objectName">dialer</string>
</object>
<object class="IBObjectRecord">
<int key="objectID">94</int>
<reference key="object" ref="185207809"/>
<reference key="parent" ref="331380355"/>
<string key="objectName">contacts</string>
</object>
<object class="IBObjectRecord">
<int key="objectID">93</int>
<reference key="object" ref="914839389"/>
<reference key="parent" ref="331380355"/>
<string key="objectName">addcall</string>
</object>
<object class="IBObjectRecord">
<int key="objectID">92</int>
<reference key="object" ref="464527620"/>
<reference key="parent" ref="331380355"/>
<string key="objectName">mute</string>
</object>
<object class="IBObjectRecord">
<int key="objectID">91</int>
<reference key="object" ref="694322717"/>
<reference key="parent" ref="331380355"/>
<string key="objectName">merge</string>
</object>
<object class="IBObjectRecord">
<int key="objectID">90</int>
<reference key="object" ref="43602080"/>
@ -1087,12 +1177,34 @@
<string key="objectName">video</string>
</object>
<object class="IBObjectRecord">
<int key="objectID">88</int>
<reference key="object" ref="677109388"/>
<array class="NSMutableArray" key="children">
<reference ref="1019514465"/>
</array>
<reference key="parent" ref="134115264"/>
<int key="objectID">91</int>
<reference key="object" ref="694322717"/>
<reference key="parent" ref="331380355"/>
<string key="objectName">merge</string>
</object>
<object class="IBObjectRecord">
<int key="objectID">93</int>
<reference key="object" ref="914839389"/>
<reference key="parent" ref="331380355"/>
<string key="objectName">addcall</string>
</object>
<object class="IBObjectRecord">
<int key="objectID">94</int>
<reference key="object" ref="185207809"/>
<reference key="parent" ref="331380355"/>
<string key="objectName">contacts</string>
</object>
<object class="IBObjectRecord">
<int key="objectID">95</int>
<reference key="object" ref="884236009"/>
<reference key="parent" ref="331380355"/>
<string key="objectName">dialer</string>
</object>
<object class="IBObjectRecord">
<int key="objectID">97</int>
<reference key="object" ref="551654695"/>
<reference key="parent" ref="331380355"/>
<string key="objectName">pauseresume</string>
</object>
<object class="IBObjectRecord">
<int key="objectID">87</int>
@ -1116,70 +1228,10 @@
<string key="objectName">pad</string>
</object>
<object class="IBObjectRecord">
<int key="objectID">111</int>
<reference key="object" ref="1017517001"/>
<int key="objectID">99</int>
<reference key="object" ref="46522822"/>
<reference key="parent" ref="815826897"/>
<string key="objectName">star</string>
</object>
<object class="IBObjectRecord">
<int key="objectID">110</int>
<reference key="object" ref="855969656"/>
<reference key="parent" ref="815826897"/>
<string key="objectName">1</string>
</object>
<object class="IBObjectRecord">
<int key="objectID">109</int>
<reference key="object" ref="693786132"/>
<reference key="parent" ref="815826897"/>
<string key="objectName">8</string>
</object>
<object class="IBObjectRecord">
<int key="objectID">108</int>
<reference key="object" ref="778910645"/>
<reference key="parent" ref="815826897"/>
<string key="objectName">hash</string>
</object>
<object class="IBObjectRecord">
<int key="objectID">107</int>
<reference key="object" ref="19432561"/>
<reference key="parent" ref="815826897"/>
<string key="objectName">close</string>
</object>
<object class="IBObjectRecord">
<int key="objectID">106</int>
<reference key="object" ref="274639717"/>
<reference key="parent" ref="815826897"/>
<string key="objectName">2</string>
</object>
<object class="IBObjectRecord">
<int key="objectID">105</int>
<reference key="object" ref="171697004"/>
<reference key="parent" ref="815826897"/>
<string key="objectName">0</string>
</object>
<object class="IBObjectRecord">
<int key="objectID">104</int>
<reference key="object" ref="167373992"/>
<reference key="parent" ref="815826897"/>
<string key="objectName">3</string>
</object>
<object class="IBObjectRecord">
<int key="objectID">103</int>
<reference key="object" ref="9029257"/>
<reference key="parent" ref="815826897"/>
<string key="objectName">4</string>
</object>
<object class="IBObjectRecord">
<int key="objectID">102</int>
<reference key="object" ref="767525360"/>
<reference key="parent" ref="815826897"/>
<string key="objectName">6</string>
</object>
<object class="IBObjectRecord">
<int key="objectID">101</int>
<reference key="object" ref="686137646"/>
<reference key="parent" ref="815826897"/>
<string key="objectName">7</string>
<string key="objectName">5</string>
</object>
<object class="IBObjectRecord">
<int key="objectID">100</int>
@ -1188,21 +1240,105 @@
<string key="objectName">9</string>
</object>
<object class="IBObjectRecord">
<int key="objectID">99</int>
<reference key="object" ref="46522822"/>
<int key="objectID">101</int>
<reference key="object" ref="686137646"/>
<reference key="parent" ref="815826897"/>
<string key="objectName">5</string>
<string key="objectName">7</string>
</object>
<object class="IBObjectRecord">
<int key="objectID">98</int>
<reference key="object" ref="1019514465"/>
<reference key="parent" ref="677109388"/>
<string key="objectName">end</string>
<int key="objectID">102</int>
<reference key="object" ref="767525360"/>
<reference key="parent" ref="815826897"/>
<string key="objectName">6</string>
</object>
<object class="IBObjectRecord">
<int key="objectID">61</int>
<reference key="object" ref="447519759"/>
<int key="objectID">103</int>
<reference key="object" ref="9029257"/>
<reference key="parent" ref="815826897"/>
<string key="objectName">4</string>
</object>
<object class="IBObjectRecord">
<int key="objectID">104</int>
<reference key="object" ref="167373992"/>
<reference key="parent" ref="815826897"/>
<string key="objectName">3</string>
</object>
<object class="IBObjectRecord">
<int key="objectID">105</int>
<reference key="object" ref="171697004"/>
<reference key="parent" ref="815826897"/>
<string key="objectName">0</string>
</object>
<object class="IBObjectRecord">
<int key="objectID">106</int>
<reference key="object" ref="274639717"/>
<reference key="parent" ref="815826897"/>
<string key="objectName">2</string>
</object>
<object class="IBObjectRecord">
<int key="objectID">107</int>
<reference key="object" ref="19432561"/>
<reference key="parent" ref="815826897"/>
<string key="objectName">close</string>
</object>
<object class="IBObjectRecord">
<int key="objectID">108</int>
<reference key="object" ref="778910645"/>
<reference key="parent" ref="815826897"/>
<string key="objectName">hash</string>
</object>
<object class="IBObjectRecord">
<int key="objectID">109</int>
<reference key="object" ref="693786132"/>
<reference key="parent" ref="815826897"/>
<string key="objectName">8</string>
</object>
<object class="IBObjectRecord">
<int key="objectID">110</int>
<reference key="object" ref="855969656"/>
<reference key="parent" ref="815826897"/>
<string key="objectName">1</string>
</object>
<object class="IBObjectRecord">
<int key="objectID">111</int>
<reference key="object" ref="1017517001"/>
<reference key="parent" ref="815826897"/>
<string key="objectName">star</string>
</object>
<object class="IBObjectRecord">
<int key="objectID">152</int>
<reference key="object" ref="268077918"/>
<array class="NSMutableArray" key="children">
<reference ref="1044210264"/>
<reference ref="202372206"/>
<reference ref="1000324624"/>
<reference ref="70050671"/>
</array>
<reference key="parent" ref="134115264"/>
<string key="objectName">video</string>
</object>
<object class="IBObjectRecord">
<int key="objectID">158</int>
<reference key="object" ref="1044210264"/>
<reference key="parent" ref="268077918"/>
<string key="objectName">video_preview</string>
</object>
<object class="IBObjectRecord">
<int key="objectID">157</int>
<reference key="object" ref="202372206"/>
<reference key="parent" ref="268077918"/>
<string key="objectName">video_view</string>
</object>
<object class="IBObjectRecord">
<int key="objectID">154</int>
<reference key="object" ref="1000324624"/>
<reference key="parent" ref="268077918"/>
</object>
<object class="IBObjectRecord">
<int key="objectID">153</int>
<reference key="object" ref="70050671"/>
<reference key="parent" ref="268077918"/>
<string key="objectName">call_quality_video</string>
</object>
</array>
</object>
@ -1235,13 +1371,19 @@
<string key="110.IBPluginDependency">com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string>
<string key="111.CustomClassName">UIDigitButton</string>
<string key="111.IBPluginDependency">com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string>
<string key="152.IBPluginDependency">com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string>
<string key="153.IBPluginDependency">com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string>
<string key="154.CustomClassName">UICamSwitch</string>
<string key="154.IBPluginDependency">com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string>
<string key="157.IBPluginDependency">com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string>
<string key="158.IBPluginDependency">com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string>
<string key="59.IBPluginDependency">com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string>
<string key="60.IBPluginDependency">com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string>
<string key="61.IBPluginDependency">com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string>
<string key="87.IBPluginDependency">com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string>
<string key="88.IBPluginDependency">com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string>
<string key="89.IBPluginDependency">com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string>
<string key="90.CustomClassName">UIAddVideoButton</string>
<string key="90.CustomClassName">UIToggleVideoButton</string>
<string key="90.IBPluginDependency">com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string>
<string key="91.IBPluginDependency">com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string>
<real value="3" key="91.IBUIButtonInspectorSelectedStateConfigurationMetadataKey"/>
@ -1266,7 +1408,7 @@
<nil key="activeLocalization"/>
<dictionary class="NSMutableDictionary" key="localizations"/>
<nil key="sourceID"/>
<int key="maxID">144</int>
<int key="maxID">162</int>
</object>
<object class="IBClassDescriber" key="IBDocument.Classes">
<array class="NSMutableArray" key="referencedPartialClassDescriptions">
@ -1311,6 +1453,9 @@
<string key="star">UIButton</string>
<string key="three">UIButton</string>
<string key="two">UIButton</string>
<string key="videoGroup">UIView</string>
<string key="videoPreview">UIView</string>
<string key="videoView">UIView</string>
<string key="videoViewController">VideoViewController</string>
<string key="zero">UIButton</string>
</dictionary>
@ -1419,6 +1564,18 @@
<string key="name">two</string>
<string key="candidateClassName">UIButton</string>
</object>
<object class="IBToOneOutletInfo" key="videoGroup">
<string key="name">videoGroup</string>
<string key="candidateClassName">UIView</string>
</object>
<object class="IBToOneOutletInfo" key="videoPreview">
<string key="name">videoPreview</string>
<string key="candidateClassName">UIView</string>
</object>
<object class="IBToOneOutletInfo" key="videoView">
<string key="name">videoView</string>
<string key="candidateClassName">UIView</string>
</object>
<object class="IBToOneOutletInfo" key="videoViewController">
<string key="name">videoViewController</string>
<string key="candidateClassName">VideoViewController</string>
@ -1433,14 +1590,6 @@
<string key="minorKey">./Classes/IncallViewController.h</string>
</object>
</object>
<object class="IBPartialClassDescription">
<string key="className">UIAddVideoButton</string>
<string key="superclassName">UIButton</string>
<object class="IBClassDescriptionSource" key="sourceIdentifier">
<string key="majorKey">IBProjectSource</string>
<string key="minorKey">./Classes/UIAddVideoButton.h</string>
</object>
</object>
<object class="IBPartialClassDescription">
<string key="className">UICamSwitch</string>
<string key="superclassName">UIButton</string>
@ -1500,6 +1649,14 @@
<string key="minorKey">./Classes/UIToggleButton.h</string>
</object>
</object>
<object class="IBPartialClassDescription">
<string key="className">UIToggleVideoButton</string>
<string key="superclassName">UIButton</string>
<object class="IBClassDescriptionSource" key="sourceIdentifier">
<string key="majorKey">IBProjectSource</string>
<string key="minorKey">./Classes/UIToggleVideoButton.h</string>
</object>
</object>
<object class="IBPartialClassDescription">
<string key="className">VideoViewController</string>
<string key="superclassName">UIViewController</string>
@ -1628,6 +1785,7 @@
<string key="HP_inverse.png">{107, 67}</string>
<string key="ajouter.png">{107, 67}</string>
<string key="clavier-01-106px.png">{106, 60}</string>
<string key="clavier-01-108px.png">{108, 60}</string>
<string key="clavier-01-160px.png">{160, 60}</string>
<string key="clavier.png">{106, 67}</string>
<string key="contact.png">{107, 67}</string>

View file

@ -82,7 +82,7 @@
UIImage* verified, *unverified;
UIImage* stat_sys_signal_0, *stat_sys_signal_1, *stat_sys_signal_2, *stat_sys_signal_3, *stat_sys_signal_4;
UIActionSheet* zrtpVerificationSheet;
UIActionSheet* visibleActionSheet;
NSTimer* hideControlsTimer;
}

View file

@ -122,6 +122,61 @@ void addAnimationFadeTransition(UIView* view, float duration) {
[view.layer addAnimation:animation forKey:nil];
}
-(void) orientationChanged: (NSNotification*) notif {
int oldLinphoneOrientation = linphone_core_get_device_rotation([LinphoneManager getLc]);
UIDeviceOrientation orientation = [UIDevice currentDevice].orientation;
switch (orientation) {
case UIInterfaceOrientationPortrait:
linphone_core_set_device_rotation([LinphoneManager getLc], 0);
break;
case UIInterfaceOrientationLandscapeRight:
linphone_core_set_device_rotation([LinphoneManager getLc], 270);
break;
case UIInterfaceOrientationLandscapeLeft:
linphone_core_set_device_rotation([LinphoneManager getLc], 90);
break;
default:
break;
}
if (oldLinphoneOrientation != linphone_core_get_device_rotation([LinphoneManager getLc])) {
linphone_core_set_native_video_window_id([LinphoneManager getLc],(unsigned long)videoView);
LinphoneCall* call = linphone_core_get_current_call([LinphoneManager getLc]);
if (call && linphone_call_params_video_enabled(linphone_call_get_current_params(call))) {
//Orientation has change, must call update call
linphone_core_update_call([LinphoneManager getLc], call, NULL);
/* animate button images rotation */
#define degreesToRadians(x) (M_PI * x / 180.0)
CGAffineTransform transform = CGAffineTransformIdentity;
switch (orientation) {
case UIInterfaceOrientationLandscapeRight:
transform = CGAffineTransformMakeRotation(degreesToRadians(90));
break;
case UIInterfaceOrientationLandscapeLeft:
transform = CGAffineTransformMakeRotation(degreesToRadians(-90));
break;
default:
transform = CGAffineTransformIdentity;
break;
}
[UIView beginAnimations:nil context:NULL];
[UIView setAnimationDuration:0.2f];
endCtrl.imageView.transform = transform;
mute.imageView.transform = transform;
speaker.imageView.transform = transform;
pause.imageView.transform = transform;
contacts.imageView.transform = transform;
addCall.imageView.transform = transform;
addVideo.imageView.transform = transform;
dialer.imageView.transform = transform;
[UIView commitAnimations];
}
}
}
-(void) showControls:(id)sender {
if (hideControlsTimer) {
[hideControlsTimer invalidate];
@ -148,6 +203,8 @@ void addAnimationFadeTransition(UIView* view, float duration) {
}
-(void) enableVideoDisplay {
[self orientationChanged:nil];
[videoGroup setHidden:FALSE];
[controlSubView setHidden:TRUE];
[hangUpView setHidden:TRUE];
@ -155,7 +212,6 @@ void addAnimationFadeTransition(UIView* view, float duration) {
linphone_core_set_native_video_window_id([LinphoneManager getLc],(unsigned long)videoView);
linphone_core_set_native_preview_window_id([LinphoneManager getLc],(unsigned long)videoPreview);
linphone_core_set_device_rotation([LinphoneManager getLc], 0);
[[UIApplication sharedApplication] setStatusBarHidden:YES withAnimation:UIStatusBarAnimationSlide];
@ -180,6 +236,15 @@ void addAnimationFadeTransition(UIView* view, float duration) {
hideControlsTimer = nil;
}
/* restore buttons orientation */
endCtrl.imageView.transform = CGAffineTransformIdentity;
mute.imageView.transform = CGAffineTransformIdentity;
speaker.imageView.transform = CGAffineTransformIdentity;
pause.imageView.transform = CGAffineTransformIdentity;
contacts.imageView.transform = CGAffineTransformIdentity;
addCall.imageView.transform = CGAffineTransformIdentity;
dialer.imageView.transform = CGAffineTransformIdentity;
[[UIApplication sharedApplication] setStatusBarHidden:NO withAnimation:UIStatusBarAnimationNone];
}
@ -212,6 +277,12 @@ void addAnimationFadeTransition(UIView* view, float duration) {
} else {
[LinphoneManager set:pause hidden:YES withName:"PAUSE button" andReason:AT];
}
if (linphone_call_params_video_enabled(linphone_call_get_current_params(selectedCall))) {
addVideo.titleLabel.text = NSLocalizedString(@"-video", nil);
} else {
addVideo.titleLabel.text = NSLocalizedString(@"+video", nil);
}
} else {
if (callsCount == 1) {
LinphoneCall* c = (LinphoneCall*)linphone_core_get_calls(lc)->data;
@ -342,28 +413,6 @@ void addAnimationFadeTransition(UIView* view, float duration) {
[self updateUIFromLinphoneState: nil];
}
-(void) orientationChanged: (NSNotification*) notif {
int oldLinphoneOrientation = linphone_core_get_device_rotation([LinphoneManager getLc]);
UIDeviceOrientation orientation = [UIDevice currentDevice].orientation;
switch (orientation) {
case UIInterfaceOrientationPortrait:
linphone_core_set_device_rotation([LinphoneManager getLc], 0);
break;
case UIInterfaceOrientationLandscapeRight:
linphone_core_set_device_rotation([LinphoneManager getLc], 270);
break;
case UIInterfaceOrientationLandscapeLeft:
linphone_core_set_device_rotation([LinphoneManager getLc], 90);
break;
}
if ((oldLinphoneOrientation != linphone_core_get_device_rotation([LinphoneManager getLc]))
&& linphone_core_get_current_call([LinphoneManager getLc])) {
linphone_core_set_native_video_window_id([LinphoneManager getLc],(unsigned long)videoView);
//Orientation has change, must call update call
linphone_core_update_call([LinphoneManager getLc], linphone_core_get_current_call([LinphoneManager getLc]), NULL);
}
}
-(void) awakeFromNib
{
@ -403,15 +452,15 @@ void addAnimationFadeTransition(UIView* view, float duration) {
bool enableVideo = [[NSUserDefaults standardUserDefaults] boolForKey:@"enable_video_preference"];
bool startVideo = [[NSUserDefaults standardUserDefaults] boolForKey:@"start_video_preference"];
[LinphoneManager set:contacts hidden:(enableVideo && !startVideo) withName:"CONTACT button" andReason:AT];
[LinphoneManager set:contacts hidden:enableVideo withName:"CONTACT button" andReason:AT];
[LinphoneManager set:addVideo hidden:!contacts.hidden withName:"ADD_VIDEO button" andReason:AT];
}
}
}
-(void) viewWillDisappear:(BOOL)animated {
if (zrtpVerificationSheet != nil) {
[zrtpVerificationSheet dismissWithClickedButtonIndex:2 animated:NO];
if (visibleActionSheet != nil) {
[visibleActionSheet dismissWithClickedButtonIndex:visibleActionSheet.cancelButtonIndex animated:NO];
}
}
@ -459,11 +508,6 @@ void addAnimationFadeTransition(UIView* view, float duration) {
}
-(void) dismissVideoView {
[[UIApplication sharedApplication] setStatusBarHidden:NO withAnimation:UIStatusBarAnimationNone];
[self dismissModalViewControllerAnimated:FALSE];//just in case
mVideoShown=FALSE;
}
-(void) displayInCall:(LinphoneCall*) call FromUI:(UIViewController*) viewCtrl forUser:(NSString*) username withDisplayName:(NSString*) displayName {
dismissed = false;
UIDevice *device = [UIDevice currentDevice];
@ -474,9 +518,6 @@ void addAnimationFadeTransition(UIView* view, float duration) {
[self updateUIFromLinphoneState: nil];
[self disableVideoDisplay];
/*if (self.presentedViewController == (UIViewController*)mVideoViewController) {
[self dismissVideoView];
}*/
}
-(void) displayDialerFromUI:(UIViewController*) viewCtrl forUser:(NSString*) username withDisplayName:(NSString*) displayName {
[self disableVideoDisplay];
@ -512,11 +553,46 @@ void addAnimationFadeTransition(UIView* view, float duration) {
else
ms_message("Do not present again videoViewController");
} else {
//postepone presentation
//postpone presentation
mVideoIsPending=TRUE;
}
}
-(void) dismissActionSheet: (id)o {
if (visibleActionSheet != nil) {
[visibleActionSheet dismissWithClickedButtonIndex:visibleActionSheet.cancelButtonIndex animated:TRUE];
visibleActionSheet = nil;
}
}
-(void) displayAskToEnableVideoCall:(LinphoneCall*) call forUser:(NSString*) username withDisplayName:(NSString*) displayName {
if (linphone_core_get_video_policy([LinphoneManager getLc])->automatically_accept)
return;
// ask the user if he agrees
CallDelegate* cd = [[CallDelegate alloc] init];
cd.eventType = CD_VIDEO_UPDATE;
cd.delegate = self;
cd.call = call;
if (visibleActionSheet != nil) {
[visibleActionSheet dismissWithClickedButtonIndex:visibleActionSheet.cancelButtonIndex animated:TRUE];
}
NSString* title = [NSString stringWithFormat : NSLocalizedString(@"'%@' would like to enable video",nil), ([displayName length] > 0) ?displayName:username];
visibleActionSheet = [[UIActionSheet alloc] initWithTitle:title
delegate:cd
cancelButtonTitle:NSLocalizedString(@"Decline",nil)
destructiveButtonTitle:NSLocalizedString(@"Accept",nil)
otherButtonTitles:nil];
visibleActionSheet.actionSheetStyle = UIActionSheetStyleDefault;
[visibleActionSheet showInView:self.view];
/* start cancel timer */
cd.timeout = [NSTimer scheduledTimerWithTimeInterval:30 target:self selector:@selector(dismissActionSheet:) userInfo:nil repeats:NO];
[visibleActionSheet release];
}
- (IBAction)doAction:(id)sender {
if (sender == dialer) {
@ -813,33 +889,60 @@ void addAnimationFadeTransition(UIView* view, float duration) {
LinphoneCall* call = [IncallViewController retrieveCallAtIndex:path.row inConference:NO];
// start action sheet to validate/unvalidate zrtp code
CallDelegate* cd = [[CallDelegate alloc] init];
cd.eventType = CD_ZRTP;
cd.delegate = self;
cd.call = call;
UIView* container=(UIView*)[callTableView cellForRowAtIndexPath:path].accessoryView;
UIButton *button=(UIButton*)[container viewWithTag:SECURE_BUTTON_TAG];
[button setImage:nil forState:UIControlStateNormal];
zrtpVerificationSheet = [[UIActionSheet alloc] initWithTitle:[NSString stringWithFormat:NSLocalizedString(@" Mark auth token '%s' as:",nil),linphone_call_get_authentication_token(call)]
if (visibleActionSheet != nil) {
[visibleActionSheet dismissWithClickedButtonIndex:visibleActionSheet.cancelButtonIndex animated:TRUE];
}
visibleActionSheet = [[UIActionSheet alloc] initWithTitle:[NSString stringWithFormat:NSLocalizedString(@" Mark auth token '%s' as:",nil),linphone_call_get_authentication_token(call)]
delegate:cd
cancelButtonTitle:NSLocalizedString(@"Unverified",nil)
destructiveButtonTitle:NSLocalizedString(@"Verified",nil)
otherButtonTitles:nil];
zrtpVerificationSheet.actionSheetStyle = UIActionSheetStyleDefault;
[zrtpVerificationSheet showInView:self.view];
[zrtpVerificationSheet release];
visibleActionSheet.actionSheetStyle = UIActionSheetStyleDefault;
[visibleActionSheet showInView:self.view];
[visibleActionSheet release];
}
}
-(void) actionSheet:(UIActionSheet *)actionSheet clickedButtonAtIndex:(NSInteger)buttonIndex withUserDatas:(void *)datas {
-(void) actionSheet:(UIActionSheet *)actionSheet ofType:(enum CallDelegateType)type clickedButtonAtIndex:(NSInteger)buttonIndex withUserDatas:(void *)datas {
LinphoneCall* call = (LinphoneCall*)datas;
// maybe we could verify call validity
if (buttonIndex == 0)
linphone_call_set_authentication_token_verified(call, YES);
else if (buttonIndex == 1)
linphone_call_set_authentication_token_verified(call, NO);
zrtpVerificationSheet = nil;
switch (type) {
case CD_ZRTP: {
if (buttonIndex == 0)
linphone_call_set_authentication_token_verified(call, YES);
else if (buttonIndex == 1)
linphone_call_set_authentication_token_verified(call, NO);
visibleActionSheet = nil;
break;
}
case CD_VIDEO_UPDATE: {
LinphoneCall* call = (LinphoneCall*)datas;
LinphoneCallParams* paramsCopy = linphone_call_params_copy(linphone_call_get_current_params(call));
if ([visibleActionSheet destructiveButtonIndex] == buttonIndex) {
// accept video
linphone_call_params_enable_video(paramsCopy, TRUE);
linphone_core_accept_call_update([LinphoneManager getLc], call, paramsCopy);
} else {
// decline video
ms_message("User declined video proposal");
linphone_core_accept_call_update([LinphoneManager getLc], call, NULL);
}
linphone_call_params_destroy(paramsCopy);
visibleActionSheet = nil;
break;
}
default:
ms_error("Unhandled CallDelegate event of type: %d received - ignoring", type);
}
}
// UITableViewDataSource (required)

View file

@ -81,7 +81,7 @@
<string key="NSFrameSize">{320, 460}</string>
<reference key="NSSuperview" ref="858247959"/>
<reference key="NSWindow"/>
<reference key="NSNextKeyView" ref="1017044170"/>
<reference key="NSNextKeyView"/>
<string key="NSReuseIdentifierKey">_NS:196</string>
<reference key="IBUIBackgroundColor" ref="95762599"/>
<bool key="IBUIAutoresizesSubviews">NO</bool>
@ -395,6 +395,7 @@
<reference key="NSNextKeyView" ref="478667533"/>
<reference key="IBUIBackgroundColor" ref="95762599"/>
<bool key="IBUIOpaque">NO</bool>
<bool key="IBUIAutoresizesSubviews">NO</bool>
<bool key="IBUIClearsContextBeforeDrawing">NO</bool>
<string key="targetRuntimeIdentifier">IBCocoaTouchFramework</string>
<int key="IBUIContentHorizontalAlignment">0</int>
@ -1381,7 +1382,7 @@
<string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string>
<real value="1"/>
<string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string>
<string>UIAddVideoButton</string>
<string>UIToggleVideoButton</string>
<string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string>
<string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string>
<string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string>
@ -1440,7 +1441,7 @@
<reference key="dict.values" ref="0"/>
</object>
<nil key="sourceID"/>
<int key="maxID">133</int>
<int key="maxID">134</int>
</object>
<object class="IBClassDescriber" key="IBDocument.Classes">
<object class="NSMutableArray" key="referencedPartialClassDescriptions">
@ -1699,14 +1700,6 @@
<string key="minorKey">./Classes/IncallViewController.h</string>
</object>
</object>
<object class="IBPartialClassDescription">
<string key="className">UIAddVideoButton</string>
<string key="superclassName">UIButton</string>
<object class="IBClassDescriptionSource" key="sourceIdentifier">
<string key="majorKey">IBProjectSource</string>
<string key="minorKey">./Classes/UIAddVideoButton.h</string>
</object>
</object>
<object class="IBPartialClassDescription">
<string key="className">UICamSwitch</string>
<string key="superclassName">UIButton</string>
@ -1766,6 +1759,14 @@
<string key="minorKey">./Classes/UIToggleButton.h</string>
</object>
</object>
<object class="IBPartialClassDescription">
<string key="className">UIToggleVideoButton</string>
<string key="superclassName">UIButton</string>
<object class="IBClassDescriptionSource" key="sourceIdentifier">
<string key="majorKey">IBProjectSource</string>
<string key="minorKey">./Classes/UIToggleVideoButton.h</string>
</object>
</object>
<object class="IBPartialClassDescription">
<string key="className">VideoViewController</string>
<string key="superclassName">UIViewController</string>

View file

@ -23,6 +23,7 @@
#include "linphonecore.h"
#import "LogView.h"
#import "LinphoneUIDelegates.h"
typedef enum _Connectivity {
wifi,
wwan

View file

@ -150,6 +150,7 @@ extern void libmsbcg729_init();
[lE164Number release];
return;
}
-(void) onCall:(LinphoneCall*) call StateChanged: (LinphoneCallState) new_state withMessage: (const char *) message {
const char* lUserNameChars=linphone_address_get_username(linphone_call_get_remote_address(call));
NSString* lUserName = lUserNameChars?[[[NSString alloc] initWithUTF8String:lUserNameChars] autorelease]:NSLocalizedString(@"Unknown",nil);
@ -169,7 +170,9 @@ extern void libmsbcg729_init();
[callDelegate displayVideoCall:call FromUI:mCurrentViewController
forUser:lUserName
withDisplayName:lDisplayName];
}
} else {
[callDelegate displayInCall:call FromUI:mCurrentViewController forUser:lUserName withDisplayName:lDisplayName];
}
break;
case LinphoneCallIncomingReceived:
@ -192,7 +195,31 @@ extern void libmsbcg729_init();
forUser:lUserName
withDisplayName:lDisplayName];
break;
case LinphoneCallUpdatedByRemote:
{
const LinphoneCallParams* current = linphone_call_get_current_params(call);
const LinphoneCallParams* remote = linphone_call_get_remote_params(call);
/* remote wants to add video */
if (!linphone_call_params_video_enabled(current) && linphone_call_params_video_enabled(remote) && !linphone_core_get_video_policy(theLinphoneCore)->automatically_accept) {
linphone_core_defer_call_update(theLinphoneCore, call);
[callDelegate displayAskToEnableVideoCall:call forUser:lUserName withDisplayName:lDisplayName];
} else if (linphone_call_params_video_enabled(current) && !linphone_call_params_video_enabled(remote)) {
[callDelegate displayInCall:call FromUI:mCurrentViewController forUser:lUserName withDisplayName:lDisplayName];
}
break;
}
case LinphoneCallUpdated:
{
const LinphoneCallParams* current = linphone_call_get_current_params(call);
if (linphone_call_params_video_enabled(current)) {
[callDelegate displayVideoCall:call FromUI:mCurrentViewController forUser:lUserName withDisplayName:lDisplayName];
} else {
[callDelegate displayInCall:call FromUI:mCurrentViewController forUser:lUserName withDisplayName:lDisplayName];
}
break;
}
case LinphoneCallError: {
/*
NSString* lTitle= state->message!=nil?[NSString stringWithCString:state->message length:strlen(state->message)]: @"Error";
@ -649,6 +676,11 @@ void networkReachabilityCallBack(SCNetworkReachabilityRef target, SCNetworkReach
bool enableSrtp = [[NSUserDefaults standardUserDefaults] boolForKey:@"enable_srtp_preference"];
linphone_core_set_media_encryption(theLinphoneCore, enableSrtp?LinphoneMediaEncryptionSRTP:LinphoneMediaEncryptionZRTP);
LinphoneVideoPolicy policy;
policy.automatically_accept = [[NSUserDefaults standardUserDefaults] boolForKey:@"start_video_preference"];;
policy.automatically_initiate = [[NSUserDefaults standardUserDefaults] boolForKey:@"start_video_preference"];
linphone_core_set_video_policy(theLinphoneCore, &policy);
UIDevice* device = [UIDevice currentDevice];
bool backgroundSupported = false;
if ([device respondsToSelector:@selector(isMultitaskingSupported)])

View file

@ -28,6 +28,7 @@
-(void) displayVideoCall:(LinphoneCall*) call FromUI:(UIViewController*) viewCtrl forUser:(NSString*) username withDisplayName:(NSString*) displayName;
//status reporting
-(void) displayStatus:(NSString*) message;
-(void) displayAskToEnableVideoCall:(LinphoneCall*) call forUser:(NSString*) username withDisplayName:(NSString*) displayName;
@end

View file

@ -52,9 +52,7 @@
LinphoneProxyConfig* proxyCfg;
//get default proxy
linphone_core_get_default_proxy([LinphoneManager getLc],&proxyCfg);
bool startVideo = [[NSUserDefaults standardUserDefaults] boolForKey:@"start_video_preference"];
LinphoneCallParams* lcallParams = linphone_core_create_default_call_parameters([LinphoneManager getLc]);
linphone_call_params_enable_video(lcallParams,startVideo&linphone_core_video_enabled([LinphoneManager getLc]));
if ([mAddress.text length] == 0) return; //just return
if ([mAddress.text hasPrefix:@"sip:"]) {

View file

@ -1,4 +1,4 @@
/* UIAddVideoButton.h
/* UIToggleVideoButton.h
*
* Copyright (C) 2011 Belledonne Comunications, Grenoble, France
*
@ -19,6 +19,6 @@
#import <UIKit/UIKit.h>
@interface UIAddVideoButton : UIButton
@interface UIToggleVideoButton : UIButton
- (id)initWithCoder:(NSCoder *)decoder;
@end

View file

@ -1,4 +1,4 @@
/* UIAddVideoButton.m
/* UIToggleVideoButton.m
*
* Copyright (C) 2011 Belledonne Comunications, Grenoble, France
*
@ -17,21 +17,31 @@
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
*/
#import "UIAddVideoButton.h"
#import "UIToggleVideoButton.h"
#include "LinphoneManager.h"
@implementation UIAddVideoButton
@implementation UIToggleVideoButton
-(void) touchUp:(id) sender {
LinphoneCore* lc = [LinphoneManager getLc];
if (!linphone_core_video_enabled(lc))
return;
LinphoneCall* call = linphone_core_get_current_call([LinphoneManager getLc]);
if (call) {
LinphoneCallParams* call_params = linphone_call_params_copy(linphone_call_get_current_params(call));
linphone_call_params_enable_video(call_params, TRUE);
if (linphone_call_params_video_enabled(call_params)) {
ms_message("Disabling video");
linphone_call_params_enable_video(call_params, FALSE);
} else {
ms_message("Enabling video");
linphone_call_params_enable_video(call_params, TRUE);
}
linphone_core_update_call(lc, call, call_params);
linphone_call_params_destroy(call_params);
} {
ms_warning("Cannot add video, because no current call");
} else {
ms_warning("Cannot toggle video, because no current call");
}
}

View file

@ -258,6 +258,7 @@
}
} else {
CallDelegate* cd = [[CallDelegate alloc] init];
cd.eventType = CD_NEW_CALL;
cd.delegate = self;
cd.call = call;
@ -326,9 +327,16 @@
[mMainScreenWithVideoPreview showPreview:NO];
}
-(void) displayAskToEnableVideoCall:(LinphoneCall*) call forUser:(NSString*) username withDisplayName:(NSString*) displayName {
[mIncallViewController displayAskToEnableVideoCall:call forUser:username withDisplayName:displayName];
}
- (void)actionSheet:(UIActionSheet *)actionSheet clickedButtonAtIndex:(NSInteger)buttonIndex withUserDatas:(void *)datas{
- (void)actionSheet:(UIActionSheet *)actionSheet ofType:(enum CallDelegateType)type clickedButtonAtIndex:(NSInteger)buttonIndex withUserDatas:(void *)datas {
if (type != CD_NEW_CALL)
return;
LinphoneCall* call = (LinphoneCall*)datas;
if (buttonIndex == actionSheet.destructiveButtonIndex ) {
linphone_core_accept_call([LinphoneManager getLc],call);

View file

@ -37,7 +37,6 @@
<int key="NSvFlags">274</int>
<string key="NSFrameSize">{768, 1004}</string>
<reference key="NSSuperview"/>
<reference key="NSWindow"/>
<object class="NSColor" key="IBUIBackgroundColor">
<int key="NSColorSpace">4</int>
<bytes key="NSWhite">MAA</bytes>
@ -53,18 +52,25 @@
<int key="NSvFlags">292</int>
<string key="NSFrame">{{-9, 0}, {777, 1004}}</string>
<reference key="NSSuperview" ref="25193021"/>
<reference key="NSWindow"/>
<reference key="NSNextKeyView" ref="68468370"/>
<string key="NSReuseIdentifierKey">_NS:569</string>
<bool key="IBUIUserInteractionEnabled">NO</bool>
<string key="targetRuntimeIdentifier">IBIPadFramework</string>
</object>
<object class="IBUIImageView" id="901145609">
<reference key="NSNextResponder" ref="25193021"/>
<int key="NSvFlags">292</int>
<string key="NSFrame">{{20, 956}, {28, 28}}</string>
<reference key="NSSuperview" ref="25193021"/>
<string key="NSReuseIdentifierKey">_NS:567</string>
<bool key="IBUIUserInteractionEnabled">NO</bool>
<string key="targetRuntimeIdentifier">IBIPadFramework</string>
</object>
<object class="IBUIButton" id="897140295">
<reference key="NSNextResponder" ref="25193021"/>
<int key="NSvFlags">292</int>
<string key="NSFrame">{{329, 942}, {108, 62}}</string>
<reference key="NSSuperview" ref="25193021"/>
<reference key="NSWindow"/>
<reference key="NSNextKeyView" ref="509323940"/>
<bool key="IBUIOpaque">NO</bool>
<string key="targetRuntimeIdentifier">IBIPadFramework</string>
@ -107,7 +113,6 @@
<int key="NSvFlags">292</int>
<string key="NSFrame">{{223, 942}, {108, 62}}</string>
<reference key="NSSuperview" ref="25193021"/>
<reference key="NSWindow"/>
<reference key="NSNextKeyView" ref="897140295"/>
<bool key="IBUIOpaque">NO</bool>
<string key="targetRuntimeIdentifier">IBIPadFramework</string>
@ -128,7 +133,6 @@
<int key="NSvFlags">292</int>
<string key="NSFrame">{{598, 779}, {170, 225}}</string>
<reference key="NSSuperview" ref="25193021"/>
<reference key="NSWindow"/>
<object class="NSColor" key="IBUIBackgroundColor">
<int key="NSColorSpace">3</int>
<bytes key="NSWhite">MQA</bytes>
@ -143,7 +147,6 @@
<int key="NSvFlags">292</int>
<string key="NSFrame">{{436, 942}, {108, 62}}</string>
<reference key="NSSuperview" ref="25193021"/>
<reference key="NSWindow"/>
<reference key="NSNextKeyView" ref="679593526"/>
<bool key="IBUIOpaque">NO</bool>
<string key="targetRuntimeIdentifier">IBIPadFramework</string>
@ -161,20 +164,9 @@
<reference key="IBUIFontDescription" ref="714163490"/>
<reference key="IBUIFont" ref="5163959"/>
</object>
<object class="IBUIImageView" id="901145609">
<reference key="NSNextResponder" ref="25193021"/>
<int key="NSvFlags">292</int>
<string key="NSFrame">{{20, 956}, {28, 28}}</string>
<reference key="NSSuperview" ref="25193021"/>
<reference key="NSWindow"/>
<string key="NSReuseIdentifierKey">_NS:567</string>
<bool key="IBUIUserInteractionEnabled">NO</bool>
<string key="targetRuntimeIdentifier">IBIPadFramework</string>
</object>
</array>
<string key="NSFrameSize">{768, 1004}</string>
<reference key="NSSuperview"/>
<reference key="NSWindow"/>
<reference key="NSNextKeyView" ref="873033834"/>
<string key="NSReuseIdentifierKey">_NS:212</string>
<object class="NSColor" key="IBUIBackgroundColor">
@ -192,7 +184,6 @@
<int key="NSvFlags">292</int>
<string key="NSFrameSize">{1004, 768}</string>
<reference key="NSSuperview" ref="763566492"/>
<reference key="NSWindow"/>
<reference key="NSNextKeyView" ref="637528292"/>
<string key="NSReuseIdentifierKey">_NS:569</string>
<bool key="IBUIUserInteractionEnabled">NO</bool>
@ -203,7 +194,6 @@
<int key="NSvFlags">292</int>
<string key="NSFrame">{{779, 598}, {225, 170}}</string>
<reference key="NSSuperview" ref="763566492"/>
<reference key="NSWindow"/>
<object class="NSColor" key="IBUIBackgroundColor">
<int key="NSColorSpace">3</int>
<bytes key="NSWhite">MQA</bytes>
@ -216,7 +206,6 @@
<int key="NSvFlags">292</int>
<string key="NSFrame">{{341, 706}, {108, 62}}</string>
<reference key="NSSuperview" ref="763566492"/>
<reference key="NSWindow"/>
<reference key="NSNextKeyView" ref="303730267"/>
<bool key="IBUIOpaque">NO</bool>
<string key="targetRuntimeIdentifier">IBIPadFramework</string>
@ -237,7 +226,6 @@
<int key="NSvFlags">292</int>
<string key="NSFrame">{{448, 706}, {108, 62}}</string>
<reference key="NSSuperview" ref="763566492"/>
<reference key="NSWindow"/>
<reference key="NSNextKeyView" ref="499714887"/>
<bool key="IBUIOpaque">NO</bool>
<string key="targetRuntimeIdentifier">IBIPadFramework</string>
@ -259,7 +247,6 @@
<int key="NSvFlags">292</int>
<string key="NSFrame">{{555, 706}, {108, 62}}</string>
<reference key="NSSuperview" ref="763566492"/>
<reference key="NSWindow"/>
<reference key="NSNextKeyView" ref="756580344"/>
<bool key="IBUIOpaque">NO</bool>
<string key="targetRuntimeIdentifier">IBIPadFramework</string>
@ -282,7 +269,6 @@
<int key="NSvFlags">292</int>
<string key="NSFrame">{{20, 720}, {28, 28}}</string>
<reference key="NSSuperview" ref="763566492"/>
<reference key="NSWindow"/>
<string key="NSReuseIdentifierKey">_NS:567</string>
<bool key="IBUIUserInteractionEnabled">NO</bool>
<string key="targetRuntimeIdentifier">IBIPadFramework</string>
@ -290,7 +276,6 @@
</array>
<string key="NSFrameSize">{1004, 768}</string>
<reference key="NSSuperview"/>
<reference key="NSWindow"/>
<reference key="NSNextKeyView" ref="696525010"/>
<string key="NSReuseIdentifierKey">_NS:212</string>
<object class="NSColor" key="IBUIBackgroundColor">
@ -312,7 +297,6 @@
<int key="NSvFlags">292</int>
<string key="NSFrameSize">{1004, 768}</string>
<reference key="NSSuperview" ref="79829529"/>
<reference key="NSWindow"/>
<reference key="NSNextKeyView" ref="243148779"/>
<string key="NSReuseIdentifierKey">_NS:569</string>
<bool key="IBUIUserInteractionEnabled">NO</bool>
@ -323,7 +307,6 @@
<int key="NSvFlags">292</int>
<string key="NSFrame">{{779, 598}, {225, 170}}</string>
<reference key="NSSuperview" ref="79829529"/>
<reference key="NSWindow"/>
<object class="NSColor" key="IBUIBackgroundColor">
<int key="NSColorSpace">3</int>
<bytes key="NSWhite">MQA</bytes>
@ -336,7 +319,6 @@
<int key="NSvFlags">292</int>
<string key="NSFrame">{{341, 706}, {108, 62}}</string>
<reference key="NSSuperview" ref="79829529"/>
<reference key="NSWindow"/>
<reference key="NSNextKeyView" ref="796028571"/>
<bool key="IBUIOpaque">NO</bool>
<string key="targetRuntimeIdentifier">IBIPadFramework</string>
@ -357,7 +339,6 @@
<int key="NSvFlags">292</int>
<string key="NSFrame">{{448, 706}, {108, 62}}</string>
<reference key="NSSuperview" ref="79829529"/>
<reference key="NSWindow"/>
<reference key="NSNextKeyView" ref="551257366"/>
<bool key="IBUIOpaque">NO</bool>
<string key="targetRuntimeIdentifier">IBIPadFramework</string>
@ -379,7 +360,6 @@
<int key="NSvFlags">292</int>
<string key="NSFrame">{{555, 706}, {108, 62}}</string>
<reference key="NSSuperview" ref="79829529"/>
<reference key="NSWindow"/>
<reference key="NSNextKeyView" ref="799261982"/>
<bool key="IBUIOpaque">NO</bool>
<string key="targetRuntimeIdentifier">IBIPadFramework</string>
@ -402,7 +382,6 @@
<int key="NSvFlags">292</int>
<string key="NSFrame">{{20, 720}, {28, 28}}</string>
<reference key="NSSuperview" ref="79829529"/>
<reference key="NSWindow"/>
<string key="NSReuseIdentifierKey">_NS:567</string>
<bool key="IBUIUserInteractionEnabled">NO</bool>
<string key="targetRuntimeIdentifier">IBIPadFramework</string>
@ -410,7 +389,6 @@
</array>
<string key="NSFrameSize">{1004, 768}</string>
<reference key="NSSuperview"/>
<reference key="NSWindow"/>
<reference key="NSNextKeyView" ref="97794255"/>
<string key="NSReuseIdentifierKey">_NS:212</string>
<object class="NSColor" key="IBUIBackgroundColor">
@ -813,170 +791,7 @@
<nil key="sourceID"/>
<int key="maxID">53</int>
</object>
<object class="IBClassDescriber" key="IBDocument.Classes">
<array class="NSMutableArray" key="referencedPartialClassDescriptions">
<object class="IBPartialClassDescription">
<string key="className">UICamSwitch</string>
<string key="superclassName">UIButton</string>
<object class="NSMutableDictionary" key="outlets">
<string key="NS.key.0">preview</string>
<string key="NS.object.0">UIView</string>
</object>
<object class="NSMutableDictionary" key="toOneOutletInfosByName">
<string key="NS.key.0">preview</string>
<object class="IBToOneOutletInfo" key="NS.object.0">
<string key="name">preview</string>
<string key="candidateClassName">UIView</string>
</object>
</object>
<object class="IBClassDescriptionSource" key="sourceIdentifier">
<string key="majorKey">IBProjectSource</string>
<string key="minorKey">./Classes/UICamSwitch.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/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/UIMuteButton.h</string>
</object>
</object>
<object class="IBPartialClassDescription">
<string key="className">UIToggleButton</string>
<string key="superclassName">UIButton</string>
<object class="IBClassDescriptionSource" key="sourceIdentifier">
<string key="majorKey">IBProjectSource</string>
<string key="minorKey">./Classes/UIToggleButton.h</string>
</object>
</object>
<object class="IBPartialClassDescription">
<string key="className">VideoViewController</string>
<string key="superclassName">UIViewController</string>
<dictionary class="NSMutableDictionary" key="outlets">
<string key="mCallQuality">UIImageView</string>
<string key="mCallQualityLandLeft">UIImageView</string>
<string key="mCallQualityLandRight">UIImageView</string>
<string key="mCamSwitch">UICamSwitch</string>
<string key="mCamSwitchLandLeft">UICamSwitch</string>
<string key="mCamSwitchLandRight">UICamSwitch</string>
<string key="mDisplay">UIView</string>
<string key="mDisplayLandLeft">UIView</string>
<string key="mDisplayLandRight">UIView</string>
<string key="mHangUp">UIHangUpButton</string>
<string key="mHangUpLandLeft">UIHangUpButton</string>
<string key="mHangUpLandRight">UIHangUpButton</string>
<string key="mLandscapeLeft">UIView</string>
<string key="mLandscapeRight">UIView</string>
<string key="mMute">UIMuteButton</string>
<string key="mMuteLandLeft">UIMuteButton</string>
<string key="mMuteLandRight">UIMuteButton</string>
<string key="mPortrait">UIView</string>
<string key="mPreview">UIView</string>
<string key="mPreviewLandLeft">UIView</string>
<string key="mPreviewLandRight">UIView</string>
</dictionary>
<dictionary class="NSMutableDictionary" key="toOneOutletInfosByName">
<object class="IBToOneOutletInfo" key="mCallQuality">
<string key="name">mCallQuality</string>
<string key="candidateClassName">UIImageView</string>
</object>
<object class="IBToOneOutletInfo" key="mCallQualityLandLeft">
<string key="name">mCallQualityLandLeft</string>
<string key="candidateClassName">UIImageView</string>
</object>
<object class="IBToOneOutletInfo" key="mCallQualityLandRight">
<string key="name">mCallQualityLandRight</string>
<string key="candidateClassName">UIImageView</string>
</object>
<object class="IBToOneOutletInfo" key="mCamSwitch">
<string key="name">mCamSwitch</string>
<string key="candidateClassName">UICamSwitch</string>
</object>
<object class="IBToOneOutletInfo" key="mCamSwitchLandLeft">
<string key="name">mCamSwitchLandLeft</string>
<string key="candidateClassName">UICamSwitch</string>
</object>
<object class="IBToOneOutletInfo" key="mCamSwitchLandRight">
<string key="name">mCamSwitchLandRight</string>
<string key="candidateClassName">UICamSwitch</string>
</object>
<object class="IBToOneOutletInfo" key="mDisplay">
<string key="name">mDisplay</string>
<string key="candidateClassName">UIView</string>
</object>
<object class="IBToOneOutletInfo" key="mDisplayLandLeft">
<string key="name">mDisplayLandLeft</string>
<string key="candidateClassName">UIView</string>
</object>
<object class="IBToOneOutletInfo" key="mDisplayLandRight">
<string key="name">mDisplayLandRight</string>
<string key="candidateClassName">UIView</string>
</object>
<object class="IBToOneOutletInfo" key="mHangUp">
<string key="name">mHangUp</string>
<string key="candidateClassName">UIHangUpButton</string>
</object>
<object class="IBToOneOutletInfo" key="mHangUpLandLeft">
<string key="name">mHangUpLandLeft</string>
<string key="candidateClassName">UIHangUpButton</string>
</object>
<object class="IBToOneOutletInfo" key="mHangUpLandRight">
<string key="name">mHangUpLandRight</string>
<string key="candidateClassName">UIHangUpButton</string>
</object>
<object class="IBToOneOutletInfo" key="mLandscapeLeft">
<string key="name">mLandscapeLeft</string>
<string key="candidateClassName">UIView</string>
</object>
<object class="IBToOneOutletInfo" key="mLandscapeRight">
<string key="name">mLandscapeRight</string>
<string key="candidateClassName">UIView</string>
</object>
<object class="IBToOneOutletInfo" key="mMute">
<string key="name">mMute</string>
<string key="candidateClassName">UIMuteButton</string>
</object>
<object class="IBToOneOutletInfo" key="mMuteLandLeft">
<string key="name">mMuteLandLeft</string>
<string key="candidateClassName">UIMuteButton</string>
</object>
<object class="IBToOneOutletInfo" key="mMuteLandRight">
<string key="name">mMuteLandRight</string>
<string key="candidateClassName">UIMuteButton</string>
</object>
<object class="IBToOneOutletInfo" key="mPortrait">
<string key="name">mPortrait</string>
<string key="candidateClassName">UIView</string>
</object>
<object class="IBToOneOutletInfo" key="mPreview">
<string key="name">mPreview</string>
<string key="candidateClassName">UIView</string>
</object>
<object class="IBToOneOutletInfo" key="mPreviewLandLeft">
<string key="name">mPreviewLandLeft</string>
<string key="candidateClassName">UIView</string>
</object>
<object class="IBToOneOutletInfo" key="mPreviewLandRight">
<string key="name">mPreviewLandRight</string>
<string key="candidateClassName">UIView</string>
</object>
</dictionary>
<object class="IBClassDescriptionSource" key="sourceIdentifier">
<string key="majorKey">IBProjectSource</string>
<string key="minorKey">./Classes/VideoViewController.h</string>
</object>
</object>
</array>
</object>
<object class="IBClassDescriber" key="IBDocument.Classes"/>
<int key="IBDocument.localizationMode">0</int>
<string key="IBDocument.TargetRuntimeIdentifier">IBIPadFramework</string>
<bool key="IBDocument.PluginDeclaredDependenciesTrackSystemTargetVersion">YES</bool>

View file

@ -117,8 +117,6 @@
22BB1A69132FF16A005CD7AA /* UIEraseButton.m in Sources */ = {isa = PBXBuildFile; fileRef = 22BB1A68132FF16A005CD7AA /* UIEraseButton.m */; };
22C755601317E59C007BC101 /* UIBluetoothButton.m in Sources */ = {isa = PBXBuildFile; fileRef = 22C7555F1317E59C007BC101 /* UIBluetoothButton.m */; };
22D1B68112A3E0BE001AE361 /* libresolv.dylib in Frameworks */ = {isa = PBXBuildFile; fileRef = 22D1B68012A3E0BE001AE361 /* libresolv.dylib */; };
22D817AD147A9F33001CFB9C /* UIAddVideoButton.m in Sources */ = {isa = PBXBuildFile; fileRef = 22D817AC147A9F33001CFB9C /* UIAddVideoButton.m */; };
22D817AE147A9F33001CFB9C /* UIAddVideoButton.m in Sources */ = {isa = PBXBuildFile; fileRef = 22D817AC147A9F33001CFB9C /* UIAddVideoButton.m */; };
22D8F11F147548E2008C97DB /* linphonerc in Resources */ = {isa = PBXBuildFile; fileRef = 2274550710700509006EC466 /* linphonerc */; };
22D8F120147548E2008C97DB /* PhoneViewController.xib in Resources */ = {isa = PBXBuildFile; fileRef = 22F2508D107141E100AC9B3F /* PhoneViewController.xib */; };
22D8F121147548E2008C97DB /* ringback.wav in Resources */ = {isa = PBXBuildFile; fileRef = 22F254801073D99800AC9B3F /* ringback.wav */; };
@ -218,6 +216,8 @@
288765FD0DF74451002DB57D /* CoreGraphics.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 288765FC0DF74451002DB57D /* CoreGraphics.framework */; };
340751971506459A00B89C47 /* CoreTelephony.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 340751961506459A00B89C47 /* CoreTelephony.framework */; };
34075199150645A300B89C47 /* CoreTelephony.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 340751961506459A00B89C47 /* CoreTelephony.framework */; };
340751E7150F38FD00B89C47 /* UIToggleVideoButton.m in Sources */ = {isa = PBXBuildFile; fileRef = 340751E6150F38FD00B89C47 /* UIToggleVideoButton.m */; };
340751E8150F38FD00B89C47 /* UIToggleVideoButton.m in Sources */ = {isa = PBXBuildFile; fileRef = 340751E6150F38FD00B89C47 /* UIToggleVideoButton.m */; };
340A75B014C0670B006AA708 /* ConferenceCallDetailView-ipad.xib in Resources */ = {isa = PBXBuildFile; fileRef = 340A75AF14C0670A006AA708 /* ConferenceCallDetailView-ipad.xib */; };
340A75B114C0670B006AA708 /* ConferenceCallDetailView-ipad.xib in Resources */ = {isa = PBXBuildFile; fileRef = 340A75AF14C0670A006AA708 /* ConferenceCallDetailView-ipad.xib */; };
3418843714C58BB100EA48C7 /* nowebcamCIF.jpg in Resources */ = {isa = PBXBuildFile; fileRef = 3418843614C58BB100EA48C7 /* nowebcamCIF.jpg */; };
@ -589,8 +589,6 @@
22C7564A13265C6A007BC101 /* x509_vfy.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = x509_vfy.h; sourceTree = "<group>"; };
22C7564B13265C6A007BC101 /* x509v3.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = x509v3.h; sourceTree = "<group>"; };
22D1B68012A3E0BE001AE361 /* libresolv.dylib */ = {isa = PBXFileReference; lastKnownFileType = "compiled.mach-o.dylib"; name = libresolv.dylib; path = usr/lib/libresolv.dylib; sourceTree = SDKROOT; };
22D817AB147A9F33001CFB9C /* UIAddVideoButton.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UIAddVideoButton.h; sourceTree = "<group>"; };
22D817AC147A9F33001CFB9C /* UIAddVideoButton.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UIAddVideoButton.m; sourceTree = "<group>"; };
22D8F187147548E2008C97DB /* linphone-no-gpl-thirdparties.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = "linphone-no-gpl-thirdparties.app"; sourceTree = BUILT_PRODUCTS_DIR; };
22E028B413B4CCBD0068A713 /* VideoViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = VideoViewController.h; sourceTree = "<group>"; };
22E028B513B4CCBD0068A713 /* VideoViewController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = VideoViewController.m; sourceTree = "<group>"; };
@ -614,6 +612,9 @@
29B97316FDCFA39411CA2CEA /* main.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = main.m; sourceTree = "<group>"; };
32CA4F630368D1EE00C91783 /* linphone_Prefix.pch */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = linphone_Prefix.pch; sourceTree = "<group>"; };
340751961506459A00B89C47 /* CoreTelephony.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = CoreTelephony.framework; path = System/Library/Frameworks/CoreTelephony.framework; sourceTree = SDKROOT; };
340751E4150E4D0200B89C47 /* CallDelegate.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CallDelegate.h; sourceTree = "<group>"; };
340751E5150F38FC00B89C47 /* UIToggleVideoButton.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UIToggleVideoButton.h; sourceTree = "<group>"; };
340751E6150F38FD00B89C47 /* UIToggleVideoButton.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UIToggleVideoButton.m; sourceTree = "<group>"; };
340A75AF14C0670A006AA708 /* ConferenceCallDetailView-ipad.xib */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.xib; path = "ConferenceCallDetailView-ipad.xib"; sourceTree = "<group>"; };
3418843614C58BB100EA48C7 /* nowebcamCIF.jpg */ = {isa = PBXFileReference; lastKnownFileType = image.jpeg; name = nowebcamCIF.jpg; path = submodules/linphone/mediastreamer2/src/nowebcamCIF.jpg; sourceTree = "<group>"; };
3418844514C6CAD300EA48C7 /* StatusSubViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = StatusSubViewController.h; sourceTree = "<group>"; };
@ -752,6 +753,7 @@
080E96DDFE201D6D7F000001 /* Classes */ = {
isa = PBXGroup;
children = (
340751E4150E4D0200B89C47 /* CallDelegate.h */,
2211DBBB14769C8200DEE054 /* CallDelegate.m */,
2214EB7012F84668002A5394 /* LinphoneUI */,
2218A92212FBE1340088A667 /* FirstLoginViewController.h */,
@ -1007,6 +1009,8 @@
2214EB7012F84668002A5394 /* LinphoneUI */ = {
isa = PBXGroup;
children = (
340751E5150F38FC00B89C47 /* UIToggleVideoButton.h */,
340751E6150F38FD00B89C47 /* UIToggleVideoButton.m */,
2248E90C12F7E4CF00220D9C /* UIDigitButton.h */,
2248E90D12F7E4CF00220D9C /* UIDigitButton.m */,
2248E99D12F801C200220D9C /* LinphoneManager.h */,
@ -1034,8 +1038,6 @@
223963161393CFAF001DE689 /* FastAddressBook.m */,
22AA8AFF13D83F6300B30535 /* UICamSwitch.h */,
22AA8B0013D83F6300B30535 /* UICamSwitch.m */,
22D817AB147A9F33001CFB9C /* UIAddVideoButton.h */,
22D817AC147A9F33001CFB9C /* UIAddVideoButton.m */,
);
path = LinphoneUI;
sourceTree = "<group>";
@ -1497,10 +1499,10 @@
22AA8B0113D83F6300B30535 /* UICamSwitch.m in Sources */,
2211DBBE14769C8300DEE054 /* CallDelegate.m in Sources */,
2211DBC014769CB200DEE054 /* IncallViewController.m in Sources */,
22D817AD147A9F33001CFB9C /* UIAddVideoButton.m in Sources */,
344ABD77147FCB68007420B6 /* ConferenceCallDetailView.m in Sources */,
34CA8539148F692A00503C01 /* MainScreenWithVideoPreview.m in Sources */,
3418844814C6CAD300EA48C7 /* StatusSubViewController.m in Sources */,
340751E7150F38FD00B89C47 /* UIToggleVideoButton.m in Sources */,
);
runOnlyForDeploymentPostprocessing = 0;
};
@ -1532,10 +1534,10 @@
22D8F159147548E2008C97DB /* UICamSwitch.m in Sources */,
2211DBBF14769C8300DEE054 /* CallDelegate.m in Sources */,
2211DBC114769CB300DEE054 /* IncallViewController.m in Sources */,
22D817AE147A9F33001CFB9C /* UIAddVideoButton.m in Sources */,
344ABD78147FCB68007420B6 /* ConferenceCallDetailView.m in Sources */,
34CA853A148F692A00503C01 /* MainScreenWithVideoPreview.m in Sources */,
3418844914C6CAD300EA48C7 /* StatusSubViewController.m in Sources */,
340751E8150F38FD00B89C47 /* UIToggleVideoButton.m in Sources */,
);
runOnlyForDeploymentPostprocessing = 0;
};
@ -1574,7 +1576,7 @@
HAVE_SILK,
);
GCC_THUMB_SUPPORT = NO;
GCC_VERSION = com.apple.compilers.llvm.clang.1_0;
GCC_VERSION = com.apple.compilers.llvmgcc42;
HEADER_SEARCH_PATHS = (
submodules/linphone/coreapi,
submodules/linphone/mediastreamer2/include,
@ -1640,7 +1642,7 @@
HAVE_SILK,
);
GCC_THUMB_SUPPORT = NO;
GCC_VERSION = com.apple.compilers.llvm.clang.1_0;
GCC_VERSION = com.apple.compilers.llvmgcc42;
HEADER_SEARCH_PATHS = (
submodules/linphone/coreapi,
submodules/linphone/mediastreamer2/include,
@ -1916,7 +1918,7 @@
HAVE_SILK,
);
GCC_THUMB_SUPPORT = NO;
GCC_VERSION = com.apple.compilers.llvm.clang.1_0;
GCC_VERSION = com.apple.compilers.llvmgcc42;
HEADER_SEARCH_PATHS = (
submodules/linphone/coreapi,
submodules/linphone/mediastreamer2/include,
@ -1983,7 +1985,7 @@
HAVE_SILK,
);
GCC_THUMB_SUPPORT = NO;
GCC_VERSION = com.apple.compilers.llvm.clang.1_0;
GCC_VERSION = com.apple.compilers.llvmgcc42;
HEADER_SEARCH_PATHS = (
submodules/linphone/coreapi,
submodules/linphone/mediastreamer2/include,

@ -1 +1 @@
Subproject commit b3e55a3c93b39af43666acec45191b41f2016fa0
Subproject commit 8483ca292c10e4bca3331040dd9babf8431d0393

@ -1 +1 @@
Subproject commit 4006baf2895166f78b8fe4c2721fa77656607988
Subproject commit 86cb50783bf6923fc812219066d4aefd656ee80a