[flexcoders] Transparent background and HTML interaction

2007-11-07 Thread flashcrow2000
Hi everybody,

I have an existing ASP.NET page and I need to build some hovering flex
windows over existing HTML. I found this page
http://www.morearty.com/blog/2006/10/02/transparent-flex-apps-with-html-showing-through/
which explains how to do this (the same way as it was done in Flash)
but with one problem: there is no way (apparently) of interacting with
the HTML below the flash object.

You can guess where I'm going with thisis there a way of
interacting with the HTML objects below the flash object? (I currently
have a combo box and a button, in HTML, but they don't work).

Thank you



[flexcoders] load an image inside a UIComponent

2007-10-29 Thread flashcrow2000
Hello,

I have the following situation: I have an AS class which extends
UIComponent, and based on some settings read from an xml, I must load
an image, a movie or display a text inside that class.

When I'm creating the image, and adding it with addChild(imageObject),
if I don't set some values for width and height, it will not display.
Can I find out the original width and height of the picture after it
has been displayed this way?

As a quick remark, if I use parent.addChild(imageObject) (where parent
is Application), the image displays without any width and height set
(i'm using Flex 2), but i would like to have each picture displayed
inside the corresponding class.

Thanks!



[flexcoders] dynamic images and copy protection

2007-10-29 Thread flashcrow2000
Another crazy idea from my clients :).

I need to load images from xml, and also the client wants some
protection for the images. The only protection I can think of is to
embed them, but how can i do that if i have an xml which defines the
whole layout and content?

Encrypting them us not an option. Also, they have to run locally, so
loading the images from a server is also not an option.

Any ideas?

Can I embed images with dynamic paths? If so, maybe I can use MTASC
and recompile the SWF every time a picture or something changes.

Thanks



[flexcoders] Re: dynamic images and copy protection

2007-10-29 Thread flashcrow2000
Embedding the images in swfs might do the trick. the problem is that
the application will be used on some scales in supermarkets, so there
is no chance in hell i will be able to install a server or something
on those machines. Also, the application will start inside a canvas
from another application (to which i don't have access) so there is no
internet browser either.

If you have any other ideas, please do share. And thank you :)



[flexcoders] Re: A file found in a source-path must have the same package structure

2007-09-19 Thread flashcrow2000
When i usually get this error, I delete the package name and I hit
Ctrl+Space, and let Flex autocomplete with its correct value. It might
be a problem with the Folder name. I presume you have a folder list of
something like com/classes/Events (if no, you might consider using one)

--- In flexcoders@yahoogroups.com, droponrcll [EMAIL PROTECTED]
wrote:

 Hi, all;
 
 I'm working through the tutorial in the Flex Builder 2 Training from 
 the Source book, using Flex Builder 3 beta.  I accidentally called my 
 events folder Events, and now when I renamed it I get A file found 
 in a source-path must have the same package structure 'Events', as the 
 definition's package, 'events'.  I have changed the package name to 
 events from Events, and I've even tried deleting the file and 
 recreating it from scratch, but I still get the error.  I had similar 
 problems when I accidentally set the transparency of an AIR app without 
 turning off its SystemChrome.  No matter WHAT I did to that file, I 
 still got errors.  Unfortunately, I don't remember the fix to that.  If 
 anyone could give me a suggestion or two, I'd appreciate it.
 
 Thanks





[flexcoders] Re: drag and drop an image object, over a list object

2007-09-18 Thread flashcrow2000
Indeed it is. I expected the DragEvent to have something similar. If
someone needs this, it works like this:

private function onDragDrop(event:DragEvent):void {
trace(droped on:+List(event.target).calculateDropIndex(event))
}

Thanks Alex


--- In flexcoders@yahoogroups.com, Alex Harui [EMAIL PROTECTED] wrote:

 It is a method, not a property.  I assume you have a dragdrop event
 handler?  The one in LIstBase.as might serve as an example.
 
  
 
 
 
 From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
 Behalf Of flashcrow2000
 Sent: Monday, September 17, 2007 10:56 AM
 To: flexcoders@yahoogroups.com
 Subject: [flexcoders] Re: drag and drop an image object, over a list
 object
 
  
 
 Which is not an option for a List item. I tried using it from the mxml
 declaration (and it does not exist, according to Flash 2.0.1), and
 also from AS (of course, with the same result). If i'm doing something
 wrong, can you please provide a small code sample?
 
 Thank you Alex
 --- In flexcoders@yahoogroups.com mailto:flexcoders%40yahoogroups.com
 , Alex Harui aharui@ wrote:
 
  calculateDropIndex?
  
  
  
  
  
  From: flexcoders@yahoogroups.com mailto:flexcoders%40yahoogroups.com
 [mailto:flexcoders@yahoogroups.com mailto:flexcoders%40yahoogroups.com
 ] On
  Behalf Of flashcrow2000
  Sent: Monday, September 17, 2007 5:56 AM
  To: flexcoders@yahoogroups.com mailto:flexcoders%40yahoogroups.com 
  Subject: [flexcoders] drag and drop an image object, over a list
 object
  
  
  
  Hello all,
  
  I have the following problem: I need to be able to drag an Image
  object over a list, and make some operations based on the specific row
  i'm dropping that picture on. The list contains names of different
  people, and each picture I drag over one name becomes assigned to that
  person.
  
  I have the drag and drop capability all worked out (i'm using the
  DragManager of course, and the List object accepts the drop) but I
  can't seem to be able to actually find out on what row the user
  dropped the picture. Any ideas? (I'm sure it's simple, but I just
  don't see it yet)
  
  Thanks, 
  Cosmin
 





[flexcoders] web cam live feed

2007-09-17 Thread flashcrow2000
Hello all,

I know this is quite large, but can someone please point out what
technologies I need, and how can I build a webcam live feed?
Basically, I will have a laptop with a webcam, and users will be able
to connect at any time and watch live. This will be used for promoting
new products in more locations in the same time, so probably we are
not talking about video conferencing.

If any of you can point me to a tutorial on this, it would be great.

Thanks guys,
Cosmin



[flexcoders] Re: web cam live feed

2007-09-17 Thread flashcrow2000
can i ask why?

--- In flexcoders@yahoogroups.com, Paul Andrews [EMAIL PROTECTED] wrote:

 The subject line alone almost made me delete the post without
opening it..
 
 - Original Message - 
 From: flashcrow2000 [EMAIL PROTECTED]
 To: flexcoders@yahoogroups.com
 Sent: Monday, September 17, 2007 8:49 AM
 Subject: [flexcoders] web cam live feed
 
 
  Hello all,
 
  I know this is quite large, but can someone please point out what
  technologies I need, and how can I build a webcam live feed?
  Basically, I will have a laptop with a webcam, and users will be able
  to connect at any time and watch live. This will be used for promoting
  new products in more locations in the same time, so probably we are
  not talking about video conferencing.
 
  If any of you can point me to a tutorial on this, it would be great.
 
  Thanks guys,
  Cosmin
 
 
 
  --
  Flexcoders Mailing List
  FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
  Search Archives:
http://www.mail-archive.com/flexcoders%40yahoogroups.com
  Yahoo! Groups Links
 
 
 
 





[flexcoders] drag and drop an image object, over a list object

2007-09-17 Thread flashcrow2000
Hello all,

I have the following problem: I need to be able to drag an Image
object over a list, and make some operations based on the specific row
i'm dropping that picture on. The list contains names of different
people, and each picture I drag over one name becomes assigned to that
person.

I have the drag and drop capability all worked out (i'm using the
DragManager of course, and the List object accepts the drop) but I
can't seem to be able to actually find out on what row the user
dropped the picture. Any ideas? (I'm sure it's simple, but I just
don't see it yet)

Thanks, 
Cosmin



[flexcoders] Re: drag and drop an image object, over a list object

2007-09-17 Thread flashcrow2000
Which is not an option for a List item. I tried using it from the mxml
declaration (and it does not exist, according to Flash 2.0.1), and
also from AS (of course, with the same result). If i'm doing something
wrong, can you please provide a small code sample?

Thank you Alex
--- In flexcoders@yahoogroups.com, Alex Harui [EMAIL PROTECTED] wrote:

 calculateDropIndex?
 
  
 
 
 
 From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
 Behalf Of flashcrow2000
 Sent: Monday, September 17, 2007 5:56 AM
 To: flexcoders@yahoogroups.com
 Subject: [flexcoders] drag and drop an image object, over a list object
 
  
 
 Hello all,
 
 I have the following problem: I need to be able to drag an Image
 object over a list, and make some operations based on the specific row
 i'm dropping that picture on. The list contains names of different
 people, and each picture I drag over one name becomes assigned to that
 person.
 
 I have the drag and drop capability all worked out (i'm using the
 DragManager of course, and the List object accepts the drop) but I
 can't seem to be able to actually find out on what row the user
 dropped the picture. Any ideas? (I'm sure it's simple, but I just
 don't see it yet)
 
 Thanks, 
 Cosmin





[flexcoders] Re: web cam live feed

2007-09-17 Thread flashcrow2000
Wow! thanks guys for your quick response! I knew I'll have to get down
and dirty with Flash Media Server, but I will also take a look at the
other servers you mentioned.

--- In flexcoders@yahoogroups.com, greg h [EMAIL PROTECTED] wrote:

 Hi Cosmin,
 
 For true video, a server is required and Jobe's list of the server
options
 is comprehensive.
 
 For a tutorial you can adapt from Renaun's Video Conference with Flex 
 FMS.
 Article:
 http://mxdj.sys-con.com/read/295379.htm
 Source  Live Demo:
 http://renaun.com/blog/2006/10/28/139/
 
 Renaun's article give you the webcam record side and the server
setup.  For
 viewers, you can use

mx.controls.VideoDisplayhttp://livedocs.adobe.com/flex/201/langref/mx/controls/VideoDisplay.htmlsetting
 the

source=http://livedocs.adobe.com/flex/201/langref/mx/controls/VideoDisplay.html#sourceproperty
 to the stream's RTMP URI.  Or, if you want a more lightweight swf
 for viewers you can use either ActionScript only with

flash.media.Videohttp://livedocs.adobe.com/flex/201/langref/flash/media/Video.html(used
 in Renaun's Video Conference in class
 VideoContainer.as), or Flash's FLVPlayback component.
 
 If you want to publish video of higher quality, you can use the
Flash Media
 Encoder
http://www.adobe.com/products/flashmediaserver/flashmediaencoder/(not
 Flex).
 
 Please post back if you find this helpful or if you have further
questions.
 
 hth,
 
 g
 
 
 On 9/17/07, Jobe Makar [EMAIL PROTECTED] wrote:
 
   Hi Cosmin,
 
  When it comes to live web cam feeds using Flash there are only a few
  options:
  Flash Media Server
  ElectroServer 4 (a week or two from release) www.electro-server.com
  Red 5
  Wowza
 
  Jobe Makar
  http://www.electrotank.com
  http://www.electro-server.com
  phone: 252-627-8026
  mobile: 919-609-0408
  fax: 919-882-1121
 





[flexcoders] Re: DoubleClick together with Mouse_Down and Mouse_Up

2007-09-04 Thread flashcrow2000
Alex, according to the Flex Help, the DoubleClick must follow a
sequence of mouse_down, mouse_up, click, mouse_down, mouse_up events.

My main issue is that the mouse_up event (which is not being
re-dispatched) is caught in a double_click sequence in the first
place, so my actual question was if I can instruct the player to
handle these events with some sort of timeout (something like, check
if the mouse_down is part of a double_click sequence, and if so, do
nothing; otherwise, do what it's supposed to do).

If you have any ideas on how this could be implemented, or you happen
to have an example, it would be of great help.

Again, my goal is a thumbnail that the user can either double click,
or drag and drop over a specific target.

--- In flexcoders@yahoogroups.com, Paul Hastings [EMAIL PROTECTED]
wrote:

 Alex Harui wrote:
  You might get two MOUSE_UPs, but not continuous.  Are you sure you're 
  not redispatching the event?
 
 i had the same sort of problem, listening for pretty much all mouse
events  we 
 found it impossible to capture *just* the double click, the app
would react to 
 the mouse down/up instead of the double click. had to resort to using 
 control-key+mouse click.
 
 how should we have done this?





[flexcoders] Re: DoubleClick together with Mouse_Down and Mouse_Up

2007-09-04 Thread flashcrow2000
Another thing (sorry for the double post). On the mouse_down event,
I'm creating a copy of the thumbnail's picture under the mouse
pointer, so I guess the mouse up isn't caught at all by the thumbnail,
but rather by the thumbnail's copy.

--- In flexcoders@yahoogroups.com, Paul Hastings [EMAIL PROTECTED]
wrote:

 Alex Harui wrote:
  You might get two MOUSE_UPs, but not continuous.  Are you sure you're 
  not redispatching the event?
 
 i had the same sort of problem, listening for pretty much all mouse
events  we 
 found it impossible to capture *just* the double click, the app
would react to 
 the mouse down/up instead of the double click. had to resort to using 
 control-key+mouse click.
 
 how should we have done this?





[flexcoders] DoubleClick together with Mouse_Down and Mouse_Up

2007-09-03 Thread flashcrow2000
Hi all,

I have a custom made thumbnail class, and I must allow the user to
either drag and drop the thumbnail, or double-click it in order to do
whatever it is the thumb does. Now...I have the drag and drop all
figured out (I'm not using DragManager, I'm catching the mouse_down
and mouse_up event) but if I double click the thumb (which has
doubleClickEnabled set to true), I get my double click method called
once, but also my mouse_up listener method called continuously, even
though I have no timers or any other mechanism which might explain a
continuous call of a method. 

To put it simple, I'm asking if there is a way to tell one object to
ignore a mouse_down - mouse_up sequence if that sequence is part of a
mouse_doubleClick event. 

If you have any ideas, please let me know.
Thanks



[flexcoders] swapchildren error: The supplied DisplayObject must be a child of the caller

2007-09-03 Thread flashcrow2000
Hi again.

I have the following sequence of code:

if (this.parent.getChildIndex(this)  this.parent.numChildren-1) {
  trace(this.parent+ should swap the following items:)
  trace(this+ on level +this.parent.getChildIndex(this))
  trace(this.parent.getChildAt(this.parent.numChildren-1)+ on level
   +(this.parent.numChildren-1))
  try {
this.parent.swapChildren(this, 
this.parent.getChildAt(int(this.parent.numChildren-1))
);
  }
  catch (e:*) {
trace(e)
  }
}

and it's output from the console window:

FloatingWidgetContainer135.FloatingFrontView138.WidgetMainView198.Canvas248
should swap the following items:
FloatingWidgetContainer135.FloatingFrontView138.WidgetMainView198.Canvas248.thumbnail280
on level 1
FloatingWidgetContainer135.FloatingFrontView138.WidgetMainView198.Canvas248.thumbnail409
on level 2
ArgumentError: Error #2025: The supplied DisplayObject must be a child
of the caller.


The above code is called inside the mouse_Down listener for a custom
thumbnail. The thumbnail is located inside a canvas and more instances
of the thumbnail are added programatically when needed. The user has
the option to drag and drop the thumbnail (this are thumbnails of
uploaded pictures) and I need to swap them because the dragged object
is shown below some of the thumbnails (for example, if I have 2
thumbs, and I drag the first one, it will be displayed below the
second one, because of their corresponding depths. Each thumbnail
creates the floating, draggable image as it's own child).

One option would be to create the draggable item in the same canvas
with the other thumbnails, but that might raise some issues related to
the position of the draggable picture.

Any ideas on this (I hope i'm not being too ambiguous)
Thanks.



[flexcoders] Re: Drag and drop for list items

2007-08-28 Thread flashcrow2000
I think I'm trying to go with the first option (making everything a
valid droptarget). The problem is that I'm working with some existing
components and they have no dropEnabled property. Is there any way
to make them drop-enabled? 

Another solution would be to use an invisible sprite, or something,
and drag that along with my list item, and use that as a drop target.
But I think it's a bit cumbersome, so, please let me know if there's
any other way.

--- In flexcoders@yahoogroups.com, Alex Harui [EMAIL PROTECTED] wrote:

 Maybe by making everything else a valid droptarget?  Or do you want the
 no-drop feedback during mousemove?
 
 
 
 From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
 Behalf Of flashcrow2000
 Sent: Monday, August 27, 2007 6:21 AM
 To: flexcoders@yahoogroups.com
 Subject: [flexcoders] Drag and drop for list items
 
 
 
 Hi all,
 
 I have a problem (obviously). It's a bit hard to explain, but I'll do
 my best.
 
 So...I have a list item, and whenever I drag and drop one entry
 outside of the list, I want it to display the same animation as when
 I'm dropping the entry on the list ( or any other mxml element which
 support dropEnabled). 
 
 For example. If you drag and drop one item from one list, to another,
 the dragged item will zoom out under your mouse. If you drag and drop
 the item outside a drop enabled element, it will zoom out and slide
 back to it's original position on it's parent list.
 
 Is there a way to tell the list to always just zoom out the dragged
 element, regardless of the drop target? (I really hope I managed to
 make myself understood).
 
 Thanks guys,
 Cosmin





[flexcoders] Re: Drag and drop for list items

2007-08-28 Thread flashcrow2000
I found some samples on the flex developer's guide. I'll have to
give those a try and see if I can make them work for me.

Thanks for your help :)

--- In flexcoders@yahoogroups.com, Alex Harui [EMAIL PROTECTED] wrote:

 I think you can put drag_enter on the application or maybe a background
 behind everything?  Or pick up drag_enter in capture phase.
 
  
 
 
 
 From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
 Behalf Of flashcrow2000
 Sent: Monday, August 27, 2007 11:05 PM
 To: flexcoders@yahoogroups.com
 Subject: [flexcoders] Re: Drag and drop for list items
 
  
 
 I think I'm trying to go with the first option (making everything a
 valid droptarget). The problem is that I'm working with some existing
 components and they have no dropEnabled property. Is there any way
 to make them drop-enabled? 
 
 Another solution would be to use an invisible sprite, or something,
 and drag that along with my list item, and use that as a drop target.
 But I think it's a bit cumbersome, so, please let me know if there's
 any other way.
 
 --- In flexcoders@yahoogroups.com mailto:flexcoders%40yahoogroups.com
 , Alex Harui aharui@ wrote:
 
  Maybe by making everything else a valid droptarget? Or do you want the
  no-drop feedback during mousemove?
  
  
  
  From: flexcoders@yahoogroups.com mailto:flexcoders%40yahoogroups.com
 [mailto:flexcoders@yahoogroups.com mailto:flexcoders%40yahoogroups.com
 ] On
  Behalf Of flashcrow2000
  Sent: Monday, August 27, 2007 6:21 AM
  To: flexcoders@yahoogroups.com mailto:flexcoders%40yahoogroups.com 
  Subject: [flexcoders] Drag and drop for list items
  
  
  
  Hi all,
  
  I have a problem (obviously). It's a bit hard to explain, but I'll do
  my best.
  
  So...I have a list item, and whenever I drag and drop one entry
  outside of the list, I want it to display the same animation as when
  I'm dropping the entry on the list ( or any other mxml element which
  support dropEnabled). 
  
  For example. If you drag and drop one item from one list, to another,
  the dragged item will zoom out under your mouse. If you drag and drop
  the item outside a drop enabled element, it will zoom out and slide
  back to it's original position on it's parent list.
  
  Is there a way to tell the list to always just zoom out the dragged
  element, regardless of the drop target? (I really hope I managed to
  make myself understood).
  
  Thanks guys,
  Cosmin
 





