renamed the colors dialog to types
[debian/gnuradio] / grc / gui / ActionHandler.py
index 2c411a175a88c4752066c3e871f792bbf3b543e5..9af580e8e1e5721ad7c3f65cff0065eac69b5825 100644 (file)
@@ -133,7 +133,7 @@ class ActionHandler:
                                Actions.FLOW_GRAPH_OPEN, Actions.FLOW_GRAPH_SAVE_AS,
                                Actions.FLOW_GRAPH_CLOSE, Actions.ABOUT_WINDOW_DISPLAY,
                                Actions.FLOW_GRAPH_SCREEN_CAPTURE, Actions.HELP_WINDOW_DISPLAY,
-                               Actions.COLORS_WINDOW_DISPLAY,
+                               Actions.TYPES_WINDOW_DISPLAY,
                        ): Actions.get_action_from_name(action).set_sensitive(True)
                        if not self.init_file_paths:
                                self.init_file_paths = Preferences.files_open()
@@ -237,8 +237,8 @@ class ActionHandler:
                        Dialogs.AboutDialog(self.get_flow_graph().get_parent())
                elif state == Actions.HELP_WINDOW_DISPLAY:
                        Dialogs.HelpDialog()
-               elif state == Actions.COLORS_WINDOW_DISPLAY:
-                       Dialogs.ColorsDialog(self.get_flow_graph().get_parent())
+               elif state == Actions.TYPES_WINDOW_DISPLAY:
+                       Dialogs.TypesDialog(self.get_flow_graph().get_parent())
                ##################################################
                # Param Modifications
                ##################################################
@@ -297,10 +297,7 @@ class ActionHandler:
                elif state == Actions.FLOW_GRAPH_SCREEN_CAPTURE:
                        file_path = SaveImageFileDialog(self.get_page().get_file_path()).run()
                        if file_path is not None:
-                               pixmap = self.get_flow_graph().get_pixmap()
-                               width, height = pixmap.get_size()
-                               pixbuf = gtk.gdk.Pixbuf(gtk.gdk.COLORSPACE_RGB, 0, 8, width, height)
-                               pixbuf.get_from_drawable(pixmap, pixmap.get_colormap(), 0, 0, 0, 0, width, height)
+                               pixbuf = self.get_flow_graph().get_drawing_area().get_pixbuf()
                                pixbuf.save(file_path, IMAGE_FILE_EXTENSION[1:])
                ##################################################
                # Gen/Exec/Stop