Merge pull request #59 from Jauzee/fix/titleViewPosition
Fix titleView position
This commit is contained in:
@@ -1,7 +1,10 @@
|
||||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<document type="com.apple.InterfaceBuilder3.CocoaTouch.Storyboard.XIB" version="3.0" toolsVersion="11201" systemVersion="15G1004" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" colorMatched="YES" initialViewController="L1n-Ia-Jrw">
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<document type="com.apple.InterfaceBuilder3.CocoaTouch.Storyboard.XIB" version="3.0" toolsVersion="12120" systemVersion="16F73" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" colorMatched="YES" initialViewController="L1n-Ia-Jrw">
|
||||
<device id="retina4_7" orientation="portrait">
|
||||
<adaptation id="fullscreen"/>
|
||||
</device>
|
||||
<dependencies>
|
||||
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="11161"/>
|
||||
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="12088"/>
|
||||
<capability name="Constraints to layout margins" minToolsVersion="6.0"/>
|
||||
<capability name="documents saved in the Xcode 8 format" minToolsVersion="8.0"/>
|
||||
</dependencies>
|
||||
@@ -18,8 +21,11 @@
|
||||
<rect key="frame" x="0.0" y="0.0" width="375" height="667"/>
|
||||
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
|
||||
<subviews>
|
||||
<imageView userInteractionEnabled="NO" contentMode="scaleToFill" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="BackgroundImage" translatesAutoresizingMaskIntoConstraints="NO" id="o88-Ae-QCA"/>
|
||||
<imageView userInteractionEnabled="NO" contentMode="scaleToFill" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="BackgroundImage" translatesAutoresizingMaskIntoConstraints="NO" id="o88-Ae-QCA">
|
||||
<rect key="frame" x="0.0" y="0.0" width="375" height="667"/>
|
||||
</imageView>
|
||||
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="1/15" textAlignment="center" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="Irl-Rb-fcB">
|
||||
<rect key="frame" x="172" y="626.5" width="31" height="20.5"/>
|
||||
<fontDescription key="fontDescription" type="system" pointSize="17"/>
|
||||
<color key="textColor" red="0.85882352941176465" green="0.8666666666666667" blue="0.87058823529411766" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<nil key="highlightedColor"/>
|
||||
@@ -39,10 +45,11 @@
|
||||
<nil key="title"/>
|
||||
<barButtonItem key="leftBarButtonItem" image="searchIcon" id="xuF-jX-6LN"/>
|
||||
<view key="titleView" contentMode="scaleToFill" id="U0J-H7-fvX">
|
||||
<rect key="frame" x="68" y="6" width="240" height="33"/>
|
||||
<rect key="frame" x="67.5" y="5.5" width="240" height="33"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
<subviews>
|
||||
<imageView userInteractionEnabled="NO" contentMode="scaleToFill" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="Title" translatesAutoresizingMaskIntoConstraints="NO" id="92b-RV-q6w">
|
||||
<rect key="frame" x="94.5" y="8.5" width="51" height="16"/>
|
||||
<constraints>
|
||||
<constraint firstAttribute="width" constant="51" id="E8y-UB-H4U"/>
|
||||
<constraint firstAttribute="height" constant="16" id="FBz-Jg-2za"/>
|
||||
@@ -67,6 +74,8 @@
|
||||
</navigationItem>
|
||||
<connections>
|
||||
<outlet property="pageLabel" destination="Irl-Rb-fcB" id="oUZ-x9-PkD"/>
|
||||
<outlet property="titleImageView" destination="92b-RV-q6w" id="3lS-Ot-c9A"/>
|
||||
<outlet property="titleImageViewXConstraint" destination="kLZ-Jr-wTP" id="cFl-I4-nzg"/>
|
||||
<segue destination="7RW-i0-HfN" kind="show" identifier="NoName" id="enc-PY-spo"/>
|
||||
</connections>
|
||||
</viewController>
|
||||
@@ -108,17 +117,21 @@
|
||||
<rect key="frame" x="0.0" y="0.0" width="375" height="124"/>
|
||||
<autoresizingMask key="autoresizingMask"/>
|
||||
<tableViewCellContentView key="contentView" opaque="NO" clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="center" tableViewCell="SFA-X2-Rbf" id="RQr-Ti-ps0">
|
||||
<frame key="frameInset" width="375" height="124"/>
|
||||
<rect key="frame" x="0.0" y="0.0" width="375" height="124"/>
|
||||
<autoresizingMask key="autoresizingMask"/>
|
||||
<subviews>
|
||||
<imageView userInteractionEnabled="NO" contentMode="scaleToFill" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="map" translatesAutoresizingMaskIntoConstraints="NO" id="MOR-g7-Roh"/>
|
||||
<imageView userInteractionEnabled="NO" contentMode="scaleToFill" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="map" translatesAutoresizingMaskIntoConstraints="NO" id="MOR-g7-Roh">
|
||||
<rect key="frame" x="0.0" y="0.0" width="375" height="124"/>
|
||||
</imageView>
|
||||
<imageView userInteractionEnabled="NO" contentMode="scaleToFill" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="stars" translatesAutoresizingMaskIntoConstraints="NO" id="u4E-kh-oBd">
|
||||
<rect key="frame" x="40" y="92" width="77" height="12"/>
|
||||
<constraints>
|
||||
<constraint firstAttribute="width" constant="77" id="fcy-Ae-Cqj"/>
|
||||
<constraint firstAttribute="height" constant="12" id="r69-to-MYP"/>
|
||||
</constraints>
|
||||
</imageView>
|
||||
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="La Crescenta-Montrose, CA91020 Glendale
NO. 7911847" lineBreakMode="tailTruncation" numberOfLines="0" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="Xh7-la-W1r">
|
||||
<rect key="frame" x="40" y="49" width="327" height="26.5"/>
|
||||
<fontDescription key="fontDescription" type="system" pointSize="11"/>
|
||||
<color key="textColor" red="0.49803921568627452" green="0.51764705882352935" blue="0.53725490196078429" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<nil key="highlightedColor"/>
|
||||
@@ -141,27 +154,33 @@
|
||||
<rect key="frame" x="0.0" y="124" width="375" height="124"/>
|
||||
<autoresizingMask key="autoresizingMask"/>
|
||||
<tableViewCellContentView key="contentView" opaque="NO" clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="center" tableViewCell="ew1-hI-ark" id="tMC-aw-BE2">
|
||||
<frame key="frameInset" width="375" height="124"/>
|
||||
<rect key="frame" x="0.0" y="0.0" width="375" height="124"/>
|
||||
<autoresizingMask key="autoresizingMask"/>
|
||||
<subviews>
|
||||
<imageView userInteractionEnabled="NO" contentMode="scaleAspectFit" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="face2" translatesAutoresizingMaskIntoConstraints="NO" id="9zL-0u-FrF">
|
||||
<rect key="frame" x="40" y="20" width="40" height="40"/>
|
||||
<constraints>
|
||||
<constraint firstAttribute="width" constant="40" id="78B-o8-UlD"/>
|
||||
<constraint firstAttribute="height" constant="40" id="b9d-Vi-STe"/>
|
||||
</constraints>
|
||||
</imageView>
|
||||
<imageView userInteractionEnabled="NO" contentMode="scaleToFill" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="heand" translatesAutoresizingMaskIntoConstraints="NO" id="Nk4-8x-Lwg"/>
|
||||
<imageView userInteractionEnabled="NO" contentMode="scaleToFill" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="heand" translatesAutoresizingMaskIntoConstraints="NO" id="Nk4-8x-Lwg">
|
||||
<rect key="frame" x="299" y="33.5" width="14" height="13"/>
|
||||
</imageView>
|
||||
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="Peter Allan" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="KVC-Pp-S9H">
|
||||
<rect key="frame" x="108" y="31" width="74" height="18"/>
|
||||
<fontDescription key="fontDescription" type="system" pointSize="15"/>
|
||||
<color key="textColor" red="0.41960784313725491" green="0.41960784313725491" blue="0.41960784313725491" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<nil key="highlightedColor"/>
|
||||
</label>
|
||||
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="FEB 14th" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="UAK-of-lpJ">
|
||||
<rect key="frame" x="219" y="34" width="43" height="12"/>
|
||||
<fontDescription key="fontDescription" type="system" pointSize="10"/>
|
||||
<color key="textColor" red="0.76470588235294112" green="0.76470588235294112" blue="0.76470588235294112" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<nil key="highlightedColor"/>
|
||||
</label>
|
||||
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" textAlignment="natural" lineBreakMode="tailTruncation" numberOfLines="3" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="2zo-A7-sbM">
|
||||
<rect key="frame" x="40" y="57" width="273" height="59"/>
|
||||
<constraints>
|
||||
<constraint firstAttribute="height" constant="59" id="zel-Yy-v9k"/>
|
||||
</constraints>
|
||||
@@ -190,27 +209,33 @@
|
||||
<rect key="frame" x="0.0" y="248" width="375" height="124"/>
|
||||
<autoresizingMask key="autoresizingMask"/>
|
||||
<tableViewCellContentView key="contentView" opaque="NO" clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="center" tableViewCell="0ee-7A-I2I" id="jPx-eH-c2S">
|
||||
<frame key="frameInset" width="375" height="124"/>
|
||||
<rect key="frame" x="0.0" y="0.0" width="375" height="124"/>
|
||||
<autoresizingMask key="autoresizingMask"/>
|
||||
<subviews>
|
||||
<imageView userInteractionEnabled="NO" contentMode="scaleAspectFit" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="face1" translatesAutoresizingMaskIntoConstraints="NO" id="T8j-gX-HQZ">
|
||||
<rect key="frame" x="40" y="20" width="40" height="40"/>
|
||||
<constraints>
|
||||
<constraint firstAttribute="height" constant="40" id="AKq-2T-BRC"/>
|
||||
<constraint firstAttribute="width" constant="40" id="lAw-yT-R7T"/>
|
||||
</constraints>
|
||||
</imageView>
|
||||
<imageView userInteractionEnabled="NO" contentMode="scaleToFill" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="heand" translatesAutoresizingMaskIntoConstraints="NO" id="szO-5V-CyH"/>
|
||||
<imageView userInteractionEnabled="NO" contentMode="scaleToFill" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="heand" translatesAutoresizingMaskIntoConstraints="NO" id="szO-5V-CyH">
|
||||
<rect key="frame" x="299" y="33.5" width="14" height="13"/>
|
||||
</imageView>
|
||||
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="Amada Iin" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="UEu-Ap-Kms">
|
||||
<rect key="frame" x="108" y="31" width="68" height="18"/>
|
||||
<fontDescription key="fontDescription" type="system" pointSize="15"/>
|
||||
<color key="textColor" red="0.41960784309999999" green="0.41960784309999999" blue="0.41960784309999999" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<nil key="highlightedColor"/>
|
||||
</label>
|
||||
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="FEB 14th" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="7hI-Qw-bUn">
|
||||
<rect key="frame" x="213" y="34" width="43" height="12"/>
|
||||
<fontDescription key="fontDescription" type="system" pointSize="10"/>
|
||||
<color key="textColor" red="0.76470588240000004" green="0.76470588240000004" blue="0.76470588240000004" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<nil key="highlightedColor"/>
|
||||
</label>
|
||||
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" textAlignment="natural" lineBreakMode="tailTruncation" numberOfLines="3" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="rkV-jC-tTs">
|
||||
<rect key="frame" x="40" y="57" width="273" height="59"/>
|
||||
<constraints>
|
||||
<constraint firstAttribute="height" constant="59" id="pYw-qC-eUH"/>
|
||||
</constraints>
|
||||
@@ -239,27 +264,33 @@
|
||||
<rect key="frame" x="0.0" y="372" width="375" height="124"/>
|
||||
<autoresizingMask key="autoresizingMask"/>
|
||||
<tableViewCellContentView key="contentView" opaque="NO" clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="center" tableViewCell="fTH-KP-Ac5" id="BGd-Mp-TnE">
|
||||
<frame key="frameInset" width="375" height="124"/>
|
||||
<rect key="frame" x="0.0" y="0.0" width="375" height="124"/>
|
||||
<autoresizingMask key="autoresizingMask"/>
|
||||
<subviews>
|
||||
<imageView userInteractionEnabled="NO" contentMode="scaleAspectFit" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="face2" translatesAutoresizingMaskIntoConstraints="NO" id="l6O-iU-Deh">
|
||||
<rect key="frame" x="40" y="20" width="40" height="40"/>
|
||||
<constraints>
|
||||
<constraint firstAttribute="height" constant="40" id="Wvu-NC-dmu"/>
|
||||
<constraint firstAttribute="width" constant="40" id="goR-UO-N7g"/>
|
||||
</constraints>
|
||||
</imageView>
|
||||
<imageView userInteractionEnabled="NO" contentMode="scaleToFill" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="heand" translatesAutoresizingMaskIntoConstraints="NO" id="ceS-Mg-PrP"/>
|
||||
<imageView userInteractionEnabled="NO" contentMode="scaleToFill" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="heand" translatesAutoresizingMaskIntoConstraints="NO" id="ceS-Mg-PrP">
|
||||
<rect key="frame" x="299" y="33.5" width="14" height="13"/>
|
||||
</imageView>
|
||||
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="Peter Allan" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="a3U-of-sdv">
|
||||
<rect key="frame" x="108" y="31" width="74" height="18"/>
|
||||
<fontDescription key="fontDescription" type="system" pointSize="15"/>
|
||||
<color key="textColor" red="0.41960784309999999" green="0.41960784309999999" blue="0.41960784309999999" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<nil key="highlightedColor"/>
|
||||
</label>
|
||||
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="FEB 14th" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="h3x-N2-MWJ">
|
||||
<rect key="frame" x="219" y="34" width="43" height="12"/>
|
||||
<fontDescription key="fontDescription" type="system" pointSize="10"/>
|
||||
<color key="textColor" red="0.76470588240000004" green="0.76470588240000004" blue="0.76470588240000004" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<nil key="highlightedColor"/>
|
||||
</label>
|
||||
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" textAlignment="natural" lineBreakMode="tailTruncation" numberOfLines="3" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="3ZN-4l-hGa">
|
||||
<rect key="frame" x="40" y="57" width="273" height="59"/>
|
||||
<constraints>
|
||||
<constraint firstAttribute="height" constant="59" id="z9M-6w-uYi"/>
|
||||
</constraints>
|
||||
@@ -288,27 +319,33 @@
|
||||
<rect key="frame" x="0.0" y="496" width="375" height="124"/>
|
||||
<autoresizingMask key="autoresizingMask"/>
|
||||
<tableViewCellContentView key="contentView" opaque="NO" clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="center" tableViewCell="irZ-0L-X9r" id="t3x-Eb-ktg">
|
||||
<frame key="frameInset" width="375" height="124"/>
|
||||
<rect key="frame" x="0.0" y="0.0" width="375" height="124"/>
|
||||
<autoresizingMask key="autoresizingMask"/>
|
||||
<subviews>
|
||||
<imageView userInteractionEnabled="NO" contentMode="scaleAspectFit" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="face1" translatesAutoresizingMaskIntoConstraints="NO" id="SY0-ki-F5U">
|
||||
<rect key="frame" x="40" y="20" width="40" height="40"/>
|
||||
<constraints>
|
||||
<constraint firstAttribute="width" constant="40" id="1XW-AC-9LK"/>
|
||||
<constraint firstAttribute="height" constant="40" id="jDR-B8-a7U"/>
|
||||
</constraints>
|
||||
</imageView>
|
||||
<imageView userInteractionEnabled="NO" contentMode="scaleToFill" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="heand" translatesAutoresizingMaskIntoConstraints="NO" id="g7r-dJ-em9"/>
|
||||
<imageView userInteractionEnabled="NO" contentMode="scaleToFill" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="heand" translatesAutoresizingMaskIntoConstraints="NO" id="g7r-dJ-em9">
|
||||
<rect key="frame" x="299" y="33.5" width="14" height="13"/>
|
||||
</imageView>
|
||||
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="Amada Iin" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="0sx-fO-Xiy">
|
||||
<rect key="frame" x="108" y="31" width="68" height="18"/>
|
||||
<fontDescription key="fontDescription" type="system" pointSize="15"/>
|
||||
<color key="textColor" red="0.41960784309999999" green="0.41960784309999999" blue="0.41960784309999999" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<nil key="highlightedColor"/>
|
||||
</label>
|
||||
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="FEB 14th" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="SVA-lD-IQs">
|
||||
<rect key="frame" x="213" y="34" width="43" height="12"/>
|
||||
<fontDescription key="fontDescription" type="system" pointSize="10"/>
|
||||
<color key="textColor" red="0.76470588240000004" green="0.76470588240000004" blue="0.76470588240000004" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<nil key="highlightedColor"/>
|
||||
</label>
|
||||
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" textAlignment="natural" lineBreakMode="tailTruncation" numberOfLines="3" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="kYn-LQ-ReD">
|
||||
<rect key="frame" x="40" y="57" width="273" height="59"/>
|
||||
<constraints>
|
||||
<constraint firstAttribute="height" constant="59" id="sMt-dP-LYh"/>
|
||||
</constraints>
|
||||
@@ -337,27 +374,33 @@
|
||||
<rect key="frame" x="0.0" y="620" width="375" height="124"/>
|
||||
<autoresizingMask key="autoresizingMask"/>
|
||||
<tableViewCellContentView key="contentView" opaque="NO" clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="center" tableViewCell="Fj4-n4-S6M" id="D8J-AG-YUN">
|
||||
<frame key="frameInset" width="375" height="124"/>
|
||||
<rect key="frame" x="0.0" y="0.0" width="375" height="124"/>
|
||||
<autoresizingMask key="autoresizingMask"/>
|
||||
<subviews>
|
||||
<imageView userInteractionEnabled="NO" contentMode="scaleAspectFit" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="face2" translatesAutoresizingMaskIntoConstraints="NO" id="dRk-IE-zXs">
|
||||
<rect key="frame" x="40" y="20" width="40" height="40"/>
|
||||
<constraints>
|
||||
<constraint firstAttribute="height" constant="40" id="KNl-fy-6Ga"/>
|
||||
<constraint firstAttribute="width" constant="40" id="hN8-5E-akX"/>
|
||||
</constraints>
|
||||
</imageView>
|
||||
<imageView userInteractionEnabled="NO" contentMode="scaleToFill" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="heand" translatesAutoresizingMaskIntoConstraints="NO" id="hz8-Cp-lQj"/>
|
||||
<imageView userInteractionEnabled="NO" contentMode="scaleToFill" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="heand" translatesAutoresizingMaskIntoConstraints="NO" id="hz8-Cp-lQj">
|
||||
<rect key="frame" x="299" y="33.5" width="14" height="13"/>
|
||||
</imageView>
|
||||
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="Peter Allan" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="YjL-xf-PcV">
|
||||
<rect key="frame" x="108" y="31" width="74" height="18"/>
|
||||
<fontDescription key="fontDescription" type="system" pointSize="15"/>
|
||||
<color key="textColor" red="0.41960784309999999" green="0.41960784309999999" blue="0.41960784309999999" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<nil key="highlightedColor"/>
|
||||
</label>
|
||||
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="FEB 14th" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="J4t-pX-zbM">
|
||||
<rect key="frame" x="219" y="34" width="43" height="12"/>
|
||||
<fontDescription key="fontDescription" type="system" pointSize="10"/>
|
||||
<color key="textColor" red="0.76470588240000004" green="0.76470588240000004" blue="0.76470588240000004" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<nil key="highlightedColor"/>
|
||||
</label>
|
||||
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" textAlignment="natural" lineBreakMode="tailTruncation" numberOfLines="3" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="Q6w-vY-gMp">
|
||||
<rect key="frame" x="40" y="57" width="273" height="59"/>
|
||||
<constraints>
|
||||
<constraint firstAttribute="height" constant="59" id="T4M-G7-7hc"/>
|
||||
</constraints>
|
||||
@@ -390,14 +433,16 @@
|
||||
<outlet property="delegate" destination="7RW-i0-HfN" id="28D-Ct-5A9"/>
|
||||
</connections>
|
||||
</tableView>
|
||||
<toolbarItems/>
|
||||
<navigationItem key="navigationItem" id="9zG-W9-jGP">
|
||||
<nil key="title"/>
|
||||
<barButtonItem key="leftBarButtonItem" image="searchIcon" id="sSw-AG-wrF"/>
|
||||
<view key="titleView" contentMode="scaleToFill" id="qyb-Fh-aIr" userLabel="Item View">
|
||||
<rect key="frame" x="68" y="6" width="240" height="33"/>
|
||||
<rect key="frame" x="67.5" y="5.5" width="240" height="33"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
<subviews>
|
||||
<imageView userInteractionEnabled="NO" contentMode="scaleToFill" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="Title" translatesAutoresizingMaskIntoConstraints="NO" id="a24-t2-9jd">
|
||||
<rect key="frame" x="94.5" y="8.5" width="51" height="16"/>
|
||||
<constraints>
|
||||
<constraint firstAttribute="height" constant="16" id="5Zr-Wx-iQB"/>
|
||||
<constraint firstAttribute="width" constant="51" id="RtX-4m-x9W"/>
|
||||
@@ -416,6 +461,11 @@
|
||||
</connections>
|
||||
</barButtonItem>
|
||||
</navigationItem>
|
||||
<simulatedToolbarMetrics key="simulatedBottomBarMetrics"/>
|
||||
<connections>
|
||||
<outlet property="titleImageView" destination="a24-t2-9jd" id="dZR-2A-N8b"/>
|
||||
<outlet property="titleImageViewXConstraint" destination="sdW-OO-2BS" id="huK-Bc-7RX"/>
|
||||
</connections>
|
||||
</tableViewController>
|
||||
<placeholder placeholderIdentifier="IBFirstResponder" id="koT-TQ-RUs" userLabel="First Responder" sceneMemberID="firstResponder"/>
|
||||
</objects>
|
||||
|
||||
+19
-3
@@ -17,19 +17,36 @@ class DemoTableViewController: ExpandingTableViewController {
|
||||
let image1 = Asset.backgroundImage.image
|
||||
tableView.backgroundView = UIImageView(image: image1)
|
||||
}
|
||||
|
||||
@IBOutlet weak var titleImageView: UIImageView!
|
||||
@IBOutlet weak var titleImageViewXConstraint: NSLayoutConstraint!
|
||||
|
||||
}
|
||||
// MARK: Helpers
|
||||
|
||||
// MARK: - Lifecycle
|
||||
extension DemoTableViewController {
|
||||
|
||||
override func viewWillLayoutSubviews() {
|
||||
super.viewWillLayoutSubviews()
|
||||
guard let titleView = navigationItem.titleView else { return }
|
||||
let center = UIScreen.main.bounds.midX
|
||||
let diff = center - titleView.frame.midX
|
||||
titleImageViewXConstraint.constant = diff
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
// MARK: Helpers
|
||||
extension DemoTableViewController {
|
||||
|
||||
fileprivate func configureNavBar() {
|
||||
navigationItem.leftBarButtonItem?.image = navigationItem.leftBarButtonItem?.image!.withRenderingMode(UIImageRenderingMode.alwaysOriginal)
|
||||
navigationItem.rightBarButtonItem?.image = navigationItem.rightBarButtonItem?.image!.withRenderingMode(UIImageRenderingMode.alwaysOriginal)
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
// MARK: Actions
|
||||
|
||||
extension DemoTableViewController {
|
||||
|
||||
@IBAction func backButtonHandler(_ sender: AnyObject) {
|
||||
@@ -46,7 +63,6 @@ extension DemoTableViewController {
|
||||
}
|
||||
|
||||
// MARK: UIScrollViewDelegate
|
||||
|
||||
extension DemoTableViewController {
|
||||
|
||||
override func scrollViewDidScroll(_ scrollView: UIScrollView) {
|
||||
|
||||
+32
-22
@@ -15,10 +15,12 @@ class DemoViewController: ExpandingViewController {
|
||||
fileprivate let items: [ItemInfo] = [("item0", "Boston"),("item1", "New York"),("item2", "San Francisco"),("item3", "Washington")]
|
||||
|
||||
@IBOutlet weak var pageLabel: UILabel!
|
||||
@IBOutlet weak var titleImageView: UIImageView!
|
||||
@IBOutlet weak var titleImageViewXConstraint: NSLayoutConstraint!
|
||||
|
||||
}
|
||||
|
||||
// MARK: life cicle
|
||||
|
||||
// MARK: - Lifecycle 🌎
|
||||
extension DemoViewController {
|
||||
|
||||
override func viewDidLoad() {
|
||||
@@ -26,14 +28,22 @@ extension DemoViewController {
|
||||
super.viewDidLoad()
|
||||
|
||||
registerCell()
|
||||
fillCellIsOpeenArry()
|
||||
addGestureToView(collectionView!)
|
||||
fillCellIsOpenArray()
|
||||
addGesture(to: collectionView!)
|
||||
configureNavBar()
|
||||
}
|
||||
|
||||
override func viewWillLayoutSubviews() {
|
||||
super.viewWillLayoutSubviews()
|
||||
guard let titleView = navigationItem.titleView else { return }
|
||||
let center = UIScreen.main.bounds.midX
|
||||
let diff = center - titleView.frame.midX
|
||||
titleImageViewXConstraint.constant = diff
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
// MARK: Helpers
|
||||
|
||||
// MARK: Helpers
|
||||
extension DemoViewController {
|
||||
|
||||
fileprivate func registerCell() {
|
||||
@@ -42,10 +52,8 @@ extension DemoViewController {
|
||||
collectionView?.register(nib, forCellWithReuseIdentifier: String(describing: DemoCollectionViewCell.self))
|
||||
}
|
||||
|
||||
fileprivate func fillCellIsOpeenArry() {
|
||||
for _ in items {
|
||||
cellsIsOpen.append(false)
|
||||
}
|
||||
fileprivate func fillCellIsOpenArray() {
|
||||
cellsIsOpen = Array(repeating: false, count: items.count)
|
||||
}
|
||||
|
||||
fileprivate func getViewController() -> ExpandingTableViewController {
|
||||
@@ -57,22 +65,22 @@ extension DemoViewController {
|
||||
fileprivate func configureNavBar() {
|
||||
navigationItem.leftBarButtonItem?.image = navigationItem.leftBarButtonItem?.image!.withRenderingMode(UIImageRenderingMode.alwaysOriginal)
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
/// MARK: Gesture
|
||||
|
||||
extension DemoViewController {
|
||||
|
||||
fileprivate func addGestureToView(_ toView: UIView) {
|
||||
let gesutereUp = Init(UISwipeGestureRecognizer(target: self, action: #selector(DemoViewController.swipeHandler(_:)))) {
|
||||
fileprivate func addGesture(to view: UIView) {
|
||||
let upGesture = Init(UISwipeGestureRecognizer(target: self, action: #selector(DemoViewController.swipeHandler(_:)))) {
|
||||
$0.direction = .up
|
||||
}
|
||||
|
||||
let gesutereDown = Init(UISwipeGestureRecognizer(target: self, action: #selector(DemoViewController.swipeHandler(_:)))) {
|
||||
let downGesture = Init(UISwipeGestureRecognizer(target: self, action: #selector(DemoViewController.swipeHandler(_:)))) {
|
||||
$0.direction = .down
|
||||
}
|
||||
toView.addGestureRecognizer(gesutereUp)
|
||||
toView.addGestureRecognizer(gesutereDown)
|
||||
view.addGestureRecognizer(upGesture)
|
||||
view.addGestureRecognizer(downGesture)
|
||||
}
|
||||
|
||||
func swipeHandler(_ sender: UISwipeGestureRecognizer) {
|
||||
@@ -89,28 +97,28 @@ extension DemoViewController {
|
||||
|
||||
let open = sender.direction == .up ? true : false
|
||||
cell.cellIsOpen(open)
|
||||
cellsIsOpen[(indexPath as NSIndexPath).row] = cell.isOpened
|
||||
cellsIsOpen[indexPath.row] = cell.isOpened
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
// MARK: UIScrollViewDelegate
|
||||
|
||||
// MARK: UIScrollViewDelegate
|
||||
extension DemoViewController {
|
||||
|
||||
func scrollViewDidScroll(_ scrollView: UIScrollView) {
|
||||
pageLabel.text = "\(currentIndex+1)/\(items.count)"
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
// MARK: UICollectionViewDataSource
|
||||
|
||||
extension DemoViewController {
|
||||
|
||||
override func collectionView(_ collectionView: UICollectionView, willDisplay cell: UICollectionViewCell, forItemAt indexPath: IndexPath) {
|
||||
super.collectionView(collectionView, willDisplay: cell, forItemAt: indexPath)
|
||||
guard let cell = cell as? DemoCollectionViewCell else { return }
|
||||
|
||||
let index = (indexPath as NSIndexPath).row % items.count
|
||||
let index = indexPath.row % items.count
|
||||
let info = items[index]
|
||||
cell.backgroundImageView?.image = UIImage(named: info.imageName)
|
||||
cell.customTitle.text = info.title
|
||||
@@ -119,7 +127,7 @@ extension DemoViewController {
|
||||
|
||||
func collectionView(_ collectionView: UICollectionView, didSelectItemAtIndexPath indexPath: IndexPath) {
|
||||
guard let cell = collectionView.cellForItem(at: indexPath) as? DemoCollectionViewCell
|
||||
, currentIndex == (indexPath as NSIndexPath).row else { return }
|
||||
, currentIndex == indexPath.row else { return }
|
||||
|
||||
if cell.isOpened == false {
|
||||
cell.cellIsOpen(true)
|
||||
@@ -131,6 +139,7 @@ extension DemoViewController {
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
// MARK: UICollectionViewDataSource
|
||||
@@ -143,4 +152,5 @@ extension DemoViewController {
|
||||
override func collectionView(_ collectionView: UICollectionView, cellForItemAt indexPath: IndexPath) -> UICollectionViewCell {
|
||||
return collectionView.dequeueReusableCell(withReuseIdentifier: String(describing: DemoCollectionViewCell.self), for: indexPath)
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user