using BitmapImage changes nothing..

how is there no examples of a list containing images? anyone?

Thank You
Dan Vega
[email protected]
http://www.danvega.org/


On Wed, Mar 31, 2010 at 6:20 AM, Carlos Rovira <[email protected]>wrote:

>
>
> Yesterday I was using a itemRenderer based on mx:Image and must to change
> to runtime BitmapImage like this one:
>
> http://polygeek.com/2452_flex_extending-spark-bitmapimage
>
> so I recomend you to go that way
>
>
>
> 2010/3/31 Alex Harui <[email protected]>
>
>
>>
>> If you search the archives, you’ll see that image-based renderers cause
>> lots of problems.
>>
>>
>>
>> On 3/30/10 6:02 PM, "Dan Vega" <[email protected]> wrote:
>>
>>
>>
>>
>>
>>
>> Really? Nobody has ever built a dynamic list of images before ?
>>
>> Thank You
>> Dan Vega
>> [email protected]
>> http://www.danvega.org/
>>
>>
>> On Tue, Mar 30, 2010 at 2:01 PM, Alex Harui <[email protected]> wrote:
>>
>>
>>
>>
>>
>>
>> I think list does a bit more thinking.  I think it computes a typicalItem
>> and uses that as the default size.  One of the issues with Image-based
>> renderers is that they have no size until the image loads.  If you know the
>> size upfront, set that on the renderer.
>>
>>
>>
>>
>> On 3/30/10 6:29 AM, "Dan Vega" <[email protected] <
>> http://[email protected]> > wrote:
>>
>>
>>
>>
>>
>>
>> Take the following example. On the left you have a list that loads data
>> from another file. The data is a basically a set of typed objects that have
>> a src attribute that points to an image. Don't worry to much about that,
>> just know that we are getting a list of images. The list on the left shows
>> an initial list with some scrollbars and about 5 images. The list looks like
>> it can only scroll 1 or 2 more images but in fact there are about 20 images.
>> As you start scrolling the list figures out that there are more and adjusts
>> the scroll bars. It keeps doing this until we reach the last images and
>> finally the scroll bars work as expected.
>>
>> What I don't understand is the data group next to it works exactly how I
>> expect the list to work. I thought the list was basically using the data
>> group in the end anyways? What am I missing / doing wrong? If you need the
>> full example I can email it to you, just ping me.
>>
>> <?xml version="1.0" encoding="utf-8"?>
>> <s:Application
>> xmlns:fx="http://ns.adobe.com/mxml/2009";
>> xmlns:s="library://ns.adobe.com/flex/spark <
>> http://ns.adobe.com/flex/spark>  <http://ns.adobe.com/flex/spark> "
>> xmlns:mx="library://ns.adobe.com/flex/mx <http://ns.adobe.com/flex/mx>  <
>> http://ns.adobe.com/flex/mx> "
>>
>>
>> initialize="GalleryService.loadData()" >
>> <s:layout>
>> <s:HorizontalLayout paddingTop="20" paddingRight="20" paddingBottom="20"
>> paddingLeft="20"/>
>> </s:layout>
>> <s:List
>> height="100%"
>> dataProvider="{GalleryService.results}"
>> itemRenderer="GalleryImageRenderer"
>> dragEnabled="true"
>> >
>> <s:layout>
>> <s:VerticalLayout horizontalAlign="justify"/>
>> </s:layout>
>> </s:List>
>> <s:Scroller height="100%">
>> <s:DataGroup dataProvider="{GalleryService.results}"
>> itemRenderer="GalleryImageRenderer">
>> <s:layout>
>> <s:VerticalLayout horizontalAlign="justify"/>
>> </s:layout>
>> </s:DataGroup>
>> </s:Scroller>
>> -->
>> </s:Application>
>>
>>
>> Thank You
>> Dan Vega
>> [email protected] <http://[email protected]>
>> http://www.danvega.org/
>>
>>
>>
>>
>>
>> --
>> Alex Harui
>> Flex SDK Team
>> Adobe System, Inc.
>> http://blogs.adobe.com/aharui
>>
>
>  
>

Reply via email to