gpt4 book ai didi

org.uberfire.client.workbench.part.WorkbenchPartPresenter.getTitle()方法的使用及代码示例

转载 作者:知者 更新时间:2024-03-24 12:55:05 26 4
gpt4 key购买 nike

本文整理了Java中org.uberfire.client.workbench.part.WorkbenchPartPresenter.getTitle()方法的一些代码示例,展示了WorkbenchPartPresenter.getTitle()的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。WorkbenchPartPresenter.getTitle()方法的具体详情如下:
包路径:org.uberfire.client.workbench.part.WorkbenchPartPresenter
类名称:WorkbenchPartPresenter
方法名:getTitle

WorkbenchPartPresenter.getTitle介绍

[英]Returns the text that a panel may choose to display beside this part's title. For example, MultiTabWorkbenchPanelPresenter uses this text for the tab's label.
[中]返回面板可能选择显示在此部件标题旁边的文本。例如,MultiTabWorkbenchPanelPresenter使用此文本作为选项卡的标签。

代码示例

代码示例来源:origin: org.uberfire/uberfire-workbench-client-views-patternfly

public void addPart(final WorkbenchPartPresenter.View view) {
  final PartDefinition part = view.getPresenter().getDefinition();
  partView.put(part,
         view);
  buildWidgets(part,
         view.getPresenter().getTitle(),
         view.getPresenter().getTitleDecoration());
  if (partTitles.size() == 1) {
    selectPart(part);
  }
}

代码示例来源:origin: org.uberfire/uberfire-workbench-client-views-patternfly

void setupCSSLocators(WorkbenchPartPresenter.View view,
               FlowPanel panel) {
  if (view.getPresenter() != null || view.getPresenter().getTitle() != null) {
    panel.getElement().addClassName(CSSLocatorsUtils.buildLocator("qe-list-bar-content",
                                   view.getPresenter().getTitle()));
  }
}

代码示例来源:origin: kiegroup/appformer

public void addPart(final WorkbenchPartPresenter.View view) {
  final PartDefinition part = view.getPresenter().getDefinition();
  partView.put(part,
         view);
  buildWidgets(part,
         view.getPresenter().getTitle(),
         view.getPresenter().getTitleDecoration());
  if (partTitles.size() == 1) {
    selectPart(part);
  }
}

代码示例来源:origin: kiegroup/appformer

void setupCSSLocators(WorkbenchPartPresenter.View view,
               FlowPanel panel) {
  if (view.getPresenter() != null || view.getPresenter().getTitle() != null) {
    panel.getElement().addClassName(CSSLocatorsUtils.buildLocator("qe-list-bar-content",
                                   view.getPresenter().getTitle()));
  }
}

代码示例来源:origin: org.uberfire/uberfire-workbench-client-views-patternfly

@Override
public void addPart(final WorkbenchPartPresenter.View view) {
  final PartDefinition partDefinition = view.getPresenter().getDefinition();
  if (parts.containsKey(partDefinition) == false) {
    final MultiScreenView screen = multiScreenViews.get();
    screen.setContent(view);
    screen.setTitle(view.getPresenter().getTitle());
    if (view.getPresenter().getTitleDecoration() != null) {
      screen.setTitleWidget(view.getPresenter().getTitleDecoration());
    }
    if (parts.isEmpty() && partDefinition.getParentPanel().getPosition() == null) {
      screen.disableClose();
    }
    screen.setCloseHandler(() -> panelManager.closePart(partDefinition));
    Optional.ofNullable(view.getPresenter().getMenus())
        .ifPresent(menus -> menus.getItems().stream().map(menuBuilder)
            .forEachOrdered(e -> e.ifPresent(element -> screen.addMenus(element)))
    );
    content.appendChild(screen.getElement());
    parts.put(partDefinition,
         screen);
  }
  selectPart(partDefinition);
}

代码示例来源:origin: org.uberfire/uberfire-workbench-client-views-bs2

/**
 * Subroutine of {@link #createTab(View, boolean, int, int)}. Exposed for testing. Never call this except from
 * within the other createTab method.
 */
Tab createTab( final WorkbenchPartPresenter.View view,
        final boolean isActive ) {
  Tab tab = new Tab();
  tab.setHeading( view.getPresenter().getTitle() );
  tab.setActive( isActive );
  return tab;
}

代码示例来源:origin: org.uberfire/uberfire-workbench-client-views-bs2

