1. #1
    Sencha User
    Join Date
    Apr 2008
    Posts
    18
    Vote Rating
    0
    mmiotk is on a distinguished road

      0  

    Default FormPanel & gwt widgets like ListBox

    FormPanel & gwt widgets like ListBox


    Why I can't add to FormPanel any gwt widgets like ListBox?

    Code:
            FormPanel panel = new FormPanel();
            panel.frame = true;
            panel.fieldWidth = 300;
            panel.labelWidth = 200;
            panel.buttonAlign = HorizontalAlignment.CENTER;
            panel.setHeading(getPageTitle());
            panel.setIconStyle("icon-form");
            panel.setWidth(600);
            panel.setStyleAttribute("padding", "20");
    
            final ListBox lb = new ListBox();
            lb.setWidth("200px");
            lb.setVisibleItemCount(1);
            lb.addItem("item 1 ");
            lb.addItem("item 2 ");
            lb.addItem("item 3 ");
            panel.add(lb);
    
            final TextBox tb = new TextBox();
            tb.setText("xxxx");
            panel.add(tb);
    But form panel is empy.




    (I work with Firefox browser)

  2. #2
    Sencha - GXT Dev Team darrellmeyer's Avatar
    Join Date
    May 2007
    Location
    Washington, DC
    Posts
    2,242
    Vote Rating
    2
    darrellmeyer is on a distinguished road

      0  

    Default


    FormPanel children need to be instances of Field. Can you use ComboBox?

  3. #3
    Sencha User
    Join Date
    Apr 2008
    Posts
    18
    Vote Rating
    0
    mmiotk is on a distinguished road

      0  

    Default


    Quote Originally Posted by darrellmeyer View Post
    FormPanel children need to be instances of Field. Can you use ComboBox?
    Yes, I tried, but how can I set the default value from ComboBox.
    I tried:

    a) call ComboBox: : select(5)
    b) call ComboBox: : setValue("MyItemLabel");
    c) call ComboBox: : setValue(new CDCBaseModel("MyItemLabel")); where CDCBaseModel extends BaseModel and overrides hashCode() and equals()

    but these variants doesn't give any effects.

    Because I had this problem, I tried to use ListBox.

    (I work with Firefox browser)

  4. #4
    Sencha - GXT Dev Team darrellmeyer's Avatar
    Join Date
    May 2007
    Location
    Washington, DC
    Posts
    2,242
    Vote Rating
    2
    darrellmeyer is on a distinguished road

      0  

    Default


    There were some bugs in setValue for ComboBox. The fix is in SVN and will go out in beta2.

    You should pass an existing record from the store or the text that will match value field of a record in the store.

Thread Participants: 1

Turkiyenin en sevilen filmlerinin yer aldigi xnxx internet sitemiz olan ve porn sex tarzi bir site olan mobil porno izle sitemiz gercekten dillere destan bir durumda herkesin sevdigi bir site olarak tarihe gececege benziyor. Sitenin en belirgin ozelliklerinden birisi de Turkiyede gercekten kaliteli ve muntazam, duzenli porno izle siteleri olmamasidir. Bu yuzden iste. Ayrica en net goruntu kalitesine sahip adresinde yayinlanmaktadir. Mesela diğer sitelerimizden bahsedecek olursak, en iyi hd porno video arşivine sahip bir siteyiz. "The Best anal porn videos and slut anus, big asses movies set..." hd porno faketaxi