[flexcoders] Drag and drop for list items

2007-08-27 Thread flashcrow2000
Hi all,

I have a problem (obviously). It's a bit hard to explain, but I'll do
my best.

So...I have a list item, and whenever I drag and drop one entry
outside of the list, I want it to display the same animation as when
I'm dropping the entry on the list ( or any other mxml element which
support dropEnabled). 

For example. If you drag and drop one item from one list, to another,
the dragged item will zoom out under your mouse. If you drag and drop
the item outside a drop enabled element, it will zoom out and slide
back to it's original position on it's parent list.

Is there a way to tell the list to always just zoom out the dragged
element, regardless of the drop target? (I really hope I managed to
make myself understood).

Thanks guys,
Cosmin



[flexcoders] Buttons with dynamic loaded images

2007-06-04 Thread flashcrow2000
Hello everybody,

I have the next problem: I'm trying to build a field containing a
Button/SimpleButton and a LinkButton. I also have an XML file which
points, for each entry, to a text, an URL, and three pictures, one for
each button state: up, over, down. 

I'm having trouble displaying a button with a dynamic loaded picture.
If I ebed them, it works ok. I've tried using the Image class, with an
event listener to catch when the picture loaded completely and then
adding it to the button, still nothing.
This is the button declaration:

display:SimpleButton 
id=btn 
mouseOver=onBtnOver() 
mouseOut=onBtnOut() 
/

