Skip to content

Commit 88cd305

Browse files
committed
Release v2.2.0: New Footer UI & Translations
1 parent 0b2979e commit 88cd305

File tree

10 files changed

+181
-207
lines changed

10 files changed

+181
-207
lines changed

src/core/config_manager.py

Lines changed: 0 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -176,30 +176,5 @@ def set_muted(self, muted: bool):
176176
def is_muted(self) -> bool:
177177
return not self.config.get("sound_enabled", True)
178178

179-
# --- Stream/OBS Integration ---
180-
def get_obs_integration_enabled(self) -> bool:
181-
return self.config.get("obs_integration_enabled", True)
182179

183-
def set_obs_integration_enabled(self, enabled: bool):
184-
self.config["obs_integration_enabled"] = enabled
185-
self.save_config()
186-
187-
def get_stream_output_path(self) -> str:
188-
"""Returns the path where stream info (txt/images) will be written."""
189-
# Default to a folder named "StreamKit" in the Documents/BioMetrics or similar
190-
# For simplicity, let's use a subdirectory of the main config dir or a specific Documents folder
191-
# The user PROBABLY wants this accessible.
192-
# Let's use: User Documents/BioMetrics/StreamKit
193-
# If not set in config, return default.
194-
custom = self.config.get("stream_output_path")
195-
if custom:
196-
return custom
197-
198-
docs = QStandardPaths.writableLocation(QStandardPaths.DocumentsLocation)
199-
# Assuming app name used elsewhere is "BioMetrics" implicitly or checking if we can use a standard folder
200-
return os.path.join(docs, "BioMetrics", "StreamKit")
201-
202-
def set_stream_output_path(self, path: str):
203-
self.config["stream_output_path"] = path
204-
self.save_config()
205180

src/core/downloader.py

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -15,9 +15,7 @@ class Downloader:
1515

1616
def __init__(self, config_manager: ConfigManager):
1717
self.config_manager = config_manager
18-
from src.core.stream_integration import StreamIntegration
1918
from src.core.backup_manager import BackupManager
20-
self.stream_integration = StreamIntegration(config_manager)
2119
self.backup_manager = BackupManager(config_manager)
2220

2321
def install_character(self, character: Character) -> bool:
@@ -42,8 +40,6 @@ def install_character(self, character: Character) -> bool:
4240
character.status = "installed"
4341
character.local_filename = existing_filename
4442

45-
# Update Stream Info
46-
self.stream_integration.update_stream_info(character)
4743
return True
4844

4945
try:
@@ -85,8 +81,7 @@ def install_character(self, character: Character) -> bool:
8581
character.local_filename = os.path.basename(final_path) # Store exact filename
8682
logger.info(f"Successfully installed {character.name}")
8783

88-
# Update Stream Info
89-
self.stream_integration.update_stream_info(character)
84+
9085

9186
return True
9287
else:

src/core/stream_integration.py

Lines changed: 0 additions & 85 deletions
This file was deleted.

src/ui/components/footer_bar.py

Lines changed: 68 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,68 @@
1+
from PySide6.QtWidgets import QFrame, QHBoxLayout, QLabel, QPushButton, QVBoxLayout, QWidget, QGraphicsDropShadowEffect
2+
from PySide6.QtCore import Signal, Qt
3+
from PySide6.QtGui import QColor, QCursor
4+
5+
class FooterBar(QFrame):
6+
launch_clicked = Signal()
7+
8+
def __init__(self, parent=None):
9+
super().__init__(parent)
10+
self.setObjectName("FooterBar")
11+
self.setup_ui()
12+
13+
def setup_ui(self):
14+
layout = QHBoxLayout(self)
15+
layout.setContentsMargins(20, 10, 20, 15) # Bottom padding for visual breathing room
16+
layout.setSpacing(15)
17+
18+
# --- Left: Status Area ---
19+
self.status_container = QWidget()
20+
status_layout = QVBoxLayout(self.status_container)
21+
status_layout.setContentsMargins(0, 0, 0, 0)
22+
status_layout.setSpacing(2)
23+
24+
self.status_label = QLabel("Ready")
25+
self.status_label.setObjectName("FooterStatusLabel")
26+
27+
self.sub_status_label = QLabel("BioMetrics Systems Online")
28+
self.sub_status_label.setObjectName("FooterSubStatusLabel")
29+
30+
status_layout.addWidget(self.status_label)
31+
status_layout.addWidget(self.sub_status_label)
32+
33+
layout.addWidget(self.status_container)
34+
35+
# Spacer
36+
layout.addStretch()
37+
38+
# --- Right: Launch Module ---
39+
40+
# Version Label (Small, next to button)
41+
self.version_label = QLabel("LIVE 3.24.X")
42+
self.version_label.setObjectName("FooterVersionLabel")
43+
self.version_label.setAlignment(Qt.AlignRight | Qt.AlignVCenter)
44+
layout.addWidget(self.version_label)
45+
46+
# THE BIG BUTTON
47+
self.launch_btn = QPushButton("LAUNCH GAME")
48+
self.launch_btn.setObjectName("FooterLaunchButton")
49+
self.launch_btn.setCursor(QCursor(Qt.PointingHandCursor))
50+
self.launch_btn.clicked.connect(self.launch_clicked.emit)
51+
52+
# Add Shadow to Button
53+
shadow = QGraphicsDropShadowEffect(self)
54+
shadow.setBlurRadius(20)
55+
shadow.setColor(QColor(0, 255, 100, 80)) # Green Glow
56+
shadow.setOffset(0, 0)
57+
self.launch_btn.setGraphicsEffect(shadow)
58+
59+
layout.addWidget(self.launch_btn)
60+
61+
def set_status(self, text):
62+
self.status_label.setText(text)
63+
64+
def set_version_text(self, text):
65+
self.version_label.setText(text)
66+
67+
def set_launch_text(self, text):
68+
self.launch_btn.setText(text)

