~azzar1/unity/add-show-desktop-key

« back to all changes in this revision

Viewing changes to ivle/webapp/console/media/console.js

  • Committer: William Grant
  • Date: 2009-02-25 23:04:11 UTC
  • Revision ID: grantw@unimelb.edu.au-20090225230411-lbdyl32ir0m3d59b
Make all of the services executable.

Show diffs side-by-side

added added

removed removed

Lines of Context:
254
254
 
255
255
    if (typeof(inputbox) == "string")
256
256
    {
257
 
        var inputline = inputbox + "\n";
 
257
        var inputline = inputbox;
258
258
        inputbox = null;
259
259
    }
260
260
    else
270
270
        var span = document.createElement("span");
271
271
        span.setAttribute("class", "inputPrompt");
272
272
        span.appendChild(document.createTextNode(
273
 
              document.getElementById("console_prompt").firstChild.nodeValue)
 
273
              document.getElementById("console_prompt").firstChild.textContent)
274
274
                        );
275
275
        output.appendChild(span);
276
276
        // Print input line itself in a span
440
440
    case 38:                /* Up arrow */
441
441
        hist.up(inp.value);
442
442
        inp.value = hist.curr();
443
 
        /* Inhibit further responses to this event, or WebKit moves the
444
 
         * cursor to the start. */
445
 
        return false;
446
443
        break;
447
444
    case 40:                /* Down arrow */
448
445
        hist.down(inp.value);
449
446
        inp.value = hist.curr();
450
 
        return false;
451
447
        break;
452
448
    }
453
449
}
468
464
    else
469
465
    {
470
466
        xhr = ajax_call(null, "console", "service", {"ivle.op": "chat", "kind": "terminate", "key": server_key}, "POST");
471
 
        console_response(null, null, xhr.responseText);
 
467
        console_response(null, null, null, xhr.responseText);
472
468
    }
473
469
}
474
470