diff --git a/daemon/core/gui/dialogs/canvaswallpaper.py b/daemon/core/gui/dialogs/canvaswallpaper.py index f3635377..62fa8fe5 100644 --- a/daemon/core/gui/dialogs/canvaswallpaper.py +++ b/daemon/core/gui/dialogs/canvaswallpaper.py @@ -12,7 +12,7 @@ from core.gui.themes import PADX, PADY from core.gui.widgets import image_chooser -class CanvasBackgroundDialog(Dialog): +class CanvasWallpaperDialog(Dialog): def __init__(self, master, app): """ create an instance of CanvasWallpaper object diff --git a/daemon/core/gui/dialogs/colorpicker.py b/daemon/core/gui/dialogs/colorpicker.py index b94ae635..28d21f42 100644 --- a/daemon/core/gui/dialogs/colorpicker.py +++ b/daemon/core/gui/dialogs/colorpicker.py @@ -8,7 +8,7 @@ from tkinter import ttk from core.gui.dialogs.dialog import Dialog -class ColorPicker(Dialog): +class ColorPickerDialog(Dialog): def __init__(self, master, app, initcolor="#000000"): super().__init__(master, app, "color picker", modal=True) self.red_entry = None diff --git a/daemon/core/gui/dialogs/linkconfig.py b/daemon/core/gui/dialogs/linkconfig.py index b59307d6..9fd9130b 100644 --- a/daemon/core/gui/dialogs/linkconfig.py +++ b/daemon/core/gui/dialogs/linkconfig.py @@ -6,7 +6,7 @@ import tkinter as tk from tkinter import ttk from core.api.grpc import core_pb2 -from core.gui.dialogs.colorpicker import ColorPicker +from core.gui.dialogs.colorpicker import ColorPickerDialog from core.gui.dialogs.dialog import Dialog from core.gui.themes import PADX, PADY @@ -27,7 +27,7 @@ def get_float(var): return None -class LinkConfiguration(Dialog): +class LinkConfigurationDialog(Dialog): def __init__(self, master, app, edge): super().__init__(master, app, "Link Configuration", modal=True) self.app = app @@ -237,7 +237,7 @@ class LinkConfiguration(Dialog): return frame def click_color(self): - dialog = ColorPicker(self, self.app, self.color.get()) + dialog = ColorPickerDialog(self, self.app, self.color.get()) color = dialog.askcolor() self.color.set(color) self.color_button.config(background=color) diff --git a/daemon/core/gui/dialogs/marker.py b/daemon/core/gui/dialogs/marker.py index 3a078d86..dc0c3bc4 100644 --- a/daemon/core/gui/dialogs/marker.py +++ b/daemon/core/gui/dialogs/marker.py @@ -6,13 +6,13 @@ import logging import tkinter as tk from tkinter import ttk -from core.gui.dialogs.colorpicker import ColorPicker +from core.gui.dialogs.colorpicker import ColorPickerDialog from core.gui.dialogs.dialog import Dialog MARKER_THICKNESS = [3, 5, 8, 10] -class Marker(Dialog): +class MarkerDialog(Dialog): def __init__(self, master, app, initcolor="#000000"): super().__init__(master, app, "marker tool", modal=False) self.app = app @@ -56,7 +56,7 @@ class Marker(Dialog): canvas.delete(i) def change_color(self, event): - color_picker = ColorPicker(self, self.app, self.color) + color_picker = ColorPickerDialog(self, self.app, self.color) color = color_picker.askcolor() event.widget.configure(background=color) self.color = color diff --git a/daemon/core/gui/dialogs/nodeservice.py b/daemon/core/gui/dialogs/nodeservice.py index 730a5ff9..2bbe0589 100644 --- a/daemon/core/gui/dialogs/nodeservice.py +++ b/daemon/core/gui/dialogs/nodeservice.py @@ -5,12 +5,12 @@ import tkinter as tk from tkinter import messagebox, ttk from core.gui.dialogs.dialog import Dialog -from core.gui.dialogs.serviceconfiguration import ServiceConfiguration +from core.gui.dialogs.serviceconfig import ServiceConfigDialog from core.gui.themes import FRAME_PAD, PADX, PADY from core.gui.widgets import CheckboxList, ListboxScroll -class NodeService(Dialog): +class NodeServiceDialog(Dialog): def __init__(self, master, app, canvas_node, services=None): title = f"{canvas_node.core_node.name} Services" super().__init__(master, app, title, modal=True) @@ -106,7 +106,7 @@ class NodeService(Dialog): def click_configure(self): current_selection = self.current.listbox.curselection() if len(current_selection): - dialog = ServiceConfiguration( + dialog = ServiceConfigDialog( master=self, app=self.app, service_name=self.current.listbox.get(current_selection[0]), diff --git a/daemon/core/gui/dialogs/serviceconfiguration.py b/daemon/core/gui/dialogs/serviceconfig.py similarity index 99% rename from daemon/core/gui/dialogs/serviceconfiguration.py rename to daemon/core/gui/dialogs/serviceconfig.py index f0d5b19b..fd4f8c26 100644 --- a/daemon/core/gui/dialogs/serviceconfiguration.py +++ b/daemon/core/gui/dialogs/serviceconfig.py @@ -13,7 +13,7 @@ from core.gui.themes import FRAME_PAD, PADX, PADY from core.gui.widgets import CodeText, ListboxScroll -class ServiceConfiguration(Dialog): +class ServiceConfigDialog(Dialog): def __init__(self, master, app, service_name, node_id): title = f"{service_name} Service" super().__init__(master, app, title, modal=True) diff --git a/daemon/core/gui/dialogs/shapemod.py b/daemon/core/gui/dialogs/shapemod.py index f77b45a8..8dc56f43 100644 --- a/daemon/core/gui/dialogs/shapemod.py +++ b/daemon/core/gui/dialogs/shapemod.py @@ -4,7 +4,7 @@ shape input dialog import tkinter as tk from tkinter import font, ttk -from core.gui.dialogs.colorpicker import ColorPicker +from core.gui.dialogs.colorpicker import ColorPickerDialog from core.gui.dialogs.dialog import Dialog from core.gui.graph import tags from core.gui.graph.shapeutils import is_draw_shape, is_shape_text @@ -135,18 +135,18 @@ class ShapeDialog(Dialog): button.grid(row=0, column=1, sticky="ew") def choose_text_color(self): - color_picker = ColorPicker(self, self.app, "#000000") + color_picker = ColorPickerDialog(self, self.app, "#000000") color = color_picker.askcolor() self.text_color = color def choose_fill_color(self): - color_picker = ColorPicker(self, self.app, self.fill_color) + color_picker = ColorPickerDialog(self, self.app, self.fill_color) color = color_picker.askcolor() self.fill_color = color self.fill.config(background=color, text=color) def choose_border_color(self): - color_picker = ColorPicker(self, self.app, self.border_color) + color_picker = ColorPickerDialog(self, self.app, self.border_color) color = color_picker.askcolor() self.border_color = color self.border.config(background=color, text=color) diff --git a/daemon/core/gui/graph/edges.py b/daemon/core/gui/graph/edges.py index b80c106c..ebcda49e 100644 --- a/daemon/core/gui/graph/edges.py +++ b/daemon/core/gui/graph/edges.py @@ -3,7 +3,7 @@ import tkinter as tk from tkinter.font import Font from core.gui import themes -from core.gui.dialogs.linkconfig import LinkConfiguration +from core.gui.dialogs.linkconfig import LinkConfigurationDialog from core.gui.graph import tags from core.gui.nodeutils import NodeUtils @@ -177,5 +177,5 @@ class CanvasEdge: def configure(self): logging.debug("link configuration") - dialog = LinkConfiguration(self.canvas, self.canvas.app, self) + dialog = LinkConfigurationDialog(self.canvas, self.canvas.app, self) dialog.show() diff --git a/daemon/core/gui/graph/node.py b/daemon/core/gui/graph/node.py index 68405a37..b348fe15 100644 --- a/daemon/core/gui/graph/node.py +++ b/daemon/core/gui/graph/node.py @@ -9,7 +9,7 @@ from core.gui import themes from core.gui.dialogs.emaneconfig import EmaneConfigDialog from core.gui.dialogs.mobilityconfig import MobilityConfigDialog from core.gui.dialogs.nodeconfig import NodeConfigDialog -from core.gui.dialogs.nodeservice import NodeService +from core.gui.dialogs.nodeservice import NodeServiceDialog from core.gui.dialogs.wlanconfig import WlanConfigDialog from core.gui.errors import show_grpc_error from core.gui.graph import tags @@ -243,7 +243,7 @@ class CanvasNode: def show_services(self): self.canvas.context = None - dialog = NodeService(self.app.master, self.app, self) + dialog = NodeServiceDialog(self.app.master, self.app, self) dialog.show() def has_emane_link(self, interface_id): diff --git a/daemon/core/gui/menuaction.py b/daemon/core/gui/menuaction.py index 4c310cd7..be532218 100644 --- a/daemon/core/gui/menuaction.py +++ b/daemon/core/gui/menuaction.py @@ -13,7 +13,7 @@ import grpc from core.gui.appconfig import XMLS_PATH from core.gui.dialogs.about import AboutDialog from core.gui.dialogs.canvassizeandscale import SizeAndScaleDialog -from core.gui.dialogs.canvaswallpaper import CanvasBackgroundDialog +from core.gui.dialogs.canvaswallpaper import CanvasWallpaperDialog from core.gui.dialogs.hooks import HooksDialog from core.gui.dialogs.observers import ObserverDialog from core.gui.dialogs.preferences import PreferencesDialog @@ -113,7 +113,7 @@ class MenuAction: dialog.show() def canvas_set_wallpaper(self): - dialog = CanvasBackgroundDialog(self.app, self.app) + dialog = CanvasWallpaperDialog(self.app, self.app) dialog.show() def help_core_github(self): diff --git a/daemon/core/gui/toolbar.py b/daemon/core/gui/toolbar.py index 2d0dad94..7c1db24c 100644 --- a/daemon/core/gui/toolbar.py +++ b/daemon/core/gui/toolbar.py @@ -6,7 +6,7 @@ from tkinter import ttk from tkinter.font import Font from core.gui.dialogs.customnodes import CustomNodesDialog -from core.gui.dialogs.marker import Marker +from core.gui.dialogs.marker import MarkerDialog from core.gui.graph import tags from core.gui.graph.enums import GraphMode from core.gui.graph.shapeutils import ShapeType, is_marker @@ -407,7 +407,7 @@ class Toolbar(ttk.Frame): self.app.canvas.annotation_type = shape_type if is_marker(shape_type): if not self.marker_tool: - self.marker_tool = Marker(self.master, self.app) + self.marker_tool = MarkerDialog(self.master, self.app) self.marker_tool.show() def click_run_button(self): @@ -418,7 +418,7 @@ class Toolbar(ttk.Frame): def click_marker_button(self): logging.debug("Click on marker button") - dialog = Marker(self.master, self.app) + dialog = MarkerDialog(self.master, self.app) dialog.show() # dialog.position()