Skip to content
This repository was archived by the owner on May 17, 2021. It is now read-only.

Global object should be equal to the parent object.#46

Merged
Olical merged 3 commits intoOlical:developfrom
nathggns:global_object
Jul 6, 2013
Merged

Global object should be equal to the parent object.#46
Olical merged 3 commits intoOlical:developfrom
nathggns:global_object

Conversation

@nathggns
Copy link
Contributor

@nathggns nathggns commented Jul 3, 2013

Inside event handlers, the global object (this), should be equal to the object the event is being triggered on.

This fixes that, and adds a test for it.

@Olical
Copy link
Owner

Olical commented Jul 3, 2013

I was always under the impression that the scope would just follow through magically, I probably should have investigated this a while ago. I guess people could always have used bind to set the scope, but this seems a lot better.

I'll have a poke around with this soon and probably merge it in as soon as I'm sure it's okay and I have it documented. Thank you for adding tests too!

It would be interesting to see if this would break any current code, although I highly doubt it.

Thanks a lot for the improvements.

@ghost ghost assigned Olical Jul 6, 2013
@Olical Olical merged commit ba42e2f into Olical:develop Jul 6, 2013
@desandro
Copy link
Contributor

Any reason why this was closed? This seemed useful.

@Olical
Copy link
Owner

Olical commented Jul 13, 2013

Oh, don't worry, it has been merged in. I should of put a comment in here, my bad.

It was commited to master and I merged it into develop, I also merged it with the wrong argument and didn't realise. So GitHub can't see it, but it was merged in.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants

Comments