Commit 53a441076337133de64eb14ad915fe7e44dad8a4
1 parent
8bbf316e
Exists in
newLive
no message
Showing
7 changed files
with
88 additions
and
40 deletions
Show diff stats
YouerLiveVideo/YouerLiveVideo/Base.lproj/Main.storyboard
1 | -<?xml version="1.0" encoding="UTF-8" standalone="no"?> | ||
2 | -<document type="com.apple.InterfaceBuilder3.CocoaTouch.Storyboard.XIB" version="3.0" toolsVersion="11762" systemVersion="15G1217" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" colorMatched="YES" initialViewController="fhe-aI-EYq"> | 1 | +<?xml version="1.0" encoding="UTF-8"?> |
2 | +<document type="com.apple.InterfaceBuilder3.CocoaTouch.Storyboard.XIB" version="3.0" toolsVersion="11762" systemVersion="16A323" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" colorMatched="YES" initialViewController="fhe-aI-EYq"> | ||
3 | <device id="retina4_7" orientation="portrait"> | 3 | <device id="retina4_7" orientation="portrait"> |
4 | <adaptation id="fullscreen"/> | 4 | <adaptation id="fullscreen"/> |
5 | </device> | 5 | </device> |
@@ -33,7 +33,7 @@ | @@ -33,7 +33,7 @@ | ||
33 | <nil key="highlightedColor"/> | 33 | <nil key="highlightedColor"/> |
34 | </label> | 34 | </label> |
35 | <button opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="fz6-VO-SIi"> | 35 | <button opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="fz6-VO-SIi"> |
36 | - <rect key="frame" x="310" y="10" width="57" height="30"/> | 36 | + <rect key="frame" x="302" y="10" width="65" height="30"/> |
37 | <constraints> | 37 | <constraints> |
38 | <constraint firstAttribute="height" constant="30" id="NCP-Ag-7c1"/> | 38 | <constraint firstAttribute="height" constant="30" id="NCP-Ag-7c1"/> |
39 | </constraints> | 39 | </constraints> |
@@ -46,7 +46,7 @@ | @@ -46,7 +46,7 @@ | ||
46 | </connections> | 46 | </connections> |
47 | </button> | 47 | </button> |
48 | <button opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="a7C-jD-YSJ"> | 48 | <button opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="a7C-jD-YSJ"> |
49 | - <rect key="frame" x="245" y="14" width="57" height="22"/> | 49 | + <rect key="frame" x="229" y="10" width="65" height="30"/> |
50 | <fontDescription key="fontDescription" type="system" pointSize="17"/> | 50 | <fontDescription key="fontDescription" type="system" pointSize="17"/> |
51 | <state key="normal" title="排序" image="starLive"> | 51 | <state key="normal" title="排序" image="starLive"> |
52 | <color key="titleColor" white="0.0" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/> | 52 | <color key="titleColor" white="0.0" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/> |
@@ -826,12 +826,7 @@ | @@ -826,12 +826,7 @@ | ||
826 | <subviews> | 826 | <subviews> |
827 | <tableView clipsSubviews="YES" contentMode="scaleToFill" alwaysBounceVertical="YES" dataMode="prototypes" style="plain" separatorStyle="none" rowHeight="44" sectionHeaderHeight="28" sectionFooterHeight="28" translatesAutoresizingMaskIntoConstraints="NO" id="CFz-Ro-N17"> | 827 | <tableView clipsSubviews="YES" contentMode="scaleToFill" alwaysBounceVertical="YES" dataMode="prototypes" style="plain" separatorStyle="none" rowHeight="44" sectionHeaderHeight="28" sectionFooterHeight="28" translatesAutoresizingMaskIntoConstraints="NO" id="CFz-Ro-N17"> |
828 | <rect key="frame" x="0.0" y="184" width="375" height="434"/> | 828 | <rect key="frame" x="0.0" y="184" width="375" height="434"/> |
829 | - <color key="backgroundColor" red="0.93503493069999999" green="0.93562394380000002" blue="0.96585971120000003" alpha="1" colorSpace="custom" customColorSpace="sRGB"/> | ||
830 | - <view key="tableFooterView" contentMode="scaleToFill" id="IB7-84-pRF"> | ||
831 | - <rect key="frame" x="0.0" y="72" width="375" height="1"/> | ||
832 | - <autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/> | ||
833 | - <color key="backgroundColor" red="0.93503493069999999" green="0.93562394380000002" blue="0.96585971120000003" alpha="1" colorSpace="custom" customColorSpace="sRGB"/> | ||
834 | - </view> | 829 | + <color key="backgroundColor" red="0.89713114500000002" green="0.89431768659999999" blue="0.90413767099999998" alpha="1" colorSpace="custom" customColorSpace="sRGB"/> |
835 | <prototypes> | 830 | <prototypes> |
836 | <tableViewCell clipsSubviews="YES" contentMode="scaleToFill" selectionStyle="none" indentationWidth="10" reuseIdentifier="cell" id="dJF-O6-zOW" customClass="UserCenterHistoryCell" customModule="YouerLiveVideo" customModuleProvider="target"> | 831 | <tableViewCell clipsSubviews="YES" contentMode="scaleToFill" selectionStyle="none" indentationWidth="10" reuseIdentifier="cell" id="dJF-O6-zOW" customClass="UserCenterHistoryCell" customModule="YouerLiveVideo" customModuleProvider="target"> |
837 | <rect key="frame" x="0.0" y="28" width="375" height="44"/> | 832 | <rect key="frame" x="0.0" y="28" width="375" height="44"/> |
@@ -1290,39 +1285,39 @@ | @@ -1290,39 +1285,39 @@ | ||
1290 | <rect key="frame" x="0.0" y="0.0" width="375" height="667"/> | 1285 | <rect key="frame" x="0.0" y="0.0" width="375" height="667"/> |
1291 | <autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/> | 1286 | <autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/> |
1292 | <subviews> | 1287 | <subviews> |
1293 | - <tableView clipsSubviews="YES" contentMode="scaleToFill" alwaysBounceVertical="YES" dataMode="prototypes" style="plain" separatorStyle="default" rowHeight="178" sectionHeaderHeight="28" sectionFooterHeight="28" translatesAutoresizingMaskIntoConstraints="NO" id="IhH-sz-Bd2"> | 1288 | + <tableView clipsSubviews="YES" contentMode="scaleToFill" alwaysBounceVertical="YES" dataMode="prototypes" style="plain" separatorStyle="none" rowHeight="178" sectionHeaderHeight="28" sectionFooterHeight="28" translatesAutoresizingMaskIntoConstraints="NO" id="IhH-sz-Bd2"> |
1294 | <rect key="frame" x="0.0" y="64" width="375" height="554"/> | 1289 | <rect key="frame" x="0.0" y="64" width="375" height="554"/> |
1295 | <color key="backgroundColor" red="0.93503493069999999" green="0.93562394380000002" blue="0.96585971120000003" alpha="1" colorSpace="custom" customColorSpace="sRGB"/> | 1290 | <color key="backgroundColor" red="0.93503493069999999" green="0.93562394380000002" blue="0.96585971120000003" alpha="1" colorSpace="custom" customColorSpace="sRGB"/> |
1296 | <prototypes> | 1291 | <prototypes> |
1297 | - <tableViewCell clipsSubviews="YES" contentMode="scaleToFill" selectionStyle="default" indentationWidth="10" reuseIdentifier="cell" rowHeight="178" id="8PR-k0-hwX" customClass="TVStationViewControllerTableViewCell" customModule="YouerLiveVideo" customModuleProvider="target"> | 1292 | + <tableViewCell clipsSubviews="YES" contentMode="scaleToFill" selectionStyle="none" indentationWidth="10" reuseIdentifier="cell" rowHeight="178" id="8PR-k0-hwX" customClass="TVStationViewControllerTableViewCell" customModule="YouerLiveVideo" customModuleProvider="target"> |
1298 | <rect key="frame" x="0.0" y="28" width="375" height="178"/> | 1293 | <rect key="frame" x="0.0" y="28" width="375" height="178"/> |
1299 | <autoresizingMask key="autoresizingMask"/> | 1294 | <autoresizingMask key="autoresizingMask"/> |
1300 | <tableViewCellContentView key="contentView" opaque="NO" clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="center" tableViewCell="8PR-k0-hwX" id="Bb0-oI-ccB"> | 1295 | <tableViewCellContentView key="contentView" opaque="NO" clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="center" tableViewCell="8PR-k0-hwX" id="Bb0-oI-ccB"> |
1301 | - <rect key="frame" x="0.0" y="0.0" width="375" height="177"/> | 1296 | + <rect key="frame" x="0.0" y="0.0" width="375" height="178"/> |
1302 | <autoresizingMask key="autoresizingMask"/> | 1297 | <autoresizingMask key="autoresizingMask"/> |
1303 | <subviews> | 1298 | <subviews> |
1304 | <collectionView clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="scaleToFill" showsHorizontalScrollIndicator="NO" showsVerticalScrollIndicator="NO" dataMode="prototypes" translatesAutoresizingMaskIntoConstraints="NO" id="m0I-jk-Iru"> | 1299 | <collectionView clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="scaleToFill" showsHorizontalScrollIndicator="NO" showsVerticalScrollIndicator="NO" dataMode="prototypes" translatesAutoresizingMaskIntoConstraints="NO" id="m0I-jk-Iru"> |
1305 | <rect key="frame" x="0.0" y="0.0" width="375" height="177.5"/> | 1300 | <rect key="frame" x="0.0" y="0.0" width="375" height="177.5"/> |
1306 | <color key="backgroundColor" red="0.93503493069999999" green="0.93562394380000002" blue="0.96585971120000003" alpha="1" colorSpace="custom" customColorSpace="sRGB"/> | 1301 | <color key="backgroundColor" red="0.93503493069999999" green="0.93562394380000002" blue="0.96585971120000003" alpha="1" colorSpace="custom" customColorSpace="sRGB"/> |
1307 | <collectionViewFlowLayout key="collectionViewLayout" scrollDirection="horizontal" minimumLineSpacing="8" minimumInteritemSpacing="8" id="Mv6-Xf-FOx"> | 1302 | <collectionViewFlowLayout key="collectionViewLayout" scrollDirection="horizontal" minimumLineSpacing="8" minimumInteritemSpacing="8" id="Mv6-Xf-FOx"> |
1308 | - <size key="itemSize" width="176" height="164"/> | 1303 | + <size key="itemSize" width="176" height="170.5"/> |
1309 | <size key="headerReferenceSize" width="0.0" height="0.0"/> | 1304 | <size key="headerReferenceSize" width="0.0" height="0.0"/> |
1310 | <size key="footerReferenceSize" width="0.0" height="0.0"/> | 1305 | <size key="footerReferenceSize" width="0.0" height="0.0"/> |
1311 | <inset key="sectionInset" minX="0.0" minY="0.0" maxX="0.0" maxY="0.0"/> | 1306 | <inset key="sectionInset" minX="0.0" minY="0.0" maxX="0.0" maxY="0.0"/> |
1312 | </collectionViewFlowLayout> | 1307 | </collectionViewFlowLayout> |
1313 | <cells> | 1308 | <cells> |
1314 | <collectionViewCell opaque="NO" clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="center" reuseIdentifier="cell" id="Xjm-Ee-xEo" customClass="TVStationViewControllerCollectionCell" customModule="YouerLiveVideo" customModuleProvider="target"> | 1309 | <collectionViewCell opaque="NO" clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="center" reuseIdentifier="cell" id="Xjm-Ee-xEo" customClass="TVStationViewControllerCollectionCell" customModule="YouerLiveVideo" customModuleProvider="target"> |
1315 | - <rect key="frame" x="0.0" y="7" width="176" height="164"/> | 1310 | + <rect key="frame" x="0.0" y="4" width="176" height="170.5"/> |
1316 | <autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/> | 1311 | <autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/> |
1317 | <view key="contentView" opaque="NO" clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="center"> | 1312 | <view key="contentView" opaque="NO" clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="center"> |
1318 | - <rect key="frame" x="0.0" y="0.0" width="176" height="164"/> | 1313 | + <rect key="frame" x="0.0" y="0.0" width="176" height="170"/> |
1319 | <autoresizingMask key="autoresizingMask"/> | 1314 | <autoresizingMask key="autoresizingMask"/> |
1320 | <subviews> | 1315 | <subviews> |
1321 | <imageView userInteractionEnabled="NO" contentMode="scaleToFill" horizontalHuggingPriority="251" verticalHuggingPriority="251" verticalCompressionResistancePriority="749" image="icon" translatesAutoresizingMaskIntoConstraints="NO" id="BvO-kc-ckg"> | 1316 | <imageView userInteractionEnabled="NO" contentMode="scaleToFill" horizontalHuggingPriority="251" verticalHuggingPriority="251" verticalCompressionResistancePriority="749" image="icon" translatesAutoresizingMaskIntoConstraints="NO" id="BvO-kc-ckg"> |
1322 | - <rect key="frame" x="0.0" y="0.0" width="176" height="130"/> | 1317 | + <rect key="frame" x="0.0" y="0.0" width="176" height="136.5"/> |
1323 | </imageView> | 1318 | </imageView> |
1324 | <label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="Label" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="ZGv-kv-0Rn"> | 1319 | <label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="Label" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="ZGv-kv-0Rn"> |
1325 | - <rect key="frame" x="69.5" y="138" width="37.5" height="18"/> | 1320 | + <rect key="frame" x="69.5" y="144.5" width="37.5" height="18"/> |
1326 | <fontDescription key="fontDescription" type="system" pointSize="15"/> | 1321 | <fontDescription key="fontDescription" type="system" pointSize="15"/> |
1327 | <nil key="textColor"/> | 1322 | <nil key="textColor"/> |
1328 | <nil key="highlightedColor"/> | 1323 | <nil key="highlightedColor"/> |
@@ -1427,7 +1422,7 @@ | @@ -1427,7 +1422,7 @@ | ||
1427 | <nil key="highlightedColor"/> | 1422 | <nil key="highlightedColor"/> |
1428 | </label> | 1423 | </label> |
1429 | <button opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="4xl-zG-lqH"> | 1424 | <button opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="4xl-zG-lqH"> |
1430 | - <rect key="frame" x="310" y="10" width="57" height="30"/> | 1425 | + <rect key="frame" x="302" y="10" width="65" height="30"/> |
1431 | <constraints> | 1426 | <constraints> |
1432 | <constraint firstAttribute="height" constant="30" id="xBx-gX-mw4"/> | 1427 | <constraint firstAttribute="height" constant="30" id="xBx-gX-mw4"/> |
1433 | </constraints> | 1428 | </constraints> |
@@ -1440,7 +1435,7 @@ | @@ -1440,7 +1435,7 @@ | ||
1440 | </connections> | 1435 | </connections> |
1441 | </button> | 1436 | </button> |
1442 | <button opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="T2j-JJ-ft5"> | 1437 | <button opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="T2j-JJ-ft5"> |
1443 | - <rect key="frame" x="245" y="14" width="57" height="22"/> | 1438 | + <rect key="frame" x="229" y="10" width="65" height="30"/> |
1444 | <fontDescription key="fontDescription" type="system" pointSize="17"/> | 1439 | <fontDescription key="fontDescription" type="system" pointSize="17"/> |
1445 | <state key="normal" title="排序" image="starLive"> | 1440 | <state key="normal" title="排序" image="starLive"> |
1446 | <color key="titleColor" white="0.0" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/> | 1441 | <color key="titleColor" white="0.0" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/> |
@@ -1656,7 +1651,7 @@ | @@ -1656,7 +1651,7 @@ | ||
1656 | <image name="icon_tvstation" width="25" height="25"/> | 1651 | <image name="icon_tvstation" width="25" height="25"/> |
1657 | <image name="icon_user" width="25" height="25"/> | 1652 | <image name="icon_user" width="25" height="25"/> |
1658 | <image name="icon_watchcount" width="12" height="7"/> | 1653 | <image name="icon_watchcount" width="12" height="7"/> |
1659 | - <image name="starLive" width="22" height="22"/> | 1654 | + <image name="starLive" width="30" height="30"/> |
1660 | <image name="视窗.png" width="31" height="31"/> | 1655 | <image name="视窗.png" width="31" height="31"/> |
1661 | </resources> | 1656 | </resources> |
1662 | </document> | 1657 | </document> |
YouerLiveVideo/YouerLiveVideo/controllers/TVStation/MoreTVStationViewController.swift
@@ -19,7 +19,7 @@ class MoreTVStationViewController: UIViewController { | @@ -19,7 +19,7 @@ class MoreTVStationViewController: UIViewController { | ||
19 | var pageIndex:Int = 2 | 19 | var pageIndex:Int = 2 |
20 | override func viewDidLoad() { | 20 | override func viewDidLoad() { |
21 | super.viewDidLoad() | 21 | super.viewDidLoad() |
22 | - | 22 | + self.automaticallyAdjustsScrollViewInsets = false |
23 | if type != 0{ | 23 | if type != 0{ |
24 | addCellAndRefresh() | 24 | addCellAndRefresh() |
25 | } | 25 | } |
@@ -147,6 +147,14 @@ extension MoreTVStationViewController:UICollectionViewDelegate,UICollectionViewD | @@ -147,6 +147,14 @@ extension MoreTVStationViewController:UICollectionViewDelegate,UICollectionViewD | ||
147 | } | 147 | } |
148 | } | 148 | } |
149 | 149 | ||
150 | + func collectionView(_ collectionView: UICollectionView, layout collectionViewLayout: UICollectionViewLayout, insetForSectionAt section: Int) -> UIEdgeInsets { | ||
151 | + return UIEdgeInsetsMake(10, 10, 10, 10) | ||
152 | + } | ||
153 | + | ||
154 | + func collectionView(_ collectionView: UICollectionView, layout collectionViewLayout: UICollectionViewLayout, sizeForItemAt indexPath: IndexPath) -> CGSize { | ||
155 | + return CGSize(width: (getScreenWidth()-30)/2, height: 180) | ||
156 | + } | ||
157 | + | ||
150 | } | 158 | } |
151 | 159 | ||
152 | class MoreTVStationViewCollectionCell:UICollectionViewCell{ | 160 | class MoreTVStationViewCollectionCell:UICollectionViewCell{ |
YouerLiveVideo/YouerLiveVideo/controllers/TVStation/SearchTVStationListViewController.swift
@@ -90,6 +90,16 @@ class SearchTVStationListViewController: UIViewController,UISearchBarDelegate { | @@ -90,6 +90,16 @@ class SearchTVStationListViewController: UIViewController,UISearchBarDelegate { | ||
90 | selectTableView.reloadData() | 90 | selectTableView.reloadData() |
91 | } | 91 | } |
92 | 92 | ||
93 | + func searchBarShouldBeginEditing(_ searchBar: UISearchBar) -> Bool { | ||
94 | + searchBar.setShowsCancelButton(true, animated: true) | ||
95 | + return true | ||
96 | + } | ||
97 | + | ||
98 | + func searchBarCancelButtonClicked(_ searchBar: UISearchBar) { | ||
99 | + searchBar.setShowsCancelButton(false, animated: true) | ||
100 | + searchBar.resignFirstResponder() | ||
101 | + } | ||
102 | + | ||
93 | //搜索:根据搜索框中内容帅选全部符合的列表 | 103 | //搜索:根据搜索框中内容帅选全部符合的列表 |
94 | func searchBarSearchButtonClicked(_ searchBar: UISearchBar) { | 104 | func searchBarSearchButtonClicked(_ searchBar: UISearchBar) { |
95 | searchBar.resignFirstResponder() | 105 | searchBar.resignFirstResponder() |
YouerLiveVideo/YouerLiveVideo/controllers/TVStation/TVStation.storyboard
@@ -24,7 +24,7 @@ | @@ -24,7 +24,7 @@ | ||
24 | <collectionView clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="scaleToFill" dataMode="prototypes" translatesAutoresizingMaskIntoConstraints="NO" id="T5M-Yy-22h"> | 24 | <collectionView clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="scaleToFill" dataMode="prototypes" translatesAutoresizingMaskIntoConstraints="NO" id="T5M-Yy-22h"> |
25 | <rect key="frame" x="0.0" y="0.0" width="375" height="667"/> | 25 | <rect key="frame" x="0.0" y="0.0" width="375" height="667"/> |
26 | <color key="backgroundColor" red="0.93503493069999999" green="0.93562394380000002" blue="0.96585971120000003" alpha="1" colorSpace="custom" customColorSpace="sRGB"/> | 26 | <color key="backgroundColor" red="0.93503493069999999" green="0.93562394380000002" blue="0.96585971120000003" alpha="1" colorSpace="custom" customColorSpace="sRGB"/> |
27 | - <collectionViewFlowLayout key="collectionViewLayout" minimumLineSpacing="8" minimumInteritemSpacing="8" id="EWj-Hf-n52"> | 27 | + <collectionViewFlowLayout key="collectionViewLayout" minimumLineSpacing="0.0" minimumInteritemSpacing="0.0" id="EWj-Hf-n52"> |
28 | <size key="itemSize" width="180" height="182"/> | 28 | <size key="itemSize" width="180" height="182"/> |
29 | <size key="headerReferenceSize" width="0.0" height="0.0"/> | 29 | <size key="headerReferenceSize" width="0.0" height="0.0"/> |
30 | <size key="footerReferenceSize" width="0.0" height="0.0"/> | 30 | <size key="footerReferenceSize" width="0.0" height="0.0"/> |
@@ -39,23 +39,38 @@ | @@ -39,23 +39,38 @@ | ||
39 | <autoresizingMask key="autoresizingMask"/> | 39 | <autoresizingMask key="autoresizingMask"/> |
40 | <subviews> | 40 | <subviews> |
41 | <imageView userInteractionEnabled="NO" contentMode="scaleToFill" horizontalHuggingPriority="251" verticalHuggingPriority="251" translatesAutoresizingMaskIntoConstraints="NO" id="x1d-Bc-juB"> | 41 | <imageView userInteractionEnabled="NO" contentMode="scaleToFill" horizontalHuggingPriority="251" verticalHuggingPriority="251" translatesAutoresizingMaskIntoConstraints="NO" id="x1d-Bc-juB"> |
42 | - <rect key="frame" x="0.0" y="0.0" width="180" height="148"/> | 42 | + <rect key="frame" x="0.0" y="0.0" width="180" height="128"/> |
43 | + <constraints> | ||
44 | + <constraint firstAttribute="width" secondItem="x1d-Bc-juB" secondAttribute="height" multiplier="45:32" id="UyF-Ua-iSP"/> | ||
45 | + </constraints> | ||
43 | </imageView> | 46 | </imageView> |
44 | - <label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="Label" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="8hi-XF-Vgx"> | ||
45 | - <rect key="frame" x="71.5" y="156" width="37.5" height="18"/> | ||
46 | - <fontDescription key="fontDescription" type="system" pointSize="15"/> | ||
47 | - <nil key="textColor"/> | ||
48 | - <nil key="highlightedColor"/> | ||
49 | - </label> | 47 | + <view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="Ibk-FN-SZr"> |
48 | + <rect key="frame" x="0.0" y="128" width="180" height="54"/> | ||
49 | + <subviews> | ||
50 | + <label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="Label" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="8hi-XF-Vgx"> | ||
51 | + <rect key="frame" x="71.5" y="18" width="37.5" height="18"/> | ||
52 | + <fontDescription key="fontDescription" type="system" pointSize="15"/> | ||
53 | + <nil key="textColor"/> | ||
54 | + <nil key="highlightedColor"/> | ||
55 | + </label> | ||
56 | + </subviews> | ||
57 | + <color key="backgroundColor" white="1" alpha="1" colorSpace="calibratedWhite"/> | ||
58 | + <constraints> | ||
59 | + <constraint firstItem="8hi-XF-Vgx" firstAttribute="centerY" secondItem="Ibk-FN-SZr" secondAttribute="centerY" id="PuK-GO-6aZ"/> | ||
60 | + <constraint firstItem="8hi-XF-Vgx" firstAttribute="centerX" secondItem="Ibk-FN-SZr" secondAttribute="centerX" id="afd-Dr-FIr"/> | ||
61 | + </constraints> | ||
62 | + </view> | ||
50 | </subviews> | 63 | </subviews> |
51 | </view> | 64 | </view> |
65 | + <color key="backgroundColor" white="1" alpha="1" colorSpace="calibratedWhite"/> | ||
52 | <constraints> | 66 | <constraints> |
67 | + <constraint firstAttribute="bottom" secondItem="Ibk-FN-SZr" secondAttribute="bottom" id="5EZ-dA-p3Y"/> | ||
53 | <constraint firstAttribute="trailing" secondItem="x1d-Bc-juB" secondAttribute="trailing" id="6dA-qR-VvU"/> | 68 | <constraint firstAttribute="trailing" secondItem="x1d-Bc-juB" secondAttribute="trailing" id="6dA-qR-VvU"/> |
54 | - <constraint firstAttribute="bottom" secondItem="8hi-XF-Vgx" secondAttribute="bottom" constant="8" id="7yl-Kb-JGR"/> | ||
55 | - <constraint firstItem="8hi-XF-Vgx" firstAttribute="centerX" secondItem="Es8-By-Vgs" secondAttribute="centerX" id="Bua-Ka-aqB"/> | ||
56 | <constraint firstItem="x1d-Bc-juB" firstAttribute="leading" secondItem="Es8-By-Vgs" secondAttribute="leading" id="ED3-B0-TcW"/> | 69 | <constraint firstItem="x1d-Bc-juB" firstAttribute="leading" secondItem="Es8-By-Vgs" secondAttribute="leading" id="ED3-B0-TcW"/> |
70 | + <constraint firstItem="Ibk-FN-SZr" firstAttribute="leading" secondItem="Es8-By-Vgs" secondAttribute="leading" id="RBq-Ms-5of"/> | ||
57 | <constraint firstItem="x1d-Bc-juB" firstAttribute="top" secondItem="Es8-By-Vgs" secondAttribute="top" id="SVy-Ie-v5b"/> | 71 | <constraint firstItem="x1d-Bc-juB" firstAttribute="top" secondItem="Es8-By-Vgs" secondAttribute="top" id="SVy-Ie-v5b"/> |
58 | - <constraint firstItem="8hi-XF-Vgx" firstAttribute="top" secondItem="x1d-Bc-juB" secondAttribute="bottom" constant="8" id="ZHk-2T-zIf"/> | 72 | + <constraint firstAttribute="trailing" secondItem="Ibk-FN-SZr" secondAttribute="trailing" id="juw-Mj-qlE"/> |
73 | + <constraint firstItem="Ibk-FN-SZr" firstAttribute="top" secondItem="x1d-Bc-juB" secondAttribute="bottom" id="sB8-a4-r8s"/> | ||
59 | </constraints> | 74 | </constraints> |
60 | <connections> | 75 | <connections> |
61 | <outlet property="tvPicture" destination="x1d-Bc-juB" id="588-mP-2uu"/> | 76 | <outlet property="tvPicture" destination="x1d-Bc-juB" id="588-mP-2uu"/> |
@@ -253,7 +268,7 @@ | @@ -253,7 +268,7 @@ | ||
253 | <rect key="frame" x="0.0" y="44" width="375" height="48"/> | 268 | <rect key="frame" x="0.0" y="44" width="375" height="48"/> |
254 | <subviews> | 269 | <subviews> |
255 | <view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="REy-qu-6cO"> | 270 | <view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="REy-qu-6cO"> |
256 | - <rect key="frame" x="144.5" y="0.0" width="86" height="48"/> | 271 | + <rect key="frame" x="142" y="0.0" width="91" height="48"/> |
257 | <subviews> | 272 | <subviews> |
258 | <label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="Label" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="EkU-OV-GCU"> | 273 | <label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="Label" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="EkU-OV-GCU"> |
259 | <rect key="frame" x="8" y="13" width="42" height="21"/> | 274 | <rect key="frame" x="8" y="13" width="42" height="21"/> |
@@ -261,11 +276,11 @@ | @@ -261,11 +276,11 @@ | ||
261 | <nil key="textColor"/> | 276 | <nil key="textColor"/> |
262 | <nil key="highlightedColor"/> | 277 | <nil key="highlightedColor"/> |
263 | </label> | 278 | </label> |
264 | - <imageView userInteractionEnabled="NO" contentMode="scaleToFill" horizontalHuggingPriority="251" verticalHuggingPriority="251" translatesAutoresizingMaskIntoConstraints="NO" id="30V-Xl-lRB"> | ||
265 | - <rect key="frame" x="58" y="14" width="20" height="20"/> | 279 | + <imageView userInteractionEnabled="NO" contentMode="scaleToFill" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="icon_open" translatesAutoresizingMaskIntoConstraints="NO" id="30V-Xl-lRB"> |
280 | + <rect key="frame" x="58" y="16.5" width="25" height="15"/> | ||
266 | <constraints> | 281 | <constraints> |
267 | - <constraint firstAttribute="height" constant="20" id="5L5-sW-hMu"/> | ||
268 | - <constraint firstAttribute="width" secondItem="30V-Xl-lRB" secondAttribute="height" multiplier="1:1" id="MYE-j0-EQV"/> | 282 | + <constraint firstAttribute="height" constant="15" id="5L5-sW-hMu"/> |
283 | + <constraint firstAttribute="width" secondItem="30V-Xl-lRB" secondAttribute="height" multiplier="5:3" id="MYE-j0-EQV"/> | ||
269 | </constraints> | 284 | </constraints> |
270 | </imageView> | 285 | </imageView> |
271 | </subviews> | 286 | </subviews> |
@@ -361,7 +376,7 @@ | @@ -361,7 +376,7 @@ | ||
361 | <view hidden="YES" contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="LO5-7p-BlF"> | 376 | <view hidden="YES" contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="LO5-7p-BlF"> |
362 | <rect key="frame" x="0.0" y="92" width="375" height="575"/> | 377 | <rect key="frame" x="0.0" y="92" width="375" height="575"/> |
363 | <subviews> | 378 | <subviews> |
364 | - <tableView clipsSubviews="YES" contentMode="scaleToFill" alwaysBounceVertical="YES" showsHorizontalScrollIndicator="NO" showsVerticalScrollIndicator="NO" dataMode="prototypes" style="plain" separatorStyle="default" rowHeight="44" sectionHeaderHeight="28" sectionFooterHeight="28" translatesAutoresizingMaskIntoConstraints="NO" id="IbJ-62-QUz"> | 379 | + <tableView clipsSubviews="YES" contentMode="scaleToFill" alwaysBounceVertical="YES" showsHorizontalScrollIndicator="NO" showsVerticalScrollIndicator="NO" keyboardDismissMode="onDrag" dataMode="prototypes" style="plain" separatorStyle="default" rowHeight="44" sectionHeaderHeight="28" sectionFooterHeight="28" translatesAutoresizingMaskIntoConstraints="NO" id="IbJ-62-QUz"> |
365 | <rect key="frame" x="0.0" y="0.0" width="375" height="575"/> | 380 | <rect key="frame" x="0.0" y="0.0" width="375" height="575"/> |
366 | <color key="backgroundColor" white="0.0" alpha="0.0" colorSpace="calibratedWhite"/> | 381 | <color key="backgroundColor" white="0.0" alpha="0.0" colorSpace="calibratedWhite"/> |
367 | <view key="tableFooterView" contentMode="scaleToFill" id="3xH-Ja-uTC"> | 382 | <view key="tableFooterView" contentMode="scaleToFill" id="3xH-Ja-uTC"> |
@@ -682,6 +697,7 @@ | @@ -682,6 +697,7 @@ | ||
682 | </scenes> | 697 | </scenes> |
683 | <resources> | 698 | <resources> |
684 | <image name="arrow" width="7" height="12"/> | 699 | <image name="arrow" width="7" height="12"/> |
700 | + <image name="icon_open" width="14" height="8"/> | ||
685 | <image name="starLive" width="30" height="30"/> | 701 | <image name="starLive" width="30" height="30"/> |
686 | </resources> | 702 | </resources> |
687 | </document> | 703 | </document> |
YouerLiveVideo/YouerLiveVideo/controllers/TVStation/TVStationViewController.swift
@@ -138,6 +138,10 @@ extension TVStationViewController:UITableViewDelegate,UITableViewDataSource{ | @@ -138,6 +138,10 @@ extension TVStationViewController:UITableViewDelegate,UITableViewDataSource{ | ||
138 | } | 138 | } |
139 | 139 | ||
140 | 140 | ||
141 | + func tableView(_ tableView: UITableView, heightForRowAt indexPath: IndexPath) -> CGFloat { | ||
142 | + return 150 | ||
143 | + } | ||
144 | + | ||
141 | func tableView(_ tableView: UITableView, didSelectRowAt indexPath: IndexPath) { | 145 | func tableView(_ tableView: UITableView, didSelectRowAt indexPath: IndexPath) { |
142 | } | 146 | } |
143 | 147 | ||
@@ -197,6 +201,11 @@ extension TVStationViewController:UICollectionViewDelegate,UICollectionViewDeleg | @@ -197,6 +201,11 @@ extension TVStationViewController:UICollectionViewDelegate,UICollectionViewDeleg | ||
197 | return UIEdgeInsetsMake(0, 10, 0, 10) | 201 | return UIEdgeInsetsMake(0, 10, 0, 10) |
198 | } | 202 | } |
199 | 203 | ||
204 | + func collectionView(_ collectionView: UICollectionView, layout collectionViewLayout: UICollectionViewLayout, sizeForItemAt indexPath: IndexPath) -> CGSize { | ||
205 | + return CGSize(width: (getScreenWidth()-30)/2, height: 150) | ||
206 | + } | ||
207 | + | ||
208 | + | ||
200 | } | 209 | } |
201 | 210 | ||
202 | class TVStationViewControllerTableViewCell:UITableViewCell{ | 211 | class TVStationViewControllerTableViewCell:UITableViewCell{ |
YouerLiveVideo/YouerLiveVideo/controllers/User/UserEditViewController.swift
@@ -29,7 +29,7 @@ class UserEditViewController: UIViewController ,UIImagePickerControllerDelegate, | @@ -29,7 +29,7 @@ class UserEditViewController: UIViewController ,UIImagePickerControllerDelegate, | ||
29 | }else{ | 29 | }else{ |
30 | ident = "教师" | 30 | ident = "教师" |
31 | } | 31 | } |
32 | - contentArr = [user.name(),user.userid,ident,user.schoolName()] | 32 | + contentArr = [user.name(),user.phone(),ident,user.schoolName()] |
33 | } | 33 | } |
34 | 34 | ||
35 | override func viewWillAppear(_ animated: Bool) { | 35 | override func viewWillAppear(_ animated: Bool) { |
YouerLiveVideo/YouerLiveVideo/controllers/User/UserViewController.swift
@@ -154,6 +154,16 @@ extension UserViewController:UITableViewDelegate,UITableViewDataSource{ | @@ -154,6 +154,16 @@ extension UserViewController:UITableViewDelegate,UITableViewDataSource{ | ||
154 | return 44 | 154 | return 44 |
155 | } | 155 | } |
156 | 156 | ||
157 | + func tableView(_ tableView: UITableView, heightForFooterInSection section: Int) -> CGFloat { | ||
158 | + return 15 | ||
159 | + } | ||
160 | + | ||
161 | + func tableView(_ tableView: UITableView, viewForFooterInSection section: Int) -> UIView? { | ||
162 | + let view = UIView(frame: CGRect(x: 0, y: 0, width: getScreenWidth(), height: 15)) | ||
163 | + view.backgroundColor = UIColor.clear | ||
164 | + return view | ||
165 | + } | ||
166 | + | ||
157 | override func viewWillAppear(_ animated: Bool) { | 167 | override func viewWillAppear(_ animated: Bool) { |
158 | super.viewWillAppear(animated) | 168 | super.viewWillAppear(animated) |
159 | self.tabBarController?.tabBar.isHidden = false | 169 | self.tabBarController?.tabBar.isHidden = false |