Commit 808740f0 authored by Jonathan Wilkes's avatar Jonathan Wilkes
Browse files

fix #214: Cannot read property 'setAttributeNS' of null

parent ad0d9c62
...@@ -2293,8 +2293,11 @@ function gui_bng_new(cid, tag, cx, cy, radius) { ...@@ -2293,8 +2293,11 @@ function gui_bng_new(cid, tag, cx, cy, radius) {
} }
function gui_bng_button_color(cid, tag, color) { function gui_bng_button_color(cid, tag, color) {
var button = get_item(cid, tag + "button"); var button;
configure_item(button, { fill: color }); if (patchwin[cid]) {
button = get_item(cid, tag + "button");
configure_item(button, { fill: color });
}
} }
function gui_bng_configure(cid, tag, color, cx, cy, r) { function gui_bng_configure(cid, tag, color, cx, cy, r) {
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment