Ticket #1812 (closed bug: fixed)

Opened 16 years ago

Last modified 16 years ago

ClassCastException is thrown on focus lost inside the zoom percenage combo box

Reported by: dido Owned by: velizar
Priority: major Milestone:
Component: BASE_GUI_LIB Version: 2.0
Keywords: Cc: dido
Category: BASE Effort:
Importance: Ticket_group:
Estimated Number of Hours: Add Hours to Ticket:
Billable?: Total Hours:
Analysis_owners: dido Design_owners: velizar
Imp._owners: velizar Test_owners:
Analysis_reviewers: velizar Changelog:
Design_reviewers: meddle Imp._reviewers: meddle
Test_reviewers: Analysis_score: 4
Design_score: 4 Imp._score: 4
Test_score: 0

Description

Steps to reproduce:

  • Open Sophie
  • Type some data in zoom percentage combo box
  • Lose the focus
  • ClassCastException is thrown on focus lost.

Change History

comment:1 Changed 16 years ago by dido

  • Owner set to dido
  • Status changed from new to s1a_analysis_started

comment:2 Changed 16 years ago by dido

  • Status changed from s1a_analysis_started to s1b_analysis_finished

comment:3 Changed 16 years ago by velizar

  • Status changed from s1b_analysis_finished to s1c_analysis_ok

comment:4 Changed 16 years ago by velizar

  • Owner changed from dido to velizar
  • Status changed from s1c_analysis_ok to s2a_design_started

comment:5 Changed 16 years ago by dido

  • Summary changed from Tweak: ClassCastException is thrown on focus lost inside the zoom percenage combo box to ClassCastException is thrown on focus lost inside the zoom percenage combo box

comment:6 Changed 16 years ago by dido

  • Category changed from unknown to BASE

comment:7 Changed 16 years ago by velizar

  • Status changed from s2a_design_started to s2b_design_finished

There is a bug with ZoomPercentage bound combobox - a ClassCastException is thrown on focusLost. The exception is thrown when a ComboInput of type String is considered of type ZoomLevel in validate() and submitData() methods from class ZoomPercantagePanel. This happens when the input is entered from the keyboard and not from the combo items list. So a check for the type of the combo input should be made before proceeding with this methods. Another problem occurs with the float separator - although in the visual representation of the input of the combo box comma "," is used, the validation does not allowed the input to be made with "," but only with point ".". In order to support both separators all commas form the original input should be replaced by points and the result string should be proceeded to the validation. As the method, where this replacement takes place is in the base combo class, it should be overriden in ZoomPercentagePanel as we don't want the strings for all combos to be modified, but only the one for the zoom percatage.
Test is provided in class ZoomPercentagePanelTest.

Changesets: [4303] , [4572]

comment:8 Changed 16 years ago by velizar

  • Design_owners set to velizar
  • Status changed from s2b_design_finished to s2c_design_ok
  • Imp._owners set to velizar

comment:9 Changed 16 years ago by velizar

  • Status changed from s2c_design_ok to s3a_implementation_started

comment:10 Changed 16 years ago by velizar

  • Status changed from s3a_implementation_started to s3b_implementation_finished

comment:11 Changed 16 years ago by meddle

  • Status changed from s3b_implementation_finished to s3c_implementation_ok
  • Analysis_reviewers set to velizar
  • Analysis_score changed from 0 to 4
  • Imp._reviewers set to meddle
  • Design_score changed from 0 to 4
  • Design_reviewers set to meddle
  • Imp._score changed from 0 to 4

It's ok now...

4p (10m)

comment:12 Changed 16 years ago by deyan

  • Status changed from s3c_implementation_ok to closed
  • Resolution set to fixed

fixed

Note: See TracTickets for help on using tickets.