mirror of
https://github.com/Omni-guides/Jackify.git
synced 2026-06-08 03:37:44 +02:00
Sync from development - prepare for v0.4.0
This commit is contained in:
@@ -28,7 +28,7 @@ class NextStepsDialog(QDialog):
|
||||
Displays the same information as the CLI completion message but in a proper GUI format.
|
||||
"""
|
||||
|
||||
def __init__(self, modlist_name: str, parent=None):
|
||||
def __init__(self, modlist_name: str, workflow_type: str = "configure_new", parent=None):
|
||||
"""
|
||||
Initialize the Next Steps dialog.
|
||||
|
||||
@@ -38,6 +38,7 @@ class NextStepsDialog(QDialog):
|
||||
"""
|
||||
super().__init__(parent)
|
||||
self.modlist_name = modlist_name
|
||||
self.workflow_type = workflow_type
|
||||
self.setWindowTitle("Next Steps")
|
||||
self.setModal(True)
|
||||
self.setFixedSize(600, 400)
|
||||
@@ -189,10 +190,13 @@ class NextStepsDialog(QDialog):
|
||||
Returns:
|
||||
Formatted completion text string
|
||||
"""
|
||||
# Match the CLI completion text from menu_handler.py lines 627-631
|
||||
is_existing = self.workflow_type == "configure_existing"
|
||||
completion_title = "Modlist Configuration complete!" if is_existing else "Modlist Install and Configuration complete!"
|
||||
completion_log = "Configure_Existing_Modlist_workflow.log" if is_existing else "Configure_New_Modlist_workflow.log"
|
||||
|
||||
completion_text = f"""✓ Configuration completed successfully!
|
||||
|
||||
Modlist Install and Configuration complete!:
|
||||
{completion_title}
|
||||
|
||||
• You should now be able to Launch '{self.modlist_name}' through Steam.
|
||||
• Congratulations and enjoy the game!
|
||||
@@ -200,6 +204,6 @@ Modlist Install and Configuration complete!:
|
||||
NOTE: If you experience ENB issues, consider using GE-Proton 10-14 instead of
|
||||
Valve's Proton 10 (known ENB compatibility issues in Valve's Proton 10).
|
||||
|
||||
Detailed log available at: {get_jackify_logs_dir()}/Configure_New_Modlist_workflow.log"""
|
||||
Detailed log available at: {get_jackify_logs_dir()}/{completion_log}"""
|
||||
|
||||
return completion_text
|
||||
return completion_text
|
||||
|
||||
@@ -94,7 +94,7 @@ class SettingsDialog(SettingsDialogTabsMixin, SettingsDialogProtonMixin, QDialog
|
||||
def _pick_directory(self, line_edit):
|
||||
dir_path = QFileDialog.getExistingDirectory(self, "Select Directory", line_edit.text() or os.path.expanduser("~"))
|
||||
if dir_path:
|
||||
line_edit.setText(dir_path)
|
||||
line_edit.setText(os.path.realpath(dir_path))
|
||||
|
||||
def _show_help(self):
|
||||
MessageService.information(self, "Help", "Help/documentation coming soon!", safety_level="low")
|
||||
@@ -130,7 +130,17 @@ class SettingsDialog(SettingsDialogTabsMixin, SettingsDialogProtonMixin, QDialog
|
||||
auth_service = NexusAuthService()
|
||||
authenticated, method, username = auth_service.get_auth_status()
|
||||
if authenticated and method == 'oauth':
|
||||
self.oauth_status_label.setText(f"Authorised as {username}" if username else "Authorised")
|
||||
tier_label = ""
|
||||
try:
|
||||
token = auth_service.get_auth_token()
|
||||
if token:
|
||||
from jackify.backend.services.nexus_premium_service import NexusPremiumService
|
||||
is_premium, _ = NexusPremiumService().check_premium_status(token, is_oauth=True)
|
||||
tier_label = " [Premium]" if is_premium else " [Free]"
|
||||
except Exception:
|
||||
pass
|
||||
display = f"Authorised as {username}{tier_label}" if username else "Authorised"
|
||||
self.oauth_status_label.setText(display)
|
||||
self.oauth_status_label.setStyleSheet("color: #3fd0ea;")
|
||||
self.oauth_btn.setText("Revoke")
|
||||
elif method == 'oauth_expired':
|
||||
@@ -323,7 +333,7 @@ class SettingsDialog(SettingsDialogTabsMixin, SettingsDialogProtonMixin, QDialog
|
||||
# Check if debug mode changed and prompt for restart
|
||||
new_debug_mode = self.debug_checkbox.isChecked()
|
||||
if new_debug_mode != self._original_debug_mode:
|
||||
reply = MessageService.question(self, "Restart Required", "Debug mode change requires a restart. Restart Jackify now?", safety_level="low")
|
||||
reply = MessageService.question(self, "Restart Required", "Debug mode change requires a restart. Restart Jackify now?", safety_level="medium")
|
||||
if reply == QMessageBox.Yes:
|
||||
import os, sys
|
||||
# User requested restart - do it regardless of execution environment
|
||||
@@ -383,4 +393,3 @@ class SettingsDialog(SettingsDialogTabsMixin, SettingsDialogProtonMixin, QDialog
|
||||
label.setStyleSheet("font-weight: bold; color: #fff;")
|
||||
return label
|
||||
|
||||
|
||||
|
||||
@@ -15,7 +15,7 @@ class SettingsDialogProtonMixin:
|
||||
from jackify.backend.handlers.wine_utils import WineUtils
|
||||
available_protons = WineUtils.scan_valve_proton_versions()
|
||||
for proton in available_protons:
|
||||
if proton['version'].startswith('10.'):
|
||||
if proton['name'].startswith('Proton 10.'):
|
||||
return proton['path']
|
||||
return 'auto'
|
||||
except Exception:
|
||||
|
||||
Reference in New Issue
Block a user