enchant();

window.onload = function() {
    var game = new Game(320, 320);
    game.onload = function() {
        var status = new Label("");
        status.add = function(str) {
            this.text = str + "<br />" + this.text;
        };

        var round = function(num) {
            return Math.round(num * 1e3) / 1e3;
        };

        game.rootScene.on('touchstart', function(evt) {
            status.add('touchstart (' + round(evt.x) + ', ' + round(evt.y) + ')');
        });
        game.rootScene.on('touchmove', function(evt) {
            status.add('touchmove (' + round(evt.x) + ', ' + round(evt.y) + ')');
        });
        game.rootScene.on('touchstart', function(evt) {
            status.add('touchend (' + round(evt.x) + ', ' + round(evt.y) + ')');
        });

        ['up', 'down', 'right', 'left'].forEach(function (direction) {
            game.rootScene.on(direction + 'buttondown', function() {
                status.add(direction + 'buttondown');
            });
            game.rootScene.on(direction + 'buttonup', function() {
                status.add(direction + 'buttonup');
            });
        });
        game.rootScene.addChild(status);
    };
    game.start();
};

@@ -136,16 +136,42 @@
 el(%22%22);%0A
+        status._log = %5B%5D;%0A
         
@@ -220,41 +220,124 @@
 his.
-text = str + %22%3Cbr /%3E%22 + this.text
+_log.unshift(str);%0A            this._log = this._log.slice(0, 20);%0A            this.text =  this._log.join('%3Cbr /%3E')
 ;%0A  

modify eventViewer example (#188)