Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit 22f664e

Browse files
适配iOS9 & 去除warning
1 parent 52aeb6a commit 22f664e

File tree

4 files changed

+25
-16
lines changed

4 files changed

+25
-16
lines changed

‎Coding_iOS.xcodeproj/project.pbxproj

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5723,7 +5723,6 @@
57235723
IPHONEOS_DEPLOYMENT_TARGET = 7.0;
57245724
LIBRARY_SEARCH_PATHS = (
57255725
"$(inherited)",
5726-
"$(PROJECT_DIR)/Coding_iOS/Vendor/UMENG",
57275726
"$(PROJECT_DIR)/Coding_iOS/Vendor/XGPush",
57285727
"$(PROJECT_DIR)/Coding_iOS/Util/Audio/opencore-amr-iOS/lib",
57295728
"$(PROJECT_DIR)/Coding_iOS/Vendor/UMSocial_Sdk_4.2.3_Extra/SinaSSO",
@@ -5759,7 +5758,6 @@
57595758
IPHONEOS_DEPLOYMENT_TARGET = 7.0;
57605759
LIBRARY_SEARCH_PATHS = (
57615760
"$(inherited)",
5762-
"$(PROJECT_DIR)/Coding_iOS/Vendor/UMENG",
57635761
"$(PROJECT_DIR)/Coding_iOS/Vendor/XGPush",
57645762
"$(PROJECT_DIR)/Coding_iOS/Util/Audio/opencore-amr-iOS/lib",
57655763
"$(PROJECT_DIR)/Coding_iOS/Vendor/UMSocial_Sdk_4.2.3_Extra/SinaSSO",

‎Coding_iOS/Controllers/FileInfoViewController.xib

Lines changed: 17 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -61,50 +61,56 @@
6161
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" fixedFrame="YES" text="#---" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="jSi-NE-6eW">
6262
<rect key="frame" x="121" y="74" width="386" height="30"/>
6363
<fontDescription key="fontDescription" type="system" pointSize="16"/>
64-
<color key="textColor" cocoaTouchSystemColor="darkTextColor"/>
64+
<color key="textColor" red="0.0"green="0.0"blue="0.0"alpha="1"colorSpace="calibratedRGB"/>
6565
<nil key="highlightedColor"/>
6666
</label>
6767
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" fixedFrame="YES" text="jpg" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="GhD-mi-tyt">
6868
<rect key="frame" x="121" y="112" width="386" height="30"/>
6969
<fontDescription key="fontDescription" type="system" pointSize="16"/>
70-
<color key="textColor" cocoaTouchSystemColor="darkTextColor"/>
70+
<color key="textColor" red="0.0"green="0.0"blue="0.0"alpha="1"colorSpace="calibratedRGB"/>
7171
<nil key="highlightedColor"/>
7272
</label>
7373
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" fixedFrame="YES" text="220kb" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="eRh-b3-AeR">
7474
<rect key="frame" x="121" y="150" width="386" height="30"/>
7575
<fontDescription key="fontDescription" type="system" pointSize="16"/>
76-
<color key="textColor" cocoaTouchSystemColor="darkTextColor"/>
76+
<color key="textColor" red="0.0"green="0.0"blue="0.0"alpha="1"colorSpace="calibratedRGB"/>
7777
<nil key="highlightedColor"/>
7878
</label>
7979
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" fixedFrame="YES" text="2天前" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="eHY-HS-HDd">
8080
<rect key="frame" x="121" y="188" width="386" height="30"/>
8181
<fontDescription key="fontDescription" type="system" pointSize="16"/>
82-
<color key="textColor" cocoaTouchSystemColor="darkTextColor"/>
82+
<color key="textColor" red="0.0"green="0.0"blue="0.0"alpha="1"colorSpace="calibratedRGB"/>
8383
<nil key="highlightedColor"/>
8484
</label>
8585
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" fixedFrame="YES" text="刚刚" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="OAi-e6-fQP">
8686
<rect key="frame" x="121" y="226" width="386" height="30"/>
8787
<fontDescription key="fontDescription" type="system" pointSize="16"/>
88-
<color key="textColor" cocoaTouchSystemColor="darkTextColor"/>
88+
<color key="textColor" red="0.0"green="0.0"blue="0.0"alpha="1"colorSpace="calibratedRGB"/>
8989
<nil key="highlightedColor"/>
9090
</label>
9191
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" fixedFrame="YES" text="蝈蝈尹" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="b8U-cR-IzQ">
9292
<rect key="frame" x="121" y="264" width="386" height="30"/>
9393
<fontDescription key="fontDescription" type="system" pointSize="16"/>
94-
<color key="textColor" cocoaTouchSystemColor="darkTextColor"/>
94+
<color key="textColor" red="0.0"green="0.0"blue="0.0"alpha="1"colorSpace="calibratedRGB"/>
9595
<nil key="highlightedColor"/>
9696
</label>
97-
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" ambiguous="YES" misplaced="YES" text="文件名" lineBreakMode="tailTruncation" numberOfLines="0" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="zTd-Te-h0y">
98-
<rect key="frame" x="15" y="15" width="577" height="51"/>
97+
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="文件名" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="zTd-Te-h0y">
98+
<rect key="frame" x="15" y="15" width="570" height="51"/>
99+
<constraints>
100+
<constraint firstAttribute="height" constant="51" id="lEU-Bw-C3f"/>
101+
</constraints>
99102
<fontDescription key="fontDescription" type="system" pointSize="17"/>
100-
<color key="textColor" cocoaTouchSystemColor="darkTextColor"/>
103+
<color key="textColor" red="0.0"green="0.0"blue="0.0"alpha="1"colorSpace="calibratedRGB"/>
101104
<nil key="highlightedColor"/>
102105
</label>
103106
</subviews>
104107
<constraints>
105-
<constraint firstAttribute="trailing" secondItem="zTd-Te-h0y" secondAttribute="trailing" constant="15" id="wpQ-1P-lVb"/>
108+
<constraint firstItem="zTd-Te-h0y" firstAttribute="leading" secondItem="tJa-fj-hGZ" secondAttribute="leading" constant="15" id="5Cb-RJ-pDF"/>
109+
<constraint firstItem="zTd-Te-h0y" firstAttribute="top" secondItem="tJa-fj-hGZ" secondAttribute="top" constant="15" id="EaT-BW-Vud"/>
110+
<constraint firstAttribute="trailing" secondItem="zTd-Te-h0y" secondAttribute="trailing" constant="15" id="YA6-nz-7yL"/>
106111
</constraints>
107-
<point key="canvasLocation" x="264" y="652"/>
112+
<freeformSimulatedSizeMetrics key="simulatedDestinationMetrics"/>
113+
<point key="canvasLocation" x="307" y="491"/>
108114
</view>
109115
</objects>
110116
</document>

‎Coding_iOS/Controllers/RootControllers/BaseNavigationController.m

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,14 +12,19 @@ @implementation BaseNavigationController
1212

1313
- (BOOL)shouldAutorotate{
1414
return [self.visibleViewController shouldAutorotate];
15+
1516
}
1617

1718
- (UIInterfaceOrientation)preferredInterfaceOrientationForPresentation{
1819
return [self.visibleViewController preferredInterfaceOrientationForPresentation];
1920
}
2021

2122
- (UIInterfaceOrientationMask)supportedInterfaceOrientations {
22-
return [self.visibleViewController supportedInterfaceOrientations];
23+
if (![self.visibleViewController isKindOfClass:[UIAlertController class]]) {//iOS9 UIWebRotatingAlertController
24+
return [self.visibleViewController supportedInterfaceOrientations];
25+
}else{
26+
return UIInterfaceOrientationMaskPortrait;
27+
}
2328
}
2429

2530
@end

‎Coding_iOS/Util/Audio/amrFileCodec.m

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -142,7 +142,7 @@ int caclAMRFrameSize(unsigned char frameHeader)
142142
int ReadAMRFrameFirstData(char* fpamr,int pos, NSInteger maxLen, unsigned char frameBuffer[], int* stdFrameSize, unsigned char* stdFrameHeader)
143143
{
144144
int nPos = 0;
145-
memset(frameBuffer, 0, sizeof(frameBuffer));
145+
memset(frameBuffer, 0, sizeof(char *));
146146

147147
// 先读帧头
148148
//fread(stdFrameHeader, 1, sizeof(unsigned char), fpamr);
@@ -178,7 +178,7 @@ int ReadAMRFrameData(char* fpamr,int pos,NSInteger maxLen, unsigned char frameBu
178178
int nPos = 0;
179179
unsigned char frameHeader; // 帧头
180180

181-
memset(frameBuffer, 0, sizeof(frameBuffer));
181+
memset(frameBuffer, 0, sizeof(char *));
182182

183183
// 读帧头
184184
// 如果是坏帧(不是标准帧头),则继续读下一个字节,直到读到标准帧头

0 commit comments

Comments
(0)

AltStyle によって変換されたページ (->オリジナル) /