ICEfaces
  1. ICEfaces
  2. ICE-1348

AbstractChart shouldn't cast Paint to a Color

    Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 1.5.3
    • Fix Version/s: 1.6DR#3, 1.6
    • Component/s: ICE-Components
    • Labels:
      None
    • Environment:
      any

      Description

      The jcharts api support the base java.awt.Paint class, but we cast this to a java.awt.Color, which is a subclass. This creates classcastexceptions when using PaintGradients.

      suggested fix:

      --- icefaces\component\src\com\icesoft\faces\component\outputchart\AbstractChart.java 2007-02-23 11:08:27.000000000 -0700
      @@ -200,13 +200,13 @@
                       paintArray[i] = colorMap.getColor(temp[i].trim());
                   }
               } else if (obj instanceof List) {
                   List objList = (List) obj;
                   paintArray = new Paint[objList.size()];
                   for (int i = 0; i < objList.size(); i++) {
      - paintArray[i] = (Paint) objList.get(i);
      + paintArray[i] = (Color) objList.get(i);
                   }
               }
               return paintArray;
           }
       
       

        Activity

        Philip Breau created issue -
        Philip Breau made changes -
        Field Original Value New Value
        Assignee Adnan Durrani [ adnan.durrani ]
        Ken Fyten made changes -
        Fix Version/s 1.6DR#3 [ 10050 ]
        Assignee Priority P1
        Repository Revision Date User Message
        ICEsoft Public SVN Repository #13431 Wed Mar 28 09:49:12 MDT 2007 adnan.durrani Fix applied suggested in jira ICE-1348
        Files Changed
        Commit graph MODIFY /icefaces/trunk/icefaces/component/src/com/icesoft/faces/component/outputchart/AbstractChart.java
        Hide
        Adnan Durrani added a comment -

        Suggested change has been applied to the AbstractChart.java. revision # 13431

        Show
        Adnan Durrani added a comment - Suggested change has been applied to the AbstractChart.java. revision # 13431
        Adnan Durrani made changes -
        Status Open [ 1 ] Resolved [ 5 ]
        Resolution Fixed [ 1 ]
        Ken Fyten made changes -
        Fix Version/s 1.6 [ 10031 ]
        Ken Fyten made changes -
        Status Resolved [ 5 ] Closed [ 6 ]
        Assignee Priority P1
        Assignee Adnan Durrani [ adnan.durrani ]

          People

          • Assignee:
            Unassigned
            Reporter:
            Philip Breau
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: