This file contains 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( ) { | |
/** | |
* 指定したクラスを持つ要素が追加されたら発火させる | |
*/ | |
$( 'body' ).on( 'DOMNodeInserted', function( event_info ) { | |
var element = $( event_info.target ); | |
if ( element.hasClass( 'test' ) ) { | |
console.log( element.text( ) ); | |
} | |
} ); |
This file contains 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( $ ) {'use strict'; | |
$( function( ) { | |
/** | |
* あるAPIからデータを取り出すことができたらcallbacksを発火させる関数 | |
*/ | |
function get_data_from_api( callbacks ) { | |
var api_url = 'http://judge.u-aizu.ac.jp/onlinejudge/webservice/user?id=shioshiota'; | |
$.get( api_url, function( api_result ) { | |
var solved = $( 'status', api_result ).first( ).children( 'solved' ).text( ).trim( ); | |
if ( callbacks.fire ) { |
This file contains 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
/** | |
* [begin, end)の範囲で非同期的な繰り返し処理を行う | |
* | |
* @param {Object} options ループの設定 | |
* begin, end: 範囲指定 | |
* inc: まとめて実行する量 | |
* duration: ループごとに間をあける時間[ms] | |
* | |
* @return {jQuery.Deferred} | |
* progress: 非同期処理を行う部分 |
This file contains 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() { | |
var __customevents = {}, __protocol = {}, __connector = {}, __timer = {}, __options = {}, __reloader = {}, __livereload = {}, __less = {}, __startup = {}; | |
// customevents | |
var CustomEvents; | |
CustomEvents = { | |
bind: function(element, eventName, handler) { | |
if (element.addEventListener) { | |
return element.addEventListener(eventName, handler, false); | |
} else if (element.attachEvent) { |
This file contains 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 fs = require('fs'); | |
var filename = 'file'; | |
var watch_obj = fs.watch(filename, function func(event, filename) { | |
if ( event !== 'change' ) | |
return; | |
// ......... | |
watch_obj.close(); |
This file contains 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
// compile: g++ -lboost_system -lboost_thread thread.cpp | |
#include <iostream> | |
#include <boost/thread.hpp> | |
#include <boost/bind.hpp> | |
void test1() { | |
for ( int i = 0; i < 10; ++ i ) | |
std::cout << "test 1" << std::endl; | |
} |
This file contains 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
./common/b2Settings.js | |
./common/math/b2Vec2.js | |
./common/math/b2Mat22.js | |
./common/math/b2Math.js | |
./collision/b2AABB.js | |
./collision/b2Bound.js | |
./collision/b2BoundValues.js | |
./collision/b2Pair.js | |
./collision/b2PairCallback.js | |
./collision/b2BufferedPair.js |
This file contains 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
#include <iostream> | |
using namespace std; | |
struct TestA { | |
int needed_method() { | |
cout << "test" << endl; | |
return 0; | |
} | |
}; |
This file contains 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
**/.*.swp |
This file contains 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
# 2013-12-21 | |
# test |
OlderNewer