ActionScript 3.0 :: A SortCompareFunction That Ignores Direction?

Oct 12, 2011

I'm using a pretty standard sortCompareFunction in my DataGrid:

ActionScript Code:
protected function compare(valA:*, valB:*):int {
if(valA < valB) {

[Code]......

The trouble of course is that the compare function isn't passed any info about the column being sorted, and apparently the datagrid's click handler fires AFTER the sort is applied so that's no good either.

View 3 Replies


Similar Posts:


Flex :: Call A SortCompareFunction On Initialize?

Dec 3, 2009

I want to call the sortCompareFunction for a particular row when the grids first loads. Is this possible? Otherwise is there a way to call a sort method on grid load after it has been asssigned the dataprovdier has been updatad

View 2 Replies

Flex :: Add Sortcomparefunction To Dynamic Data Grid In It?

May 28, 2010

I am trying to create a dynamic datagrid in Flex 3, I have a list of columns a list of objects which correspond to datapoints for those columns which I fetch from a url. While the grid works perfectly fine the problem is that sorting on the columns is done in lexical order.[code]...

View 1 Replies

ActionScript 2.0 :: Scrolls Continuously In A Direction Until The Direction Of The Mouse Is Changed?

Feb 24, 2009

i have a scroller developed in as2. it basically scrolls continuously in a direction until the direction of the mouse is changed. the images of course loop in the continuous scroll. now the problem is that for 10-15 photos its ok. but when i feed it with 180 photos, it seems to show only 11. why would this be? any restriction on flash ??

View 1 Replies

ActionScript 3.0 :: Direction Of The Ball In The Direction Of The Mouse

Mar 17, 2011

have a ball with the name of mc which can be moved using the keyboard .. when you press the left mouse button shoots the ball, this ball and the other flies in the face where the cursor was in the shot .. but if you move the cursor to another location and shoot a second time then the second ball is also flying in the direction of the cursor and the first ball change direction toward a second shot ..

ActionScript Code:
import flash.display.MovieClip;
import flash.display.DisplayObject;
import flash.events.MouseEvent;

[Code]....

how to make that first ball did not change its direction and continued to fly in the direction of the shot?

View 5 Replies

Flash :: Xml - Does Xml Ignores (,) OR (-) (xml Of Object)

Jun 9, 2010

[Code]....

this is the xml file of my flash.But ignores the hyphen(-) and comma(,) like New-Age comes like NewAge and Properties, comes like PropertiesWifi WHY?

View 2 Replies

ActionScript 3.0 :: SWF Ignores The Listener?

Jul 14, 2009

I'm not getting any errors. I've been over this code again and again. I based this on an exercise from Lynda.com. The code includes listeners for mouseup but the dragged object doesn't stop dragging when at mouse-up as directed. Also, the dragged object doesn't return to original position as directed.

Here is the main .as file:

Code:
private function checkTarget(event:MouseEvent):void
{
if(event.currentTarget.hitTestObject(event.currentTarget._targetPiece))
{

[code]....

View 5 Replies

ActionScript 3.0 :: Flash Ignores The AllowFullScreen?

Sep 23, 2009

I have allowFullscreen set to true. I even have allow script access to always... I just cant seem to get my movie when loaded to go right into fullscreen.

PHP Code:

var loader:Loader = new Loader();
var urlReq:URLRequest = new URLRequest("countdown.swf");
loader.load(urlReq);

[code]....

View 1 Replies

Flex :: Ignores Changes In Services-config.xml?

Jun 22, 2010

Today I tried to connect to other domain.I changed url of endpoint, but it looks like flex just ignores my changes.I am sure that an old url doesn't exist in any file in src directory,I even renamed services-config.xml to services-config2.xml, cleaned and rebuilded project many times, even made a release build, but it still connects to the same domain.I have tested flex application in localhost and in the same domain, that has AMF services, but it works in the same way.My services-config.xml is:

<?xml version="1.0" encoding="UTF-8"?>
<services-config>
<services>

[code].....

View 3 Replies

Css :: When Using Swfobject / Swf File Ignores Z-index

Oct 12, 2011

I have this issue where if I append a swf file using SWFObject, it ignores my css rules for z-index. I have tried to set the parent container, the swf file, and everything around it;

View 2 Replies

Actionscript 3.0 :: Flash Ignores ALL Scripts?

Jun 23, 2009

Flash CS4 / AS3 project Everything is set up properly, including publishing (naturally) but Flash blows past every script in the actions layer, including simple one-line stop(); scripts.

View 5 Replies

ActionScript 2.0 :: Play Reverse Ignores Stop()

Oct 25, 2010

I am currently working on a flash presentation and I have this code to play the slides:

Code:
MovieClip.prototype.playhead = function(dir) {
this.onEnterFrame = f

[Code].....

What happens is that when I press the leftBtn or rightBtn it plays the whole presentation, ignoring the stops I put in the MC. My mc has slides every 5 frames with tweens between them.

How can I make this and have my MC stop in every slide instead of just reading all at once?

View 5 Replies

Flash :: IE-8 Iframe And Object Ignores Z-index?

Jun 5, 2011

I have the following divs and I'm trying to make the iframe layer infront of my_flash. It's a common problem and I've read through all the solutions I could find and still I'm getting issues in IE8. I'm using SWFobject by the way.

Here's the source:

<script type="text/javascript">
swfobject.embedSWF("index.swf", "my_flash", "100%", "100%", "8.0.0");
swffit.fit("my_flash",900,650);
</script>

[Code]....

View 3 Replies

Flash :: Flex - TextFlow Ignores Whitespaces?

Oct 17, 2011

i'm trying to add whitespaces in front of my text, but flex removes all but one whitespace from the text. So i can't format the text.

Here is the specified line:

<s:p> - Lorem</s:p>
<s:p> ipsulum</s:p>

Here its shown correctly but when running the swf it reduces the whitespaces of the second line. Of course i tried to use CDATA but this didn't work too.

View 2 Replies

ActionScript 2.0 :: HitTest That Ignores Transparent Pixels?

Jun 17, 2009

Is there anyway I can do a hittest that ignores transparent pixels? If so how would I do it.

View 2 Replies

ActionScript 3.0 :: Flash Ide Ignores Changes In Imported Classes

Jul 20, 2009

a few days ago i have started running across various errors and glitches in the app i am developing, and after a lot of time found out the following fact:

just as the title reads, flash started ignoring changes i make to classes i use, as if it has an internal cache of imported classes and refuses to check for changes. it notices when i remove class from directory, it notices when i comment out a whole function, BUT if i comment out the contents of all of the functions, leaving just their declarations, flash executes them "perfectly" well. where does it takes their contents from? how to delete the cache?

while trying to save a class at a certain point when i was dealing with this, i got a "sharing violation" error, that told me i cant save it.

View 2 Replies

ActionScript 3.0 :: Flash Application Ignores Crossdomain.xml?

Dec 8, 2009

With a looming deadline for a big project, I've just wasted an entire evening trying to find out why my application won't properly load image content when the .swf is deployed to a web server.

Here's what I'm trying to do:

- load a jpeg image from a different domain than where my .swf's are hosted

- turn it into a Bitmap object to apply smoothing

Loading the jpeg itself is no problem, as long as I do this:

[AS]addChild(loader);[/AS]

As soon as I try to access loader.content, or loader.contentInfo.content to create a Bitmap, Flash simply aborts the script.So there you have it: a typical security sandbox violation (although no error is ever thrown). Solution: crossdomain.xml! Or that's what I thought.Now the image host has a crossdomain.xml in it's root, with *.rocketclowns.com as an entry. I'm testing my app from www.rocketclowns.com.Even if I try to force load the policy file:

[AS]Security.loadPolicyFile()[/AS]

Or, with LoaderContext:

[AS]// create a loader context that
// checks for policy files
var context:LoaderContext = new LoaderContext();
context.checkPolicyFile = true;
// use the context with your call to load
myLoader.load(request, context);[/AS]

...I still can't access my loader.content.

View 1 Replies

ActionScript 3.0 :: Regex Pattern Ignores Any Letters In Brackets?

Feb 22, 2010

I'm working on a flash chat and I'm having problems with Regular Expression.
 
In Javascript this runs ok:
 
[code]...

My regex pattern works for but it ignores any letters in brackets.

View 4 Replies

Actionscript 3 :: Set Up Collision Detect So That It Ignores A Child Of The Target?

Feb 23, 2010

So in my game, every 'enemy' movieclip creates a textfield that represents the name of the enemy. The problem is, I want my collision detect engine to detect a collision with the enemy itself, not the textfield. This is the code that I have currently have on my collision class for detecting a collision with the enemy:

for(var i = 0;i < _enemies.length; i++)
{
if(CollisionEngine.isColliding(_laser, _enemies[i]._enemyNameTextField, _animation))

[code]......

View 2 Replies

C# :: Flash Animation Embedded In C# Form Ignores Given Size?

Feb 7, 2011

I have a simple C# program that, when a user clicks on a button, opens a new frame with an activex flash object embedded in it. The code I use to open it is the following :

private void button1_Click(object sender, EventArgs e)
{
Form f = new Form();

[code]...

The test program has been run by several user, without any problem, except for one, that sees this:

I don't think that the problem is in the application itself, but in the flash player. So, the question is, what am I missing? Are there flash settings that force the window to have the default size?

View 1 Replies

ActionScript 3.0 :: TextField With HTML Ignores Line Breaks?

Mar 24, 2011

I have a TextField that uses a stylesheet and gets its text as htmlText. That text is read from an *.xml file with the neccessary CDATA tag. The htmlText is read correctly (I have a debug output to check that), and when displaying the .text attribute, it shows line breaks as expected. multiline, wordwrap and condenseWhite are enabled. No AutoSizing is done, instead I set width and height of the field manually.

But the text it actually shows on the screen is all shown in one line, with multiple lines being drawn in the same line. It also seems to interpret the html correctly, as the words with '<b></b>' around them are bold. Only the line breaks are not working. The height can't be the problem as I set it manually to a value high enough, and debug output shows that it really has that height.

This only happens when viewing the *.swf online and only with empty cache. When I press F5 in the window, the TextField works as intended. So it works offline and when it has already been loaded.

But the creation, scaling of the TextField and filling the TextField with text is all done in the same function, without any breaks so I really don't know how the cache could possibly affect this.

View 2 Replies

ActionScript 3.0 :: Input Text FocusEvent Ignores TextFormat?

Sep 26, 2009

I am making a simple contact form in as3, but I am having problems formating it. As soon as I use a FocusEvent, as below, it completely ignores the formating which I set?

[AS]private function onFocus(evt:FocusEvent):void
{
if(evt.target.text == "Enter here.") {

[code].....

View 2 Replies

ActionScript 3.0 :: Movie Clip Ignores Mask, Overtakes Screen?

May 15, 2009

I have a textbox that accepts information from the internet, and i turned it into a movie clip. However, when it moves, it goes on top of everything else and ignores the mask i put on it.

View 8 Replies

IE Ignores Flash Width/height, Display Remains Small?

Feb 26, 2012

[URL]how do i stretch the movie to fill the entire white area which is set to be 500 to 350 px (please see pic)

the code:

<object type="application/x-shockwave-flash" data="videos/player.swf" width="500" height="350">
<param name="movie" value="videos/player.swf">
<param name="quality" value="Best">
<param name="allowFullScreen" value="true">

[code].....

View 2 Replies

ActionScript 3.0 :: Export SWF... From Flash Library Ignores Base Class?

Mar 24, 2009

I have a symbol in the Library with a Base Class that extends the MovieClip Class and adds some additional functionality. I want to be able to export this from the Library by right clicking on the symbol and selecting Export SWF. I was hopping this would essentially give me the same results as if the symbol contents was on the main timeline and I had declared the Base Class as the Document Class. When I import this SWF using the Loader Class it seems to loose all of Base Class functionality and think of itself as a MovieClip.

Looking at the below sample code, the alpha property is correctly set but the param1 getter is unaccessible. What the hell is going on?

[Code]...

View 1 Replies

ActionScript 3.0 :: Flash Breaks Randomly, Won't Compile, Ignores Document Class?

Sep 16, 2011

I have run into a strange and annoying problem since updating to Flash Professional CS5.5 on my work computer.Sometimes, seemingly randomly, Flash stops compiling things correctly. I Test Movie by hitting Cmd+Return and it just displays what's on the stage, frame 1. The document class is never initialized, no errors at all, no trace statements print out; it acts as if there is no code at all. After this happens once, it will continue to do this until I restart Flash, which fixes the problem. However, restarting Flash every 10 - 15 minutes is very annoying.It seems to happen regardless of what project I'm working on or what state the project is in (i.e. if the code contains errors or not). All of our projects use external AS3 classes (no code on the timeline).

View 2 Replies

Actionscript 3 :: Flash Builder Ignores Output Folder When Syncing With SVN Repository

Nov 19, 2010

I am having a lot of trouble while syncing my Flash Builder Actionscript project with Subversion. I have read that the output folders bin, bin-debug and html-template should not be checked in to the repository. The project bin folder contains a lot of XML files and assets that other project members needs to access. The problem is that Flash builder ignores it.

Is there a way of setting up Flash Builder to override the ignored bin folder? If not, what other approach should I consider? Different folder structures?

/src (commited)
/bin (ignored)
/swc (commited)

I would really like to override the default "DO NOT COMMIT YOUR DEPLOY FOLDER" setting. Bounty it is.

View 5 Replies

ActionScript 3.0 :: Flash PrintJob Ignores HTMLText With Font Face Declaration

Nov 21, 2011

I am trying to print a string with html formatting. Part of the formatting includes font face. I have found that my print job will not print any string that includes a font face declaration. I'm guessing because the font isn't embedded, but I'm not positive.

This works:
string = "<b>bold</b> not bold";

Doesn't work:
string = "<TEXTFORMAT LEADING="2"><P ALIGN="LEFT"><FONT FACE="Arial" SIZE="12" COLOR="#000000" LETTERSPACING="0" KERNING="0">this is my string</font></p></textformat>";

How can I get around this. I need the ability to print any font on a users computer.

View 1 Replies

ActionScript 2.0 :: Flash8 Numerical Sort - If The One Of The Numbers Has A Higher Digit Value, It Ignores The Statement Entirely?

Dec 17, 2009

I defined an array construct and assigned two variables to part of the array so I can simple sort it:

number1 = array[i]
number2 = array[i+1]
if(number1 > number2){
...swap etc

Problem is, when I try the comparason if the one of the numbers has a higher digit value, it ignores the statement entirely. Eg If 16 > 8 it skips it. So I tried adding '16' and '08' into the array and that worked perfectly with the statement.

View 2 Replies

Actionscript 3 :: Overlay A Border/image In Flash/Firefox That Ignores Mouse Clicks?

Dec 4, 2010

I'm building a flash app that will go full screen. I need to ensure it's usable at a variety of resolutions.I can overlay them fine, but the problem is I now can't interact with the app, because when I click on some part of the UI, it thinks I'm clicking on the image, since it's technically in front. I want the image to be in the front at a visual level, but without it having any bearing on the keyboard/mouse interaction with the app.My fall back is to create a series of 1pixel wide lines, which will still be in the foreground mouse/keyboard wise, but I can cope with losing that much interaction ability.

View 1 Replies







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