|
JIDE 3.4.0 | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectcom.jidesoft.plaf.TableHeaderUIDelegate
com.jidesoft.plaf.basic.BasicCellStyleTableHeaderUIDelegate
com.jidesoft.plaf.basic.BasicSortableTableHeaderUIDelegate
com.jidesoft.plaf.basic.BasicEditableTableHeaderUIDelegate
com.jidesoft.plaf.basic.BasicAutoFilterTableHeaderUIDelegate
public class BasicAutoFilterTableHeaderUIDelegate
The UIDelegate class for AutoFilterTableHeader works for all L&Fs.
| Nested Class Summary | |
|---|---|
class |
BasicAutoFilterTableHeaderUIDelegate.DropDownSwingWorker
|
| Field Summary | |
|---|---|
protected Object |
HIDE_POPUP_KEY
|
| Fields inherited from class com.jidesoft.plaf.basic.BasicCellStyleTableHeaderUIDelegate |
|---|
_header, _mouseXOffset, _rendererPane |
| Constructor Summary | |
|---|---|
BasicAutoFilterTableHeaderUIDelegate(JTableHeader header,
CellRendererPane rendererPane)
|
|
| Method Summary | |
|---|---|
protected void |
applyFilter(Filter filter,
int columnIndex)
Applies the filter to the specified column index of the FilterableTableModel. |
protected void |
applyFilter(Filter filter,
int columnIndex,
boolean clearFirst)
Applies the filter to the specified column index of the FilterableTableModel. |
protected Point |
calculatePopupLocation()
calculate the popup location. |
protected String |
convertElementToString(Object item)
Converts the element from object to string. |
protected String |
convertElementToString(Object item,
boolean isArray,
ObjectGrouper grouper)
Converts element to string. |
protected String |
convertElementToString(Object item,
ConverterContext context)
Converts the element from object to string. |
protected PopupPanel |
createCheckBoxListChooserPanel(TableModel tableModel,
int columnIndex,
Object[] possibleValues,
ObjectGrouper objectGrouper,
DefaultComboBoxModel comboBoxModel)
Create a multiple selection popup panel (check box list chooser panel). |
protected CustomFilterEditor |
createCustomFilterEditor(FilterFactoryManager filterFactoryManager,
Class<?> type,
ConverterContext converterContext,
Object[] possibleValues)
Creates the CustomFilterEditor used in the FieldBox's custom filter drop down list. |
protected StandardDialog |
createCustomFilterEditorDialog(Container container,
String title,
CustomFilterEditor filterEditor)
Creates the CustomFilterEditorDialog when the "(Custom...)" is clicked in the drop down list of the AutoFilterBox. |
protected PopupPanel |
createListChooserPanel(TableModel tableModel,
int columnIndex,
Object[] possibleValues,
ObjectGrouper objectGrouper,
DefaultComboBoxModel comboBoxModel)
Create a single selection popup panel (list chooser panel). |
protected PopupPanel |
createPopupPanel(TableModel tableModel,
int columnIndex,
Object[] possibleValues)
Create the popup panel while the customer clicks the filter icon. |
protected JidePopup |
createPopupWindow()
Creates the popup window. |
protected void |
customizeList(JList list)
Create Searchable instance for drop down list in AutoFilterTableHeader. |
protected Filter[] |
getCurrentFilters()
Gets the current filters in the FilterableTableModel for the column this AutoFilterBox is working on. |
protected int[] |
getFilterCellDecoratorProperties()
Gets the properties which will help FilterableTableHeaderCellDecorator paints. |
protected TableCellRenderer |
getHeaderRenderer(TableColumn aColumn)
Gets header renderer from the TableColumn instance and the column index. |
Object[] |
getPossibleValues(ObjectGrouper objectGrouper,
Object[] values,
Comparator comparator)
Gets possible values under the object grouper. |
protected boolean |
hasFocus(int columnIndex)
Checks if the column index should have focus. |
void |
hidePopup()
Causes the combo box to close its popup window. |
boolean |
isPopupVisible()
Determines the visibility of the popup. |
void |
mouseClicked(MouseEvent e)
|
void |
mouseExited(MouseEvent e)
|
void |
mouseMoved(MouseEvent e)
|
protected boolean |
mouseOverFilterButton(Point p)
Check if the mouse point is over the filter button. |
void |
paint(Graphics g,
JComponent c)
Paint method to paint the entire header. |
protected void |
paintCell(Graphics g,
Rectangle cellRect,
int columnIndex,
Object value,
boolean isSelected,
boolean hasFocus,
boolean paintCellDecorators)
Paints the header cell. |
protected void |
showCustomFilterEditor(IFilterableTableModel filterableTableModel,
int columnIndex,
Object[] possibleValues)
Shows CustomFilterEditor when "(Custom...) is selected in the drop down list. |
| Methods inherited from class com.jidesoft.plaf.basic.BasicEditableTableHeaderUIDelegate |
|---|
mouseDragged, mouseReleased |
| Methods inherited from class com.jidesoft.plaf.basic.BasicSortableTableHeaderUIDelegate |
|---|
mouseEntered, mousePressed, propertyChange, sortChanged, sortChanging |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
protected Object HIDE_POPUP_KEY
| Constructor Detail |
|---|
public BasicAutoFilterTableHeaderUIDelegate(JTableHeader header,
CellRendererPane rendererPane)
| Method Detail |
|---|
protected TableCellRenderer getHeaderRenderer(TableColumn aColumn)
BasicCellStyleTableHeaderUIDelegate
getHeaderRenderer in class BasicCellStyleTableHeaderUIDelegateaColumn - the TableColumn instance
protected void paintCell(Graphics g,
Rectangle cellRect,
int columnIndex,
Object value,
boolean isSelected,
boolean hasFocus,
boolean paintCellDecorators)
BasicCellStyleTableHeaderUIDelegate
paintCell in class BasicCellStyleTableHeaderUIDelegateg - the Graphics instancecellRect - the cell rectangle to be painted incolumnIndex - the view column index to paintvalue - the header value to paintisSelected - if the column is selectedhasFocus - if the column has focuspaintCellDecorators - if the cell decorators should be used as wellprotected boolean hasFocus(int columnIndex)
columnIndex - the view column index.
public void paint(Graphics g,
JComponent c)
BasicSortableTableHeaderUIDelegate
paint in class BasicSortableTableHeaderUIDelegateg - the Graphics instancec - the component to be paintedpublic void mouseClicked(MouseEvent e)
mouseClicked in interface MouseListenermouseClicked in class BasicEditableTableHeaderUIDelegateprotected boolean mouseOverFilterButton(Point p)
p - the mouse point
protected int[] getFilterCellDecoratorProperties()
FilterableTableHeaderCellDecorator paints.
public void mouseMoved(MouseEvent e)
mouseMoved in interface MouseMotionListenermouseMoved in class BasicEditableTableHeaderUIDelegatepublic void mouseExited(MouseEvent e)
mouseExited in interface MouseListenermouseExited in class BasicSortableTableHeaderUIDelegate
protected PopupPanel createPopupPanel(TableModel tableModel,
int columnIndex,
Object[] possibleValues)
tableModel - the table modelcolumnIndex - the column index to create the popup panelpossibleValues - possible values to be displayed
protected JidePopup createPopupWindow()
public boolean isPopupVisible()
public void hidePopup()
protected Point calculatePopupLocation()
public Object[] getPossibleValues(ObjectGrouper objectGrouper,
Object[] values,
Comparator comparator)
objectGrouper - the groupervalues - the original valuescomparator - the comparator
protected PopupPanel createListChooserPanel(TableModel tableModel,
int columnIndex,
Object[] possibleValues,
ObjectGrouper objectGrouper,
DefaultComboBoxModel comboBoxModel)
tableModel - the table modelcolumnIndex - the column indexpossibleValues - possible values to be displayed in the listobjectGrouper - the grouper which contains the information how we should display those values if the values
are groupers.comboBoxModel - the combo box model of the list.
protected PopupPanel createCheckBoxListChooserPanel(TableModel tableModel,
int columnIndex,
Object[] possibleValues,
ObjectGrouper objectGrouper,
DefaultComboBoxModel comboBoxModel)
tableModel - the table modelcolumnIndex - the column indexpossibleValues - possible values to be displayed in the check box listobjectGrouper - the grouper which contains the information how we should display those values if the values
are groupers.comboBoxModel - the combo box model of the check box list.
protected void customizeList(JList list)
new ListSearchable(list) {
protected String convertElementToString(Object object) {
return cellRenderer.convertElementToString(list.getLocale(), object);
}
};
list - the list generated by possible valuesprotected Filter[] getCurrentFilters()
protected void applyFilter(Filter filter,
int columnIndex)
FilterableTableModel.
filter - the filter.columnIndex - the column index.
protected void applyFilter(Filter filter,
int columnIndex,
boolean clearFirst)
FilterableTableModel.
filter - the filter.columnIndex - the column index.clearFirst - the flag indicating if it should clear current filter inside FilterableTableModel or not.
protected void showCustomFilterEditor(IFilterableTableModel filterableTableModel,
int columnIndex,
Object[] possibleValues)
filterableTableModel - the FilterableTableModelcolumnIndex - the column index of the AutoFilterBox relative to the filterableTableModel.possibleValues - the possible values of the column in the table model.
protected CustomFilterEditor createCustomFilterEditor(FilterFactoryManager filterFactoryManager,
Class<?> type,
ConverterContext converterContext,
Object[] possibleValues)
filterFactoryManager - the FilterFactoryManager.type - the type.converterContext - the ConverterContext.possibleValues - the possible values.
protected StandardDialog createCustomFilterEditorDialog(Container container,
String title,
CustomFilterEditor filterEditor)
container - the top level ancestor of the AutoFilterBox.title - the title of the dialog.filterEditor - the CustomFilterEditor.
protected String convertElementToString(Object item,
boolean isArray,
ObjectGrouper grouper)
item - the itemisArray - the flag indicating if the item is an array or notgrouper - the object grouper
protected String convertElementToString(Object item)
item - the item
protected String convertElementToString(Object item,
ConverterContext context)
item - the itemcontext - the converter context
|
JIDE 3.4.0 | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||