diff options
Diffstat (limited to 'src')
| -rw-r--r-- | src/client/rz_core.js | 2 | ||||
| -rw-r--r-- | src/client/view/activity.js | 11 |
2 files changed, 11 insertions, 2 deletions
diff --git a/src/client/rz_core.js b/src/client/rz_core.js index 8255486e..8b18f975 100644 --- a/src/client/rz_core.js +++ b/src/client/rz_core.js @@ -207,7 +207,7 @@ function init() { init_graphs(); init_graph_views(); init_ws_connection(); - activity.init(main_graph, $('.graph-view')); + activity.init(main_graph, main_graph_view, $('.graph-view')); if (rz_config.backend_enabled) { var cur_rzdoc_name = rzdoc__current__get_name(); diff --git a/src/client/view/activity.js b/src/client/view/activity.js index 53706c06..4457a47f 100644 --- a/src/client/view/activity.js +++ b/src/client/view/activity.js @@ -4,13 +4,15 @@ function($, _, Bacon, selection) { var incomingActivityBus = new Bacon.Bus(), activity_element, graph_view_element, + graph_view, graph; -function init(_graph, _graph_view_element) +function init(_graph, _graph_view, _graph_view_element) { activity_element = $('<div class="activity-root-div"></div>'); graph_view_element = _graph_view_element; graph_view_element.append(activity_element); + graph_view = _graph_view; graph = _graph; } @@ -105,6 +107,13 @@ function appendActivity(diff) (event.shiftKey ? selection.invert_both : selection.select_both) (affected_nodes, affected_links); }); + new_div.hover(function (e) { + _.each(affected_nodes, graph_view.node__hover__start); + _.each(affected_links, graph_view.link__hover__start); + }, function (e) { + _.each(affected_nodes, graph_view.node__hover__end); + _.each(affected_links, graph_view.link__hover__end); + }); // TODO - x button // TODO - format of text per activity (topo/attr) // TODO - user data (requires protocol update?) |
