 		guard
 			let navigationController = selectedViewController as? UINavigationController,
 			let tableViewController = navigationController.viewControllers.last as? UITableViewController
+			where selectedIndex == tabBar.items?.indexOf(item)
 		else {
 			return
 		}
 
+		cachedSelectedIndex = selectedIndex
+
 		let tableView = tableViewController.tableView
 
-		tableView.setContentOffset(CGPoint(x: 0, y: -tableView.contentInset.top), animated: true)
+		tableViewController.tableView.setContentOffset(CGPoint(x: 0, y: -tableView.contentInset.top), animated: true)
 	}
 }
 

		dashboardViewController.popToRootViewControllerAnimated(false)
		(dashboardViewController.topViewController as! DashboardViewController).gotoBookmark(selectedId)

		selectedIndex = 0
	}
}

class MainViewController: UITabBarController {
	private var statusBarBackgroundView: UIView!
	private var observer: AnyObject!
	private var cachedSelectedIndex: Int = 0

	override func viewDidLoad() {
		super.viewDidLoad()
