Skip to content

Commit

Permalink
PortName: Rename to IP_PortName.
Browse files Browse the repository at this point in the history
Rename module accordingly.

Signed-off-by: Chris PeBenito <pebenito@ieee.org>
  • Loading branch information
pebenito committed Nov 13, 2023
1 parent cdac5ac commit f10dc12
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 10 deletions.
2 changes: 1 addition & 1 deletion setoolsgui/widgets/criteria/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,12 +7,12 @@
from .context import *
from .infiniband import *
from .ipnetwork import *
from .ipports import *
from .mlslevelrange import *
from .mlsruletype import *
from .name import *
from .objclass import *
from .permission import *
from .ports import *
from .radioenum import *
from .rbacruletype import *
from .role import *
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,10 +10,10 @@

VALIDATION = r"[0-9]+(-[0-9]+)?"

__all__ = ("PortName",)
__all__ = ("IP_PortName",)


class PortName(RangedCriteriaWidget):
class IP_PortName(RangedCriteriaWidget):

"""
Widget providing a QLineEdit that saves the input to the attributes
Expand Down Expand Up @@ -82,7 +82,7 @@ def set_criteria(self) -> None:

app = QtWidgets.QApplication(sys.argv)
mw = QtWidgets.QMainWindow()
widget = PortName("Test Range", q, "default", enable_range_opts=True, parent=mw)
widget = IP_PortName("Test Range", q, "default", enable_range_opts=True, parent=mw)
widget.setToolTip("test tooltip")
widget.setWhatsThis("test whats this")
mw.setCentralWidget(widget)
Expand Down
12 changes: 6 additions & 6 deletions setoolsgui/widgets/portconquery.py
Original file line number Diff line number Diff line change
Expand Up @@ -26,12 +26,12 @@ def __init__(self, policy: setools.SELinuxPolicy, _, /, *,
#
# Set up criteria widgets
#
ports = criteria.PortName("Port/Port Range",
self.query,
"ports",
convert_range=True,
enable_range_opts=True,
parent=self.criteria_frame)
ports = criteria.IP_PortName("Port/Port Range",
self.query,
"ports",
convert_range=True,
enable_range_opts=True,
parent=self.criteria_frame)
ports.setToolTip("The port number or port number range for portcon matching.")
ports.setWhatsThis(
"""
Expand Down

0 comments on commit f10dc12

Please sign in to comment.