How can I put a widget in a CellTable Cell?

后端 未结 5 2099
抹茶落季
抹茶落季 2021-02-04 03:35

I am using CellTable to show my records but now the thing is I want show a select box when user clicks on a cell. One more thing is that select box is my own widget, not a prede

5条回答
  •  无人共我
    2021-02-04 03:46

    I think @Kel has given the closest answer , I use his answer and I found ActionCell can use IdentityColumn and CellTable Can use IdentityColumn

    ActionCell refreshCell = new ActionCell<>("Refresh", new ActionCell.Delegate() {
    
      @Override
      public void execute(MyEntity entity) {
        //bla bla bla
      }
    });
    IdentityColumn refreshColumn = new IdentityColumn<>(refreshCell);
    cellTable.addColumn(refreshColumn, "Refresh");
    

提交回复
热议问题