Tile List Selection indicator

I have a tile list layout with some thumbnails.
When one is selected it gets a default blueish background.
Could someone explain how i would go about putting a nice green tick over a thumbnail once its selected?

Thank you both for your replies.
I'm already using a custom component that extends a spark List with layout property set to TileLayout. This is so i can mimick the user holding the CTRL key for multiple selection.
I also already have a custom item renderer that displays the thumbnail and fires off an event when clicked.
Really confused as where to put either of your code snippets.
this is my custom component
package
     import flash.events.MouseEvent;
     import mx.core.IVisualElement;
     import spark.components.List;
     public class CheckList extends List
          public function CheckList()
               super();
               allowMultipleSelection = true;
           * Override the mouseDown handler to act as though the Ctrl key is always down
          override protected function item_mouseDownHandler(event:MouseEvent):void
               var newIndex:Number = dataGroup.getElementIndex(event.currentTarget as IVisualElement);
               // always assume the Ctrl key is pressed by setting the third parameter of
               // calculateSelectedIndices() to true
               selectedIndices = calculateSelectedIndices(newIndex, event.shiftKey, true);
and this is my item renderer
<?xml version="1.0" encoding="utf-8"?>
<s:ItemRenderer xmlns:fx="http://ns.adobe.com/mxml/2009"
                    xmlns:s="library://ns.adobe.com/flex/spark"
                    xmlns:mx="library://ns.adobe.com/flex/mx"
                    autoDrawBackground="true" width="300" height="315" click="thumb_clickHandler(event)">
     <mx:Image id="thumb" x="25" y="26" width="250" height="265" source="{data.thumburl}"/>
     <fx:Script>
          <![CDATA[
               import flashx.textLayout.factory.TruncationOptions;
               import mx.controls.Alert;
               import mx.events.ItemClickEvent;
               protected function thumb_clickHandler(event:MouseEvent):void
                    var ev:ItemClickEvent = new ItemClickEvent(ItemClickEvent.ITEM_CLICK, true);
                    ev.item = data;
                    ev.index = itemIndex;
                    //Alert.show(ev.item.imageurl);
                    dispatchEvent(ev);
          ]]>
     </fx:Script>
</s:ItemRenderer>
Any help you can give me would be great, the code is getting really messy, should i merge these into one class?