and this are the actions i'm using:

public var upState:Image = new Image();
public var upStateString:String = null;
private function onInit():void {
upState.load(upStateString);
upState.addEventListener(Event.COMPLETE, onImageComplete)
}

private function onImageComplete(event:Event) : void {
btn.upState = DisplayObject(upState);
}

Any ideas? Please :D
thanks!




[flexcoders] unable to set origin point for zoom effect

2007-05-29 Thread flashcrow2000
Hello everybody,

I have the following problem: I have a custom title window built 
from scratch (extends Canvas); I also have a number of widgets 
which extend this window (they actually contain one instance of 
this window, and the content is generated and loaded inside it at 
runtime) and all widgets are loaded as modules afterwards.

I am able to drag and drop windows on the screen, and with each drag-
drop, I move the module loader so that inside the module, the title 
window is always situated at coordinates (0, 0) (except of course 
when actually dragging it).

My problem is this: when using a Zoom effect for the hideEffect, it 
resizes to the top-left corner. I tried changing the originX and 
originY values for the effect, but still nothing. 

Here is the actual effect:

mx:Zoom id=myZoom  
originX={origX} originY={origY} /

where origX and origY are set when the content of the window and its 
width and height are set. I have also added a function for 
effectStart and it traces good values for origX and origY (width/2 
and height/2 of the window).

