Tracking Forums, Newsgroups, Maling Lists
Home Scripts Tutorials Tracker Forums
  Advanced Search
  HOME    TRACKER    Flash


Advertisements:










Flex :: VGroup: How To Have A New Element Show Up Smoothly (resize) When Added/removed


When adding/removing elements to/from a VGroup I need it to happen smoothly, resize the item. I believe I have to use transition effects. But how?

At item (element) level? At VGroup level? Should I use a DataGroup instead and do it at ItemRenderer level?

I've been trying to do it at item level but I still didn't manage to make it work and somehow it doesn't feel right. It feels like it should be done at a higher level.

For example, I defined a "death" state which resizes the item to height=0. But then, after it shrunk, it has to somehow notify VGroup in order for it to be removed or remove itself from VGroup. It feels unnecessarily complicated.

way to associate an effect to inserting and removing items from a VGroup?


View 2 Replies (Posted: Apr 20 11 at 12:33)

Sponsored Links:

Related Forum Messages For Flash category:
Flex :: Float - 4: While In A Vgroup - Add A Moveable Element That Won't Be Part Of The Vgroup?
I created several components that are placed inside a VGroup. in one of the components code, i want to add an image and to move it. i don't want the image to be part of the vgroup and to be bound to the vgroup area, i want it to be like float in css. how can I do that?

update I want to be able to move the element in the entire area of the application. not to move it within the vgroup. i don't want this object to be attached to any container besides the main application window in order for me not to have limits how much can i move it and where.

[Code]...

Posted: Jun 22 10 at 17:17

View 1 Replies!   View Related
Actionscript 3 :: Flex: Find Which Element Is Clicked In Vgroup?
I am dynamically creating 10 textinputs inside a vgroup . when user clicks a button, I want to fetch the text present on all textinputs. How to do this. My code looks like this

var vgroup:VGroup = new VGroup;
for(var i:number=0;i<10;i++){
var textinput:TextInput=new TextInput();
vgroup.addElement(textinput):
}

Posted: Aug 26 11 at 6:29

View 1 Replies!   View Related
Flex :: Add Mxml Element Once It Has Been Removed From Display Object?
I have some MXML elements which i would like to remove and add to a parent element. Unfortunately I am constrained to removing the MXML object as this is handled by the custom component. So is there any way to reinstate a removed MXML element back into the display list?

Posted: Jul 1 10 at 11:50

View 1 Replies!   View Related
Flex :: Allow A User To Smoothly Resize Elements In It?
I have a Flex 3 app that has elements that a user can add to the main canvas then resize and reposition.

There are 3 key functions I am using for the resize which are as follows[code]...

Posted: Jun 28 11 at 14:24

View 1 Replies!   View Related
Actionscript 3 :: Button Removed With RemoveChild() Gets Re-added In It's Over State?
I have a SimpleButton on the stage, and in the click event for it, I remove it using removeChild(). When re-adding the button, it gets re-added in it's "over" state, not the "up" state as expected.

I'm pretty sure it's a bug, so I've filed a JIRA:[URL]..What I've tried: sing visible = false instead works, but I'd prefer to remove it off the stage altogether as the game I'm working on can have a lot of popups/screens. Firing the mouse_out event manually - doesn't work, and in any case, the mouse_out event fires as expected (perhaps before resetting to the up state, it makes a check to see if it's added to the stage, finds out it's not, then quits early)Resetting the stage focus - I thought it was a problem with the stage focus, as you were losing focus when the button was hidden, but resetting it didn't fix it.I could temporarily swap the over and up state when it's hidden, but that seems like an ugly fix.

Posted: Sep 5 11 at 9:33

View 1 Replies!   View Related
ActionScript 3.0 :: ADDED Event In Document Class After Removed From Stage?
I am currently play with the document class (the class acts as main) constructor for a SWF file.

