def _get_widget_selections(widgets, widget_selections):
	"""Return lists of widgets that are selected and unselected.
    Args:
        widgets (list):
            A list of widgets that we have registered already.
        widget_selections (dict):
            A dictionary mapping widgets
            (:py:class:`reviewboard.admin.widgets.Widget`) to whether or not
            they are selected (as a :py:class:`unicode`).
    Returns:
        tuple of list:
        A 2-tuple containing a list of selected widgets (to display
        on the dashboard) and a list of the unselected widgets.
    """
	selected_widgets = []
	unselected_widgets = []
	if widget_selections:
		for widget in widgets:
			if widget_selections.get(widget.widget_id) == "1":
				selected_widgets.append(widget)
			else:
				unselected_widgets.append(widget)
	else:
		selected_widgets = widgets
		unselected_widgets = None
	return selected_widgets, unselected_widgets