-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
add-nib-examples: added segment and switch cells
- Loading branch information
1 parent
589acba
commit a4937da
Showing
12 changed files
with
227 additions
and
11 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
14 changes: 14 additions & 0 deletions
14
...er-Example/ViewControllers/ListViewsNibSupport/Views/SegmentCell/ANETableXibSegmentCell.h
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
// | ||
// ANETableXibSegmentCell.h | ||
// Alister-Example | ||
// | ||
// Created by ANODA on 2/15/17. | ||
// Copyright © 2017 Oksana Kovalchuk. All rights reserved. | ||
// | ||
|
||
#import "ANBaseTableViewCell.h" | ||
#import "ANETableXibSegmentCellViewModel.h" | ||
|
||
@interface ANETableXibSegmentCell : ANBaseTableViewCell | ||
|
||
@end |
19 changes: 19 additions & 0 deletions
19
...er-Example/ViewControllers/ListViewsNibSupport/Views/SegmentCell/ANETableXibSegmentCell.m
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
// | ||
// ANETableXibSegmentCell.m | ||
// Alister-Example | ||
// | ||
// Created by ANODA on 2/15/17. | ||
// Copyright © 2017 Oksana Kovalchuk. All rights reserved. | ||
// | ||
|
||
#import "ANETableXibSegmentCell.h" | ||
|
||
@interface ANETableXibSegmentCell () | ||
|
||
@property (weak, nonatomic) IBOutlet UISegmentedControl* segmentControl; | ||
|
||
@end | ||
|
||
@implementation ANETableXibSegmentCell | ||
|
||
@end |
43 changes: 43 additions & 0 deletions
43
...-Example/ViewControllers/ListViewsNibSupport/Views/SegmentCell/ANETableXibSegmentCell.xib
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,43 @@ | ||
<?xml version="1.0" encoding="UTF-8"?> | ||
<document type="com.apple.InterfaceBuilder3.CocoaTouch.XIB" version="3.0" toolsVersion="11762" systemVersion="16B2555" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" colorMatched="YES"> | ||
<device id="retina4_7" orientation="portrait"> | ||
<adaptation id="fullscreen"/> | ||
</device> | ||
<dependencies> | ||
<deployment identifier="iOS"/> | ||
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="11757"/> | ||
<capability name="documents saved in the Xcode 8 format" minToolsVersion="8.0"/> | ||
</dependencies> | ||
<objects> | ||
<placeholder placeholderIdentifier="IBFilesOwner" id="-1" userLabel="File's Owner"/> | ||
<placeholder placeholderIdentifier="IBFirstResponder" id="-2" customClass="UIResponder"/> | ||
<tableViewCell clipsSubviews="YES" contentMode="scaleToFill" selectionStyle="default" indentationWidth="10" reuseIdentifier="ANETableXibSegmentCellViewModel<=>kANDefaultCellKind" rowHeight="113" id="rky-uT-t5M" customClass="ANETableXibSegmentCell"> | ||
<rect key="frame" x="0.0" y="0.0" width="428" height="113"/> | ||
<autoresizingMask key="autoresizingMask"/> | ||
<tableViewCellContentView key="contentView" opaque="NO" clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="center" tableViewCell="rky-uT-t5M" id="2eH-oT-zKu"> | ||
<rect key="frame" x="0.0" y="0.0" width="428" height="112"/> | ||
<autoresizingMask key="autoresizingMask"/> | ||
<subviews> | ||
<segmentedControl opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="left" contentVerticalAlignment="top" segmentControlStyle="plain" selectedSegmentIndex="0" translatesAutoresizingMaskIntoConstraints="NO" id="l9Q-7t-yQK"> | ||
<rect key="frame" x="134" y="42" width="160" height="29"/> | ||
<constraints> | ||
<constraint firstAttribute="width" constant="160" id="9PU-9n-68L"/> | ||
</constraints> | ||
<segments> | ||
<segment title="On"/> | ||
<segment title="Off"/> | ||
</segments> | ||
</segmentedControl> | ||
</subviews> | ||
<constraints> | ||
<constraint firstItem="l9Q-7t-yQK" firstAttribute="centerX" secondItem="2eH-oT-zKu" secondAttribute="centerX" id="SZB-lt-iIX"/> | ||
<constraint firstItem="l9Q-7t-yQK" firstAttribute="centerY" secondItem="2eH-oT-zKu" secondAttribute="centerY" id="vT0-cK-Y43"/> | ||
</constraints> | ||
</tableViewCellContentView> | ||
<connections> | ||
<outlet property="segmentControl" destination="l9Q-7t-yQK" id="lFP-nY-Xnr"/> | ||
</connections> | ||
<point key="canvasLocation" x="130" y="867.5"/> | ||
</tableViewCell> | ||
</objects> | ||
</document> |
11 changes: 11 additions & 0 deletions
11
...e/ViewControllers/ListViewsNibSupport/Views/SegmentCell/ANETableXibSegmentCellViewModel.h
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
// | ||
// ANETableXibSegmentCellViewModel.h | ||
// Alister-Example | ||
// | ||
// Created by ANODA on 2/15/17. | ||
// Copyright © 2017 Oksana Kovalchuk. All rights reserved. | ||
// | ||
|
||
@interface ANETableXibSegmentCellViewModel : NSObject | ||
|
||
@end |
13 changes: 13 additions & 0 deletions
13
...e/ViewControllers/ListViewsNibSupport/Views/SegmentCell/ANETableXibSegmentCellViewModel.m
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
// | ||
// ANETableXibSegmentCellViewModel.m | ||
// Alister-Example | ||
// | ||
// Created by ANODA on 2/15/17. | ||
// Copyright © 2017 Oksana Kovalchuk. All rights reserved. | ||
// | ||
|
||
#import "ANETableXibSegmentCellViewModel.h" | ||
|
||
@implementation ANETableXibSegmentCellViewModel | ||
|
||
@end |
14 changes: 14 additions & 0 deletions
14
...ster-Example/ViewControllers/ListViewsNibSupport/Views/SwitchCell/ANETableXibSwitchCell.h
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
// | ||
// ANETableXibSwitchCell.h | ||
// Alister-Example | ||
// | ||
// Created by ANODA on 2/15/17. | ||
// Copyright © 2017 Oksana Kovalchuk. All rights reserved. | ||
// | ||
|
||
#import "ANBaseTableViewCell.h" | ||
#import "ANETableXibSwitchCellViewModel.h" | ||
|
||
@interface ANETableXibSwitchCell : ANBaseTableViewCell | ||
|
||
@end |
19 changes: 19 additions & 0 deletions
19
...ster-Example/ViewControllers/ListViewsNibSupport/Views/SwitchCell/ANETableXibSwitchCell.m
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
// | ||
// ANETableXibSwitchCell.m | ||
// Alister-Example | ||
// | ||
// Created by ANODA on 2/15/17. | ||
// Copyright © 2017 Oksana Kovalchuk. All rights reserved. | ||
// | ||
|
||
#import "ANETableXibSwitchCell.h" | ||
|
||
@interface ANETableXibSwitchCell () | ||
|
||
@property (weak, nonatomic) IBOutlet UISwitch* switchControl; | ||
|
||
@end | ||
|
||
@implementation ANETableXibSwitchCell | ||
|
||
@end |
Oops, something went wrong.