@Override @Nullable public Object getData(@NonNls final String dataId) { if (myDataProvider != null) { final Object value = myDataProvider.getData(dataId); if (value != null) return value; } if (SwitchProvider.KEY.getName().equals(dataId) && myOwnSwitchProvider) { return this; } if (QuickActionProvider.KEY.getName().equals(dataId)) { return this; } return NAVIGATION_ACTIONS_KEY.is(dataId) ? this : null; }
@Override public Object getData(@NonNls String dataId) { if (SwitchProvider.KEY.getName().equals(dataId)) { return myContentUI; } if (QuickActionProvider.KEY.getName().equals(dataId)) { return myContentUI; } if (RunnerContentUi.KEY.getName().equals(dataId)) { return myContentUI; } final DataProvider provider = DataManager.getDataProvider(this); return provider != null ? provider.getData(dataId) : null; }
@Override @Nullable public Object getData(@Nonnull @NonNls final Key<?> dataId) { if (myDataProvider != null) { final Object value = myDataProvider.getData(dataId); if (value != null) return value; } if (SwitchProvider.KEY == dataId && myOwnSwitchProvider) { return this; } if (QuickActionProvider.KEY == dataId) { return this; } return NAVIGATION_ACTIONS_KEY == dataId ? this : null; }
@Nullable public Object getData(@NonNls String dataId) { if (PlatformDataKeys.TOOL_WINDOW.is(dataId)) return myWindow; if (CloseAction.CloseTarget.KEY.is(dataId)) { return computeCloseTarget(); } if (SwitchProvider.KEY.is(dataId) && myType == ToolWindowContentUiType.TABBED) { return this; } return null; }
@Override public List<SwitchTarget> getTargets(boolean onlyVisible, boolean originalProvider) { if (myUI instanceof SwitchProvider) { return ((SwitchProvider)myUI).getTargets(onlyVisible, false); } return new SmartList<SwitchTarget>(); }
@Nullable @Override public Object getData(@NonNls String dataId) { if (SwitchProvider.KEY.is(dataId) || QuickActionProvider.KEY.is(dataId) || RunnerContentUi.KEY.is(dataId)) { return myContentUI; } return null; }
@Override public List<SwitchTarget> getTargets(boolean onlyVisible, boolean originalProvider) { if (myUI instanceof SwitchProvider) { return ((SwitchProvider)myUI).getTargets(onlyVisible, false); } return new ArrayList<SwitchTarget>(); }
@Override public SwitchTarget getCurrentTarget() { if (myUI instanceof SwitchProvider) { return ((SwitchProvider)myUI).getCurrentTarget(); } return null; }
@Override public JComponent getComponent() { if (myUI instanceof SwitchProvider) { return myUI.getComponent(); } return this; }
@Override @Nullable public Object getData(@Nonnull @NonNls Key<?> dataId) { if (PlatformDataKeys.TOOL_WINDOW == dataId) return myWindow; if (CloseAction.CloseTarget.KEY == dataId) { return computeCloseTarget(); } if (SwitchProvider.KEY == dataId && myType == ToolWindowContentUiType.TABBED) { return this; } return null; }
@Nullable @Override public Object getData(@Nonnull @NonNls Key dataId) { if (SwitchProvider.KEY == dataId || QuickActionProvider.KEY == dataId || RunnerContentUi.KEY == dataId) { return myContentUI; } return null; }
@Override @javax.annotation.Nullable public Object getData(@Nonnull @NonNls Key<?> dataId) { if (PlatformDataKeys.TOOL_WINDOW == dataId) return myWindow; if (CloseAction.CloseTarget.KEY == dataId) { return computeCloseTarget(); } if (SwitchProvider.KEY == dataId && myType == ToolWindowContentUiType.TABBED) { return this; } return null; }
@Override public JBTabs setAdditionalSwitchProviderWhenOriginal(SwitchProvider delegate) { mySwitchDelegate = delegate; return this; }
@Override public SwitchTarget getCurrentTarget() { return myUI instanceof SwitchProvider ? ((SwitchProvider)myUI).getCurrentTarget() : null; }
@Override public JComponent getComponent() { return myUI instanceof SwitchProvider ? myUI.getComponent() : this; }
@Override public boolean isCycleRoot() { return myUI instanceof SwitchProvider && ((SwitchProvider)myUI).isCycleRoot(); }
JBTabs setAdditionalSwitchProviderWhenOriginal(SwitchProvider delegate);