-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
2762d6b
commit 6d2b452
Showing
3 changed files
with
22 additions
and
5 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,11 +1,16 @@ | ||
from PyQt6.QtWidgets import QToolBar | ||
from typing import TYPE_CHECKING | ||
|
||
if TYPE_CHECKING: | ||
from ...laserstudio import LaserStudio | ||
|
||
class LaserToolbar(QToolBar): | ||
def __init__(self, title: str, laser_model: str, laser_num: int): | ||
def __init__(self, title: str, laser_studio: "LaserStudio", laser_num: int): | ||
""" | ||
:param laser_model: Equipment model, such as "pdm". Used for settings save and restore. | ||
:param laser_studio: Main windows of laserstudio. Can be used for interacting with | ||
other elements of the UI. | ||
:param laser_num: Laser equipment index. | ||
""" | ||
super().__init__(title) | ||
super().setObjectName(f"toolbox-laser-{laser_model}-{laser_num}") # For settings save and restore | ||
self.laser_studio = laser_studio | ||
super().setObjectName(f"toolbox-laser-{laser_num}") # For settings save and restore |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters