Merge pull request #1856 from ethereum/debugger

Fix updating debugger views
pull/3094/head
Liana Husikyan 6 years ago committed by GitHub
commit 28baddbbc3
  1. 7
      src/app/debugger/debuggerUI/vmDebugger/DropdownPanel.js

@ -98,11 +98,10 @@ DropdownPanel.prototype.update = function (_data, _header) {
DropdownPanel.prototype.setContent = function (node) { DropdownPanel.prototype.setContent = function (node) {
if (!this.view) return if (!this.view) return
var parent = this.view.querySelector('.dropdownpanel div.dropdowncontent') yo.update(this.view, this.render(null, node))
if (parent) parent.replaceChild(node, parent.firstElementChild)
} }
DropdownPanel.prototype.render = function (overridestyle) { DropdownPanel.prototype.render = function (overridestyle, node) {
var content = yo`<div>Empty</div>` var content = yo`<div>Empty</div>`
if (this.json) { if (this.json) {
content = this.treeView.render({}) content = this.treeView.render({})
@ -117,7 +116,7 @@ DropdownPanel.prototype.render = function (overridestyle) {
var contentNode = yo`<div class='dropdownpanel ${css.dropdownpanel}' style='display:none'> var contentNode = yo`<div class='dropdownpanel ${css.dropdownpanel}' style='display:none'>
<i class="${css.refresh} fa fa-refresh" aria-hidden="true"></i> <i class="${css.refresh} fa fa-refresh" aria-hidden="true"></i>
<div class='dropdowncontent'>${content}</div> <div class='dropdowncontent'>${node || content}</div>
<div class='dropdownrawcontent' style='display:none'></div> <div class='dropdownrawcontent' style='display:none'></div>
<div class='message' style='display:none'></div> <div class='message' style='display:none'></div>
</div>` </div>`

Loading…
Cancel
Save