rstudio/shiny — pull request #348 by jjallaire (2013-12-24 14:20:35+00:00)
Title: add id parameter to navbarPage (support for tab input binding)

There are two changes required to support tab input bindings for navbarPage:

1. Rather than looking for the "nav-tabs" class, add a new sentinel class ("shiny-tab-input") used for locating the input binding (note this also allows input bindings to work for tabsetPanels with style "pills" and navlistPanel).

2. Update the input binding to account for the fact that nested tabPanel instances exist when navbarMenu is used. For getValue I've confirmed that this works as expected with both nested and non-nested tabPanels. However, for setValue I'm unsure what the correct incantation in server.R is to programmatically select a tabPanel. I've checked in the code I think will work in setValue however this code is **untested**. Hopefully the person reviewing this PR will know how to test it :-)