Class DefaultListViewMenuPopupBuilder
java.lang.Object
de.hybris.platform.cockpit.model.listview.impl.DefaultListViewMenuPopupBuilder
- All Implemented Interfaces:
ListViewMenuPopupBuilder
- Direct Known Subclasses:
DynamicListViewMenuPopupBuilder
Default implementation of
ListViewHeaderColumnMenuPopupBuilder interface.-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected Comparator<ColumnDescriptor>The column comparator.protected final org.zkoss.zul.MenupopupThe new header popup.protected static final Stringprotected static final StringThe Constant LISTVIEW_COLUMN_MENU_HIDECOLUMN.protected static final StringThe Constant LISTVIEW_COLUMN_MENU_OTHERLANGUAGES.protected static final StringThe Constant LISTVIEW_COLUMN_MENU_RESET.protected static final StringThe Constant LISTVIEW_COLUMN_MENU_SHOWCOLUMN.static final String -
Constructor Summary
ConstructorsConstructorDescriptionInstantiates a new default list view header column menu popup builder. -
Method Summary
Modifier and TypeMethodDescriptionvoidaddAllColumnElement(UIListView listView, org.zkoss.zul.Menupopup columnMenuPopup, int colIndex) voidaddAllColumnLogic(UIListView listView, org.zkoss.zul.Menupopup allColumnsMenuPopup, int colIndex) voidaddHideColumnElement(UIListView listView, int columnIndex) Adds the hide column element.voidaddLocalizedColumnElement(UIListView listView, ColumnDescriptor descriptor) Adds the localized column element.voidaddResetColumnElement(UIListView listView) Adds the reset column element.voidAdds the separator.voidaddShowColumnElement(UIListView listView, int colIndex, boolean addResetItem) Adds the show column element.voidaddShowColumnElement(UIListView listView, ColumnLayoutComponent mainColumnComponent, boolean addResetItem) Adds the show column element.voidaddShowColumnLogic(UIListView listView, org.zkoss.zul.Menupopup hiddenColumnMenuPopup, int colIndex, boolean open) Adds the show column logic.org.zkoss.zul.MenupopupbuildBackgroundColumnMenuPopup(UIListView listView, ColumnLayoutComponent mainColumnComponent) Builds menu popup for use in ListView's background column.intbuildHiddenColumnMenupopup(UIListView listView, ColumnGroup group, org.zkoss.zul.Menupopup menuPopup, int colIndex) Builds the hidden column menupopup.org.zkoss.zul.MenupopupbuildStandardColumnMenuPopup(UIListView listView, ColumnDescriptor descriptor, int columnIndex) Builds the standard column menu popup.protected org.zkoss.zul.MenupopupcreateNewMenuPopup(String menuLabel, org.zkoss.zul.Menupopup menuPopup) Creates the new menu popup attached toMenupopupobject passed as parameter.protected Comparator<ColumnDescriptor>Gets the column comparator.
-
Field Details
-
ON_LATER
- See Also:
-
LISTVIEW_COLUMN_MENU_HIDECOLUMN
The Constant LISTVIEW_COLUMN_MENU_HIDECOLUMN.- See Also:
-
LISTVIEW_COLUMN_MENU_OTHERLANGUAGES
The Constant LISTVIEW_COLUMN_MENU_OTHERLANGUAGES.- See Also:
-
LISTVIEW_COLUMN_MENU_RESET
The Constant LISTVIEW_COLUMN_MENU_RESET.- See Also:
-
LISTVIEW_COLUMN_MENU_SHOWCOLUMN
The Constant LISTVIEW_COLUMN_MENU_SHOWCOLUMN.- See Also:
-
LISTVIEW_COLUMN_MENU_ALL_COLUMNS
- See Also:
-
headerPopup
protected final org.zkoss.zul.Menupopup headerPopupThe new header popup. -
colComparator
The column comparator.
-
-
Constructor Details
-
DefaultListViewMenuPopupBuilder
public DefaultListViewMenuPopupBuilder()Instantiates a new default list view header column menu popup builder.
-
-
Method Details
-
addHideColumnElement
Adds the hide column element.- Parameters:
columnIndex- the column indexlistView- the list view
-
addLocalizedColumnElement
Adds the localized column element.- Parameters:
descriptor- the descriptor
-
addResetColumnElement
Adds the reset column element. -
addSeparator
public void addSeparator()Adds the separator. -
addShowColumnElement
public void addShowColumnElement(UIListView listView, ColumnLayoutComponent mainColumnComponent, boolean addResetItem) Adds the show column element.- Parameters:
mainColumnComponent- the main column componentaddResetItem- the add reset itemlistView- the list view
-
addShowColumnElement
Adds the show column element.- Parameters:
colIndex- the col indexaddResetItem- the add reset itemlistView- the list view
-
addShowColumnLogic
public void addShowColumnLogic(UIListView listView, org.zkoss.zul.Menupopup hiddenColumnMenuPopup, int colIndex, boolean open) Adds the show column logic.- Parameters:
hiddenColumnMenuPopup- the hidden column menu popupcolIndex- the col indexopen- true in case of openinglistView- the list view
-
addAllColumnElement
public void addAllColumnElement(UIListView listView, org.zkoss.zul.Menupopup columnMenuPopup, int colIndex) -
addAllColumnLogic
public void addAllColumnLogic(UIListView listView, org.zkoss.zul.Menupopup allColumnsMenuPopup, int colIndex) -
buildBackgroundColumnMenuPopup
public org.zkoss.zul.Menupopup buildBackgroundColumnMenuPopup(UIListView listView, ColumnLayoutComponent mainColumnComponent) Description copied from interface:ListViewMenuPopupBuilderBuilds menu popup for use in ListView's background column.- Specified by:
buildBackgroundColumnMenuPopupin interfaceListViewMenuPopupBuildermainColumnComponent- the main column component- Returns:
- the menupopup
-
buildHiddenColumnMenupopup
public int buildHiddenColumnMenupopup(UIListView listView, ColumnGroup group, org.zkoss.zul.Menupopup menuPopup, int colIndex) Builds the hidden column menupopup.- Parameters:
group- the groupmenuPopup- the menu popupcolIndex- the col indexlistView- the list view- Returns:
- the int
-
buildStandardColumnMenuPopup
public org.zkoss.zul.Menupopup buildStandardColumnMenuPopup(UIListView listView, ColumnDescriptor descriptor, int columnIndex) Description copied from interface:ListViewMenuPopupBuilderBuilds the standard column menu popup.- Specified by:
buildStandardColumnMenuPopupin interfaceListViewMenuPopupBuilderdescriptor- the descriptorcolumnIndex- the column index- Returns:
- the menupopup
-
createNewMenuPopup
protected org.zkoss.zul.Menupopup createNewMenuPopup(String menuLabel, org.zkoss.zul.Menupopup menuPopup) Creates the new menu popup attached toMenupopupobject passed as parameter.- Parameters:
menuLabel- the label for newly created MenumenuPopup- the menu popup object for which newly created menu popup should be attached- Returns:
- the newly created menu popup object
-
getColumnComparator
Gets the column comparator.- Returns:
- the column comparator
-