|
337 | 337 | }
|
338 | 338 |
|
339 | 339 | function debug_file_response(data) {
|
| 340 | + function populate_variables(data) { |
| 341 | + $('#variables-wrapper pre').text(""); |
| 342 | + for (var i=0; i<data.length; i++) { |
| 343 | + if (data[i].name && data[i].content && data[i].type) { |
| 344 | + var content = data[i].name + ": " + data[i].content + '\n'; |
| 345 | + $('#variables-wrapper pre').append(document.createTextNode(content)); |
| 346 | + } |
| 347 | + |
| 348 | + } |
| 349 | + } |
| 350 | + |
340 | 351 | occEditor.debug_toggle_buttons(true);
|
341 | 352 | occEditor.debug_message('Ready');
|
342 | 353 | //console.log(data);
|
|
663 | 674 | if (is_script(file.extension)) {
|
664 | 675 | $(templates.editor_bar_run_link).appendTo('.editor-bar-actions');
|
665 | 676 | $(templates.editor_bar_debug_link).appendTo('.editor-bar-actions');
|
666 |
| - |
| 677 | + |
667 | 678 | //$(templates.editor_bar_trace_link).appendTo('.editor-bar-actions');
|
668 | 679 | }
|
669 | 680 |
|
|
1096 | 1107 | return !$link.hasClass('debug-link-disabled');
|
1097 | 1108 | }
|
1098 | 1109 |
|
1099 |
| - function populate_variables(data) { |
1100 |
| - $('#variables-wrapper pre').text(""); |
1101 |
| - for (var i=0; i<data.length; i++) { |
1102 |
| - if (data[i].name && data[i].content && data[i].type) { |
1103 |
| - var content = data[i].name + ": " + data[i].content + '\n'; |
1104 |
| - $('#variables-wrapper pre').append(document.createTextNode(content)); |
1105 |
| - } |
1106 |
| - |
1107 |
| - } |
1108 |
| - } |
1109 |
| - |
1110 |
| - |
1111 |
| - |
1112 | 1110 | function get_breakpoints() {
|
1113 | 1111 | var editor_breakpoints = editor.getSession().getBreakpoints();
|
1114 | 1112 | var breakpoints = "";
|
|
1198 | 1196 | occEditor.populate_editor(file);
|
1199 | 1197 |
|
1200 | 1198 | //clean up listeners
|
1201 |
| - socket.removeAllListeners('debug-file-response'); |
1202 | 1199 | $(document).off('click touchstart', '.debug-step-over');
|
1203 | 1200 | $(document).off('click touchstart', '.debug-step-in');
|
1204 | 1201 | $(document).off('click touchstart', '.debug-run');
|
|
0 commit comments