Commit 47f67721 authored by Lars Kruse's avatar Lars Kruse

minor GUI cleanup

* hide "description" column of processes (not in use, yet)
* trigger control update for name changes of model/tool/process/bounds
parent 049b63dd
......@@ -373,6 +373,7 @@ class Bounds(pycam.Plugins.ListPluginBase):
bounds = self.get_by_path(path)
if bounds and (new_text != bounds["name"]) and new_text:
bounds["name"] = new_text
self.core.emit_event("bounds-list-changed")
class BoundsDict(pycam.Plugins.ObjectWithAttributes):
......
......@@ -138,6 +138,7 @@ class Models(pycam.Plugins.ListPluginBase):
model = self.get_by_path(path)
if model and (new_text != model["name"]) and new_text:
model["name"] = new_text
self.core.emit_event("model-list-changed")
def _visualize_model_name(self, column, cell, model, m_iter):
model_obj = self.get_by_path(model.get_path(m_iter))
......
......@@ -132,6 +132,7 @@ class Processes(pycam.Plugins.ListPluginBase):
process = self.get_by_path(path)
if process and (new_text != process["name"]) and new_text:
process["name"] = new_text
self.core.emit_event("process-list-changed")
def _trigger_table_update(self):
self.gui.get_object("NameColumn").set_cell_data_func(
......
......@@ -171,6 +171,7 @@ class Tools(pycam.Plugins.ListPluginBase):
tool = self.get_by_path(path)
if tool and (new_text != tool["name"]) and new_text:
tool["name"] = new_text
self.core.emit_event("tool-list-changed")
def _edit_tool_id(self, cell, path, new_text):
tool = self.get_by_path(path)
......
......@@ -51,12 +51,13 @@
<child>
<object class="GtkCellRendererText" id="NameCell">
<property name="editable">True</property>
</object>
</object>
</child>
</object>
</child>
<child>
<object class="GtkTreeViewColumn" id="DescriptionColumn">
<property name="visible">False</property>
<property name="title">Description</property>
<property name="expand">True</property>
<child>
......
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