forked from mirrors/linphone-iphone
dialer: hide pad on iphone landscape
This commit is contained in:
parent
7513b95494
commit
a62aaee025
3 changed files with 14 additions and 3 deletions
|
|
@ -1,5 +1,5 @@
|
|||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<document type="com.apple.InterfaceBuilder3.CocoaTouch.XIB" version="3.0" toolsVersion="9531" systemVersion="15B42" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none">
|
||||
<document type="com.apple.InterfaceBuilder3.CocoaTouch.XIB" version="3.0" toolsVersion="9531" systemVersion="15C50" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none">
|
||||
<dependencies>
|
||||
<deployment identifier="iOS"/>
|
||||
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="9529"/>
|
||||
|
|
@ -20,6 +20,7 @@
|
|||
<outlet property="landscapeView" destination="171" id="mdM-t5-k4V"/>
|
||||
<outlet property="nineButton" destination="36" id="200"/>
|
||||
<outlet property="oneButton" destination="38" id="191"/>
|
||||
<outlet property="padView" destination="180" id="bxG-9v-Pvj"/>
|
||||
<outlet property="portraitView" destination="171" id="GLX-cG-iOA"/>
|
||||
<outlet property="sevenButton" destination="34" id="197"/>
|
||||
<outlet property="sixButton" destination="33" id="196"/>
|
||||
|
|
@ -74,6 +75,10 @@
|
|||
</button>
|
||||
</subviews>
|
||||
</view>
|
||||
<imageView userInteractionEnabled="NO" tag="2" contentMode="scaleAspectFit" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="dialer_background.png" id="AH0-S5-0Ku" userLabel="logoImage">
|
||||
<rect key="frame" x="100" y="279" width="340" height="294"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMinX="YES" widthSizable="YES" flexibleMaxX="YES" flexibleMinY="YES" heightSizable="YES" flexibleMaxY="YES"/>
|
||||
</imageView>
|
||||
<view contentMode="scaleToFill" id="180" userLabel="pad">
|
||||
<rect key="frame" x="0.0" y="66" width="540" height="720"/>
|
||||
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
|
||||
|
|
@ -236,7 +241,7 @@
|
|||
</connections>
|
||||
</button>
|
||||
</subviews>
|
||||
<color key="backgroundColor" white="0.0" alpha="0.0" colorSpace="calibratedWhite"/>
|
||||
<color key="backgroundColor" white="1" alpha="1" colorSpace="calibratedWhite"/>
|
||||
</view>
|
||||
<view contentMode="scaleToFill" id="182" userLabel="bottomBar">
|
||||
<rect key="frame" x="0.0" y="786" width="540" height="66"/>
|
||||
|
|
@ -321,7 +326,7 @@
|
|||
</subviews>
|
||||
<color key="backgroundColor" red="1" green="1" blue="0.0" alpha="1" colorSpace="calibratedRGB"/>
|
||||
<freeformSimulatedSizeMetrics key="simulatedDestinationMetrics"/>
|
||||
<point key="canvasLocation" x="-67.5" y="223.5"/>
|
||||
<point key="canvasLocation" x="-68" y="223"/>
|
||||
</view>
|
||||
</objects>
|
||||
<resources>
|
||||
|
|
@ -342,6 +347,7 @@
|
|||
<image name="color_L.png" width="2" height="2"/>
|
||||
<image name="contact_add_default.png" width="34" height="29"/>
|
||||
<image name="contact_add_disabled.png" width="34" height="29"/>
|
||||
<image name="dialer_background.png" width="408" height="350"/>
|
||||
<image name="numpad_0_default.png" width="52" height="48"/>
|
||||
<image name="numpad_0_over.png" width="52" height="48"/>
|
||||
<image name="numpad_1_default.png" width="52" height="48"/>
|
||||
|
|
|
|||
|
|
@ -59,6 +59,7 @@
|
|||
@property(nonatomic, strong) IBOutlet UIView *backgroundView;
|
||||
@property(nonatomic, strong) IBOutlet UIView *videoPreview;
|
||||
@property(nonatomic, strong) IBOutlet UICamSwitch *videoCameraSwitch;
|
||||
@property(weak, nonatomic) IBOutlet UIView *padView;
|
||||
|
||||
- (IBAction)onAddContactClick:(id)event;
|
||||
- (IBAction)onBackClick:(id)event;
|
||||
|
|
|
|||
|
|
@ -94,6 +94,9 @@ static UICompositeViewDescription *compositeDescription = nil;
|
|||
- (void)viewWillAppear:(BOOL)animated {
|
||||
[super viewWillAppear:animated];
|
||||
|
||||
_padView.hidden =
|
||||
!IPAD && UIInterfaceOrientationIsLandscape(PhoneMainView.instance.mainViewController.currentOrientation);
|
||||
|
||||
// Set observer
|
||||
[[NSNotificationCenter defaultCenter] addObserver:self
|
||||
selector:@selector(callUpdateEvent:)
|
||||
|
|
@ -206,6 +209,7 @@ static UICompositeViewDescription *compositeDescription = nil;
|
|||
CGRect frame = self.view.frame;
|
||||
frame.origin = CGPointMake(0, 0);
|
||||
videoPreview.frame = frame;
|
||||
_padView.hidden = !IPAD && UIInterfaceOrientationIsLandscape(toInterfaceOrientation);
|
||||
}
|
||||
|
||||
#pragma mark - Event Functions
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue