Feature: Häkchen im Menü 'Vorhandene Projekte' für geladenes Projekt
This commit is contained in:
@@ -233,8 +233,13 @@ class MainWindow(
|
||||
# Füge jedes gültige Projekt als Menü-Eintrag hinzu
|
||||
for project in valid_projects:
|
||||
project_action = QAction(project.name, self)
|
||||
project_action.setCheckable(True)
|
||||
project_action.setToolTip(f"Projekt-Ordner: {project.project_dir}")
|
||||
|
||||
# Markiere das aktuell geladene Projekt
|
||||
if hasattr(self, "project") and self.project and self.project.id == project.id:
|
||||
project_action.setChecked(True)
|
||||
|
||||
# Verbinde die Aktion mit der Projekt-Öffnen-Funktion
|
||||
project_action.triggered.connect(lambda checked, proj=project: self.open_existing_project(proj))
|
||||
|
||||
@@ -297,6 +302,9 @@ class MainWindow(
|
||||
self.ui.menuAktion.setEnabled(True)
|
||||
logger.info("Aktions-Menü aktiviert nach Projekt-Laden")
|
||||
|
||||
# Aktualisiere das Projekte-Menü um das Häkchen beim geladenen Projekt anzuzeigen
|
||||
self._setup_projects_menu()
|
||||
|
||||
except Exception as e:
|
||||
logger.error(f"Fehler beim Laden des Projekts '{project.name}': {e}")
|
||||
# Fallback: Erstelle Standard-Einstellungen
|
||||
|
||||
Reference in New Issue
Block a user