Announcement

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

    Don`t work DrawHandler in SmartGWT 2.5

    I use method:
    Code:
    addDrawHandler(new DrawHandler() {
          public void onDraw(final DrawEvent drawEvent) {
                SC.say("OnDraw");
          }
    });
    Method(onDraw) is never called in SmartGwt 2.5. Although works fine in SmartGwt 2.4.
    Аnyone experienced this?

    #2
    Hello,

    I have exactly the same problem. When using a DrawHandler the onDraw() method will not be called at all. This problem appeared when I upgraded to SmartGWT 2.5. It also seems that this behaviour is browser independent. There is also no exception thrown, neither a Java- nor a JavaScriptException.
    The sample code is simple and short:

    Code:
    public void onModuleLoad() {
    
    		Layout content = new VLayout();
    		content.setContents("hello world");
    
    		content.addDrawHandler(new DrawHandler() {
    			public void onDraw(DrawEvent event) {
    				SC.say("onDraw");
    			}
    		});
    
    		content.show();
    	}
    When the layout is drawn, there is no "onDraw" message.

    Note: When I explicitly let the layout fire a DrawEvent, the DrawHandler is called. But I need it to be called automatically.

    In my eyes this is a bug that has to be fixed. Otherwise, essential functionality of SmartGWT is impaired.

    Best regards.

    Comment


      #3
      We're not reproducing this problem with exactly your code.
      A few things to check:
      - what's the reported version in the SmartClient developer-console (evaluate "isc.version" to see this)?
      - what browser/OS are you using?
      - does the problem occur in development mode only?
      - what version of GWT?
      - how are you launching the application (Eclipse or command line "ant hosted" or something else)?

      Thanks
      Isomorphic Software

      Comment


        #4
        Originally posted by Isomorphic
        We're not reproducing this problem with exactly your code.
        A few things to check:
        1. what's the reported version in the SmartClient developer-console (evaluate "isc.version" to see this)?
        2. what browser/OS are you using?
        3. does the problem occur in development mode only?
        4. what version of GWT?
        5. how are you launching the application (Eclipse or command line "ant hosted" or something else)?

        Thanks
        Isomorphic Software
        1. isc_version=trunk.js
        2. Chrome, IE8, FF5 - Windows XP
        3. No.
        4. 2.3.0
        5. WAR file in tomcat. Development mode: use maven and command gwt:debug

        Comment


          #5
          Originally posted by Isomorphic
          We're not reproducing this problem with exactly your code.
          A few things to check:
          - what's the reported version in the SmartClient developer-console (evaluate "isc.version" to see this)?
          - what browser/OS are you using?
          - does the problem occur in development mode only?
          - what version of GWT?
          - how are you launching the application (Eclipse or command line "ant hosted" or something else)?

          Thanks
          Isomorphic Software
          1. Evaluator: result of 'isc.version' (0ms):
          "SC_SNAPSHOT-2010-12-19/LGPL Development Only"
          2. Chrome, IE8, IE6, FF5, Safari - Windows XP
          3. No.
          4. 2.0.4
          5. I also have a war-file on a tomcat and I'm running it via maven and the gwt devmode.

          I noticed that in the jar-file of SmartGWT 2.4 there is a com/gwt-folder but in SmartGWT 2.5 is no such folder. And in this folder there are some GWT-classes related to the event mechanism.

          Best regards and thank you for caring.

          Comment


            #6
            rdeurig: please try upgrading GWT and let us know if that corrects the problem

            BeezeR: please try downloading a build from smartclient.com/builds rather than using Maven. If this works, it's likely there's something wrong with your Maven setup.

            Also both of you: please retest after manually running a GWT compile and clearing your browser cache, and restarting your browser.

            Comment


              #7
              Originally posted by Isomorphic
              BeezeR: please try downloading a build from smartclient.com/builds rather than using Maven. If this works, it's likely there's something wrong with your Maven setup.
              Thanks, it works.
              Please, see what is wrong with maven repository.

              Comment


                #8
                After upgrading to GWT version 2.3.0 and a long time of integrating it in our process I must say that the draw handler still doesn't work, so it has nothing to do with the versions of SmartGWT or GWT and also it's no compatibility related issue. I really don't understand the reason for this misbehaviour. To make my confusion even worse the draw handler behaves normal when I run my test case in a SmartGWT project configured without maven.
                Could it be a problem similar to this:
                http://code.google.com/p/google-web-toolkit/issues/detail?id=4853
                Or do you have any idea how maven or the maven configuration could break the draw handler functionality?

                By the way, I'm using Maven 2.2.1 and the JDK 1.5.0.21.

                Comment


                  #9
                  Are you using the 2.5-patch version? You should be. See this thread.

                  Comment

                  Working...
                  X