src/ui/dialogs/settings_dialog.py

Lines changed: 2 additions & 43 deletions
Original file line numberDiff line numberDiff line change
@@ -97,39 +97,7 @@ def setup_ui(self):
9797
ptu_layout.addLayout(ptu_input_layout)
9898
layout.addLayout(ptu_layout)
9999

100-
# --- Stream Integration Section ---
101-
stream_group = QFrame()
102-
stream_group.setFrameShape(QFrame.StyledPanel)
103-
stream_layout = QVBoxLayout(stream_group)
104-
105-
self.chk_stream_enabled = QCheckBox("Enable Stream Integration (OBS Kit)")
106-
self.chk_stream_enabled.setChecked(self.config_manager.get_obs_integration_enabled())
107-
self.chk_stream_enabled.stateChanged.connect(self.toggle_stream_path)
108-
stream_layout.addWidget(self.chk_stream_enabled)
109-
110-
self.stream_path_container = QWidget()
111-
self.stream_path_layout = QVBoxLayout(self.stream_path_container)
112-
self.stream_path_layout.setContentsMargins(0, 5, 0, 0)
113-
114-
lbl_stream = QLabel("Output Folder for Overlays (.txt/.jpg):")
115-
self.stream_path_layout.addWidget(lbl_stream)
116-
117-
stream_input_box = QHBoxLayout()
118-
self.stream_path_input = QLineEdit()
119-
self.stream_path_input.setText(self.config_manager.get_stream_output_path())
120-
setup_localized_context_menu(self.stream_path_input)
121-
122-
btn_browse_stream = QPushButton(self.tr("browse"))
123-
btn_browse_stream.clicked.connect(self.browse_stream_path)
124-
125-
stream_input_box.addWidget(self.stream_path_input)
126-
stream_input_box.addWidget(btn_browse_stream)
127-
128-
self.stream_path_layout.addLayout(stream_input_box)
129-
stream_layout.addWidget(self.stream_path_container)
130-
131-
layout.addWidget(stream_group)
132-
self.toggle_stream_path(self.chk_stream_enabled.checkState())
100+
133101

134102
# --- Automation Section ---
135103
auto_group = QFrame()
@@ -202,14 +170,7 @@ def browse_ptu_path(self):
202170
if path:
203171
self.ptu_input.setText(path)
204172

205-
def browse_stream_path(self):
206-
current = self.stream_path_input.text()
207-
path = QFileDialog.getExistingDirectory(self, "Select Stream Output Folder", current)
208-
if path:
209-
self.stream_path_input.setText(path)
210173

211-
def toggle_stream_path(self, state):
212-
self.stream_path_container.setVisible(bool(state))
213174

214175
def toggle_cloud_path(self, state):
215176
self.cloud_path_container.setVisible(bool(state))
@@ -240,9 +201,7 @@ def save_settings(self):
240201
# Update via manager (also saves)
241202
self.theme_manager.set_theme_mode(selected_theme)
242203

243-
# Save Stream Settings
244-
self.config_manager.set_obs_integration_enabled(self.chk_stream_enabled.isChecked())
245-
self.config_manager.set_stream_output_path(self.stream_path_input.text())
204+
246205

247206
# Save Automation Settings
248207
self.config_manager.config["auto_backup_enabled"] = self.chk_auto_backup.isChecked()

0 commit comments

Comments
 (0)