use of org.rstudio.core.client.command.Handler in project rstudio by rstudio.
the class Workbench method onSetWorkingDirToProjectDir.
@Handler
void onSetWorkingDirToProjectDir() {
FileSystemItem projectDir = session_.getSessionInfo().getActiveProjectDir();
if (projectDir != null) {
consoleDispatcher_.executeSetWd(projectDir, false);
eventBus_.fireEvent(new DirectoryNavigateEvent(projectDir, true));
}
}
use of org.rstudio.core.client.command.Handler in project rstudio by rstudio.
the class PaneManager method onLayoutZoomCurrentPane.
@Handler
public void onLayoutZoomCurrentPane() {
LogicalWindow activeWindow = getActiveLogicalWindow();
if (activeWindow == null)
return;
toggleWindowZoom(activeWindow, null);
}
use of org.rstudio.core.client.command.Handler in project rstudio by rstudio.
the class Shell method onConsoleClear.
@Handler
void onConsoleClear() {
// clear output
view_.clearOutput();
// notify server
server_.resetConsoleActions(new VoidServerRequestCallback());
// if we don't bounce setFocus the menu retains focus
Scheduler.get().scheduleDeferred(new ScheduledCommand() {
public void execute() {
view_.getInputEditorDisplay().setFocus(true);
}
});
}
use of org.rstudio.core.client.command.Handler in project rstudio by rstudio.
the class PaneManager method onActivateConsolePane.
@Handler
public void onActivateConsolePane() {
// Ensure that the console window is activated
LogicalWindow consoleWindow = getConsoleLogicalWindow();
if (consoleWindow.getState().equals(WindowState.MINIMIZE)) {
WindowStateChangeEvent event = new WindowStateChangeEvent(WindowState.NORMAL);
consoleWindow.onWindowStateChange(event);
}
// created.
if (consoleTabPanel_.isEmpty()) {
consolePane_.focus();
} else {
LogicalWindow activeWindow = getActiveLogicalWindow();
if (consoleWindow.equals(activeWindow)) {
consoleTabPanel_.selectNextTab();
} else {
consoleTabPanel_.selectTab(consoleTabPanel_.getSelectedIndex());
}
}
}
use of org.rstudio.core.client.command.Handler in project rstudio by rstudio.
the class WorkbenchScreen method onLayoutZoomHelp.
@Handler
void onLayoutZoomHelp() {
paneManager_.zoomTab(Tab.Help);
fireEventDelayed(new ActivateHelpEvent(), 200);
}
Aggregations