diff --git a/fluents/navigator.py b/fluents/navigator.py index 44b73f4..e4e71ae 100644 --- a/fluents/navigator.py +++ b/fluents/navigator.py @@ -383,8 +383,9 @@ class NavigatorMenu(gtk.Menu): def on_transpose(self, item, navigator): project = main.project ds = self.dataset.transpose() - icon = fluents.icon_factory.get("dataset") - project.data_tree_insert(self.tree_iter, self.dataset.get_name()+".T", ds, None, "black", icon) + ds._name = ds._name + ".T" + icon = fluents.icon_factory.get(ds) + project.data_tree_insert(self.tree_iter, ds.get_name(), ds, None, "black", icon) def on_standardise_rows(self, item, navigator): project = main.project @@ -392,8 +393,8 @@ class NavigatorMenu(gtk.Menu): ds._name = self.dataset._name + ".rsc" axis = 1 ds._array = ds._array/scipy.expand_dims(ds._array.std(axis), axis) - icon = fluents.icon_factory.get("dataset") - project.data_tree_insert(self.tree_iter, ds._name, ds, None, "black", icon) + icon = fluents.icon_factory.get(ds) + project.data_tree_insert(self.tree_iter, ds.get_name(), ds, None, "black", icon) def on_standardise_cols(self, item, navigator): project = main.project @@ -401,8 +402,8 @@ class NavigatorMenu(gtk.Menu): ds._name = self.dataset._name + ".csc" axis = 0 ds._array = ds._array/scipy.expand_dims(ds._array.std(axis), axis) - icon = fluents.icon_factory.get("dataset") - project.data_tree_insert(self.tree_iter, ds._name, ds, None, "black", icon) + icon = fluents.icon_factory.get(ds) + project.data_tree_insert(self.tree_iter, ds.get_name(), ds, None, "black", icon) def on_log(self, item, navigator): project = main.project @@ -415,6 +416,6 @@ class NavigatorMenu(gtk.Menu): ds = self.dataset.copy() ds._array = scipy.log(ds._array) - icon = fluents.icon_factory.get("dataset") - ds._name = self.dataset.get_name()+".log" - project.data_tree_insert(self.tree_iter, ds._name, ds, None, "black", icon) + icon = fluents.icon_factory.get(ds) + ds._name = ds._name + ".log" + project.data_tree_insert(self.tree_iter, ds.get_name(), ds, None, "black", icon)