Re: [Flashcoders] search engine optimization for flash sites
Robin, maybe this will help. It wont solve all your problems, but could make a solution a bit easier. http://www.asual.com/swfaddress/ Jiri Robin Burrer wrote: Hi there, My client wants to have his website optimized for search engines. I don't know much about this topic. The binary data of a flash file can't obviously be read by a search engine though. I have this idea to create a html site map for my flash page. Basically this site map would have short summaries of all flash pages and links to these pages (e.g. http://myDomain.com/myflashPgae.htm?page =home). The search engines should then be able to find the site map page. Ideally this site page would be generated dynamically. But for now a static page will do. Does anybody have experience with such an approach? Any thoughts? Cheers Robin ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com
[Flashcoders] Iterator question
Hello list, i have a page object that contains has a Array that holds pageElements. This is a storage for elements with an iPageElement interface. The page object has an destroy() method. When page.destroy() is called, it will loop trough the page.pageElements Array using an iterator. Every iPageElement broadcasts an onElementKilled message when is has been destroyed. When a pageElement broadcast this message, the page need to continue in deleting the next element in the page.pageElement Array. The callback method onElementKilled in the page instance, searches for the element that has been deleted and then removes it from the page.pageElements Array. This is where i think a problem rises, because if the page.pageElements array is updated during the process, the index does not match the element to remove anymore. How can I solve this potential risk? Another question, the array that is passes into the iterator is a reference to the pageElements Array. Does this mean, that if I delete an element from this array from within the iterator, the page.pageElements array is modified? I hope my question is clear.. thank you in advance. Jiri Below a snippet: private function getPageElementIterator() : Void { return new PageElementIterator(this.pageElements) } //initiated the deleting proces, by starting with the first element. public function destroyPageElements() : Void { destroyElement(this.pageElements[0]); } private function destroyElement(element:iPageElement) : Void { curElement.addEventListener('onElementKilled' , this) curElement.destroy(); } private function onElementKilled(eventObj:Object) : Void { var killElement:iPageElement = eventObj.target; var iter:PageElementIterator = this.getPageElementIterator(); while(iter.hasNext()){ var curElement:iPage = iPage (iter.next()); if(killElement == curElement) { //deleted the element now clear the listener and continue killElement.removeEventListener('onElementKilled' , this) /* * POTENTIAL RISK, if a new element is added, then the index, does not match the right element anymore * * get the current index from the deleted element by checking what * the currentIndex of the iterator is, and remove it from this.pageElements Array */ this.pageElements = this.pageElements.splice((iter.getCurrentIndex() , 0) //get the next element in the iterator array if(iter.hasNext()) this.destroyElement( iPage(iter.next()) ); delete killedElement; break; } } } if(this.pageElements.length == 0){ trace('all page elements have been removed') } } ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com
[Flashcoders] Colin Moock Book - stores in Berlin
Hello, My question has not so much to do with actual coding, so I hope that it is not a problem posting it here. I am currently living in Berlin for a few months and I am looking for a bookstore where I can buy the new Colin Moock book on AS3. If somebody on the list happens to be living in Berlin and knows a shop where I can buy books on computer programming (especially the Moock Book), I would love to know it ? And yes I am aware of amazon and the lot, but I prefer looking into books before buying them ;) Jiri ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com
[Flashcoders] Preloading mp3 - onLoad vs GetBytesLoaded()
Hello list, I have a question on preloading mp3's. When I start preloading the mp3 I set the isstreaming to false. Then I check the bytesloaded compared to bytestotal en when that is 100% procent it means all is loaded When I start preloading the sound, I also delegate the function onLoad of the sound Object. I put a trace inside this delegated onLoad method and that fires much later after the 100% loaded is fired? I noticed that when the mp3 is 100% loaded according to the BytesLoaded, and I start the sound by creating a new sound object and using the same url as the preloaded mp3, but setting the streaming flag to true, it stills takes some time, as it seems to buffer the sound. Shouldn't is start immediatedly, as it was preloaded before and is resisiding in the browser cache? How is this possible and what is the best way then to preload a mp3. Many thanx Jiri ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com
Re: [Flashcoders] Grid / Math - getting neighbouring positions
I'll take it ;) thanks for everybody's help. Jiri Merrill, Jason wrote: That is a nice solution, but it leaves me with the problem that starting from one point (3,2) it only produces a set of points of ring directly around the selected point. I am looking for a solution to get _all_ the points, from a certain point and the move in a ring towerds the outside of a grid. Uh, you can still do that with my code - just modify it as needs be. You know how long each array is, you can move out from the center by moving one place back in the arrray in one direction, one way in the other by increasing the position in the array. Take it or leave it I guess. Jason Merrill Bank of America GTO Learning Leadership Development eTools Multimedia Team ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com
Re: [Flashcoders] Grid / Math - getting neighbouring positions
Please I really need help on this on, I am cracking my head over it. Bresenham algo is also not the way to go, because it is for circle's and to complex! I can only get one ring, arggg If I go one ring further then it results in many double values, calculate allready when doing the first ring. Here is the code.. var row = 0; var c:Number = 3; var ring:Number = 1; //take start pos [2,2] var x:Number = 2; var y:Number = 2; // while (rowc) { for (var i:Number = 0; ic; i++) { var rowID:Number = (x-ring)+i; var colID:Number = (y-ring)+row; if (rowID0 || colID0 /* || (rowID == sR colID == sC)*/) { continue; } trace('['+colID+','+rowID+']'); } row++; } ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com
Re: [Flashcoders] Grid / Math - getting neighbouring positions
Thxn Joshua and others, I have to look into that. In the mean time I came up with the following code. This takes in a vector and then calculates a 'ring' from that position. With this, I can scale up the 'radius' and get recursively get all the rings from a point from in to outer ring. My goal i still to fill an array with all the points of the grid, starting from a center point en then moving outwards in a ring. Here is the code so far, i hope someone can maybe give some commment on it. var i:Number = 0; var cycle:Number = 1; var dir:Number = 1; var count:Number = 3; var row:Number = 0; function getTiles(startX:Number , startY:Number) : Void { //startX -= (count-1); //startY -= (count-1); var x:Number = 0; var y:Number = 0; while (cycle=4) { if (cycle2 dir == 1) { dir = -1; } row = (cycle%2); while (icount) { if (dir == 1) { if (row) { display(startX + x, startY + y); x++; } else { display(startX + x, startY + y); y++; } } else { if (row) { display(startX + x, startY + y); x--; } else { display(startX + x, startY + y); y--; } } i++; } i = 0; cycle++; } } function display(x, y) { trace('['+x+','+y+']'); } getTiles(2,2) ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com
[Flashcoders] Mathematics specialist - trigonometry
Hello list, I have a client that wants something like this: http://www.wdcs.co.uk/media/flash/whalebanner/content_pub_en.html Basically a huge image is split into tiles, and each load a tileImage. The user can drag a navigator (small view in ratio) over the image. It can occur that the tiles under the view are not loaded yet. To deal with this I need to know wich tiles are visable, after the user has moved the navigator and then load the corresponding image in at the position. Becuase the amount of tiles, can become quit big I dont want to loop through all the tile MovieClips to find out the closestby. I have a feeling trignomotry is the way to ga, but am poor in Mathmatics. In my example you will find a image with 100x100 movieclip tiles. This is just for testing, because in the end I would like to dynamically createMovieClips on there right location. So I actually need to find out locations [x,y] that are visible. I uploaded some files and hope someone will take the time to dowlaod them and help me with finding a solution. Here is a view: http://playground.dadata.org/trig/test_01.swf and here the .fla can be downloaded http://playground.dadata.org/trig/test_01.fla Many thnx Jiri ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com
[Flashcoders] Grid - getting neighbouring positions
[0,0] [1,0] [2,0] [3,0] [4,0] [0,1] [1,1] [2,1] [3,1] [4,1] [0,2] [1,2] [2,2] [3,2] [4,2] [0,3] [1,3] [2,3] [3,3] [4,3] [0,4] [1,4] [2,4] [3,4] [4,4] I have the following grid and would like to find the neighbouring positions of a certain point, going in a radius from in to out, covering all the positions. Let say I take point [2,2] then its neighbours are in the first ring [1,1] [2,1] [3,1] [3,2] [3,3] [2,3] [1,3] [1,2] I manage to get the first ring, but getting the other rings I haven't got a clue on how to do that. Can somebody help me? Thank you, jiri ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com
[Flashcoders] Grid / Math - getting neighbouring positions
Hello list, I have the following grid and would like to find the neighbouring positions of a certain point, going in a radius from in to out, covering all the positions. [0,0] [1,0] [2,0] [3,0] [4,0] [0,1] [1,1] [2,1] [3,1] [4,1] [0,2] [1,2] [2,2] [3,2] [4,2] [0,3] [1,3] [2,3] [3,3] [4,3] [0,4] [1,4] [2,4] [3,4] [4,4] Let say I take point [2,2] then its neighbours are in the first ring [1,1] [2,1] [3,1] [3,2] [3,3] [2,3] [1,3] [1,2] I manage to get the first ring, but getting the other rings I haven't got a clue on how to do that. Can somebody help me? Thank you, jiri ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com
Re: [Flashcoders] Grid / Math - getting neighbouring positions
The ring is defined by distance not by connectedness. It is used for the following. A big image will be split into tiles of 100x100 pixels, that are loaded from a server. The total image made of these tiles are loaded in a movieclip so that the image is rebuilded. The image is masked by a 100x100 mask and can be scrolled to left and right. Based on the tile that is in the view, i would like to preload the rest of the tiles 'intelligently'. To do this, i take the current tile and start building a loadingQue Array from there. So first the ring around the current tile, the a ring around the first ring and so on, until all the tiles of the total image are in the array. Does that make sense? JIri Ron Wheeler wrote: It depends how you define the rings. It is by distance or by connectedness? Is 0,0 in the second ring with 1.0 and 0,1? What is the purpose of knowing this? Ron Jiri Heitlager | dadata.org wrote: Hello list, I have the following grid and would like to find the neighbouring positions of a certain point, going in a radius from in to out, covering all the positions. [0,0] [1,0] [2,0] [3,0] [4,0] [0,1] [1,1] [2,1] [3,1] [4,1] [0,2] [1,2] [2,2] [3,2] [4,2] [0,3] [1,3] [2,3] [3,3] [4,3] [0,4] [1,4] [2,4] [3,4] [4,4] Let say I take point [2,2] then its neighbours are in the first ring [1,1] [2,1] [3,1] [3,2] [3,3] [2,3] [1,3] [1,2] I manage to get the first ring, but getting the other rings I haven't got a clue on how to do that. Can somebody help me? Thank you, jiri ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com
Re: [Flashcoders] Grid / Math - getting neighbouring positions
That is a nice solution, but it leaves me with the problem that starting from one point (3,2) it only produces a set of points of ring directly around the selected point. I am looking for a solution to get _all_ the points, from a certain point and the move in a ring towerds the outside of a grid. Jiri Merrill, Jason wrote: This requires you to re-do your grid, but it's one way to handle it without complex math. It seems a simple way would be to make each row of the grid an array (the entire thing can be an array as well, but make each row it's own array). You could do some object mix-in to ease syntax and allow for storing complex data types: myGrid = {row:[{cell:[{id:0},{id:1},{id:2},{id:3}], id:0}, {cell:[{id:0},{id:1},{id:2},{id:3}], id:1}, {cell:[{id:0},{id:1},{id:2},{id:3}], id:2}, {cell:[{id:0},{id:1},{id:2},{id:3}], id:3}]} (you would make that with for-loops, not necessarily hand-type, though you could) So the cell at position 3,2 would be: myGrid.row[2].cell[1] (since arrays start at 0) So to get surrounding cells of myGrid.row[2].cell[1], it would be: myGrid.row[1].cell[0] myGrid.row[1].cell[1] myGrid.row[1].cell[2] myGrid.row[2].cell[0] myGrid.row[2].cell[2] myGrid.row[3].cell[0] myGrid.row[3].cell[1] myGrid.row[3].cell[2] In other words, for the cell up and to the left of the current cell, it would be: myGrid.row[thisRow.id-1].cell[thisCell.id-1] the grid cell directly above would be: myGrid.row[thisRow.id-1].cell[thisCell.id] the grid cell directly above and to the right would be: myGrid.row[thisRow.id-1].cell[thisCell.id+1] the grid cell directly to the left would be: myGrid.row[thisRow.id].cell[thisCell.id-1] etc. get thisRow and thisCell objects with for loops. for(var i-0; imyGrid.row.length; i++) { var thisRow:Object = myGrid.row[i] for(var n=0; nthisRow.cell.length; n++) { var thisCell:Object = thisRow.cell[n] //do get grid spaces logic as desc. above here } } Restructure the grid objects to contain the data you need. Make sense? Maybe that's not how you want to handle a grid, but that's what works for me - less math that way. Jason Merrill Bank of America GTO Learning Leadership Development eTools Multimedia Team -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Jiri Heitlager | dadata.org Sent: Saturday, June 16, 2007 8:16 AM To: flashcoders@chattyfig.figleaf.com Subject: [Flashcoders] Grid / Math - getting neighbouring positions Hello list, I have the following grid and would like to find the neighbouring positions of a certain point, going in a radius from in to out, covering all the positions. [0,0] [1,0] [2,0] [3,0] [4,0] [0,1] [1,1] [2,1] [3,1] [4,1] [0,2] [1,2] [2,2] [3,2] [4,2] [0,3] [1,3] [2,3] [3,3] [4,3] [0,4] [1,4] [2,4] [3,4] [4,4] Let say I take point [2,2] then its neighbours are in the first ring [1,1] [2,1] [3,1] [3,2] [3,3] [2,3] [1,3] [1,2] I manage to get the first ring, but getting the other rings I haven't got a clue on how to do that. Can somebody help me? Thank you, jiri ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com
[Flashcoders] SWX and security
I have been reading up on SWX by Aral Balkan and have a question that maybe the list can answer. Dealing with sending data to a server from flash there is always the question of security. Making games in flash and sending data to a server is always a hassle when the sended data needs to be obscured. I wonder if SWX has the potential to make sending data over the wire 'saver', that is when the swf is created on the server side, maybe it can be encrypted. But still the URL to the gateway on the server can be read with different tool, so that makes me wonder if it is possible at all. Some thoughts on the matter by the more genious among the list would be nice ;) Jiri ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com
Re: [Flashcoders] amfphp.org?
The new URL is http://www.amf-php.org Jiri Hershell Bryant wrote: See Count Schemula's reply...it's at sourceforge. -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of dnk Sent: Tuesday, May 15, 2007 9:43 AM To: Flashcoders Subject: [Flashcoders] amfphp.org? looks like the domain has expired (May 7th). I am assuming the project is not dead, but it is rather just an over site by the owner. Does anyone have any info on this? How about a spot to download the latest? d ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com
[Flashcoders] Question on removing Proxied Functions and EventListeners
Hello List, I was wondering if I am doing something correctly when adding listeners to objects. My question is, if I remove the listener is the code below then the right way. Do I use the Proxy class (or mx.utils.Delegate) also when I remove the listener?? //adding a listener this.currentDisplayObject.addEventListener('onContentCleared' , utils.Proxy.create(this , onBlockContentDestoyed , 'text ' , url)) //removing it this.currentDisplayObject.removeEventListener('onContentCleared' , utils.Proxy.create(this , onBlockContentDestoyed)) Thank you Jiri ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com
[Flashcoders] Question on removeEventListener and Delegate callback
Hello List, I was wondering if I am doing something correctly when adding listeners to objects. My question is, if I remove the listener is the code below then the right way. Do I use the Proxy class (or mx.utils.Delegate) also when I remove the listener?? //adding a listener this.currentDisplayObject.addEventListener('onContentCleared' , utils.Proxy.create(this , onBlockContentDestoyed , 'text ' , url)) //removing it this.currentDisplayObject.removeEventListener('onContentCleared' , utils.Proxy.create(this , onBlockContentDestoyed)) Thank you Jiri John Trentini wrote: Hi guys, I want to create as many text fields (which eventually I would like to turn into buttons) as the length of an array. I also want to use the content of the array to populate the text of the fields created dynamically. I have tried everything I know but all I seem to get is one filed with the lasat item in the array, sheesh! I've gone absolutely mad on this one (newish to actionScript, I am!) but can anyone tell me what I am doing wrong here? I could do with a helping hand or seven =:-) var myTxt:Array = new Array(branding, news, about us, print, marks, contact); var myX = 430; var menuArray:Array = new Array(); var ySpacing:Number = 90; // /*create textFields**/ // // for(i=0; imyTxt.length; i++) { _root.createTextField(mytext+[i], 1, myX, 0, 100, 30); myId = _root[mytext+[i]]; myId._y = ySpacing; ySpacing += 40; // trace(myTxt[i]);//the trace works, it list all tyhe lements in the array but myId.text = myTxt[i]; // this one in not producing the appropriate results // myId.border = false; myformat = new TextFormat(); myformat.font = Verdana; myformat.size = 14; myformat.bold = true; myformat.color = 0x55; myformat.align = right; // myId.selectable = false; myId.setTextFormat(myformat); //myId.text = myTxt[i]; //tried putting it at the end but no dah! // } ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com
[Flashcoders] Question on removeEventListener and Delegate callback
I was wondering if I am doing something correctly when adding listeners to objects. My question is, if I remove the listener is the code below then the right way. Do I use the Proxy class (or mx.utils.Delegate) also when I remove the listener?? //adding a listener this.currentDisplayObject.addEventListener('onContentCleared' , utils.Proxy.create(this , onBlockContentDestoyed , 'text ' , url)) //removing it this.currentDisplayObject.removeEventListener('onContentCleared' , utils.Proxy.create(this , onBlockContentDestoyed)) Thank you Jiri ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com
[Flashcoders] Question on removeEventListener and Delegate callback
I was wondering if I am doing something correctly when adding listeners to objects. My question is, if I remove the listener is the code below then the right way. Do I use the Proxy class (or mx.utils.Delegate) also when I remove the listener?? //adding a listener this.currentDisplayObject.addEventListener('onContentCleared' , utils.Proxy.create(this , onBlockContentDestoyed , 'text ' , url)) //removing it this.currentDisplayObject.removeEventListener('onContentCleared' , utils.Proxy.create(this , onBlockContentDestoyed)) Thank you Jiri John Trentini wrote: Hi guys, I want to create as many text fields (which eventually I would like to turn into buttons) as the length of an array. I also want to use the content of the array to populate the text of the fields created dynamically. I have tried everything I know but all I seem to get is one filed with the lasat item in the array, sheesh! I've gone absolutely mad on this one (newish to actionScript, I am!) but can anyone tell me what I am doing wrong here? I could do with a helping hand or seven =:-) var myTxt:Array = new Array(branding, news, about us, print, marks, contact); var myX = 430; var menuArray:Array = new Array(); var ySpacing:Number = 90; // /*create textFields**/ // // for(i=0; imyTxt.length; i++) { _root.createTextField(mytext+[i], 1, myX, 0, 100, 30); myId = _root[mytext+[i]]; myId._y = ySpacing; ySpacing += 40; // trace(myTxt[i]);//the trace works, it list all tyhe lements in the array but myId.text = myTxt[i]; // this one in not producing the appropriate results // myId.border = false; myformat = new TextFormat(); myformat.font = Verdana; myformat.size = 14; myformat.bold = true; myformat.color = 0x55; myformat.align = right; // myId.selectable = false; myId.setTextFormat(myformat); //myId.text = myTxt[i]; //tried putting it at the end but no dah! // } ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com
[Flashcoders] Matrix Building
Can somebody help me out with dynamically building a matrix of clips. Well it is not really a matrix, see example: 1 2 3 4 12 5 11 6 10 9 8 7 Thanks.. Jiri ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com
[Flashcoders] Matrix Building
Can somebody help me out with dynamically building a matrix of clips. Well it is not really a matrix, see example: 1 2 3 4 12 5 11 6 10 9 8 7 Thanks.. Jiri ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com
[Flashcoders] Init generic clip
Hello list, I have made a very simpele MovieClip that functions as a generic button, this is clip 'gen_btn_mc'. For the designers it is important that I place the gen_btn_mc on stage and not attach it at runtime. The gen_btn_mc clip itself has a few functions on the 1st frame of its timeline, these are: setLabel() setSize() setIcon() Because the button is place on stage during authortime, it seems the functions of the gen_btn_mc can only be called after one 'onEnterFrame' because it seems the functions are 'undefined' otherwise. EXAMPLE clipInstance0 is set on stage timeline. Then on the stage timeline I have to put this code. onEnterFrame = function(){ clipInstance0.setLabel('hello world') clipInstance0.setSize(200) clipInstance0.setIcon(true) delete this.onEnterFrame } This makes the clip flicker, and it is clearly being set, becuase of the one onEnterFrame loop. QUESTION Is there a way I can overcome this init. problem WITHOUT attaching the clip at runtime? Many thanks. Jiri ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com
Re: [Flashcoders] Init generic clip
Thnks for the posts Both suggested solutions don't work, altough the first one by Gilles does work. But I want the button to be selfcontained, no external initFunctions. Just a MovieClip onStage called btn and on the parent timeline of btn something like btn.setLabel('hello world') The onLoad suggestion I dont get working. btn.onLoad = function(){ this.setLabel('hello world') } this is actual the same as the onEnterFrame. It is not that I have a problem with the onEnterFrame, I just dont understand how Flash VM works. Basically I would like the enclosed script to be executed before the frame of the timeline it is seen on is started. Is this possible. For more light on what I am trying to achive, the file can be downloaded here: playground.dadata.org/initButtonWoo.fla Jiri Heitlager | dadata.org wrote: Hello list, I have made a very simpele MovieClip that functions as a generic button, this is clip 'gen_btn_mc'. For the designers it is important that I place the gen_btn_mc on stage and not attach it at runtime. The gen_btn_mc clip itself has a few functions on the 1st frame of its timeline, these are: setLabel() setSize() setIcon() Because the button is place on stage during authortime, it seems the functions of the gen_btn_mc can only be called after one 'onEnterFrame' because it seems the functions are 'undefined' otherwise. EXAMPLE clipInstance0 is set on stage timeline. Then on the stage timeline I have to put this code. onEnterFrame = function(){ clipInstance0.setLabel('hello world') clipInstance0.setSize(200) clipInstance0.setIcon(true) delete this.onEnterFrame } This makes the clip flicker, and it is clearly being set, becuase of the one onEnterFrame loop. QUESTION Is there a way I can overcome this init. problem WITHOUT attaching the clip at runtime? Many thanks. Jiri ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com
Re: [Flashcoders] AS2 TextField with html content question
I think you have to use a placeholder. So in you html code that is rendered in the input field set the width and height: img align='left' src='pics' width='100' height='100'/ To detect if images are loaded I think you will have to make something like a proxy class that handles the loading of the images (offscreen for instance) Jiri Max Kaufmann wrote: If a TextField in AS2 contains images, how does one detect that the images have finished loading? Or that the internal content height has changed? Max Kaufmann l Technical Artist - 2105 Sarah St | Pittsburgh, PA 15203 O (412) 567-4606 W www.silvertreemedia.com C (440) 915-8277 E [EMAIL PROTECTED] ___ [EMAIL PROTECTED] To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com ___ [EMAIL PROTECTED] To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com