Similar Messages

  • Disable Spark List selection indicator

    How do I get rid of the Spark List selection indicator entirely?  I don't want the rectangular indicator when the mouse hovers over an item, and I don't want the color to change when the mouse is clicked.

    You'll have to extend default item renderer (ItemRenderer for instance) and set autoDrawBackground to false. And then use your item renderer in a list.
    See this document for more information on spark item renderers.

  • Tile List selection after pressing embedded Image button

    Hi;
    I am working on SAP Work Manager 6.0 customizing using Agentry 6.1.3. I have this tile list that contains items. At the bottom of this tile list, I have a button that targets the selected item on the tile list. This button has an action which changes the icon  of the selected item when pressed and also executes an edit transaction that prints/changes the selected item property values based on rules. After selecting a particular item from the tile list and clicking on this button, the selected item's image changes to the image that I want, but the selection highlighter toggles and always moves to the first item on the tile list. I have tried implementing a list selection but it somehow always ignores this and always toggles back to the first item on the tile list. I would like it to stay on the selected item, whose image has just been changed. How would I go about having the selection highlighter stay on the same item before and after pressing the button?
    Your help is greatly appreciated!
    Thanks in advance!
    Sizo Ndlovu

    Hi Jason;
    Thank you for the prompt response.I'm using the .NET client to test on the development machine and the application is deployed onto an Android 4.0.4 device. I have tried implementing this as shown below:
    The action steps:
    The Navigation step:
    The List Selection step:
    The List Selection rule:
    I have also tried implementing this using the navigation only or the list selection only, with no success.
    Thanks and Regards;
    Sizo Ndlovu

  • Dynamically Select tile list item

    Hi,
    is it possibly to select / highlight an item in a tile list by interacting with something else in the app? So if i click a button i want to select the third itme in a tile list.
    Cheers
    Tim

    the problem is really working out which of the items I want to select, as I'm not able to loop through the children of the list in order to make my comparison.

  • Tile list - clicking on the images to change get different movies to play

    I am buiding an application where I just got the tile list working with images loaded in.  My question is there a way to click on the images that are loaded in to get them to do things, such as change a video, in my video player?
    Thanks!

    Using the 'adjust date and time' setting is the best way to syncronise the photos from all your cameras. However as you say this merely puts them all in the correct order chronologically.
    If there are photos that you feel would be best somewhere else in an album other than in date order, it may depend on how many as to which is the best option for you. If it's only a few you may wish to adjust the date/time on these few manually so they fit in with the rest where you want them.
    If you have a lot of photos you want in a different order to the order by date, or you really don't care about what date/time is used and just want them in the order you want them in, then 'batch change' is the best option.
    From the view menu, select 'sort photos - manually', drag the photos around until they are in the order you want, select all of them. Now select the batch change option and choose 'Date' from the 'set' options, type in a date and time for the first photo, it can be anything but it's probably a good idea to choose something close to the original date, then check the box 'Add'. You can keep the value set at 1 minute or enter any value you want, it may be more realistic to divide the length of your holiday by the number of photos you have to calculate a value, but it really isn't necessary. Clicking OK will adjust all the dates without affecting the title or description and the photos will now show on the Apple TV in that order.
    Just to be sure iTunes is updated, you may want to go to the advanced menu/choose photos to share in iTunes and deselect the album, apply, reselect the album and apply again.

  • Clear out tile list on change event

    I have a tile list component with thumbnails that changes when a combo box is changed.  The thumbnails load in videos when clicked.  When I change between items in the combo box, ghosted images of the previous item in the tilelist remain.  Also, the videos seem to be loading on top of each other when I change the combo box.
    In the change event, I would like the tilelist to clear out so there are no ghosted thumbnails from the previous combo box choice and I want the video player to clear out so the videos don't play on top of each other.
    This is the change event function that I have:
    myTileList.addEventListener(Event.CHANGE, listListener);
    // Detect when new video is selected, and play it
    function listListener(event:Event):void {
    var targetSource=event.target.selectedItem.data;
    if (targetSource.indexOf(".jpg")>-1) {
      //var URL=event.target.selectedItem.data;
      var req:URLRequest=new URLRequest(event.target.selectedItem.data);
      navigateToURL(req);
    } else {
      var flvControl:FLVPlayback=display;
      flvControl.source = event.target.selectedItem.data;
      flvControl.addEventListener(VideoProgressEvent.PROGRESS, progressHandler);
      flvControl.addEventListener(VideoEvent.READY, readyHandler);
      addChild(pb);
      flvControl.play();
    Do you see the issue that is causing the duplication?

    Hello Tim,
    And in GET_V of the attribute serving as dropdown you defined an event?
    * Set the type of the field:  dropdown menu
       CASE iv_property.
        WHEN if_bsp_wd_model_setter_getter=>fp_fieldtype.
          rv_value = cl_bsp_dlc_view_descriptor=>field_type_picklist.
        WHEN if_bsp_wd_model_setter_getter=>fp_onclick.
          rv_value = 'select'.
      ENDCASE.
    Best Regards,
    Yevgen

  • Tile list area text

    I am using a tile list component and an areatext component.  when I click on the graphic in the list a description of the graphic comes up in the text area.  No problems so far.  However I want to view a large image of the graphic at the same time as the text.  Now I have a problem because I do not know what to do.   I will attach one graphic so you can see how they show up.  I will attach the .swf file also.  You can see in the middle of the two areas (where the green square is) this is where I want the larger graphic to appear.  I have tried different things, but since I really do not know how to write script I don't know what to do.
    Here is the script
    majorworksthumb_tl.addEventListener(Event.CHANGE, majorworksthumbClicked)
    function majorworksthumbClicked(event:Event):void {
        majorwork_ta.text = event.target.selectedItem.data;
        majorworks_mc.MovieClip = event.target.selectedItem.MovieClip;
    majorworksthumb_tl.addItem({label:"BISON COOP MAIN", source:"majorworksthumb/BisonCoopMain.jpg", data:" BISON COOP MAIN \n\nBison Coop in New Rockford - (Exact Location, How Big, made of what?)."});
    Thank You
    Colleen

    Dan,
    I figured it out and now what I want is happening.  however when I click on a thumbnail, then another the preious one still shows up. do I have to do some kind of end, or stop or false or somthing to get rid of the previous picture?
    Here is my new script
    import fl.controls.ScrollPolicy;
    import fl.controls.TileList;
    import fl.data.DataProvider;
    import fl.controls.UIScrollBar;
    import fl.events.ScrollEvent;
    import fl.controls.ScrollBarDirection;
    myText.text = "Select an Image";
    //add a bunch of images and labels
    var dp:DataProvider = new DataProvider();
    dp.addItem();
    dp.addItem();
    dp.addItem();
    var myTileList:TileList = new TileList();
    myTileList.dataProvider = dp;
    myTileList.scrollPolicy = ScrollPolicy.ON;
    myTileList.columnWidth = 200
    myTileList.rowHeight = 128;
    myTileList.setSize(300,300);
    myTileList.columnCount = 1;
    myTileList.rowCount = 4
    myTileList.move(20, 195);
    addChild(myTileList);
    myTileList.addEventListener(MouseEvent.CLICK,itemClicked);
    function itemClicked(e:Event):void {
         //myText
         myText.text = myTileList.selectedItem.data;
         //myMC
         var i =new Loader();
         i.load(new URLRequest(myTileList.selectedItem.source));
         myMC.addChild(i);
    Thank You
    Colleen Bredahl
    Art/Art Marketing

  • Getting children of tile list

    Hi,
    I have a tile list as follows, if i want to hide the third item in the tile list how can i do so? I can't seem to target the children of the list.
    <mx:TileList x="1" y="1" height="568" width="98"
    id="palette_list"
    dataProvider="{Application.application.dataModel.shapes}"
    dragEnabled="true"
            dropEnabled="true"
            dragMoveEnabled="true"
            dragDrop="reorderShapes(event)"
            columnWidth="95"
            rowHeight="45"
            horizontalScrollPolicy="off"
            themeColor="0xcccccc"
            liveScrolling="true">
    <mx:itemRenderer>
    <mx:Component>
    <mx:HBox width="100%" height="45" horizontalScrollPolicy="off" verticalScrollPolicy="off" useHandCursor="true" buttonMode="true" mouseChildren="false">
    <mx:Image height="36" width="36" source="{data.imageSource}"/>
    <mx:Text height="36" leading="-1" fontSize="8.7" width="50" textAlign="left" text="{data.text}"/>
    </mx:HBox>
    </mx:Component>
    </mx:itemRenderer>
    </mx:TileList>

    "Mattg2379" <[email protected]> wrote in
    message
    news:ghu3c9$16i$[email protected]..
    > Hi all.
    >
    > I've created a display list of checkboxes (chapter
    titles) with child
    > select
    > boxes underneath (slides)
    > All works well.
    >
    > I have now written an onclick function for the chapter
    check boxes (that
    > sends
    > that two variables required to build the string matching
    the id of any
    > slide
    > (child) checkboxes underneath it.
    >
    > I cant seem to actually find the child checkboxes.
    >
    > Basically, I want to loop through the children and set
    them to either true
    > or
    > false, depending on the value of the chapter checkbox.
    >
    > How can I get to them by their IDs? FLEX / AS doesnt
    have a getElementById
    > function, which is a damn shame. :(
    The id doesn't actually buy you much unless you create the
    component in
    mxml. Just use an array or a dictionary to store references
    to your
    components as you create them.
    HTH;
    Amy

  • How can I get a drop-down list selection also be selected in another field with the same list but a different name?

    I have a street address and a billing address. A question is posed with a checkbox — "Is the billing address the same as the street address?" If Yes is checked, the street address automatically fills the billing fields. If No is checked, the user must fill in new information. In both the street address and billing addres, the State field is a drop-down list. How can I get the drop-down list selection in the street address State also be selected in drop-down list for the billing address State?

    Has anyone done this?

  • UI - How to make Columns in a Drop Down List Selection?

    I am altering a code from Peter Kahrel "Beginning Script UI". I am trying to make a searchable drop down list that will have 4 columns. So far, the search works and I have headings in the search, but I cannot seem to make the columns for the actual data. I believe I need to change the type_ahead since the array is looking at this data. I'm stuck in the water. Can someone tell me what I need to do to get the list to show up as columns? How do I turn the picked = type_ahead data into four columns? Code and Screenshot below:
    picked = type_ahead (["bat", "bear", "beaver", "bee", "cat", "cats_and_dogs",
    "dog", "maggot", "moose", "moth", "mouse"]);
    function type_ahead (array)
    var w = new Window ("dialog", "Quick select");
    var entry = w.add ("edittext", [0, 0, 800, 22]);
    entry.active = true;
    var list = w.add ("listbox",  [0, 0,800, 500], "",
    {numberOfColumns: 4, showHeaders: true,
    columnTitles: ["Non-Approved Word", "Approved Alternative", "Approved Use", "Non-Approved Use"], columnWidths: [200,200,200,200]});
    list.selection = 0;
    entry.onChanging = function ()
    var temp = this.text;
    list.removeAll ();
    for (var i = 0; i < array.length; i++)
    if (array[i].toLowerCase().indexOf (temp) == 0)
    list.add ("item", array[i]);
    if (list.items.length > 0)
    list.selection = 0;
    entry.onChange = function () {w.close (1)}
    if (w.show () != 2)
    return list.selection.text;
    else
    w.close ();

    Hi Peter,
    This is one of those developments that push the limits of my knowledge-base and when things do that, I lose sleep until I figure it out. With that said :-) here is where I have ended up.
    Basically I made a new array for the table data.  I then use an array lookup to sort the array in the listbox based on the 0 array item. See the code below. Once it is loaded type in "b" and the list will start to sort.
    I need to try to get this to work as a pallete instead of a dialog box. Do palletes support this type of functionality?
    var newarray = new Array(
    new Array('Butterfly ','has wings','can fly'),
    new Array('bohemith moth','has wings','cannot fly very good'),
    new Array('word 3','replacement word','use case'));
    picked = type_ahead (newarray);
    function type_ahead (array)
    var w = new Window ("dialog", "STE Checker");
    var entry = w.add ("edittext", [0, 0, 800, 22]);
    entry.active = true;
    var list = w.add ("listbox",  [0, 0,800, 500], "",
    {numberOfColumns: 3, showHeaders: true,
    columnTitles: ["Column 1",  "Column 2", "Column 3" ], columnWidths: [200,200,400]});
    list.selection = 0;
    entry.onChanging = function ()
    var temp = this.text;
    list.removeAll ();
    for (var i = 0; i < array.length; i++)
    if (array[i][0].toLowerCase().indexOf (temp) == 0)
    with (list.add ("item", array[i][0]))
    subItems[0].text = array[i][1];
    subItems[1].text = array[i][2];
    if (list.items.length > 0)
    list.selection = 0;
    entry.onChange = function () {}
    if (w.show () != 2)
    return list.selection.text;
    else
    w.close ();

  • Query Report - To display additional column in list selection box.

    Hi,
    There is query report where i want to display the additional column in list selection.
    Below is the system query report, where parameter passed is card code.
    When the cardcode - list selection is clicked system displays 2 columns i.e. Customer Code & No. of Records.
    Now in the same list selection; is it possible to display the customer name along with cardcode only for reference.
    SELECT T0.DocDate, T1.SlpName, T2.Name, T0.DocDueDate, T0.DocNum,    (CASE WHEN T0.DocStatus = 'O' THEN 'Open' ELSE 'Closed' END) AS Status,    T0.DocTotal FROM OQUT T0 LEFT JOIN OSLP T1    ON T0.SlpCode = T1.SlpCode LEFT JOIN OCPR T2 ON T0.CntctCode = T2.CntctCode WHERE T0.CardCode = N'[%0]'    ORDER BY T0.DocNum DESC
    Kindly let me know the details.
    Thanks & Regards,
    Yogesh Jadav

    Hi Yogesh Jadav,
    The answer is NO.  You may only display either code or name but not both.
    Thanks,
    Gordon

  • List selection bean

    Does anyone know where I could grab a "list selection bean" of some sort...I'm thinking the kind of widget that shows two lists. The list on the left is all available options while the list on the right can have 0 to n entries. The user selects items from the left list and puts them in the right, or removes items from the right list putting them back in the left list by pushing buttons with right/left facing arrows (or whatever) located in the center of the dialog between the two lists. Buttons on the bottom include the typical "OK", "Cancel". I'm writing some displays that require this sort of dialog to gather info from a user and am hoping I don't have to re-write the bean as I imagine several people have already accomplished this!
    Thanks!
    Dove

    It is actually not too hard to write. Create a JPanel with a TableLayout or a BorderLayout. Insert a JScrollPane each with a JList on the left and right. Grab both JList model's so you can insert/remove directly to the model. Now, in the event handler of --> you do something like:
    Object o[] = leftList.getSelectedValues();
    for (int cntr = 0; cntr < o.length; cntr++)
    rightListModel.addElement(o[cntr]);
    leftListModel.removeElement(o[cntr]);
    This would get any selected items on the left, move them to the right and remove them from the left. You would probably have to add:
    rightList.updateUI();
    leftList.updateUI();
    just to be sure both repain themselves.
    I believe that is all I used. Works great. Then, when you are ready, you get the selectedValues() from the rightList object and you are set to do what you need. Moving one or many is the same code, and the reverse is done just as easily. Removing all from either side is just as easy as well.

  • Alert is not working for mutiple times for list "select" function in sapui5 XML view

    Hello All,
    I am trying to open an alert for multiple times for list "select" function. But it's opening for only one time .
    Please find code below.
    View Part
    <List id="contactedit" select="somefunction">
        <CustomListItem id="custom1" type="Inactive" >
    <content>
    <Label text="this is label" />
    </content>
    </CustomListItem>
    </List>
    Controller Part
    somefunction: function(oEvent){
    alert("this is an alert");
    Thanks in Advance
    D.Mohanbabu

    I think I saw this question in stack overflow. And I answered it :-)
    I believe that it is because you can only one item in the list and once the item is selected, re-selecting it will not fire the event.
    Try adding more items to the list and select different items.
    Thanks
    -D

  • Selection indicator greyed our in 'Assign' tab of Dimensions

    Hi All,
    We are on 3.5 trying to re-design cubes for performance. While re-designing, the selection indicator against the characteristic is greyed out in edit mode. This is after deleting the data from fact and dimension tables.
    Please let me know if we are missing out anything.
    Regards
    Sudeepti

    Hi,
    Re-designing means u r adding any char in to u r cube .what ever it may be which u want add any char. its there in the data source or else u r doing the any Repartitioning.
    Can u give me details.
    Regards,
    Anil

  • Tile List folder contents

    I'm want to use the mx:TileList component to display the pictures in a folder. What would I put as the data provider? and what would I put in the item renderer?
    Item Renderer:
    <mx:VBox xmlns:mx="http://www.adobe.com/2006/mxml"
    horizontalAlign="center"
    verticalAlign="middle">
    <mx:Image source="" />
    <mx:Label text="" />
    </mx:VBox>

    Hi,
    Here are some links for displaying images in TileList. Hope this will help you
    http://blog.flexexamples.com/2008/03/08/creating-a-simple-image-gallery-with-the-flex-tile list-control/
    http://www.adobe.com/devnet/flash/quickstart/tilelist_component_as3.html
    Thanks and Regards,
    Pooja Kuber | [email protected] |http://www.infocepts.com

Maybe you are looking for

  • Time Machine and computer name change

    I just recently reinstalled the operator system after a computer crash when i did so changed the computer name and now when i go into time machine to restore the settings it only shows up as one sparse disc image. i have found that when i can mount i

  • Bridge not recognizing internal camera memory

    I've just transitioned my workflow back to a Mac environment (10.9.5) and have begun relying on Bridge CS6 to import my Canon Vixia HF20 AVCHD files directly from the camera. It works beautifully with anything saved to the SD card. However, Bridge wo

  • Can anyone plz tell how to bundle a color box?

    Hi all,  I am trying to pass the color of a color box control from one vi to another vi by bundling it into a cluster and passing the values. There are some other values also which are bundled along with the color. In the second vi when i tried to un

  • Want a new feature; turn off auto-spelling completely

    Please give us the ability to disable this "feature", especially when texting it is very annoying.

  • How i can do 3 partition on Macintosch HD disck?

    Goodmorning, my question is: - HOW I CAN DO 3 PARTITION ON MACINTOSCH HD DISCK? Now i have 2 partition: the first is for OS X Yosemite, the second for Windows 8. I want create a new partition for a new OS (windows 7 or Linux). How i can do it? I have