FAQ
Reviewers: golang-dev_googlegroups.com,

Message:
Hello [email protected] (cc: [email protected]),

I'd like you to review this change to
https://code.google.com/p/go.talks


Description:
go.talks/present/playground.js: auto scroll output
but only when the user scrolls to the bottom.

Please review this at http://codereview.appspot.com/6849074/

Affected files:
M present/static/playground.js


Index: present/static/playground.js
===================================================================
--- a/present/static/playground.js
+++ b/present/static/playground.js
@@ -9,11 +9,14 @@

function showMessage(o, m, className) {
var span = document.createElement("span");
+ var needScroll = (o.scrollTop + o.offsetHeight) == o.scrollHeight
m = m.replace(/&/g, "&");
m = m.replace(/</g, "&lt;");
span.innerHTML = m;
span.className = className;
o.appendChild(span);
+ if (needScroll)
+ o.scrollByLines(1)
}

function onMessage(e) {

Search Discussions

  • Minux Ma at Nov 18, 2012 at 9:25 pm
    A good test case: http://127.0.0.1:3999/2012/goforc.slide#54

    PS: scrollByLines is supported on Firefox, Safari and Chrome, but
    is not supported on IE and Opera.

    https://codereview.appspot.com/6849074/
  • Minux Ma at Nov 20, 2012 at 6:23 pm
    PTAL. Now I believe the Javascript is portable across browser.

    https://codereview.appspot.com/6849074/
  • Minux Ma at Nov 26, 2012 at 6:02 pm
  • Francesc Campoy Flores at Nov 26, 2012 at 6:13 pm
    Hi,

    Could you host this somewhere where we can have a look on how it works?
    The url you sent some days ago is local to your network.

    Thanks



    --
    --
    Francesc
  • Minux at Nov 26, 2012 at 7:10 pm

    On Tue, Nov 27, 2012 at 2:13 AM, Francesc Campoy Flores wrote:

    Could you host this somewhere where we can have a look on how it works?
    The url you sent some days ago is local to your network.
    for the play feature to work, present must be run locally (App Engine
    doesn't support
    websocket yet).

    you just need to clpatch this CL, build present if not already done, go to
    the directory
    $GOPATH/src/code.google.com/p/go.taks, and run:
    present/presnet -play

    then open the URL i mentioned.
  • Rsc at Nov 26, 2012 at 8:54 pm
    Andrew should review this, but he's out this week. I think he'll be back
    next week.


    https://codereview.appspot.com/6849074/
  • Franciscossouza at Nov 27, 2012 at 12:42 am

    On 2012/11/26 18:18:26, minux wrote:
    On Tue, Nov 27, 2012 at 2:13 AM, Francesc Campoy Flores
    wrote:
    Could you host this somewhere where we can have a look on how it
    works?
    The url you sent some days ago is local to your network.
    for the play feature to work, present must be run locally (App Engine
    doesn't support
    websocket yet).
    you just need to clpatch this CL, build present if not already done, go to
    the directory
    $GOPATH/src/code.google.com/p/go.taks, and run:
    present/presnet -play
    then open the URL i mentioned.
    Both code and feature LGTM (if that matters). It worked nicely in all
    browser I'm able to test (Firefox, Opera, Safari and Chrome).

    http://codereview.appspot.com/6849074/
  • Adg at Nov 30, 2012 at 12:44 pm
    LGTM if it works in Chrome, Firefox, and Safari.

    https://codereview.appspot.com/6849074/
  • Adg at Nov 30, 2012 at 1:29 pm
  • Minux Ma at Nov 30, 2012 at 5:03 pm
    *** Submitted as
    https://code.google.com/p/go/source/detail?r=ed69caf364d5&repo=talks ***

    go.talks/present/playground.js: auto scroll output
    but only when the user already scrolls to the bottom.

    R=adg, franciscossouza
    CC=golang-dev
    https://codereview.appspot.com/6849074


    https://codereview.appspot.com/6849074/

Related Discussions

Discussion Navigation
viewthread | post
Discussion Overview
groupgolang-dev @
categoriesgo
postedNov 18, '12 at 9:18p
activeNov 30, '12 at 5:03p
posts11
users5
websitegolang.org

People

Translate

site design / logo © 2023 Grokbase