Announcement

Collapse
No announcement yet.
X
  • Filter
  • Time
Clear All
new posts

    5.1p ComboBoxItem L10n and search-messages inconsistency

    Hi Isomorphic,

    please see this v10.1p_2016-05-07 BuiltInDS based testcase. You can see that if you enter and remove a search string in a ComboBoxItem with setMinimumSearchLength(3), the display of the message "Enter a longer search string to search" is not consistent for every string less than 3 characters (see video). Also, this message is not localized (if run in German in my application).
    Click image for larger version

Name:	Animation.gif
Views:	92
Size:	104.3 KB
ID:	237794


    BuiltInDS.java:
    Code:
    package com.smartgwt.sample.client;
    
    import com.google.gwt.core.client.EntryPoint;
    import com.smartgwt.client.Version;
    import com.smartgwt.client.core.KeyIdentifier;
    import com.smartgwt.client.data.DataSource;
    import com.smartgwt.client.util.Page;
    import com.smartgwt.client.util.PageKeyHandler;
    import com.smartgwt.client.util.SC;
    import com.smartgwt.client.widgets.IButton;
    import com.smartgwt.client.widgets.Window;
    import com.smartgwt.client.widgets.events.ClickEvent;
    import com.smartgwt.client.widgets.events.ClickHandler;
    import com.smartgwt.client.widgets.form.DynamicForm;
    import com.smartgwt.client.widgets.form.fields.ComboBoxItem;
    import com.smartgwt.client.widgets.layout.VLayout;
    
    public class BuiltInDS implements EntryPoint {
        private VLayout mainLayout;
        private IButton recreateBtn;
    
        public void onModuleLoad() {
            KeyIdentifier debugKey = new KeyIdentifier();
            debugKey.setCtrlKey(true);
            debugKey.setKeyName("D");
    
            Page.registerKey(debugKey, new PageKeyHandler() {
                public void execute(String keyName) {
                    SC.showConsole();
                }
            });
    
            mainLayout = new VLayout(20);
            mainLayout.setWidth100();
            mainLayout.setHeight100();
    
            recreateBtn = new IButton("Recreate");
            recreateBtn.addClickHandler(new ClickHandler() {
                @Override
                public void onClick(ClickEvent event) {
                    recreate();
                }
            });
            mainLayout.addMember(recreateBtn);
            recreate();
            mainLayout.draw();
        }
    
        private void recreate() {
            Window w = new Window();
            w.setWidth("95%");
            w.setHeight("95%");
            w.setMembersMargin(0);
            w.setModalMaskOpacity(70);
            w.setTitle(" (" + Version.getVersion() + "/" + Version.getSCVersionNumber() + ")");
            w.setTitle("ComboBoxItem L10n and search-messages" + w.getTitle());
            w.setShowMinimizeButton(false);
            w.setIsModal(true);
            w.setShowModalMask(true);
            w.centerInPage();
    
            final DynamicForm searchForm = new DynamicForm();
    
            ComboBoxItem supplyItem = new ComboBoxItem("SI", "Search Supplyitem");
            supplyItem.setMinimumSearchLength(3);
            supplyItem.setOptionDataSource(DataSource.get("supplyItem"));
            supplyItem.setDisplayField("itemName");
            searchForm.setItems(supplyItem);
            w.addItem(searchForm);
            w.show();
        }
    
    }
    Best regards
    Blama

    #2
    This message has been localized for builds dated May 11 and later.

    We'll look at the logic bug separately.

    Comment


      #3
      We've now made a change to address the issue with the 'too short' message not showing up reliably.
      Please try the next nightly build, dated May 11 or above.

      Regards
      Isomorphic Software

      Comment

      Working...
      X