GWT CellTable - 从标题中删除排序箭头

xav*_*ard 2 java gwt

我想从CellTable的标题中删除排序箭头.(下面红色圆圈中的一个,来自GWT展示:http://gwt.google.com/samples/Showcase/Showcase.html#!CwCellTable)

箭头细胞表

但我仍然想要CellTable的排序功能.

可能吗?任何的想法?

Cap*_*row 7

未经测试,可能有点黑客,但您可以尝试覆盖默认样式以返回空白图像.扩展Hilbrand早期的解决方案以覆盖CellTable使用的ImageResources:

public interface TableResources extends CellTable.Resources {
    @Source("blank.jpg")
    ImageResource cellTableSortAscending();

    @Source("blank.jpg")
    ImageResource cellTableSortDescending();
 }
Run Code Online (Sandbox Code Playgroud)

创建'blank.jpg'并将其放在与此界面相同的资源包中.

  • 谢谢!按预期工作!但方法如下:`public ImageResource cellTableSortAscending();`和`public ImageResource cellTableSortDescending();`无论如何,感谢您的帮助. (2认同)