Permalink
Browse files

Fixed event listener usage.

Moved tests to their own directory.
Updated license to only MIT.
  • Loading branch information...
1 parent 65148f4 commit 0640e1b281f56b52275431ddc688ce81011ad66c @eligrey committed Oct 12, 2010
View
@@ -1,10 +1,9 @@
-This program is dual-licensed under the GNU GPL v3 and the MIT/X11 license.
-
+This software is licensed under the MIT/X11 license.
MIT/X11 license
---------------
-Copyright © 2010 [Elijah Grey]
+Copyright © 2010 [Elijah Grey][1], who also goes by [Eli Grey][1].
Permission is hereby granted, free of charge, to any person
obtaining a copy of this software and associated documentation
@@ -28,24 +27,4 @@ FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
OTHER DEALINGS IN THE SOFTWARE.
-GNU GPL v3 license
-------------------
-
-Copyright © 2010 [Elijah Grey]
-
-This software is free software: you can redistribute it and/or modify
-it under the terms of the GNU General Public License as published by
-the Free Software Foundation, either version 3 of the License, or
-(at your option) any later version.
-
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
-
-You should have received a copy of the GNU General Public License
-along with this program. If not, see <http://www.gnu.org/licenses/>.
-
-
-
- [Elijah Grey]: http://eligrey.com
+ [1]: http://eligrey.com
View
@@ -1,16 +1,15 @@
/*
* Asynchronous document.write
*
- * 2010-06-02
+ * 2010-10-12
*
* By Eli Grey, http://eligrey.com
- *
- * License: GNU GPL v3 and the X11/MIT license
- * See COPYING.md
+ * Licensed under the X11/MIT License
+ * See LICENSE.md
*
* Usage:
* eval(document.write.START);
- * document.write(...);
+ * document.write(html);
* eval(document.write.END);
*/
@@ -79,19 +78,19 @@
addEvtListener, remEvtListener, listener;
- if ((addEvtListener = doc.addEventListener) &&
- (remEvtListener = doc.removeEventListener))
- {
+ if (doc.addEventListener && doc.removeEventListener) {
+ addEvtListener = doc.addEventListener;
+ remEvtListener = doc.removeEventListener;
listener = function (evt) {
remEvtListener.call(doc, evt.type, listener, False);
domReady();
};
addEvtListener.call(doc, "DOMContentLoaded", listener, False);
addEvtListener.call(doc, "load", listener, False);
- } else if ((addEvtListener = doc.attachEvent) &&
- (remEvtListener = doc.detachEvent))
- {
+ } else if (doc.attachEvent && doc.detachEvent) {
+ addEvtListener = doc.attachEvent;
+ remEvtListener = doc.detachEvent;
listener = function () {
remEvtListener.call(doc, "onload", listener);
};

Some generated files are not rendered by default. Learn more.

Oops, something went wrong.
File renamed without changes.
File renamed without changes.
File renamed without changes.

0 comments on commit 0640e1b

Please sign in to comment.