Search in sources :

Example 1 with WindowFrame

use of org.rstudio.core.client.theme.WindowFrame in project rstudio by rstudio.

the class PaneManager method createTabSet.

private Triad<LogicalWindow, WorkbenchTabPanel, MinimizedModuleTabLayoutPanel> createTabSet(String persisterName, ArrayList<Tab> tabs) {
    final WindowFrame frame = new WindowFrame();
    final MinimizedModuleTabLayoutPanel minimized = new MinimizedModuleTabLayoutPanel();
    final LogicalWindow logicalWindow = new LogicalWindow(frame, minimized);
    final WorkbenchTabPanel tabPanel = new WorkbenchTabPanel(frame, logicalWindow);
    populateTabPanel(tabs, tabPanel, minimized);
    frame.setFillWidget(tabPanel);
    minimized.addSelectionHandler(new SelectionHandler<Integer>() {

        public void onSelection(SelectionEvent<Integer> integerSelectionEvent) {
            int tab = integerSelectionEvent.getSelectedItem();
            tabPanel.selectTab(tab);
        }
    });
    tabPanel.addSelectionHandler(new SelectionHandler<Integer>() {

        public void onSelection(SelectionEvent<Integer> integerSelectionEvent) {
            int index = integerSelectionEvent.getSelectedItem();
            WorkbenchTab selected = tabPanel.getTab(index);
            lastSelectedTab_ = workbenchTabToTab(selected);
            session_.persistClientState();
        }
    });
    new SelectedTabStateValue(persisterName, tabPanel);
    return new Triad<LogicalWindow, WorkbenchTabPanel, MinimizedModuleTabLayoutPanel>(logicalWindow, tabPanel, minimized);
}
Also used : LogicalWindow(org.rstudio.core.client.layout.LogicalWindow) MinimizedWindowFrame(org.rstudio.core.client.theme.MinimizedWindowFrame) PrimaryWindowFrame(org.rstudio.core.client.theme.PrimaryWindowFrame) WindowFrame(org.rstudio.core.client.theme.WindowFrame) MinimizedModuleTabLayoutPanel(org.rstudio.core.client.theme.MinimizedModuleTabLayoutPanel) Triad(org.rstudio.core.client.Triad)

Example 2 with WindowFrame

use of org.rstudio.core.client.theme.WindowFrame in project rstudio by rstudio.

the class PaneManager method createSource.

private LogicalWindow createSource() {
    WindowFrame sourceFrame = new WindowFrame();
    sourceFrame.setFillWidget(source_.asWidget());
    source_.forceLoad();
    return sourceLogicalWindow_ = new LogicalWindow(sourceFrame, new MinimizedWindowFrame("Source"));
}
Also used : MinimizedWindowFrame(org.rstudio.core.client.theme.MinimizedWindowFrame) LogicalWindow(org.rstudio.core.client.layout.LogicalWindow) MinimizedWindowFrame(org.rstudio.core.client.theme.MinimizedWindowFrame) PrimaryWindowFrame(org.rstudio.core.client.theme.PrimaryWindowFrame) WindowFrame(org.rstudio.core.client.theme.WindowFrame)

Aggregations

LogicalWindow (org.rstudio.core.client.layout.LogicalWindow)2 MinimizedWindowFrame (org.rstudio.core.client.theme.MinimizedWindowFrame)2 PrimaryWindowFrame (org.rstudio.core.client.theme.PrimaryWindowFrame)2 WindowFrame (org.rstudio.core.client.theme.WindowFrame)2 Triad (org.rstudio.core.client.Triad)1 MinimizedModuleTabLayoutPanel (org.rstudio.core.client.theme.MinimizedModuleTabLayoutPanel)1