Flex :: Cannot Move Custom Component Based On HGroup

Oct 30, 2011

I have created a custom component based on spark.components.HGroup and it works mostly as needed, but I have this minor problem: I can not move it.

Maybe someone will look at my simplified test case below and spot my error?

Here is the screenshot of my 3 custom components, representing chat bubbles:

Here my custom component Bubble.mxml drawing black text on green background:

<?xml version="1.0" encoding="utf-8"?>
<s:HGroup
xmlns:fx="http://ns.adobe.com/mxml/2009"

[Code]....

View 1 Replies


Similar Posts:


Flex :: Custom Component Based On A Group Disappears

Nov 28, 2011

I have a problem with a custom component based on a Group. Actually, I want to create a section component (a container with a border and a title). I created a path so that the border doesn't hide the label (title):

[Code]...

View 1 Replies

Flex :: Make PopUpManager Correctly Show Custom Component Based On Spark TitleWindow?

Jan 28, 2011

I use this code to create and show a MessageWindow:

var newTitleWindow:MessageWindow = PopUpManager.createPopUp(contextView,MessageWindow, true) as MessageWindow;
newTitleWindow.text = message;
PopUpManager.centerPopUp(newTitleWindow);

[Code]....

There is no nested components displayed when I run my app.

The debugger shows they are created and visible.

To my "amusement" the components are shown when I replace s:TitleWindow with mx:TitleWindow.

I really want to use spark TitleWindow.

View 1 Replies

ActionScript 2.0 :: Custom Component Based On Class With Labels

Oct 17, 2003

I am trying to build a component based on a class where when you enter a label at design time (in the properties panel), it displays on the component on the stage. This is done in all the FUI Components that have labels and I was wondering if any one knows which part of the code does this.

View 6 Replies

Actionscript 3 :: Flex 4 Disptaching Custom Event From Custom Component (why Flex Converting Custom Event To Mouseevent)?

Mar 2, 2012

This is NOT duplicate of my earlier post (its is slightly different)But this is similar issue with similar error but its not the same error The error I am getting now is below while dispatching the custom event from my custom component

TypeError: Error #1034: Type Coercion failed: cannot convert events::MapEvent@a74ab51 to flash.events.MouseEvent.
dispatchEvent(new MapEvent(MapEvent.CLICKED_ON_MAP));

Note: The error in my earlier post is giving below error message

Type Coercion failed: cannot convert flash.events::Event@81ecb79 to com.events.ShopEvent

The difference here are two things, the earlier error is while converting flash event to custom event and now this one is while converting custom event to flash event and secondly, I have no clue why it is trying to convert to the mouseevent where I am just dispatching my custom event with proper listeners.

This is my custome event

