【发布时间】:2012-03-09 18:14:57
【问题描述】:
我想从 CellTable 的标题中删除排序箭头。 (下图红圈内,来自 GWT 展柜:http://gwt.google.com/samples/Showcase/Showcase.html#!CwCellTable)
但我仍然想要 CellTable 的排序功能。
有可能吗?有什么想法吗?
【问题讨论】:
我想从 CellTable 的标题中删除排序箭头。 (下图红圈内,来自 GWT 展柜:http://gwt.google.com/samples/Showcase/Showcase.html#!CwCellTable)
但我仍然想要 CellTable 的排序功能。
有可能吗?有什么想法吗?
【问题讨论】:
未经测试,可能有点破解,但您可以尝试覆盖默认样式以返回空白图像。扩展 Hilbrand's earlier solution 以覆盖 CellTable 使用的 ImageResources:
public interface TableResources extends CellTable.Resources {
@Source("blank.jpg")
ImageResource cellTableSortAscending();
@Source("blank.jpg")
ImageResource cellTableSortDescending();
}
创建'blank.jpg'并与本界面放在同一个资源包中。
【讨论】:
public ImageResource cellTableSortAscending(); 和public ImageResource cellTableSortDescending(); 无论如何,谢谢你的帮助。
getDataGrid().getColumnSortList().clear();
删除排序箭头
【讨论】: