Actionscript 3 :: Spark Container Not Hiding Contents Outside Of Its Body

Feb 7, 2012

This is what what my screen looks like:

It is composed like this :

First container <s:HGroup>(900 X 100)--top black area
Second container <s:Group> (900 X 475)--middle white area
Third container <s:HGroup>--(900 X 100)--bottom black area

If the project were done with Flex 3, the middle area would be an <mx:Canvas>.

Now suppose I have one BorderContainer(125 X 475) and name it middleContainerChild. It is located on the right side of the middle area. When I set its y postion to -middleContainerChild.height, it should be located at y = -475, outside of the container's body. And as you can see in the image above, it has been placed there.

But other than with <mx:Canvas>, the image still shows, even though it is no longer within the <s:Group>s body, and it is rendered "on top" of the <s:HGroup>.

See the image below for more clarification:

If I use <mx:Canvas>, it is hidden away properly, but if I use a Spark container (not only a group, but any Spark container), it remains visible.

View 2 Replies


Similar Posts:


Flex :: Hiding A Tab In A Spark TabBar?

Feb 3, 2012

I have a spark TabBar and I want to hide and show some elements of it from an external user input (namely a checkbox check)

I am having trouble changing the tabs visibility. They are currently always shown.

I have seen a getTabAt on the mx TabBar but the look of the tab is important and the requirement is for it to look like a tab bar rather than a button bar.

My code for the tabs and for hiding and showing is below:

