Gelmiş geçmiş en büyük porno sitemiz olan 2pe de her zaman en kaliteli pornoları sunmayı hedefledik. Diğer video sitemiz olan vuam da ise hd porno ağırlıklı çalışmalara başladık.

Threaded View

  1. #1
    Sencha User
    Join Date
    Sep 2011
    Posts
    20
    Vote Rating
    0
    I_P is on a distinguished road

      0  

    Default Answered: Problem with Grid's data

    Answered: Problem with Grid's data


    Hello, I'm trying to make a grid:


    protected void initialize()
    {
    LayoutContainer container = new LayoutContainer();
    container.setLayout(new FitLayout());


    ContentPanel cp = new ContentPanel();
    cp.setHeading("Test");
    cp.setSize(800, 600);


    List<ColumnConfig> columns= new ArrayList<ColumnConfig>();

    ColumnConfig firstNameColumn= new ColumnConfig("firstname","FirstName",200);
    columns.add(firstNameColumn);


    ColumnConfig lastNameColumn= new ColumnConfig("lastname","LastName",200);
    columns.add(lastNameColumn);


    ColumnModel columnmodel=new ColumnModel(columns);


    ListStore<Person> ls=new ListStore<Person>();
    List<Person> lp=getPersons();
    ls.add(lp);

    Grid<Person> grid = new Grid<Person>(ls,columnmodel);
    grid.setBorders(true);

    cp.add(grid);

    container.add(cp, new FitData(50));
    }



    private List<Person> getPersons()
    {
    List<Person> p=new ArrayList<Person>();
    Person person;
    person=new Person();
    person.setFirstName("FirstName");
    person.setLastName("LastName");
    p.add(person);
    person=new Person();
    person.setFirstName("FirstName2");
    person.setLastName("LastName2");
    p.add(person);
    return p;
    }

    Class Person extends BaseModel.
    Problem is that columns headers and data isn't shown together. I mean,
    when I start application,there are shown only names of columns of grid, and no data. It may be a bit strange,but when I write: grid.setHideHeaders(true), data without headers is shown then. I'm new,so I don't know what problem may be in. I'll be very pleased if you could help me.

  2. Try to add
    Code:
    cp.setLayout(new FitLayout());
    Also you should size your "container" and not your "cp"

Thread Participants: 1