@Override
public void addPart( final WorkbenchPartPresenter.View view ) {
  final PartDefinition partDefinition = view.getPresenter().getDefinition();
  if ( parts.contains( partDefinition ) ) {
    selectPart( partDefinition );
    return;
  }
  menuArea.setVisible( true );
  parts.add( partDefinition );
  final FlowPanel panel = new FlowPanel();
  Layouts.setToFillParent( panel );
  panel.add( view );
  content.add( panel );
  // IMPORTANT! if you change what goes in this map, update the remove(PartDefinition) method
  partContentView.put( partDefinition, panel );
  final Widget title = buildTitle( view.getPresenter().getTitle(), view.getPresenter().getTitleDecoration() );
  partTitle.put( partDefinition, title );
  title.ensureDebugId( DEBUG_TITLE_PREFIX + view.getPresenter().getTitle() );
  if ( isDndEnabled ) {
    dndManager.makeDraggable( view, title );
  }
  scheduleResize();
}

代码示例来源:origin: org.uberfire/uberfire-workbench-client-views-patternfly

@Override
public void addPart(final WorkbenchPartPresenter.View view) {
  if (!tabIndex.containsKey(view)) {
    final TabPanelEntry tab = tabPanel.addItem(view.getPresenter().getTitle(),
                          view.asWidget());
    resizeIfNeeded(view.asWidget());
    tabIndex.put(view,
           tab);
    tabInvertedIndex.put(tab,
               view);
    partTabIndex.put(view.getPresenter().getDefinition(),
             tab);
    dndManager.makeDraggable(view,
                 tab.getTabWidget());
    addCloseToTab(tab);
    parts.add(view.getPresenter());
    tabIndex.put(view,
           tab);
    updateDisplayedTabs();
  }
}

代码示例来源:origin: kiegroup/appformer

@Override
public void addPart(final WorkbenchPartPresenter.View view) {
  final PartDefinition partDefinition = view.getPresenter().getDefinition();
  if (parts.containsKey(partDefinition) == false) {
    final MultiScreenView screen = multiScreenViews.get();
    screen.setContent(view);
    screen.setTitle(view.getPresenter().getTitle());
    if (view.getPresenter().getTitleDecoration() != null) {
      screen.setTitleWidget(view.getPresenter().getTitleDecoration());
    }
    if (parts.isEmpty() && partDefinition.getParentPanel().getPosition() == null) {
      screen.disableClose();
    }
    screen.setCloseHandler(() -> panelManager.closePart(partDefinition));
    Optional.ofNullable(view.getPresenter().getMenus())
        .ifPresent(menus -> menus.getItems().stream().map(menuBuilder)
            .forEachOrdered(e -> e.ifPresent(element -> screen.addMenus(element)))
    );
    content.appendChild(screen.getElement());
    parts.put(partDefinition,
         screen);
  }
  selectPart(partDefinition);
}

代码示例来源:origin: kiegroup/appformer

@Override
public void addPart(final WorkbenchPartPresenter.View view) {
  if (!tabIndex.containsKey(view)) {
    final TabPanelEntry tab = tabPanel.addItem(view.getPresenter().getTitle(),
                          view.asWidget());
    resizeIfNeeded(view.asWidget());
    tabIndex.put(view,
           tab);
    tabInvertedIndex.put(tab,
               view);
    partTabIndex.put(view.getPresenter().getDefinition(),
             tab);
    dndManager.makeDraggable(view,
                 tab.getTabWidget());
    addCloseToTab(tab);
    parts.add(view.getPresenter());
    tabIndex.put(view,
           tab);
    updateDisplayedTabs();
  }
}

代码示例来源:origin: kiegroup/appformer

final PanelDefinition sourcePanel = sourceView.getPresenter().getDefinition().getParentPanel();
final PlaceRequest place = sourcePart.getPlace();
final String title = sourceView.getPresenter().getTitle();
final IsWidget titleDecoration = sourceView.getPresenter().getTitleDecoration();
final String contextId = sourceView.getPresenter().getContextId();

代码示例来源:origin: org.uberfire/uberfire-workbench-client-views-bs2

PartChooserList() {
  initWidget( panel );
  if ( currentPart != null ) {
    final String ctitle = ( (WorkbenchPartPresenter.View) partContentView.get( currentPart.getK1() ).getWidget( 0 ) ).getPresenter().getTitle();
    panel.add( new NavLink( ctitle ) );
    for ( final PartDefinition part : parts ) {
      final String title = ( (WorkbenchPartPresenter.View) partContentView.get( part ).getWidget( 0 ) ).getPresenter().getTitle();
      panel.add( new NavLink( title ) {{
        addClickHandler( new ClickHandler() {
          @Override
          public void onClick( final ClickEvent event ) {
            selectPart( part );
          }
        } );
      }} );
    }
  }
  onResize();
}

代码示例来源:origin: org.uberfire/uberfire-workbench-client-views-bs2

newDropdownContents.addFirst( tabWidget );
if ( tabWidget == selectedTab ) {
  dropdownTab.setText( tabInvertedIndex.get( selectedTab ).getPresenter().getTitle() );

26 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com