<fx:Script>
<![CDATA[
import mx.containers.VBox;
import mx.controls.Label;

[Code].....

View 1 Replies

Flex :: Spark ItemRenderer Not Showing Contents?

Mar 1, 2011

i have a spark list component and a corresponding custom itemrenderer:

list component:

<s:List id="albumImagesList" itemRenderer="the.namespace.for.XYZImageRenderer" useVirtualLayout="false" width="400" height="160">
<s:layout>
<s:TileLayout requestedColumnCount="5"

[Code].....

it's all fine and dandy, the data gets populated correctly and i verified that the data.image_path property arrives safe and sound inside the itemrenderer.

my only problem is: the image is not displaying. i am not sure if it doesn't render at all or if it's just not visible somehow.

View 3 Replies

Flash :: Check Spark DataGrid Cells' Contents Programmatically?

Jan 24, 2012

I'm using the Spark DataGrid for the first time and finding it generally very usable.There's something I'd like to do with the contents of my grid now that I've drawn it though and I'm a bit stuck as how to proceed.I'd like to make a function that runs through each cell of a certain column in the DataGrid, that checks each value against an Array of predefined values; if it finds a match, it should then highlight the cell as conflicting, by changing its colour.I know you can access a particular cell's item renderer, by using the getItemRendererAt() function, and passing the column and row indices. But I can't see how I would, for example, loop through the values in each column

View 2 Replies

Flex :: Set Spark Element's MaxHeight To 100% Of Container's

Aug 22, 2011

I have a list component with a (row oriented) tile layout in a group that sits in the main Application. I want the list to be centred vertically when there are not enough items in to fill the application window height, so verticalCenter="0". However, when there are more items than can fit vertically on screen, the list expands beyond the application window height and the scrollbar doesn't kick in. I can remedy this if setting the list height to 100%, but that means it's not vertically centred when it contains less items. The ideal solution would be maxHeight="100%", but of course maxHeight doesn't work with percentages. How would I go about achieving this behaviour?

[Code]...

View 1 Replies

Flex :: Make A Container Resize Based On The Size Of Its Contents?

Mar 16, 2010

I'm trying to create a Flex application that can automatically shrink based on the size of the components that it contains, so that a user can shrink it to a minimal view to see more of the HTML page it's embedded in.

I know how to change the size of the whole application using ExternalInterface, but I'm having trouble automatically figuring out how much the size changed when something is hidden or shown.

For example:

Let's say I have the following flex layout:

<?xml version="1.0" encoding="utf-8"?>
<mx:Application xmlns:mx="http://www.adobe.com/2006/mxml" layout="vertical">
<mx:VBox width="100%" paddingTop="0" paddingBottom="0"

[Code]....

How can I hide one of the text fields and cause the VBox to shrink? I'm currently setting it to visible = false, but that doesn't seem to affect the parent VBox.

Once the VBox shrinks, how can I detect that the Application no longer needs so much space, and then go about figuring out how much less space it needs?

I've tried using ResizeEvent, but I haven't been able to get them to work, but I could be doing something wrong.

View 1 Replies

Flex :: Flash - Spark Application Container Disable Scroll Bars?

Jun 22, 2011

do I have to necessarily have a application container as the root node in my mxml file?econd, I was reading this document on adobe's website and it says that the spark application container has no scroll bars by default and they can be added by using a custom skin. (Look at the table comparing the mx and spark application containers). But my problem is that my application container already has scroll bars by default and I want to get rid of them. I have a main application container with a custom child component that already has scroll bars. I just want the child to have the scroll bars and not the main application

View 2 Replies

Flash :: Flex Spark Application Container Disable Scroll Bars

Nov 26, 2010

I have to necessarily have a application container as the root node in my mxml file? Second, I was reading this document on adobe's website and it says that the spark application container has no scroll bars by default and they can be added by using a custom skin. (Look at the table comparing the mx and spark application containers). But my problem is that my application container already has scroll bars by default and I want to get rid of them. I have a main application container with a custom child component that already has scroll bars. I just want the child to have the scroll bars and not the main application. Right now I get 2 scroll bars nested within each other.

View 2 Replies

Actionscript 3.0 :: Send HTML Form Contents And Flat-file Contents To Flash?

Oct 20, 2010

I have built a simple Flash application that will be presented using a projector, the application will show messages in the form of questions that will come from a simple flat-file text file or XML file.

In addition to this I would also like to be able to add my own messages using a simple HTML form.

I've been looking around the web for some resources, but have been struggling to find what I am looking for. The basic idea is that the flash application will loop through these different messages from the XML, but then when a user types in a message that will also appear within these messages. Think of it as a sort of dynamic tag cloud.

View 2 Replies

Edit Contents - Delete Contents Of The Layer And Then Add The New Clip?

Oct 12, 2009

I'm customizing an xml flash website and while I can handle all the html and xml well enough, but in Flash, I have no clue how to:
Now go on the stage, and delete the contents of the last layer(background & pattern). Here, add from the library, the square movieclip, and name it mcBackColor(see attached image).And then to add your swf background in the "background & pattern" layer from the main.fla file.
 
I can change the name, but don't know how to delete just the contents of the layer and then add the new clip.I've made a slideshow before and that's all I can do.

View 1 Replies

ActionScript 3.0 :: Spark Scroller, Switch Focus To Spark View But It Still Scrolls

Jan 26, 2012

I am working on a drag and drop feature for the sparkScroller. This is sort of how my layout looks:
 
<mx:Canvas>
<s:Scroller id="items" .. />
<mx:Box id="dummyRow" visible="false" />
<s:View id="touchView" visible="false" />
</mx:Canvas>
 
So when you hold your finger over a row in the items Scroller for more than a 30 seconds, the touchView becomes visible so does the dummyRow. The dummyRow gets populated to look like the row which you held your finger over.
 
So the touchView has the event handlers for moving your fingers and places the dummyRow where your finger is. The problem I am having is even though the touchView is reacting to my move events, the scroller still keeps reacting to my move events as well even though it's a sub layer. Because I started on the scroller it still keeps track!
 
How can I remove focus / tracking from the scroller?

View 1 Replies

Actionscript 3 :: Spark Images In Spark List With TileLayout Disappear On Scroll And Drag In Flex App

Jul 1, 2011

I have a renderer that looks like this:

[Code]...

Loading thumbnails using this method works perfectly. The issue happens when you scroll the List.

View 1 Replies

Flex :: 4 - Add Component To Title Bar Of Spark Panel Or Spark TitleWindow

Feb 7, 2011

I'm looking to add a couple of buttons to the title bar of a Spark Panel or Spark TitleWindow. Is this possible to do without making the panel from scratch?

View 1 Replies

Flex :: Prevent Container In ItemRenderer From Exceeding Width Of List Container?

Jul 2, 2011

In a Flex Mobile project I have a simple itemRenderer where I'm trying to create an "bubble" texting effect, similar to ichat or iphone (just so you get what im going for). But if the text is longer than the screen it runs off, rather than just going down a line.

If I set Group thats holding the rectangle(to create the bubble effect) and the label to 100% it works and keeps it from exceeding the list containers bounds, BUT the group is always at 100% and looks bad, I'm trying to keep the "bubble" JUST AROUND the text.

Anyway so, at the top of my itemRenderer I tried specifying:

<s:ItemRenderer xmlns:fx="http://ns.adobe.com/mxml/2009"
xmlns:s="library://ns.adobe.com/flex/spark" width="100%" height="100%">

And here's my layout I figured since msg_container has a width of 100% I was hoping bubble_lable_group would just not exceed that but...it doesnt...it just runs off. I tried setting a max width but that does not allow you to input percents. And just to say it 1 more time. I know if i set bubble_lable_group width to 100% it works, and keeps it from going off the edge, but then the rectangle "bubble" stretches all the way across and just looks bad.

<s:VGroup id="main_container" horizontalAlign="left" paddingBottom="10" paddingTop="10"
verticalAlign="top" width="100%">

[Code]....

View 1 Replies

Professional :: Run Project (main Container SWF And Child SWFs) Into Another Container File Which Place On A Website?

Jun 17, 2010

I am facing a issue in Flash container. I am having a project which has main container which call different SWFs into it. Now I call this main container file into another container, and their problem starts. Many option doesn't work properly which generally have _root, _parent etc...
 
If I want to run project (main container SWF and child SWFs) into another container file which place on a website. I want to show whole project from this container file so what I need to do?

View 1 Replies

Flex :: Dynamically Adding Container To A Dynamic Container

Sep 21, 2011

I have a loop that goes through data from a book and displays it. The book is not consistent in it's layout so I am trying to display it in two different ways. First way(works fine) is to load the text from that section in to a panel and display it. The second way is to create a new panel (panel creates fine) and then add collapsable panels(nested) to that panel. Here is the code from the else loop.

else if (newPanel == false){
// simpleData is just for the title bar of the new panel
// otherwise the panel has no content

[Code]....

The error I get is: ReferenceError: Error #1069: Property panel4.4 not found on components.readTest and there is no default value.

I have tried setting the "name" property instead of the "id" property.

View 1 Replies

Flex - Hide Container Of A Viewstack Container?

Dec 23, 2010

I have a viewstack container w/ 3 views: red, black, and blue. How can I completely hide the black & not include it?

[Code]...

View 2 Replies

Flex :: Drag Circle From One Container To Another Container?

Jan 13, 2012

I am creating an flex Air project,so mxml file will run. I have circles in one Big circle at one side and will be same on other side.

Now how to drag any circle from any Big circle to other side. Or it could be like any two container having circles, then how to drag and drop circle?

For one circle i am able to do drag and drop.But I want one Big circle on left hand side and one big circle on right hand side .And small circles with class names will be in these big circles.Now i want to drag and drop those small circles in big circles.Big cicles should not move. Even i have tried this code in actionscript

package
{
import flash.display.Sprite;
import flash.events.MouseEvent;

[Code].....

But in this i want big circles should not move and small circles should only be dragged.

View 1 Replies

ActionScript 3.0 :: Scale Container In Another Variable Container?

May 6, 2010

I need to place an image into a container. The problem is that I will not know the size of the image or the container beforehand, so it all has to be dynamic.this is how I started (have not gotten to stage(or container) changing size yet. No matter what I try, either all the images are the same width, or they are all the same height. If some images are portrait and other landscape, I don't want all the images to be X pixels high. In this variation of the code, all the images turn out the same height, regardless of portrait or landscape.

ActionScript Code:
var ratio:Number = container.width/container.height;//get the ratio, if width is bigger than height then ratio is greater than 1, else ratio is smaller than 1

[code]........

View 0 Replies

ActionScript 2.0 :: Main Contents Change Size And The Menu Position According To The Size Of Main Contents?

Nov 10, 2003

i want to know how did the creator of otradesign accomplish the effect in his site like the menu and the main contents change size and the menu position according to the size of main contents.

View 5 Replies

Flex :: Moving Children Of A Container (defined In MXML) Inside An "inner Container"

Jan 27, 2010

I'm currently working on a custom component which extends Canvas (let's call it SuperCanvas) ; it's basically a container that let you zoom & pan its contents. It would be too long to explain why, but I can't use scrollRect, so I was forced to declare a Canvas object (called innerCanvas)... inside my SuperCanvas (I know, not very nice =/) I would like to know if there's a proper way to "redirect" the creation of my component's children in this canvas.

[Code]...

View 1 Replies

ActionScript 3.0 :: Navigation - Function Has No Body

Jan 24, 2012

I am trying to create the code for a navigation in Actionscript 3, but I get the error "Function has no body". And the test just plays over and over without stopping?

// Navigational code
stop();
import flash.display.*;
import flash.events.Event;
function myReceiver(event:MouseEvent):void{
[Code] .....

View 2 Replies

Professional :: Where Is Body Line Of HTML

Jul 15, 2006

Ive been advised to do the this to get rid of borders within my HTML page [code]Im new to flash so im unsure where the body line of My HTML.is and where to paste the command

View 3 Replies

Flash :: Get Position Of A Static Body?

Apr 14, 2011

I have a Box2D world with a mixture of static and dynamic bodies. On collisions, I can only get the positions of the dynamic ones.

Is it possible to get the positions of static objects?

N.b., this is a development of a previous question, Box2D: How to get the position of a sensor?

View 1 Replies

ActionScript 3.0 :: Add An Image To The Email Body?

Jan 27, 2009

I want to send an email with the image through URLRequest.

How can I add the image to the email body ?

Something like this:

var request:URLRequest = new URLRequest("mailto:"+to.text+"?subject="+subject.t ext+"&body="+body.text+"&Attachment="+myBmp);

View 1 Replies

ActionScript 3.0 :: Get Response Body When URLLoader Gets 404?

Jun 21, 2009

I m using URLLoader to send a post request. The server returns HTTP code 404 in case the parameters are wrong, and puts the error message in the response body.Get resoinse body when URLLoader gets 404

The problem is that if the response has code 404, the IOError listener is called and I can't see the body of the response.

Is there a way to tell the URLLoader to ignore HTTP codes and always call the Completed listener?

Or maybe there is a way to get the response body in the IOError listener throw the IOErrorEvent? I couldn't find such a way.

View 2 Replies

ActionScript 2.0 :: XML Flash Menu + CSS Body ID's?

Aug 1, 2005

I've got a fun problem for ya'll. I've got an XML flash menu with sub menus and all. When you click and menu item with a sub menu, the menu expands nicely. When you click to navigate to a new page the menu "closes" to its basic appearance...

What I'm trying to do is have the menu expanded at the appropriate point automatically if you're on a sub menu page. I've been thinking how to do this and I'm guessing CSS would be the key. Could the flash menu detect a BODY ID and expand appropriately should it detect the right body id.Check out the ZIP file for source files HTML/CSS/FLASH/XML.

View 1 Replies

ActionScript 2.0 :: Flash Menu + Html Body = 1 Swf (CS3)?

Aug 2, 2010

This clients site has a flash menu, but the content of the page is in html. I know how to write the actionscript so that each menu button links to a different html page. However, I would also like the flash menu to show each page buttons link as "Active" when its on that certain page.For example, I'm on the home page. The "home" link in the flash menu is hilited. I click "products", and the products.html loads. I'm not sure how to write the actionscript so that the "products" link in the flash menu is now hilited. The only way I know to do it, would be to create a different menu.swf for each page. But I'm sure there's a way to do it using only one menu.swf.

Also, I'm doing the menu.swf on a timeline in the fla. I'm not sure how to do it otherwise or if what I need can be done on a timeline.

View 4 Replies

ActionScript 3.0 :: Posting Code Within Body Of Message

Aug 18, 2009

How do you post code within the body of a message, so that it is formatted and set apart from regular text. I haven't seen where this is listed in FAQ.

View 5 Replies

ActionScript 3.0 :: Error Popup - Function Does Not Have Body

Aug 24, 2011

I have a problem running this program. An error "function does not have a body" pops up.
stop();
import flash.events.MouseEvent
start_.addEventListener(MouseEvent.CLICK, onClick);
function onClick(event:MouseEvent):void
gotoAndStop(1,"Scene 247");
gotoAndStop(1,"Menu");

View 2 Replies







Copyrights 2005-15 www.BigResource.com, All rights reserved