custom tab bar icons

This commit is contained in:
Ryan Nystrom
2017-09-04 11:57:34 -04:00
parent fe157a7532
commit 4fe95bbc25
21 changed files with 139 additions and 4 deletions

View File

@@ -20,7 +20,8 @@ func newSettingsRootViewController(
first.sessionManager = sessionManager
first.rootNavigationManager = rootNavigationManager
nav.tabBarItem.title = NSLocalizedString("Settings", comment: "")
nav.tabBarItem.image = UIImage(named: "gear")
nav.tabBarItem.image = UIImage(named: "tab-gear")
nav.tabBarItem.selectedImage = UIImage(named: "tab-gear-selected")
}
return controller
@@ -33,14 +34,16 @@ func newNotificationsRootViewController(client: GithubClient) -> UIViewControlle
controller.navigationItem.backBarButtonItem = UIBarButtonItem(title: " ", style: .plain, target: nil, action: nil)
let nav = UINavigationController(rootViewController: controller)
nav.tabBarItem.title = title
nav.tabBarItem.image = UIImage(named: "inbox")
nav.tabBarItem.image = UIImage(named: "tab-inbox")
nav.tabBarItem.selectedImage = UIImage(named: "tab-inbox-selected")
return nav
}
func newSearchRootViewController(client: GithubClient) -> UIViewController {
let controller = SearchViewController(client: client)
let nav = UINavigationController(rootViewController: controller)
nav.tabBarItem.image = UIImage(named: "search")
nav.tabBarItem.title = NSLocalizedString("Search", comment: "")
nav.tabBarItem.image = UIImage(named: "tab-search")
nav.tabBarItem.selectedImage = UIImage(named: "tab-search-selected")
return nav
}

BIN
Design/tabs.psd Normal file

Binary file not shown.

View File

@@ -0,0 +1,22 @@
{
"images" : [
{
"idiom" : "universal",
"scale" : "1x"
},
{
"idiom" : "universal",
"filename" : "tab-gear-selected@2x.png",
"scale" : "2x"
},
{
"idiom" : "universal",
"filename" : "tab-gear-selected@3x.png",
"scale" : "3x"
}
],
"info" : {
"version" : 1,
"author" : "xcode"
}
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 944 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.3 KiB

View File

@@ -0,0 +1,22 @@
{
"images" : [
{
"idiom" : "universal",
"scale" : "1x"
},
{
"idiom" : "universal",
"filename" : "tab-gear@2x.png",
"scale" : "2x"
},
{
"idiom" : "universal",
"filename" : "tab-gear@3x.png",
"scale" : "3x"
}
],
"info" : {
"version" : 1,
"author" : "xcode"
}
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.5 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.1 KiB

View File

@@ -0,0 +1,22 @@
{
"images" : [
{
"idiom" : "universal",
"scale" : "1x"
},
{
"idiom" : "universal",
"filename" : "tab-inbox-selected@2x.png",
"scale" : "2x"
},
{
"idiom" : "universal",
"filename" : "tab-inbox-selected@3x.png",
"scale" : "3x"
}
],
"info" : {
"version" : 1,
"author" : "xcode"
}
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 724 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 1002 B

View File

@@ -0,0 +1,22 @@
{
"images" : [
{
"idiom" : "universal",
"scale" : "1x"
},
{
"idiom" : "universal",
"filename" : "tab-inbox@2x.png",
"scale" : "2x"
},
{
"idiom" : "universal",
"filename" : "tab-inbox@3x.png",
"scale" : "3x"
}
],
"info" : {
"version" : 1,
"author" : "xcode"
}
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 864 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.2 KiB

View File

@@ -0,0 +1,22 @@
{
"images" : [
{
"idiom" : "universal",
"scale" : "1x"
},
{
"idiom" : "universal",
"filename" : "tab-search-selected@2x.png",
"scale" : "2x"
},
{
"idiom" : "universal",
"filename" : "tab-search-selected@3x.png",
"scale" : "3x"
}
],
"info" : {
"version" : 1,
"author" : "xcode"
}
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 866 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.3 KiB

View File

@@ -0,0 +1,22 @@
{
"images" : [
{
"idiom" : "universal",
"scale" : "1x"
},
{
"idiom" : "universal",
"filename" : "tab-search@2x.png",
"scale" : "2x"
},
{
"idiom" : "universal",
"filename" : "tab-search@3x.png",
"scale" : "3x"
}
],
"info" : {
"version" : 1,
"author" : "xcode"
}
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.0 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.6 KiB

View File

@@ -32,7 +32,7 @@
</dict>
</array>
<key>CFBundleVersion</key>
<string>1652</string>
<string>1655</string>
<key>ITSAppUsesNonExemptEncryption</key>
<false/>
<key>LSApplicationQueriesSchemes</key>