Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add storyboard support #39 #92

Closed
wants to merge 17 commits into from
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ class DemoItem: NSObject {
init(
name: String,
controllerClass: UIViewController.Type,
controllerIdentifier: String?=nil
controllerIdentifier: String? = nil
) {
self.name = name
self.controllerClass = controllerClass
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -58,8 +58,6 @@ class HorizontalSectionController: IGListSectionController, IGListSectionType, I
return EmbeddedSectionController()
}

func emptyView(for listAdapter: IGListAdapter) -> UIView? {
return nil
}
func emptyView(for listAdapter: IGListAdapter) -> UIView? { return nil }

}
Original file line number Diff line number Diff line change
Expand Up @@ -57,8 +57,6 @@ class DemosViewController: UIViewController, IGListAdapterDataSource {
return DemoSectionController()
}

func emptyView(for listAdapter: IGListAdapter) -> UIView? {
return nil
}
func emptyView(for listAdapter: IGListAdapter) -> UIView? { return nil }

}
Original file line number Diff line number Diff line change
Expand Up @@ -59,8 +59,6 @@ class NestedAdapterViewController: UIViewController, IGListAdapterDataSource {
}
}

func emptyView(for listAdapter: IGListAdapter) -> UIView? {
return nil
}
func emptyView(for listAdapter: IGListAdapter) -> UIView? { return nil }

}
Original file line number Diff line number Diff line change
Expand Up @@ -62,9 +62,7 @@ class SearchViewController: UIViewController, IGListAdapterDataSource, SearchSec
}
}

func emptyView(for listAdapter: IGListAdapter) -> UIView? {
return nil
}
func emptyView(for listAdapter: IGListAdapter) -> UIView? { return nil }

//MARK: SearchSectionControllerDelegate

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -55,9 +55,7 @@ final class SingleSectionStoryboardViewController: UIViewController, IGListAdapt
return sectionController
}

func emptyView(for listAdapter: IGListAdapter) -> UIView? {
return nil
}
func emptyView(for listAdapter: IGListAdapter) -> UIView? { return nil }

// MARK: - IGListSingleSectionControllerDelegate

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -65,9 +65,7 @@ final class SingleSectionViewController: UIViewController, IGListAdapterDataSour
return sectionController
}

func emptyView(for listAdapter: IGListAdapter) -> UIView? {
return nil
}
func emptyView(for listAdapter: IGListAdapter) -> UIView? { return nil }

// MARK: - IGListSingleSectionControllerDelegate

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -54,8 +54,6 @@ class WorkingRangeViewController: UIViewController, IGListAdapterDataSource {
return WorkingRangeSectionController()
}

func emptyView(for listAdapter: IGListAdapter) -> UIView? {
return nil
}
func emptyView(for listAdapter: IGListAdapter) -> UIView? { return nil }

}
2 changes: 1 addition & 1 deletion Source/IGListAdapter.m
Original file line number Diff line number Diff line change
Expand Up @@ -732,7 +732,7 @@ - (__kindof UICollectionViewCell *)dequeueReusableCellFromStoryboardWithIdentifi
atIndex:(NSInteger)index {
IGAssertMainThread();
IGParameterAssert(sectionController != nil);
IGParameterAssert(identifier != nil);
IGParameterAssert(identifier.length > 0);
UICollectionView *collectionView = self.collectionView;
IGAssert(collectionView != nil, @"Reloading adapter without a collection view.");
NSIndexPath *indexPath = [self indexPathForSectionController:sectionController index:index];
Expand Down