Uploaded image for project: 'Apache Flex'
  1. Apache Flex
  2. FLEX-18542

drawHighlightIndicator draw incorrectly when a cornerRadius is set

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Open
    • Major
    • Resolution: Unresolved
    • Adobe Flex SDK 3.3 (Release)
    • None
    • None
    • Affected OS(s): All OS Platforms
      Browser: Firefox 3.x
      Language Found: English

    Description

      Steps to reproduce:
      1. you set cornerRadius in CSS for a List based component to a number greater than 0 (i.e: 6)
      2. when you point the mouse over the first or last row the highlight indicator and selection indicator does not round the appropiate corners

      Actual Results:

      this makes the use of rounded corners not useful since the result is ugly, so nobody makes skins with rounded corners since this looks unprofesional.

      Expected Results:

      the courners should render correctly to make this style functionality truly usable

      Workaround (if any):

      You can override the correspondient function with something like this :

      protected override function drawHighlightIndicator(indicator:Sprite, x:Number, y:Number,
      width:Number, height:Number, color:uint, itemRenderer:IListItemRenderer):void {

      var cornerRadiusTop:Number = 0;

      if((itemRenderer as ListItemRenderer).listData.rowIndex == 0)

      { cornerRadiusTop = getStyle("cornerRadius"); }

      var g:Graphics = Sprite(indicator).graphics;
      g.clear();
      g.beginFill(color);
      g.drawRoundRectComplex(-2, 0, width+2, height, cornerRadiusTop, cornerRadiusTop,0,0);
      g.endFill();

      indicator.x = x;
      indicator.y = y;
      }

      but this should be integrated in the ListBase.as class and give the functionality directly without the need of make this class extension.

      Hopes it could be integrated in next upgrade since this jumps to the user eye directly and we have this issue since first versions of Flex.

      Thanks

      Attachments

        Activity

          People

            Unassigned Unassigned
            adobejira Adobe JIRA
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated: