Announcement

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

    Show day of the week name in calendar - day view

    SNAPSHOT_v9.0d_2013-05-28/PowerEdition Deployment (built 2013-05-28)

    Sorry, if this a trivial question but I can't see any possibility to add the day name if the calendar is in day view.

    Thanks.

    #2
    Where do you want to put it? Probably you want to override calendar.getDateLabelText().

    Comment


      #3
      Attached a screen shot where we would see it.

      Tried this way but had no luck:

      Code:
      calendar = new Calendar() {
             @Override
      	public String getDateLabelText(String viewName, Date startDate) {
      		return "date label " + super.getDateLabelText(viewName, startDate);
      	}
      };
      Attached Files

      Comment


        #4
        Ah yes, that API isn't yet wrapped for SGWT - we'll address that and update this thread when it's been added

        Comment


          #5
          This has now been added - the method is a valid override point in nightly 4.0d builds dated June 8 or above.

          Comment


            #6
            Cannot use the inherited method?

            SNAPSHOT_v9.0d_2013-06-09/PowerEdition Deployment (built 2013-06-09)

            Using the following code the label remains empty:
            Code:
            calendar = new Calendar() {
               @Override
               public String getDateLabelText(String viewName, Date startDate, Date endDate) {
                 return "something " + super.getDateLabelText(viewName, startDate, endDate);
               }
            };
            If I remove the calling the inherited method, then it works, but I would like to extend the original functionality (so we would like to call and use the super).

            Is it possible? Thanks.

            Comment


              #7
              Smart GWT 4.0d (SmartClient Version: v9.0d_2013-06-12/PowerEdition Deployment (built 2013-06-12))

              With the latest build the date picker doesn't show anything even the getDateLabelText wasn't overridden.

              Also need your help with the previous entry (#6).

              Thanks.

              Comment


                #8
                Are you saying that in the latest nightly build you're not seeing the default date label text showing up at all? We're not reproducing this issue.
                Perhaps it would help to show a screenshot of what's missing so we can see what you're referring to (and ideally point to where we can see it on one of our samples).

                On the problems calling Super: We're looking into this and will follow up when we have a solution

                Regards
                Isomorphic Software

                Comment


                  #9
                  We've now made a change to address this issue.
                  You should be able to call "super(...)" in your custom getDateLabelText implementation.

                  Please try the next nightly build (June 14 or above)

                  Comment


                    #10
                    Yes, I can't see it. Here it is the very simple code and also the screen shot you can see the empty date picker.

                    Code:
                    Calendar calendar = new Calendar(); 
                    CalendarEvent events[] = ...;
                    calendar.setData(events);
                    calendar.draw();
                    Thank you, will test calling the super with June 14 build.
                    Attached Files

                    Comment


                      #11
                      Fixed

                      Smart GWT 4.0d (SmartClient Version: v9.0d_2013-06-14/PowerEdition Deployment (built 2013-06-14))

                      Everything is working as expected. Thank you!

                      Comment

                      Working...
                      X