I guess FB needs to know the location of the file so that it can override the corresponding class in the compiled swc? I am not 100%, but it works.
On Thursday, March 5, 2015, Dany Dhondt [via Apache Flex Development] < ml-node+s2333347n45413...@n4.nabble.com> wrote: > Thanks Kevin for this excellent tip. Why do you have to copy the directory > structure? Is it to preserve the package line in the class file? > > I'll start experimenting with these tips as soon as I feel comfortable > enough with the repo :) > Dany > > Op 5 mar 2015 om 02:09 uur uur schreef "kevin.godell" <[hidden email] > <http:///user/SendEmail.jtp?type=node&node=45413&i=0>>: > > @Dany > > I wanted to elaborate further on what Alex mentioned about adding a source > path for working on patches. > > For example, I just found a problem and wanted to make some quick edits to > see if I could fix ArrayList.as. So, I found the file in the sdk, making > note of the directory structure. I copied the file and created a duplicate > directory and put that in a folder called "monkey-patch" that I have on my > desktop. The file and directory that I created was > C:\Users\familyRoom\Desktop\monkey-patch\org\apache\flex\collections\ > containing a copy of ArrayList.as. The directory and main folder name can > be > whatever you like, but I used the desktop just for the sake of being easy > to > find. I named the main folder "monkey-patch" because I think that I may > seen > it called monkey patching on some forum. In FB, I went to project -> > properties -> flex build path -> source path and added the monkey-patch > folder via the "add folder" button. Now, the file can be seen in the > package > explorer, which allows me to make quick edits for debugging and testing, > instead of compiling after each edit. There are some limitations, such as > if > a file you are tweaking has some "include" calls to other files, you will > have to include additional directories and files to make FB happy. > > It took me longer to write this post than it did to setup the monkey-patch > and fix the file. > > > > -- > View this message in context: > http://apache-flex-development.2333347.n4.nabble.com/Setup-for-patching-tp45348p45402.html > Sent from the Apache Flex Development mailing list archive at Nabble.com. > > > > ------------------------------ > If you reply to this email, your message will be added to the discussion > below: > > http://apache-flex-development.2333347.n4.nabble.com/Setup-for-patching-tp45348p45413.html > To start a new topic under Apache Flex Development, email > ml-node+s2333347n1...@n4.nabble.com > <javascript:_e(%7B%7D,'cvml','ml-node%2bs2333347n1...@n4.nabble.com');> > To unsubscribe from Setup for patching, click here > <http://apache-flex-development.2333347.n4.nabble.com/template/NamlServlet.jtp?macro=unsubscribe_by_code&node=45348&code=a2V2aW4uZ29kZWxsQGdtYWlsLmNvbXw0NTM0OHwyNTAxOTQ4MDU=> > . > NAML > <http://apache-flex-development.2333347.n4.nabble.com/template/NamlServlet.jtp?macro=macro_viewer&id=instant_html%21nabble%3Aemail.naml&base=nabble.naml.namespaces.BasicNamespace-nabble.view.web.template.NabbleNamespace-nabble.view.web.template.NodeNamespace&breadcrumbs=notify_subscribers%21nabble%3Aemail.naml-instant_emails%21nabble%3Aemail.naml-send_instant_email%21nabble%3Aemail.naml> > -- View this message in context: http://apache-flex-development.2333347.n4.nabble.com/Setup-for-patching-tp45348p45415.html Sent from the Apache Flex Development mailing list archive at Nabble.com.