Sfoglia il codice sorgente

1.修改iOS Apex Driver Message标记颜色和大小。

Pen Li 7 anni fa
parent
commit
f5ab629956

+ 9 - 9
Redant Drivers/Apex And Drivers/Home/HomeHeader.xib

@@ -168,20 +168,19 @@
                                         <action selector="messageBtnClick:" destination="CmN-WL-UzN" eventType="touchUpInside" id="rtb-6D-QVQ"/>
                                     </connections>
                                 </button>
-                                <view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="3ey-sT-bNa">
-                                    <rect key="frame" x="88.5" y="13" width="15" height="15"/>
-                                    <color key="backgroundColor" red="1" green="0.1047433005" blue="0.075207091899999995" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
+                                <imageView userInteractionEnabled="NO" contentMode="scaleAspectFit" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="backend_flag" translatesAutoresizingMaskIntoConstraints="NO" id="IZH-5n-rpN">
+                                    <rect key="frame" x="84.5" y="12" width="20" height="20"/>
                                     <constraints>
-                                        <constraint firstAttribute="width" constant="15" id="Kg6-vG-bOI"/>
-                                        <constraint firstAttribute="height" constant="15" id="flS-ZQ-lyo"/>
+                                        <constraint firstAttribute="width" constant="20" id="ceg-Jf-F0k"/>
+                                        <constraint firstAttribute="height" constant="20" id="lA0-2I-3ZD"/>
                                     </constraints>
-                                </view>
+                                </imageView>
                             </subviews>
                             <constraints>
-                                <constraint firstItem="3ey-sT-bNa" firstAttribute="top" secondItem="g4U-M8-oMo" secondAttribute="top" constant="-6" id="7Mp-e3-81a"/>
                                 <constraint firstItem="g4U-M8-oMo" firstAttribute="centerX" secondItem="iQb-jc-IpW" secondAttribute="centerX" id="Hcz-d3-Oxr"/>
+                                <constraint firstItem="IZH-5n-rpN" firstAttribute="top" secondItem="g4U-M8-oMo" secondAttribute="top" constant="-7" id="RPQ-Bh-DpH"/>
                                 <constraint firstItem="T2T-ct-zc2" firstAttribute="centerX" secondItem="iQb-jc-IpW" secondAttribute="centerX" id="Rm8-84-grW"/>
-                                <constraint firstItem="3ey-sT-bNa" firstAttribute="trailing" secondItem="g4U-M8-oMo" secondAttribute="trailing" constant="6" id="cEc-xq-GuF"/>
+                                <constraint firstItem="IZH-5n-rpN" firstAttribute="trailing" secondItem="g4U-M8-oMo" secondAttribute="trailing" constant="7" id="W1D-Uw-1xT"/>
                             </constraints>
                         </view>
                     </subviews>
@@ -364,7 +363,7 @@
                 <outlet property="availableTitleLabel" destination="Hae-rx-iyX" id="Mlr-72-rTe"/>
                 <outlet property="backgroundView" destination="q6Y-ok-z0V" id="O1Q-PB-BO0"/>
                 <outlet property="messageBtn" destination="g4U-M8-oMo" id="s8m-Kt-9Rw"/>
-                <outlet property="messageNewFlagView" destination="3ey-sT-bNa" id="6bv-0h-I3W"/>
+                <outlet property="messageNewFlagView" destination="IZH-5n-rpN" id="T99-W6-rlo"/>
                 <outlet property="settingBtn" destination="vJn-m4-oEg" id="rqD-th-mZy"/>
                 <outlet property="signoutBtn" destination="DoZ-Kc-GDv" id="gj7-9F-yXR"/>
             </connections>
@@ -377,5 +376,6 @@
         <image name="action_setting" width="40" height="40"/>
         <image name="action_signout" width="40" height="40"/>
         <image name="action_unavailable" width="40" height="40"/>
+        <image name="backend_flag" width="20" height="20"/>
     </resources>
 </document>

+ 1 - 7
Redant Drivers/Apex And Drivers/Home/RAHomeHeaderView.m

@@ -27,7 +27,7 @@
 
 @property (nonatomic,strong) IBOutlet UIButton *messageBtn;
 
-@property (nonatomic,strong) IBOutlet UIView *messageNewFlagView;
+@property (nonatomic,strong) IBOutlet UIImageView *messageNewFlagView;
 
 @end
 
@@ -40,15 +40,9 @@
 - (void)awakeFromNib {
     [super awakeFromNib];
     
-    self.messageNewFlagView.backgroundColor = ApexDriverRedColor;
-    self.messageNewFlagView.layer.cornerRadius = 7.5f;
-    self.messageNewFlagView.layer.masksToBounds = YES;
-    
     self.NewOrderCount = self.ProcessingOrderCount = self.FinishOrderCount = 0;
     self.availabel = self.existNewMessage = NO;
     
-//    self.backgroundView.backgroundColor = ApexDriverOrangeColor;
-    
     _gradientLayer = [CAGradientLayer layer];
     
     UIColor *orangeWhiteColor =  ApexDriverOrangeWhiteColor;

+ 1 - 0
Redant Drivers/Apex And Drivers/Home/RAHomeSectionHeaderView.m

@@ -35,6 +35,7 @@ const int TagBase = 6000;
     self.backgroundView.layer.masksToBounds = YES;
     self.backgroundView.backgroundColor = ApexDriverGrayColor;
     self.titleLaebl.textColor = ApexDriverWhiteColor;
+    self.badgeView.backgroundColor = ApexDriverRedColor;
     [self.moreBtn setTitleColor:ApexDriverOrangeColor forState:UIControlStateNormal];
 }