Skip to content

Commit

Permalink
Create icons for the tabs and link them with the code (#38)
Browse files Browse the repository at this point in the history
* add tabbaricons

* remove Local/ from gitignore

* fix line length validation error
  • Loading branch information
felixfoertsch authored and kgellci committed Jan 23, 2019
1 parent 84096ff commit fec75ca
Show file tree
Hide file tree
Showing 10 changed files with 51 additions and 4 deletions.
3 changes: 1 addition & 2 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -33,5 +33,4 @@ playground.xcworkspace
*.xcodeproj
Configs/user.xcconfig
Configs/bundleIdentifier.xcconfig
tmp/

tmp/
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
{
"images" : [
{
"idiom" : "universal",
"filename" : "TabbarFeedIcon.png",
"scale" : "1x"
},
{
"idiom" : "universal",
"filename" : "TabbarFeedIcon@2x.png",
"scale" : "2x"
},
{
"idiom" : "universal",
"filename" : "TabbarFeedIcon@3x.png",
"scale" : "3x"
}
],
"info" : {
"version" : 1,
"author" : "xcode"
}
}
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
{
"images" : [
{
"idiom" : "universal",
"filename" : "TabbarSettingsIcon.png",
"scale" : "1x"
},
{
"idiom" : "universal",
"filename" : "TabbarSettingsIcon@2x.png",
"scale" : "2x"
},
{
"idiom" : "universal",
"filename" : "TabbarSettingsIcon@3x.png",
"scale" : "3x"
}
],
"info" : {
"version" : 1,
"author" : "xcode"
}
}
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
6 changes: 4 additions & 2 deletions Area51/Sources/NavigationRouter.swift
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,12 @@ import UIKit
struct NavigationRouter {
static var mainNavigation: UITabBarController {
let feedController = UIStoryboard.feed.instantiateInitialViewController()!
feedController.tabBarItem = UITabBarItem(title: "Feed", image: nil, tag: 0)
let feedIcon = UIImage(named: "TabbarFeedIcon")
feedController.tabBarItem = UITabBarItem(title: "Feed", image: feedIcon, tag: 0)

let settingsController = UIStoryboard.settings.instantiateInitialViewController()!
settingsController.tabBarItem = UITabBarItem(title: "Settings", image: nil, tag: 0)
let settingsIcon = UIImage(named: "TabbarSettingsIcon")
settingsController.tabBarItem = UITabBarItem(title: "Settings", image: settingsIcon, tag: 0)

let tabBar = UITabBarController()
tabBar.viewControllers = [feedController, settingsController]
Expand Down

0 comments on commit fec75ca

Please sign in to comment.