本文整理了Java中com.google.gwt.user.cellview.client.DataGrid.addColumnSortHandler()
方法的一些代码示例,展示了DataGrid.addColumnSortHandler()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。DataGrid.addColumnSortHandler()
方法的具体详情如下:
包路径:com.google.gwt.user.cellview.client.DataGrid
类名称:DataGrid
方法名:addColumnSortHandler
暂无
代码示例来源:origin: kaaproject/kaa
/**
* The constructor.
*/
public AbstractDataProvider(AbstractGrid<T, K> dataGrid, HasErrorMessage hasErrorMessage,
boolean addDisplay) {
this.dataGrid = dataGrid;
callback = new LoadCallback(hasErrorMessage);
dataGrid.getDataGrid().addColumnSortHandler(this);
dataGrid.addColumnFilterEventHandler(this);
if (addDisplay) {
addDataDisplay(dataGrid.getDataGrid());
}
}
代码示例来源:origin: marianbuenosayres/jBPM6-Developer-Guide
@Override
public void init(final MessageListPresenter presenter ) {
this.presenter = presenter;
listContainer.add( messageListGrid );
// Set the message to display when the table is empty.
messageListGrid.setEmptyTableWidget( new Label( constants.NoMessages() ) );
sortHandler = new ListHandler<String>(presenter.getDataProvider().getList());
messageListGrid.addColumnSortHandler(sortHandler);
initTableColumns();
presenter.addDataDisplay(messageListGrid);
}
代码示例来源:origin: org.geomajas/geomajas-puregwt-example-base
public SampleListView(List<ShowcaseSampleDefinition> data, final SampleOverviewPage overviewPage) {
initWidget(UIBINDER.createAndBindUi(this));
ProvidesKey<ShowcaseSampleDefinition> sampleKeyProvider = new ProvidesKey<ShowcaseSampleDefinition>() {
public Object getKey(ShowcaseSampleDefinition item) {
return item.getTitle();
}
};
// We fill the grid through a list of SamplePanelFactory objects:
dataProvider = new ListDataProvider<ShowcaseSampleDefinition>(sampleKeyProvider);
dataProvider.addDataDisplay(grid);
// Selection: show sample on click
final SingleSelectionModel<ShowcaseSampleDefinition> selectionModel;
selectionModel = new SingleSelectionModel<ShowcaseSampleDefinition>(sampleKeyProvider);
grid.setSelectionModel(selectionModel);
selectionModel.addSelectionChangeHandler(new SelectionChangeEvent.Handler() {
public void onSelectionChange(SelectionChangeEvent event) {
ExampleBase.showSample(selectionModel.getSelectedObject());
}
});
// Add a sort handler:
sortHandler = new ListHandler<ShowcaseSampleDefinition>(dataProvider.getList());
grid.addColumnSortHandler(sortHandler);
// Initialize the grid columns:
initColumns();
// Apply the entire data-set:
setData(data);
}
代码示例来源:origin: org.geomajas/geomajas-gwt-example-base
public SampleListView(List<ShowcaseSampleDefinition> data, final SampleOverviewPage overviewPage) {
initWidget(UIBINDER.createAndBindUi(this));
ProvidesKey<ShowcaseSampleDefinition> sampleKeyProvider = new ProvidesKey<ShowcaseSampleDefinition>() {
public Object getKey(ShowcaseSampleDefinition item) {
return item.getTitle();
}
};
// We fill the grid through a list of SamplePanelFactory objects:
dataProvider = new ListDataProvider<ShowcaseSampleDefinition>(sampleKeyProvider);
dataProvider.addDataDisplay(grid);
// Selection: show sample on click
final SingleSelectionModel<ShowcaseSampleDefinition> selectionModel;
selectionModel = new SingleSelectionModel<ShowcaseSampleDefinition>(sampleKeyProvider);
grid.setSelectionModel(selectionModel);
selectionModel.addSelectionChangeHandler(new SelectionChangeEvent.Handler() {
public void onSelectionChange(SelectionChangeEvent event) {
ExampleBase.showSample(selectionModel.getSelectedObject());
}
});
// Add a sort handler:
sortHandler = new ListHandler<ShowcaseSampleDefinition>(dataProvider.getList());
grid.addColumnSortHandler(sortHandler);
// Initialize the grid columns:
initColumns();
// Apply the entire data-set:
setData(data);
}
代码示例来源:origin: org.geomajas/geomajas-client-gwt2-example-base
public SampleListView(List<ShowcaseSampleDefinition> data, final SampleOverviewPage overviewPage) {
initWidget(UIBINDER.createAndBindUi(this));
ProvidesKey<ShowcaseSampleDefinition> sampleKeyProvider = new ProvidesKey<ShowcaseSampleDefinition>() {
public Object getKey(ShowcaseSampleDefinition item) {
return item.getTitle();
}
};
// We fill the grid through a list of SamplePanelFactory objects:
dataProvider = new ListDataProvider<ShowcaseSampleDefinition>(sampleKeyProvider);
dataProvider.addDataDisplay(grid);
// Selection: show sample on click
final SingleSelectionModel<ShowcaseSampleDefinition> selectionModel;
selectionModel = new SingleSelectionModel<ShowcaseSampleDefinition>(sampleKeyProvider);
grid.setSelectionModel(selectionModel);
selectionModel.addSelectionChangeHandler(new SelectionChangeEvent.Handler() {
public void onSelectionChange(SelectionChangeEvent event) {
ExampleBase.showSample(selectionModel.getSelectedObject());
}
});
// Add a sort handler:
sortHandler = new ListHandler<ShowcaseSampleDefinition>(dataProvider.getList());
grid.addColumnSortHandler(sortHandler);
// Initialize the grid columns:
initColumns();
// Apply the entire data-set:
setData(data);
}
内容来源于网络,如有侵权,请联系作者删除!