package {
import flash.display.*;
import flash.events.*;
public class TestSymbol extends MovieClip
{
public function TestSymbol()

[Code]...

Posted: Aug 16, 2010 1:09 AM

View 9 Replies!   View Related
Flex :: Why Doesn't ListCollectionView Show New Items Added To The Underlying List
I have an (empty) ArrayCollection that I wrap with a ListCollectionView. Then I add a series of items to the ArrayCollection, but these are not showing up in the view.

public var transactions : ArrayCollection = new ArrayCollection();
public var filteredTransactions : ListCollectionView = new ListCollectionView(transactions);

transactions contains 150 items, filteredTransactions contains none. I originally thought it was the filter I was applying, but even when I remove the filter, I still get no items in the filtered list.

Do I need to add the items to the view as well as the underlying collection (this would seem to defeat the purpose of using a view though...)?

Posted: Jun 20 11 at 4:20

View 1 Replies!   View Related
Professional :: Can Load All Images First So That Rest Of The Slide Show Runs Smoothly
in XML gallery , how we can load all images first so that rest of the slide show runs smoothly

For example: I have placed 10 images in XML , when slideshow starts , all the effects not appears , because it waste time in loading each image on its turn I want to load all images first , then want to start the slideshow how i load all images at the start ?

Posted: Jan 22, 2010 7:00 AM

View 3 Replies!   View Related
ActionScript 3 :: Call Just Added MovieClip Element
I'm adding a movieclip element ("lastSlide") to an other movieclip element("endLogoButton"). The added element has a child which is a button("endLogoButton"). How can I call that button?
mcSlideHolder.addChild(lastSlide);
/*mcSlideHolder.getChildByName("endLogoButton").buttonMode = true;;
mcSlideHolder.getChildByName("endLogoButton").mouseChildren = false;
mcSlideHolder.getChildByName("endLogoButton").useHandCursor = true;*/
lastSlide.endLogoButton.addEventListener(MouseEvent.CLICK, linkClick);
It always tells me that the access to a Nullobject reference is not possible.

Posted: May 16 11 at 16:41

View 2 Replies!   View Related
ActionScript 2.0 :: Check An Array To See If An Element Has Already Been Added?
is there a way to check an array to see if an element has already been added? I'm working with an XML document where there are 4 possible variables, but these 4 vars are repeated several times over. It's reading in fine... I just want to pull those specific variables out of the XML and add them to an array, but I do not want them to duplicate. To say it another way... I don't want my array to be more than 4 items long (it is possible to be less) with a max of those 4 different vars.

Posted: February 4th, 2005

View 1 Replies!   View Related
ActionScript 2.0 :: Check An Array To See If An Element Has Already Been Added?
is there a way to check an array to see if an element has already been added? I'm working with an XML document where there are 4 possible variables, but these 4 vars are repeated several times over. It's reading in fine... I just want to pull those specific variables out of the XML and add them to an array, but I do not want them to duplicate.I don't want my array to be more than 4 items long (it is possible to be less) with a max of those 4 different vars.

Posted: February 4th, 2005

View 1 Replies!   View Related
Flash :: Using A Vgroup As A Drop Target In Flex
Is it possible to use a VGroup as a drop target in flex? I like the functionality of a vgroup (adding elements easily, etc) but I haven't found a way to get it to register when things are dropped on it.

Posted: Dec 3 10 at 19:43

View 1 Replies!   View Related
Flex :: Use VGroup Or HGroup In Pure Actionscript3?
I'm developing a flash app by using free Flex SDK and text editor and compiling in command line.

I want to use VGroup or HGroup in my actionscript to manage positions of DisplayObjects.[code]...

Posted: Sep 3 11 at 2:11

View 1 Replies!   View Related
Actionscript 3 :: FLEX 4.0 Vgroup Seems Not To Draw Their Elements?
I got a component made with an spark Group for a survey, inside of it I have an algorithm that create the questions putting RadioButtons inside of a VGroup(dynamically).The problem is that sometimes when I call the next question, I couldn't find why, they are not drawn unless I click the right mouse button so it appears normally.

public function nextQuestion(event:MouseEvent):void
{
destroyQuestion();[code].....

So, when I run the application and I move through the questions, sometimes, the question is not drawn (exemple: I'm at question 2 and I move to the third question and it's blank, but if i press the right button in my mouse the question suddenly appears. So I move to the fourth and everything seems right)

Posted: Jan 23 at 17:48

View 1 Replies!   View Related
Flex - Find The Color Of A Pixel At A Point Within A VGroup?
I'm having trouble with this code

var imageMap:ImageSnapshot= ImageSnapshot.captureImage(object);
var pixelValue:uint = imageMap.bitmapData.getPixel(x, y);

Posted: Jul 29 11 at 8:49

View 1 Replies!   View Related
Flex :: VGroup Or List Doesn't Fit Into TileWindow, Is Too High
how to make the List and Checkbox (inside a VGroup) to fit into a TileWindow?

The complete source code Text.mxml:

<?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"

[Code].....

Posted: Nov 27 11 at 17:36

View 1 Replies!   View Related
Flex :: Change S:VGroup Height When Child.visible Set To False
I have a code similar to this:

<s:VGroup>
<s:HGroup verticalAlign="middle">
<s:Label text="label" />
<s:TextInput id="rmName"/>

[Code].....

I want that the s:VGroup container has the height only of its visible children. In this example there is a free space even the visibility mx:HorizontalList is set to false. Every time I change the visibility of the child element I want that the parent (s:VGroup) will change his height. How to do this in flex?

Posted: Nov 12 10 at 19:17

View 1 Replies!   View Related
Flex :: VGroup - (Parent) Container Does Not Change Height With Children?
I have code like the following:
<s:VGroup gap="10" id="group" height="100%">
<s:Label text="This is page 2" />
<s:Button content="Resize Canvas" click="resize(event);"/>
<mx:Canvas id="photoCanvas" color="#567898" backgroundColor="#125567">
</mx:Canvas>
</s:VGroup>

I don't understand why the following does not work:
Pushing the Button resizes the photoCanvas's height (gets taller or smaller). Since the photoCanvas control is a child element of the VGroup shouldn't the container update itself to the new height? The Vgroup has ALWAYS the same height, no matter what the (total) height of the children is! I would like the VGroup to adjust itself and get a height value equal to the sum of its children heights. Is this not possible??

Posted: May 13 11 at 20:40

View 1 Replies!   View Related
ActionScript 3.0 :: Stage Element Positions On Resize?
I'm creating a website within which I would like to achieve a menu system at the bottom of the page with a white band behind similar to this site:

[URL]

I have created the menu buttons and band but I can't figure out how to maintain their relationship with the edges of the browser window if it is rezised at any point during a user's visit (same as the site above).

I have been setting the position of the buttons and all other elements using, for example :

myBtn.y = stage.stageHeight - 100;myBtn.x = stage.stageWidth - stage.stageWidth + 50;

For publishing I use noscale, 100x100 percent, top-left justification.

Posted: Feb 2, 2011 9:41 AM

View 3 Replies!   View Related
ActionScript 3.0 :: Prevent Parent Resize When Children Is Added?
I have a rectangular movieClip named 'container'. In this movieclip, a function generates some number of squares.My problem is that; for example, if I generate 12x12 squares with each width/height of 40; it resizes the container to width/height of 480. If I set the width and the height of the container movieClip to a lower value; then the squares become smaller.I have been struggling for some time on this problem. I tried setting the ScaleMode of container and squares to various values but it did not work.How can I overcome this illogical (for me at least) problem? How can I prevent children from resizing their parent OR how can i prevent parent downsizing the children?

Posted: 12-23-2009, 10:28 PM

View 2 Replies!   View Related
ActionScript 3.0 :: Stop A Symbol Added Child Resize?
I'm making a map editor in flash. For the map area, a dynamic Movieclip will this and that in it will be loaded into a movieclip area, but I realised the problem of how a symbol resizes when a child is too big in the symbol.

Is there ANYWAY to stop it from it from doing this, as I want a specific window for this where you can drag the map around to see the other areas.

Posted: 10-19-2011, 03:38 AM

View 1 Replies!   View Related
ActionScript 3.0 :: Event Listener Being Removed Automatically When The Movie Clip Is Removed From The Stage?
if i have a movie clip with an even listener attached to it, is the event listener being removed automatically when the movie clip is removed from the stage or should i always remove the event listeners manually?

Posted: Aug 17, 2009 8:04 AM

View 4 Replies!   View Related
ActionScript 3.0 :: Add More Of Removed Children Of Same Namewithout Displaying Previously Removed?
I want to remove all children of the name (mc1) but be able to add new one when I call the add function again Heres what I have

// Draws the squares

Code:
function drawIt(e:Event=null):void{
mc1.graphics.lineStyle(1);
mc1.graphics.beginFill(ITsColor);

[code]....

Removing all the (mc1) movieclips works fine, but when i click on the butotn to call drawIt again, all previous mc1's are displayed again with the new ones

Posted: April 7th, 2011

View 2 Replies!   View Related
IDE :: Show One Array Element For 1 Sec?
I'm trying to make a memory like game. It might be called Simon or Simple Simon or something. Basically something is shown for a second and then gone, then the user clicks that something. Then two or three things are shown in order and then gone and the user clicks the order.

I'm stuck at the very beginning, just showing something from an array for half a second or so then stopping and then starting over and adding one more element.

Posted: April 14th, 2009

View 4 Replies!   View Related
Copyright 2005-08 www.BigResource.com, All rights reserved