This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // ================================================================================ | |
| // | |
| // ADOBE SYSTEMS INCORPORATED | |
| // Copyright 2010 Adobe Systems Incorporated | |
| // All Rights Reserved. | |
| // | |
| // NOTICE: Adobe permits you to use, modify, and distribute this file | |
| // in accordance with the terms of the license agreement accompanying it. | |
| // | |
| // ================================================================================ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| /** | |
| * Spinning cube in Molehill. | |
| * http://ltslashgt.com/2011/02/28/molehill-spinning-cube/ | |
| */ | |
| package { | |
| import com.adobe.utils.AGALMiniAssembler; | |
| import flash.display.Sprite; | |
| import flash.display.Stage3D; | |
| import flash.display.StageAlign; | |
| import flash.display.StageScaleMode; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?php | |
| /** | |
| * Return true if the email address is valid. | |
| * From http://www.linuxjournal.com/article/9585. | |
| * | |
| * @return bool | |
| */ | |
| function isValidEmail($email) { | |
| $isValid = true; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import os.path | |
| import struct | |
| import sys | |
| import traceback | |
| import zlib | |
| if len(sys.argv) < 2: | |
| print >> sys.stderr, "usage: %s <filename>" % sys.argv[0] | |
| sys.exit(1) | |
| filename = sys.argv[1] |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <!DOCTYPE html> | |
| <html> | |
| <body> | |
| <canvas id="canvas" width="480" height="480"></canvas> | |
| <script type="text/javascript"> | |
| var canvas = document.getElementById('canvas'); | |
| var context = canvas.getContext('2d'); | |
| context.strokeStyle = '#fff'; | |
| context.fillStyle = '#000'; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // ECMAScript 5 object proxy as JS | |
| (function(exports) { | |
| function getPropertyDescriptor(obj, propertyName) { | |
| print("getPropertyDescriptor", obj, propertyName); | |
| var desc = Object.getOwnPropertyDescriptor(obj, propertyName); | |
| if (desc !== undefined) { | |
| return desc; | |
| } else { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #import <UIKit/UIKit.h> | |
| namespace PhuceContext { | |
| // state (4.8.11.1.1) | |
| bool save(); | |
| bool restore(); | |
| // transformations (4.8.11.1.2) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| --- config/autoconf.mk.in 2010-06-05 19:06:36.000000000 -0700 | |
| +++ config/autoconf.mk.in 2010-06-05 19:06:59.000000000 -0700 | |
| @@ -97,7 +97,6 @@ | |
| NS_TRACE_MALLOC = @NS_TRACE_MALLOC@ | |
| INCREMENTAL_LINKER = @INCREMENTAL_LINKER@ | |
| -MACOSX_DEPLOYMENT_TARGET = @MACOSX_DEPLOYMENT_TARGET@ | |
| BUILD_STATIC_LIBS = @BUILD_STATIC_LIBS@ | |
| ENABLE_TESTS = @ENABLE_TESTS@ | |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // Removes all classes beginning with prefix, and replaces them | |
| // with a prefix+suffix class. For example: | |
| // $('#blah').addClass('foobaz'); | |
| // $('#blah').replaceClasses('foo', 'baz'); | |
| jQuery.fn.replaceClasses = function(prefix, suffix) { | |
| var re = new RegExp('^' + prefix); | |
| return this.each(function() { | |
| var classes = this.className.split(/\s+/); | |
| var newClasses = []; | |
| var i = classes.length; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // Javascript state machine. Allows you to specify a number of routes | |
| // and set a target state, and it will call through the routes to | |
| // get there. | |
| function Machine(defaultState, routes) { | |
| this.target = undefined; | |
| this.transition = undefined; | |
| this.routes = typeof routes === 'function' ? routes() : routes; | |
| // Set the state last, so the route will be triggered. |