package events
{
import flash.events.Event;
import ui.map.MapElement;

[code]...

View 1 Replies

Flex :: Put Custom Code In A Custom Component In Flash Builder?

Dec 11, 2010

In the main file, I would write[code]...

But if I want the component to have that behaviour innately, where do I write it in the mybutton mxml file to have it reference itself?[code]...

View 2 Replies

Flex :: Make A Custom Component Or Extend The List Component For A 2D Top Down View MAP ?

Nov 11, 2010

I'm building a top view 2D map, that it's objects are stored on the server.The kind of objects are 10 and might be a photo, label, button, lists, mix of them or labels with tooltips.The component must request the "areas" that are missing on screen.An area is 1000x1000 px and is cached in flex.To move in the map, will be like in google maps (drag-and-drop).I should be able to have another list and move objects from one to another using drag-an-drop on objects. Ex.: I grab an objects from a list and I move it on this map, I release the mouse button and the item is placed there.Now the problem is: I build a custom component for this trying to emulate the item renderer for performance and recyclage, implement drag-and-drop on objects and request the areas that are missing?

or

I extend the List component from spark and I add some features as multiple kind of itemrenderers and use recycle on them. Of course it must be able to request the missing areas on the screen and cache it's data.Maybe create a custom layout is needed too.What I need is something that must be really fluid, so the lighter this component is, the better.

UPDATE: *There will be not any object over another.

*I will not use hitTest on bitmaps because all bitmaps are wrapped in another component,as they,for now are itemrenderers.

Anyway I already begin to do this using a class that extends the SkinnableDataContainer and a custom layout. As the layout is not like a grid, is sparse, random items at diferent points(x, y).How to get the localX and localY, relative to item renderer and not to the Spark List, from a DragEvent in Flex 4?

View 1 Replies

Flex :: Dispatching Custom Event From A Custom Component?

Sep 8, 2011

I have a custom Flex 4.5 component (to be used in a List) -

Game.mxml (represents a clickable playing table in a card game):
<?xml version="1.0" encoding="utf-8"?>
<s:ItemRenderer [code].......

But I never see the "game clicked: " trace. Does anybody please know why? I'm probably missing something minor, because I can see the "Clicked: 8946" trace.

View 3 Replies

Flex :: Disptaching Custom Event From Custom Component?

Feb 16, 2012

This is similar to the question asked here. I am dispatching custom event "ShopEvent" but i am getting error "Type Coercion failed: cannot convert flash.events::Event@81ecb79 to com.events.ShopEvent"Note: Error is thrown from the parent custom component (3rd code snippet), I have added more details thereThis is my custom event. See the first constant, I copy pasted the event name in custom components.

package com.events
{
import flash.events.Event;

[code]......

View 3 Replies

Flex :: Define Custom 'contentGroups' In A Custom Flex 4 Component?

May 12, 2010

The spark panel component for example can be written like this

<Panel title="Skinny">
<child components ... />
<controlBarGroup>
<child control bar components ... />
</controlBarGroup>

[Code]...

The motivation here is that I can now create a couple different skin files to change the look and layout of those subgroups. Reading source of the spark panel, there are some calls within the mx_internal namespace such as getMXMLContent() which is a method of the spark group component, but which I have no access to.

Does the description above make sense? How can I create custom 'contentGroups' in my custom Flex4 component that can use nested mxml child components? Should I approach this a different way?

View 2 Replies

Actionscript 3 :: Why Won't Visual Elements Display Inside Custom Component Extended From Another Custom Component

Sep 6, 2011

I created a custom MXML component, TurboContent, that extends the NavigatorContent class:

<s:NavigatorContent xmlns:fx="http://ns.adobe.com/mxml/2009"
xmlns:s="library://ns.adobe.com/flex/spark"
xmlns:mx="library://ns.adobe.com/flex/mx">

[Code].....

In this case, the 'myButton' component never shows up, but all the elements of the base component do (3 buttons and a datagrid).

View 2 Replies

Flex :: Event-based Interaction Between Two Custom Classes?

May 25, 2010

I have 2 custom components, which have their own nesting hierarchy ... One is container for another. I have to "familiarize them" with each other. The way I'm trying to achieve that is using global events (one side is firing and the other one is catching):

Application.application.addEventListener("Hello", function (data:Event):void{
// .. some actions
});

[Code]...

Then should be created the connection between container and it's child.

BUT, the only thing I could acheive is passing a reference to the Container in the DynamicEvent. Is there any chance that I could access the child at the event-handler function.

View 3 Replies

Flex :: Group - SkinnableContainer As HGroup?

Nov 30, 2011

I have a SkinnableContainer class called: 'GroupNavCustomContainer' that uses a skinClass called 'GroupNavCustomSkin'. The GroupNavCustomSkin is the default one Flex creates for you: (The default skin class for a Spark SkinnableContainer container). Now, I have to add buttons to the GroupNavCustomContainer dynamically from outside the class which is not a problem. However, I can't seem to figure out out to make my skin behave as a HGroup so the buttons are spaced evenly. I tried: modifying the Group container to no avail:

[Code]....

View 1 Replies

Actionscript 3 :: Use HorizontalGap In The HGroup In Flex 4.5?

Dec 29, 2011

How can I use horizontalGap in the HGroup in Flex 4.5? This function doesn't exist in the flex 4.5 like flex 3.

View 1 Replies

Flex :: Hide Hgroup On Condition

Mar 6, 2012

i have my hGroups as like [code]and i m trying to hide the hgroups on a condition when this bean tagInfoData have a value "notworking" otherwise it will shown..should i need to write code in the creation complete as all this is in a pop up window of the button click event.[code]

View 1 Replies

Actionscript 3 :: Flex Custom TreeItemRenderer That Changes Based On Type Of Object?

Oct 7, 2011

I have a Flex tree control that holds a tree full of various types of objects. I'd like to change the label of the item based on this type (and other properties). I'd prefer to do this in a custom TreeItemRenderer rather than via label or labelfunction.It seems that whatever I do, I cannot typecheck nor cast the objects and thus I get [Object object] in the nodes of my tree. Here is my renderer:

public class MyCustomTreeItemRenderer extends TreeItemRenderer {
// Overriding to set the text for each tree node.
override protected function updateDisplayList(unscaledWidth:Number,

[code]....

View 2 Replies

Flex Align A Image To The Rightmost Of The HGroup?

Jun 9, 2011

Is there a way to align an image to the rightmost of HGroup, which is setted to 100% width ?

here is my code, but it aligning the image "imageZoom" just after the object before it :

[Code]...

View 1 Replies

Flex :: Use VGroup Or HGroup In Pure Actionscript3?

Sep 3, 2011

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]...

View 1 Replies

Flex :: Xampp / Wamp Based Apache Server Custom Reply?

Feb 20, 2012

How can I send a custom response upon a custom request on a xampp/wamp based Apache server upon a connection to a specific port?I'm trying to reply to the � a flash app is requesting in order to allow a crossdomain http GET request.The flash policy request, is made to port 843 by default and i'd like to keep it that way.The port should get a � (ending with a null char,� is just for the reference) and replying with something like:

<?xml version="1.0"?>
<!DOCTYPE cross-domain-policy SYSTEM "/xml/dtds/cross-domain-policy.dtd">
<cross-domain-policy>
<site-control permitted-cross-domain-policies="master-only"/>

[code]....

As far as i know, the request should be return as a plain text, although Content-type, might be needed as well.I've tried using the following:[URL] and although it listens to the port and accepts connections, it doesn't reply with the specified xml upon request.I wrote a simple C# web server which listens to port 843, and serves the aforementioned policy - it worked out just fine, however, when using a SecureSocket connection for a secure connection (i.e opening a socket to a HTTPS/SSL protocol) - the request that is sent is encrypted using the hosts certificate. As far as i know, there's no way of listening or acquiring the servers certificate and decrypting the data via an external app hence, the only way is to somehow 'teach' Apache to respond with the crossdomain policy after a proper request is sent via an appropriate port.

Another idea i have is to read the server's certificate file stored in the Apache directory regardless of what happens on the server itself, though imo it's an overkill.

View 1 Replies

Flex :: Why Wouldn't A Flex Remoteobject Be Able To Work Within A Custom Component

Mar 31, 2010

I have a remoteobject within my main.mxml.I can call a function on the service from an init() function on my main.mxml, and my java debugger triggers a breakpoint.When I move the remoteobject declaration and function call into a custom component (that is declared within main.mxml), the remote function on java-side no longer gets called, no breakpoints triggered, no errors, silence.[code]

View 2 Replies

Flex :: Choose A MXML Component At UI Construction Time Based On The Value Of A Field?

Jul 17, 2009

I have a flex MXML UI that is building a set of radio buttons using the Repeater component:

<mx:Repeater id="radios"
dataProvider="{_lists.(@id == _question.single.@response_list).group.listItem}">
<mx:RadioButton groupName="responses"

[Code].....

View 3 Replies

Flex :: MouseOut Event Triggers Based On Old Component's Size After It Was Resized?

Mar 22, 2011

I have a component called X. I'm trying to make a menu come down from it when I put my mouse over it.

I have a mouseOver handler which changes the component's state to another state which shows an extra child component (the menu) on the lower part. This of course makes the X component grow.

I also have mouseOut event handler which makes the menu disappear by returning component X to its original state.

When I move the mouse over the component the menu appears as expected. But when I move the mouse down to the menu that is now visible, as soon as I touch it, it disappears. This way it's impossible to reach the menu.

I guess the mouseOut event is triggered as soon as I move out of the old boundaries. Is this so? And how can I avoid it? The new boundaries should now consider the extra child with the menu.

View 1 Replies

Css :: Flex 4 - Create A Custom Css Value For A Component

Nov 5, 2009

is there any way to create a custom css value for a component and have it available to the skin class that component is using? for example, if i define this in a css file:

[Code]....

is there a way to make myCustomValue available in the PanelSkin ?

View 3 Replies

Flex :: Event In A Custom Component?

Sep 11, 2010

I'm just getting started with custom events in a custom component. And I don't quite have the hang of it, yet. I've got a component with a button in it. When it's clicked, I want to call a function in the main app.

Custom Component:
<mx:Panel xmlns:mx="http://www.adobe.com/2006/mxml"
layout="absolute" >

[code].....

View 1 Replies

IDE :: Flex Application As Custom UI Component

Dec 22, 2009

I'm making a UI for a component in Flash. I wanted to use Flex and have had no luck getting the onUpdate exernalInterface call to fire properly. I'm referencing the functionality described here: [URL]. First off, I can't embed the SWF in the FLA. It just won't start the Flex SWF. Even using the external swf, it seems that the onUpdate function is either called too early or not at all. Here's what I've tried:

Tying the externalInterfce declaration to the initialize, preinitialize, applicationComplete, and creationComplete events. Sub-classing my application and putting the externalInterface in the constructor. Neither of these options work. When I create a basic AS3 project in Eclipse and put the externalInferface in the constructor, it works as expected.

View 1 Replies

Flex :: Changing The Position Of A Scroller Container Programmatically (by HGroup Index)

Feb 10, 2012

I am trying to change the visible index of a Scroller container on an event. The Scroller contains an HGroup with Images, so on an event I want to change which of the Images is visible in the Scroller by specifying an HGroup index. Is this possible?

[Code]...

View 1 Replies

Actionscript 3 :: Create Custom Flex Component In Flex 4?

Sep 6, 2011

I need to create custom component like [code]...

Here, I need to create custom component object, changing their element values and appending that custom component in VBox. What are the correct syntax to implement this one?

View 2 Replies

Flex :: 4 - Component Move Event Doesn't Work

Apr 6, 2010

I have a CustomTextInput component based on TextInput (Spark) component. The instance of this class is placed on a popup window (TitleWindow). How can I capture the popup move (dragging the title) event inside CustomTextInput implementation?

MoveEvent.MOVE event of the CustomTextInput itself doesn't work. Of course, I can't access the parent popup window inside the component implementation, because it's a common component that can be used not only on the popup windows.

View 1 Replies

ActionScript 3.0 :: How To Use Flex Custom Component In Class

May 27, 2009

Our software team has been developing flash applications using AS3 (via the FlashDevelop IDE and the free Flex SDK). Recently, some members of the team started exploring FlexBuilder and Flex (wow... why did we wait so long?). The problem is that some folks continue to develop using pure Action Script 3 (FlashDevelop) while others are creating custom components in FlexBuilder. How do the AS3 developers use the Flex Custom components built in FlexBuilder in their AS3 Applications?

View 7 Replies

ActionScript 3.0 :: Flex - Custom Component (swc) Won't Display?

May 29, 2009

I used a FlexBuilder Library Project to create a custom component library (swc). The custom component is a control bar with text fields and buttons, etc.The vast majority of our team's code is done in pure AS3 I've successfully included my new SWC in the lib and build path in our AS3 project.I've also successfully instatiated an instance of my custom component, but for some reason, it will not display. I know it exists, because 1) the compiler had no complaints, and 2) I can trace property values of the custom component and get valid output from the trace statement.

trainer.games.board.MatchThree {
import flash.display.Sprite;
public class Test extends Sprite{

[code].....

View 5 Replies







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