Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [nebula-dev] [CalendarCombo] Bug and solution

OK. Sorry for bugzilla.
I create the bug 263636 with bugzilla ;).

Tom Schindl a écrit :
Hi Emil,

I think we need a bug report to track the contribution appropiately else
we are getting in to trouble with IP-Clearance once we do a release! I
highly appreciate the fix from Jérôme but I need to insist on a bug report!

Thanks for your understanding guys.

Tom Schindl
Nebula CoLead

Emil Crumhorn schrieb:
Hello Jermoe,

Thanks for you bug report and fix (in the future however, please use
Bugzilla for this, as then it can be tracked by others as well). I
will take a look and make the necessary fix in the coming build(s).

Best regards,
Emil

On Wed, Feb 4, 2009 at 2:29 PM, Jérôme Combes
<jerome.combes@xxxxxxxxxxxxxxxx
<mailto:jerome.combes@xxxxxxxxxxxxxxxx>> wrote:

    Hello,

    I'am using the CalendarCombo widget and I have a bug with it and I
    have a solution to correct this problem. (See the attached file).

    The bug is the following. If I select in the calendar popup
    'Today', then 'None', then 'Today', I have the following exception
    (I added a "try ... catch" to see this exception) :
    java.lang.StringIndexOutOfBoundsException: String index out of
    range: -1
      at java.lang.String.<init>(String.java:202)
      at org.eclipse.swt.internal.win32.TCHAR.toString(TCHAR.java:115)
      at org.eclipse.swt.widgets.Combo.getText(Combo.java:846)
      at
    org.eclipse.nebula.widgets.calendarcombo.CalendarCombo.setText(CalendarCombo.java:1127)
      at
    org.eclipse.nebula.widgets.calendarcombo.CalendarCombo.updateDate(CalendarCombo.java:1566)
      at
    org.eclipse.nebula.widgets.calendarcombo.CalendarCombo.access$20(CalendarCombo.java:1565)
      at
    org.eclipse.nebula.widgets.calendarcombo.CalendarCombo$17.dateChanged(CalendarCombo.java:1461)
      at
    org.eclipse.nebula.widgets.calendarcombo.CalendarComposite.notifyListeners(CalendarComposite.java:732)
      at
    org.eclipse.nebula.widgets.calendarcombo.CalendarComposite.notifyListeners(CalendarComposite.java:745)
      at
    org.eclipse.nebula.widgets.calendarcombo.CalendarComposite.clickedTodayButton(CalendarComposite.java:214)
      at
    org.eclipse.nebula.widgets.calendarcombo.CalendarComposite.externalClick(CalendarComposite.java:770)
      at
    org.eclipse.nebula.widgets.calendarcombo.CalendarCombo$9.handleEvent(CalendarCombo.java:839)

    I have this exception because in the class 'CalendarCombo' the
    method 'Combo.setText(String )' is used to set the text in the
    Combo. I think that the method 'Combo.add(...)' (like in the
    method 'CalendarCombosetText(...)') must be always used to set the
    text.
    In attached file, there is the CalendarCombo with a solution : add
    a method 'setComboText(String )' to set the text for the Combo
    (flat or not) and I am using only this method in the CalendarCombo
    class.

    Jérôme




Back to the top