ActionScript 3.0 :: Colorpicker Component Open Or Closed Status
Jun 15, 2009Haw can i see if the colorpicker component it's open or closed ?
View 6 RepliesHaw can i see if the colorpicker component it's open or closed ?
View 6 RepliesI am trying to set selectedColor of the colorPicker component to the color of a TextFormat. colorPicker.selectedColor is of type uint and TextFormat.color of type object. I looked around and found this function:
Code:
function fixColorCode( color:Object, hasAlpha:Boolean = false ):uint
{
if( color is String ){
var pattern:RegExp = /#/;
[code]....
The last line returns the following error: "1118: Implicit coercion of a value with static type Object to a possibly unrelated type Number."
I have an animated dropdown menu with 7 buttons. Each button slides down it's submenu.They're setup so that they open when you click them, but automatically close when you move the mouse out of the area of the given menu/submenu. If i permitted for more than one submenu to be open at a time, then size of the menu in total would be too big.Ok what I need is that, in plain language, when menu 1 is open - the rest is closed. But the menu 1 will close when you click menu 2, not before. OK, if my explanation was too lame here's the real thing, so you can get the idea of what i want:
View 1 RepliesI would like to display a message in flash "we are open" or "we are closed" based upon time. Naturally I can do this for the users local time on their system, but is it possible to work out if their time is different to UK time (GMT) and display those messages accordingly. After all I don't want a user to see a message "we are open" at 1pm their time - they could be in Japan and it'd be about 4am UK time. Is this possible to work out the time difference on any system?
View 1 Replieswe're developing an app that should be able to open specified file with default editor application. (so if it is .doc - it suppose to be opened by MSWord or openOffice)
But I also need to wait until user will close the editor, check if it was changed (by size and date), and upload it to the server.
So the following steps:
1) find def editor
2) open file
3) wait it be closed
4) do smth after that with the file.
now results of my research:
-> opening by def editor is simple: file.openWithDefaultApplication();
but there is no way to know that editor is closed (maybe by checking that file is not locked in timer???)
-> i can start the native process and pass file as parameter BUT looks like the code NativeApplication.nativeApplication.getDefaultApplication(file.extension); does not work for any extension :( - it doesnt work for "rtf", "doc" but works for "pdf"... and [file.openWithDefaultApplication()] works fine with any file!
In Flex (Flash Builder 4) I am opening a new window via PopUpManager.addPopUp. I have timer code that runs in my component and I need to stop my timer when that window opens and start the timer again when the window closes.
I figure it's easy enough to stop the timer in the function that opens the window, but how can I start the timer again when the window closes?
Is there a way to tell if there is a pop-up window in front of my component, or if a specific pop-up window is still open via PopUpManager?
I have to be able to cancel and kill a Loader process properly and many times. If I dont do this, it seems that the flash player (at least on mac) eventually crashes as some loader processes are flying about , strangling the CPU.
There doesnt seem to be a straightforward way to know this and just calling a Loader.close causes an error, if the stream is not open.
I have an AdvancedDataGrid with Hierarchical data in it. On itemClick I have to identify if the row I clicked is expanded or collapsed.
View 1 Repliesokay so i have this code:
[Code]...
okay, so obviously there is stuff missing from my code b.c i dont feel like copying it all over. its basically an XML controlled style blog, and i'm trying to keep track of whether an entry is open (0), or closed (1), and those values are being stored in 'myArray'. my question is, why isnt that call to myArray overwriting the existing data? i know i have doen this before (maybe not in this fashion, but i know its possible).
what the subject says: Closed Caption for Video Flv. Every documentation on internet speak about FlvPlaybackCaptioning.. I would like to made a flv player with caption on my own...
I also found an interesting component called CCForFlashAs3, but I'm not able to use it...
Is there a way that I could change the background colour using the "ColorPicker" component in flash CS5? I want to be able to change it from within the swf once it is published.
View 2 RepliesI would like to display a message in flash "we are open" or "we are closed" based upon time. Naturally I can do this for the users local time on their system, but is it possible to work out if their time is different to UK time (GMT) and display those messages accordingly. Afterall I don't want a user to see a message "we are open" at 1pm their time - they could be in Japan and it'd be about 4am UK time.Is this possible to work out the time difference on any system?
View 1 RepliesI have a checkbox in a component:
<s:CheckBox id="myCB_1" />
In my main.mxml I need to test for the state of the checkbox. I originally had all my code in main.mxml, but it was getting really long, and I thought that it was better practice to break my code into components. Also, I have other projects where the same concept will apply.I have the following function :
private function checkAlarms(currentTime:Date):void
{
if (!breakfastAlarmSounded)[code]....
doesn't work. Someone mentioned that I need to create a variable in my component that refers to the id (myCB_1) of checkbox, but I don't really understand or know how to do that, and they didn't elaborate.How do I test for the status of the CheckBox "myCB_1" in the component from within my main.mxml?
A NetStatusEvent with info.code of "NetStream.Connect.Closed" is dispatched by NetConnection when a NetStream is closed. This seems kind of weird, shouldn't the NetStream dispatch the event? how do I know which NetStream has been closed if I have more than one running (which I do)? I need to know so I can cleanup the now dead stream.
View 1 RepliesI'm loading a webpage inside a HTML component in AIR. By default, when something is clicked the next page is loaded inside the HTML component itself. I want the links from that page to open in an external web browser.
View 1 RepliesIs there a way to open multiple navigation contents at the same time with the Accordion in Flex 4.5 ?
View 1 RepliesI have a component in AIR like so:[code]The 2 alerts both work. however nothing happens when you click the new window link.all 3 links works when in a real browser so I know its ok.Is there just no support for window.open in the AIR HTML component? or is this a bug?Is there a work around?
View 2 Repliesfor example i have string:
var ccolor:String = "ffcc00";
How to set this color to ColorPicker element?
How can i change the color selected in a color picker component ?
View 2 Replieshow to make advanced colorpicker in asctionscript 3.0
View 2 Repliesim having problem with a color picker. I set the selected color with AS, see it changed on screen but then later when I try to get the selected color value it always returns 0.Im using Flash CS5.To recreate the issue make a fla with a color picker on stage with the instance name line_color. Paste in the code below.
import fl.events.ColorPickerEvent;
line_color.selectedColor = 0xff0000;trace(line_color.selectedColor); // displays 0trace(line_color.hexValue); // displays 000000
line_color.addEventListener(ColorPickerEvent.CHANGE, changedColor );[code].........
How can i change the color selected in a color picker component ?
View 3 RepliesSo I have a _mc built and it works just fine until I load it from an external source. Here is the code I have for the _mc to be loaded.
[code]...
I am trying to make a color picker that displays the name of the color that the mouse is over in a label While this works fine in my test file, the item_roll_over event does not fire in its working environment (its embedded into an html page) my plan is to create a customer color picker that would display the color's name in the ColoPicker's textbox instead of the html code that normally goes there
View 1 RepliesI have a colorpicker that I want to have his colors loaded from an external xml, my xml looks like this
<colors>
<color label="Aqua" colorHex="0xFFFFCC"/>
<color label="Forest Green" colorHex="0xCCFF00"/>
[code]....
I am trying to create a Colorpicker control for my application. I prefer pure actionscript. Does someone know how to create a picker like this: [URL] Most interestingly I am interested how to draw the gradient because the gradient has a saturation,
View 2 RepliesIs there a way to tell if my pointer is over the open mode of a colorpicker?check if mouse is over the open colorpickerpanel?
View 4 RepliesI am having two panels with separate colorpickers in them. If i select a particular color in the colorpicker, then the border of that panel should change to that color. I am able to do this perfectly but, since i have written the same code for both colorpickers, when i select the other colorpicker the previous panel color is coming to the normal color i.e. default panel color.
If i want the panels to retain the color even after selecting the other colorpicker what should i do... I am using event.CHANGE on colorpicker and setting the style of borderColor for the panel.
I'm creating a text editor and I want users to be able to select only part of a textfield and change the color.The problem I'm running into is the ColorPicker gains focus (I'm guessing) and the textfield loses it's "selection."All examples of text editing show the entire textfield changing color.
View 1 RepliesI need to use both components in an AS3 project, so I'm trying to put them both in the library. When I add ComboBox on top of ColorPicker, I get a library conflict. If I choose to replace items, the ComboBox works but ColorPicker starts producing errors, if I choose to use the existing items, the ComboBox doesn't work.
View 1 Replies