Announcement

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

    Problem with SelectItem on GWT2.0 & SmartGWT2.0 in Google Chrome in Developer mode

    Hi Folks,

    congrats (as always) on making the SmartGWT 2.0 release. The fixes surrounding DetailFormatter have allowed us to remove quite a bit of code in our app which is nice. We have moved over to the release version of GWT 2.0 and obviously to complement it SmartGWT 2.0 and everything is going great which is always nice.

    I think, however, I've found an issue when using DynamicForm and SelectItem controls with the development environment using the new browser-based plugins within the core of GWT 2.0 itself.

    When debugging the app in Google Chrome (obviously the dev stream to get the support for the GWT developer plugin) SelectItems when clicked upon do not drop down to expose the items they contain. When the select Item has the focus you can use the up/down cursors to move through the items in the control - but - you also see an additional item that was not placed into the list through code and its value appears as __gwt_Objectid. This issue does not occur when you debug via Firefox 3.5 or IE 8 plugins. I can't test this on Safari on windows environments as no plugin exists yet - but I will check the Safari plugin out on my mac when I get a chance.

    And more importantly I can't determine if this is an issue with SmartClient, SmartGWT or just the Chrome Developer plugin so I figured I'd try you guys first.

    I've attached a screen shot (SelectItemDebugIssue.jpg) so you can see what I mean. When the app is built into a war file and deployed outside of the dev environment the issue does not exist - so its only developer mode in chrome where this issue exists.

    The steps to re-produce the problem are as follows. I've tried to use as little code as possible to make this simple to re-produce.

    1. Create a skeleton GWT project in Eclipse 3.5.
    2. Place the SmartGWT jars into your app
    3. change the XML file to inherit the following:

    Code:
    <inherits name="com.smartgwt.SmartGwt"/>
    <inherits name="com.smartgwt.tools.SmartGwtTools"/>
    4. Set up the isomorphicDir variable in the apps main HTML page

    Code:
    <!-- Configure SmartClient/SmartGWT  -->
    <script type="text/javascript" language="javascript" >
        var isomorphicDir = "sgwttest/sc/";
    </script>
    5. Gut the <body> of the main HTML page so it only includes:

    Code:
    <div id="mainUI"/>
    6. Change the main EntryPoint of your app so it only includes
    Code:
    public void onModuleLoad() 
    {
        DynamicForm form = new DynamicForm(); 
    		
        TextItem textItem = new TextItem();  
        textItem.setTitle("Text");  
        textItem.setHint("<nobr>A plain text field</nobr>"); 
            
        SelectItem selectItem = new SelectItem();  
        selectItem.setTitle("Select");  
        selectItem.setHint("<nobr>A combobox with icons</nobr>");  
        LinkedHashMap<String, String> valueMap = new LinkedHashMap<String, String>();  
            
        for(int item = 1; item < 4; item++)
        {
            valueMap.put(""+item, "SelectListItem " + item );
        }
        
        selectItem.setValueMap(valueMap);  
    		
        form.setFields(textItem, selectItem);
            
        RootPanel.get("mainUI").add(form);
    }
    7. Run up the application in Debug mode

    8. View the application using the GWT Developer Plugin. You should see a text item and obviously the SelectItem. If you try and expand the SelectItem you will see that you can't. Give it focus and use the up/down cursors - you should see

    * SelectListItem 1
    * SelectListItem 2
    * SelectListItem 3
    * __gwt_ObjectId

    Would be interesting to know if you can re-produce this issue and your insight into where you think the issue is coming from.

    Regards

    Ian.G
    Attached Files

    #2
    Seeing similar issue with Criteria object

    I'm passing a Criteria object and when it reaches the server RPC side it has this value in it, when it should be empty.

    This is only happening in Chrome (Development Mode Only), works in production.
    Last edited by gcstang; 16 Dec 2009, 16:03.

    Comment


      #3
      The Chrome dev mode seems the least stable of the Dev mode plugins and is currently super super slow compared to the Firefox plugin. The GWT team is aware of this and are working on it. It's quite likely that this is a bug with the hosted mode plugin.

      I'll check out this sample and see if I can narrow down the issue. Feel free to create an issue in tracker with a pointer to this thread so that it is not lost. In the meantime try using the FF plugin which is much faster / stable.

      Sanjiv

      Comment


        #4
        I quickly scanned the GWT contrib list and there is indeed something up with the addition of __gwt_ObjectId property to the object prototype and the chrome plugin.

        See http://gwt-code-reviews.appspot.com/100812 and this thread.

        I haven't had time digest the info and will look into it closer but thought I'd let you know about this.

        Sanjiv

        Comment


          #5
          This is a GWT issue and has been fixed on GWT trunk.

          Sanjiv

          Comment


            #6
            the same bug is still existing on dev mod:

            GWT 2.2.0 / SmartGWT 2.4 / Chrome 9.0.6 / GWT Developer Plugin - Version: 1.0.9738


            Greetz

            Seven

            Comment


              #7
              This bugs persists.

              GWT 2.2.0 / SmartGWT 2.4 / Chrome 12.0.742.122 m / GWT Developer Plugin - Version: 1.0.9738

              Comment


                #8
                See FAQ, you can star the Chrome and core GWT issues if you want to know when Google fixes GWT for Chrome.

                Comment

                Working...
                X