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
/** | |
* A Quick and Dirty snippet to create iFrame Popups out of things… | |
* Require jQuery || Ember.js | |
* | |
* @class ModalIFrame | |
* | |
* @param {DOMElement} el The element acting as a launcher. | |
* @param {Object} options Defaults: | |
* { | |
* openEvent: 'click', |
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
bind '"\e[A"':history-search-backward | |
bind '"\e[B"':history-search-forward | |
export DRIVE_C="/cygdrive/c" | |
export EDITOR="nano.exe" | |
export CDPATH=.:~:/var/www:$DRIVE_C:$DRIVE_C/Users/jctherond:$DRIVE_C/Program\ Files | |
export HISTCONTROL=ignoredups:ignorespace | |
history -a | |
shopt -s histappend | |
shopt -s checkwinsize |
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
var multiAction = function(action, nb, delay){ | |
this.action = action; | |
this.nb = nb; | |
this._nb = this.nb; | |
this.delay = delay; | |
} | |
multiAction.prototype = { |
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
var blink = function(el, delay, done){ | |
//using jQuery as compatibility layer. ¬¬' | |
$(el).removeClass('active'); | |
$(el).addClass('active'); | |
setTimeout(function(){ | |
$(el).removeClass('active'); | |
done(); | |
}, delay); | |
} |
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
var Carrousel = function(el, from, to, delay){ | |
"strict"; | |
this.el = el; | |
this.delay = delay; | |
this.from = from; | |
this.to = to; | |
this.init(); | |
}; |
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
function getAudioCallback(player, eventName){ | |
var | |
callbackName = 'on' + eventName.charAt(0).toUpperCase() + eventName.substr(1), | |
self = this; | |
; | |
return _.throttle(_.bind(self.audioCallbacks[callbackName], self, player),500); | |
} |
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
---- Minecraft Crash Report ---- | |
// Surprise! Haha. Well, this is awkward. | |
Time: 19/04/14 16:46 | |
Description: Exception getting block type in world | |
java.lang.NullPointerException | |
at tropicraft.world.schematic.CustomGenKoaHut.placeDownTilGround(CustomGenKoaHut.java:28) | |
at tropicraft.world.schematic.CustomGenKoaHut.genPassPre(CustomGenKoaHut.java:20) | |
at build.world.BuildJob.buildStart(BuildJob.java:153) |
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
files: [{ | |
expand: true, | |
cwd: 'source', | |
src: [ '**/*.styl' ], | |
dest: 'build', | |
ext: '.css' | |
}] |
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
var $body = $('body'); | |
var bodySizeInform = function bodySizeInform(){ | |
$body.width(document.width); | |
$body.height(document.height); | |
return true; | |
} | |
bodySizeInform = _.throttle(bodySizeInform, 500); | |
bodySizeInform(); | |
$(window).resize(bodySizeInform); |
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
inside = (what, from)=> | |
if typeof window isnt 'undefined' | |
window[what] = from | |
else | |
global[what] = from | |
we = (obj)-> obj | |
load = (thing)=> inside thing, we require thing | |
inside '$', we require 'jquery' | |
load 'assert' |