'Sets the layout of the navigation topbar on a Reddit.  The result
is a list of menus which will be rendered in order and
displayed at the top of the Reddit.'

def build_toolbars(self):

    if (c.site == Friends):
        main_buttons = [NamedButton('new', dest='', aliases=['/hot']), NamedButton('comments'), NamedButton('gilded')]
    else:
        main_buttons = [NamedButton('hot', dest='', aliases=['/hot']), NamedButton('new'), NamedButton('rising'), NamedButton('controversial'), NamedButton('top')]
        if c.site.allow_gilding:
            main_buttons.append(NamedButton('gilded', aliases=['/comments/gilded']))
        mod = False
        if c.user_is_loggedin:
            mod = bool((c.user_is_admin or c.site.is_moderator_with_perms(c.user, 'wiki')))
        if (c.site._should_wiki and ((c.site.wikimode != 'disabled') or mod)):
            if (not g.disable_wiki):
                main_buttons.append(NavButton('wiki', 'wiki'))
        if (isinstance(c.site, (Subreddit, DefaultSR, MultiReddit)) and c.site.allow_ads):
            main_buttons.append(NavButton(menu.promoted, 'ads'))
    more_buttons = []
    if (c.user_is_loggedin and c.site.allow_ads):
        if c.user_is_sponsor:
            sponsor_button = NavButton(menu.sponsor, dest='/sponsor', sr_path=False)
            more_buttons.append(sponsor_button)
        elif c.user.pref_show_promote:
            more_buttons.append(NavButton(menu.promote, 'promoted', False))
    if (len(more_buttons) == 1):
        main_buttons.append(more_buttons[0])
        more_buttons = []
    toolbar = [NavMenu(main_buttons, type='tabmenu')]
    if more_buttons:
        toolbar.append(NavMenu(more_buttons, title=menu.more, type='tabdrop'))
    if (not isinstance(c.site, DefaultSR)):
        func = 'subreddit'
        if isinstance(c.site, DomainSR):
            func = 'domain'
        toolbar.insert(0, PageNameNav(func))
    return toolbar