Any ideas?



[flexcoders] Re: y nobody replies to my mails :(

2007-05-27 Thread flashcrow2000
maybe give us the URL to your question, or ask againor reply 
yourself to your question so it will show up in the latest 
questions ;)

Cosmin

--- In flexcoders@yahoogroups.com, kanu kukreja [EMAIL PROTECTED] 
wrote:

 Hello,
   I don't know why nobody replies to my mails.
   Am i asking such a difficult questions that nobody can answer :(

   pls reply to my mails also.
   i'm also a part of this group.
 
 
 Best Regards
   Kanu Kukreja
 

 -
 Pinpoint customers who are looking for what you sell.





[flexcoders] Re: changing states in module behaves strange

2007-05-25 Thread flashcrow2000
 target={this.parent} heightTo=140 
suspendBackgroundProcessing=true/
mx:Resize target={this.parent.parent} 
heightTo=140 suspendBackgroundProcessing=true/
/mx:Parallel
/mx:Transition

mx:Transition id=hisDn fromState=history toState=*
mx:Parallel
mx:Resize target={this.parent} heightTo=140 
suspendBackgroundProcessing=true/
mx:Resize target={this.parent.parent} 
heightTo=140 suspendBackgroundProcessing=true/
/mx:Parallel
/mx:Transition
/mx:transitions

the module loading sequence/
findMod = new ModuleLoader();
SingletonObject.getInstance().getDefaultObj().parent.addChild
(findMod);
findMod.url = m_widgetSwf_URL;
findMod.loadModule();

This is about iti know it's a lot of code, I tried to cut out 
most of the unneccessary code for this issue.

Any ideas?
Cosmin



--- In flexcoders@yahoogroups.com, Alex Harui [EMAIL PROTECTED] wrote:

 I get a feeling that the reference point for the state is relative 
to
 where it got loaded and not where it is.  Maybe showing more code 
will
 help
 
  
 
 
 
 From: flexcoders@yahoogroups.com 
[mailto:[EMAIL PROTECTED] On
 Behalf Of flashcrow2000
 Sent: Wednesday, May 23, 2007 11:16 PM
 To: flexcoders@yahoogroups.com
 Subject: [flexcoders] Re: changing states in module behaves strange
 
  
 
 I'm pretty sure the custom window shifts when transitions are 
 applied to the content. I'll try and explain some more how 
 everything is built:
 
 the custom window is a canvas with a label, a close button and 
 another canvas (contentHolder) which will hold the window's 
content.
 
 the module contains an instance of this custom window, and ads the 
 content to it via actionscript (I have a method in the custom 
window 
 class which sets the content and the dimmensions of the 
 contentHolder)
 
 the transitions are implemented in the content class.
 
 So: schematic this would look like this:
 
 content - {contentHolder} Custom Window - Module -..- Module 
 Loader.
 
 calling this.parent.parent from content would highlight 
CustomWindow 
 (seeing that this.parent would highlight contentHolder which is a 
 child of the custom window).
 
 this.parent changes only the inner canvas and even though I have 
set 
 autolayout=true, the custom window doesn't enlarge.
 
 this.parent.parent.parent doesn't work.
 
 Any ideas?
 
 --- In flexcoders@yahoogroups.com mailto:flexcoders%
40yahoogroups.com
 , Alex Harui aharui@ wrote:
 
  If you don't use a module, do you have the same problem? I'm more
  interested in who the parent of the custom window and content 
is, 
 and
  whether it is the content that shifts or the custom window.
  
  
  
  
  
  From: flexcoders@yahoogroups.com mailto:flexcoders%
40yahoogroups.com
 
 [mailto:flexcoders@yahoogroups.com mailto:flexcoders%
40yahoogroups.com
 ] On
  Behalf Of flashcrow2000
  Sent: Wednesday, May 23, 2007 8:35 AM
  To: flexcoders@yahoogroups.com mailto:flexcoders%
40yahoogroups.com 
  Subject: [flexcoders] changing states in module behaves strange
  
  
  
  Hello,
  
  Here's the story:
  I have a custom window and a class which defines a specific 
 content 
  (pictures, text, other components and so on).
  
  My module loads a custom window and sets its content to that 
  specific class (much like a popupmanager, if you like, but i 
can't 
  use that for this project).
  
  My problem is that, whenever one of the windows changes state, 
it 
  jumps back to the upper left corner, where all moduleLoaders 
 objects 
  are. 
  
  I have implemented transitions between the states, and if I 
remove 
  them, the window doesn't jump anymore.
  
  One of the transitions looks like this:
  mx:Transition id=resUp fromState=* toState=results
  mx:Sequence target={this.parent.parent}
  mx:AddChildAction/
  mx:Resize target={this.parent.parent} heightTo=460/
  /mx:Sequence
  /mx:Transition
  
  where this.parent.parent leads to the custom window.
  
  Any ideas?
  Thanks!
 





[flexcoders] Re: {fixed} changing states in module behaves strange

2007-05-25 Thread flashcrow2000
Most probably that is the case. 

I've fixed it quite simple...whenever I finish an drag action, I 
move the module loader and reset the widget's position inside the ML 
to (0,0). 

--- In flexcoders@yahoogroups.com, Alex Harui [EMAIL PROTECTED] wrote:

 Quick thought before going to sleep:  ModuleLoader extends VBox so 
if
 its layout code runs it will reposition the child in its upper 
left.
 That might be what is getting you.
 
  
   
   Hello,
   
   Here's the story:
   I have a custom window and a class which defines a specific 
  content 
   (pictures, text, other components and so on).
   
   My module loads a custom window and sets its content to that 
   specific class (much like a popupmanager, if you like, but i 
 can't 
   use that for this project).
   
   My problem is that, whenever one of the windows changes state, 
 it 
   jumps back to the upper left corner, where all moduleLoaders 
  objects 
   are. 
   
   I have implemented transitions between the states, and if I 
 remove 
   them, the window doesn't jump anymore.
   
   One of the transitions looks like this:
   mx:Transition id=resUp fromState=* toState=results
   mx:Sequence target={this.parent.parent}
   mx:AddChildAction/
   mx:Resize target={this.parent.parent} heightTo=460/
   /mx:Sequence
   /mx:Transition
   
   where this.parent.parent leads to the custom window.
   
   Any ideas?
   Thanks!
  
 





[flexcoders] Re: changing states in module behaves strange

2007-05-24 Thread flashcrow2000
I'm pretty sure the custom window shifts when transitions are 
applied to the content. I'll try and explain some more how 
everything is built:

the custom window is a canvas with a label, a close button and 
another canvas (contentHolder) which will hold the window's content.

the module contains an instance of this custom window, and ads the 
content to it via actionscript (I have a method in the custom window 
class which sets the content and the dimmensions of the 
contentHolder)

the transitions are implemented in the content class.

So: schematic this would look like this:

content - {contentHolder} Custom Window - Module -..- Module 
Loader.

calling this.parent.parent from content would highlight CustomWindow 
(seeing that this.parent would highlight contentHolder which is a 
child of the custom window).

this.parent changes only the inner canvas and even though I have set 
autolayout=true, the custom window doesn't enlarge.

this.parent.parent.parent doesn't work.

Any ideas?

--- In flexcoders@yahoogroups.com, Alex Harui [EMAIL PROTECTED] wrote:

 If you don't use a module, do you have the same problem?  I'm  more
 interested in who the parent of the custom window and content is, 
and
 whether it is the content that shifts or the custom window.
 
  
 
 
 
 From: flexcoders@yahoogroups.com 
[mailto:[EMAIL PROTECTED] On
 Behalf Of flashcrow2000
 Sent: Wednesday, May 23, 2007 8:35 AM
 To: flexcoders@yahoogroups.com
 Subject: [flexcoders] changing states in module behaves strange
 
  
 
 Hello,
 
 Here's the story:
 I have a custom window and a class which defines a specific 
content 
 (pictures, text, other components and so on).
 
 My module loads a custom window and sets its content to that 
 specific class (much like a popupmanager, if you like, but i can't 
 use that for this project).
 
 My problem is that, whenever one of the windows changes state, it 
 jumps back to the upper left corner, where all moduleLoaders 
objects 
 are. 
 
 I have implemented transitions between the states, and if I remove 
 them, the window doesn't jump anymore.
 
 One of the transitions looks like this:
 mx:Transition id=resUp fromState=* toState=results
 mx:Sequence target={this.parent.parent}
 mx:AddChildAction/
 mx:Resize target={this.parent.parent} heightTo=460/
 /mx:Sequence
 /mx:Transition
 
 where this.parent.parent leads to the custom window.
 
 Any ideas?
 Thanks!





[flexcoders] changing states in module behaves strange

2007-05-23 Thread flashcrow2000
Hello,

Here's the story:
I have a custom window and a class which defines a specific content 
(pictures, text, other components and so on).

My module loads a custom window and sets its content to that 
specific class (much like a popupmanager, if you like, but i can't 
use that for this project).

My problem is that, whenever one of the windows changes state, it 
jumps back to the upper left corner, where all moduleLoaders objects 
are. 

I have implemented transitions between the states, and if I remove 
them, the window doesn't jump anymore.

One of the transitions looks like this:
mx:Transition id=resUp fromState=* toState=results
  mx:Sequence target={this.parent.parent}
mx:AddChildAction/
mx:Resize target={this.parent.parent} heightTo=460/
  /mx:Sequence
/mx:Transition

where this.parent.parent leads to the custom window.

Any ideas?
Thanks!



[flexcoders] Zoom effect added from code...how?

2007-05-21 Thread flashcrow2000
Hello,

Here is my current problem: I have a ModuleLoader object (which I'm 
using in an AS file, so no MXML there). This ModuleLoader gets 
initialized then is sent to another application (I have access to a 
DisplayObject from that application, and I'm adding the ML to the 
DisplayObject's parent via addChild). Now, I want to implement a Zoom 
effect (If you have an example with any other kind of effect, I 
believe it will help as well) when the object loaded by the module 
dissappears (I have a close button which basicall does module.visible 
= false) but I have no clue on how to add it.

When I was able to declare the ML via MXML, I managed to use both a 
standard and a custom Zoom effect, but now I'm only using 
actionscript, so...please help me on this one. Also, using the MXML 
version is a no-no so I'm really stuck.

Thanks everybody
Cosmin



[flexcoders] Re: how to work with AS3

2007-05-21 Thread flashcrow2000
you certainly have a lot of code...

1. when building states you might want to use the Design, if you are 
a beginner (which you probably did)
2. going from state to state is as simple as :
Button label=go to state leadState 
click=this.currentState='leadState' /

try to explain the problem before pasting in all your code...someone 
must have a lot of time on their hands to take all that code and 
place it in a flex project and try to compile it.

[offtopic]
you could also try to use classes to split your work into modules, 
so that you can test them one at a time, and you know for sure, at 
every moment in time, which works, and which doesn't. But these are 
work practices, so...you can find books about these things on the 
internet.

[ontopic]
if my information wasn't helpfull, try to explain what you are 
trying to do in plain english, without much drama, and everyone here 
will be glad to help you out.

Regards,
Cosmin



[flexcoders] ambiguous question about resizable components

2007-05-03 Thread flashcrow2000
Hello,

I want to implement an application which will require 2 columns, one
with controls and one with some content. These columns will be
separated by a dragable bar; the effect will be the one on Windows
Explorer when you enlarge the folders column's width..

My question: Is there a component I can use for this, or should I
implement everything from scratch?

Thanks,
Cosmin



[flexcoders] List component scrambles rows

2007-05-02 Thread flashcrow2000
Hello,

I have a list component which gets populated when i run a simple 
query. I receive the result in an array and I set that array as the 
data provider. Also, I have an ItemRenderer which displays part of 
data (each data contains information regarding cities: name, dates, 
numbers, etc; I only display the name and the country).

The problem appears when I scroll in the List. If I scroll to the 
bottom and then scroll back up, the first item is different than 
before. 

I tried to use invalidateList on a scroll function but nothing 
changed.

I believe it has something to do with the Item renderer. Can you help 
me out please?

Cosmin



[flexcoders] List Component scrambles rows

2007-05-02 Thread flashcrow2000
Hello,

I have a list component which gets populated when i run a simple 
query. I receive the result in an array and I set that array as the 
data provider. Also, I have an ItemRenderer which displays part of 
data (each data contains information regarding cities: name, dates, 
numbers, etc; I only display the name and the country).

The problem appears when I scroll in the List. If I scroll to the 
bottom and then scroll back up, the first item is different than 
before. 

I tried to use invalidateList on a scroll function but nothing 
changed.

I believe it has something to do with the Item renderer. Can you 
help 
me out please?

Cosmin
(if this is a double post, sorry...i received a Delivery status 
Notification)



[flexcoders] Re: Is it possible to place and compile MXML application not in the root folder, but in subfolder?

2007-04-25 Thread flashcrow2000
You can modify the project properties - build path - main source 
folder and use a different sub-folder for your source files. But you 
will have to keep all your files (except the binded ones, of course) 
inside that folder (I think...)

Cosmin

--- In flexcoders@yahoogroups.com, Sergey Kovalyov 
[EMAIL PROTECTED] wrote:

 Hi All!
 
 Usually we place MXML application (class inherited from Application) 
in the
 root folder of the project. Is it possible to place application not 
in the
 root folder, but in subfolder? Therefore it could be compiled into 
the
 {PROJECT_OUTPUT_FOLDER}/subFolder/.
 
 Sergey.





[flexcoders] Re: Is it possible to place and compile MXML application not in the root folder, but in subfolder?

2007-04-25 Thread flashcrow2000
oh...and if you want to modify the output folder, change 
the properties - build path - output folder value (later edit)

Cosmin (again)

--- In flexcoders@yahoogroups.com, Sergey Kovalyov 
[EMAIL PROTECTED] wrote:

 Hi All!
 
 Usually we place MXML application (class inherited from 
Application) in the
 root folder of the project. Is it possible to place application 
not in the
 root folder, but in subfolder? Therefore it could be compiled into 
the
 {PROJECT_OUTPUT_FOLDER}/subFolder/.
 
 Sergey.





[flexcoders] Re: Help on the syntax for function set blah(param:String)

2007-04-24 Thread flashcrow2000
The set and get method are what you call setters and getters (DUH!) 
and they are used when you have private members of a class and you 
want to give the user the ability to change their value. Take this 
example for instance:
class myObject {

private var _id:Number;
..
}

let's say you have a text box where you can change that id. if you 
just say myObjectInstance._id = textbox.text when you click on a 
button, you might get errors  if you enter dev as an id (or any 
other Not a Number value). 

instead, if you define getters and setters like this:

class myObject {

private var _id:Number;
..
public function set id(value:*):void {
   if (!isNaN(value)
  _id = value;
   else
  _id = -1;
}

public function get id():Number {
   if (_id == null)
  _id = -1;
   return _id;
}
}
then, you will have something like 
myObjectInstance.id = textbox.text (notice here i'm using id 
instead of _id; it's usually a good practice to use the same name 
for setters and getters, and choose that name closely resemblant to 
the property's name you want to access) and in the case of an 
invalid number value, your getter will make sure the value get's set 
to -1 (or whatever value you might want to use).

Sobottom line, getters and setters give you a way to set/get 
private properties while having some control over the actual values.


--- In flexcoders@yahoogroups.com, Scott Hoff [EMAIL PROTECTED] wrote:

 OK, where did you see this to raise the question? Does wherever you
 took the code from work?
 
 --- In flexcoders@yahoogroups.com, Scott Hoff shoff@ wrote:
 
  What is super special about the syntax that you pasted?
  
  --- In flexcoders@yahoogroups.com, tjcox1969 tjc1969@ wrote:
  
   I have read the section on functions in the Adobe Programming
   Actionscript manual, but I see no reference to this type of 
syntax:
   
   [Bindable]
   public function set statesNames(value:ListCollectionView):void 
{
 _statesNames = value;
   }
 
   public function get statesNames():ListCollectionView {
 return _statesNames;
   }
   
   Can someone point me to some documentation on this or give a 
brief
   explanation.  I am looking at a sample I found and it works, 
but I
   want to know why and when to use this type of function set 
blah()
   syntax over function setBlah()
   
   Thanks!
  
 





[flexcoders] change a button's appeareance from it's properties

2007-04-23 Thread flashcrow2000
Hello again,

I ran into this little problem: I have to skin a number of buttons, 
and I can't modify the way the over and down states look like. 
I have a Button with rounded corners, gren outline, green text and 
white fill. I want it to have a black fill and white text (i can use 
textRollOverColor for the color, but I can't find a value similar to 
fillColors but for the over state).

I tried to use the themeColor but if I use the default values 
(haloGreen, haloSilveri was unable to find others) my buttons 
don't match the design, and if I set the themeColor to a specific 
value (0x65cdcd for example) then there is no difference between the 
over and down states :(( (extremely confusing)

SoI could draw each button's state in a preinitialize method, 
and use SimpleButtons, but I really hope there is another way 
around. 

Any ideas are welcomed. Thank you





[flexcoders] Re: change a button's appeareance from it's properties

2007-04-23 Thread flashcrow2000
I found a solution myself, and that is using custom skins, and apply 
them to the overSkin and downSkin properties.

Any other ways?

--- In flexcoders@yahoogroups.com, flashcrow2000 
[EMAIL PROTECTED] wrote:

 Hello again,
 
 I ran into this little problem: I have to skin a number of 
buttons, 
 and I can't modify the way the over and down states look like. 
 I have a Button with rounded corners, gren outline, green text and 
 white fill. I want it to have a black fill and white text (i can 
use 
 textRollOverColor for the color, but I can't find a value similar 
to 
 fillColors but for the over state).
 
 I tried to use the themeColor but if I use the default values 
 (haloGreen, haloSilveri was unable to find others) my buttons 
 don't match the design, and if I set the themeColor to a specific 
 value (0x65cdcd for example) then there is no difference between 
the 
 over and down states :(( (extremely confusing)
 
 SoI could draw each button's state in a preinitialize method, 
 and use SimpleButtons, but I really hope there is another way 
 around. 
 
 Any ideas are welcomed. Thank you





[flexcoders] probably noob question, about custom lists

2007-04-17 Thread flashcrow2000
Hello everybody,

I searched through all the posts but i couln't find anything which 
helps me so here goes:

I need to implement a list which has a custom element on each row, 
containing an icon, a label, a delete button and of course, data (not 
visible). I implemented an item object containing these elements and 
in my main application I have a list and I try adding two items via 
list.addChild(item) (item is initialized before).

The list adds the items, but they show up on top of eachother. If I 
try using addChildAt(item, 0) and addChildAt(item, 1) the items don't 
show at all.

Again, I realise this is a noob question, and probably the answer is 
right there before me, but at the moment, I don't really see it.

Thanks for your help