Fixed size bug
This commit is contained in:
parent
294a7201be
commit
349bdad1a1
3 changed files with 14 additions and 7 deletions
|
@ -3,7 +3,7 @@ import os
|
||||||
from PyQt5.QtCore import Qt, pyqtSignal
|
from PyQt5.QtCore import Qt, pyqtSignal
|
||||||
from PyQt5.QtGui import QPixmap, QKeyEvent
|
from PyQt5.QtGui import QPixmap, QKeyEvent
|
||||||
from PyQt5.QtWidgets import QWidget, QPushButton, QVBoxLayout, QLabel, QHBoxLayout, QTabWidget, QMessageBox, \
|
from PyQt5.QtWidgets import QWidget, QPushButton, QVBoxLayout, QLabel, QHBoxLayout, QTabWidget, QMessageBox, \
|
||||||
QProgressBar, QStackedWidget, QGroupBox
|
QProgressBar, QStackedWidget, QGroupBox, QScrollArea
|
||||||
from qtawesome import icon
|
from qtawesome import icon
|
||||||
|
|
||||||
from rare.components.dialogs.uninstall_dialog import UninstallDialog
|
from rare.components.dialogs.uninstall_dialog import UninstallDialog
|
||||||
|
@ -42,7 +42,7 @@ class InfoTabs(QTabWidget):
|
||||||
self.parent().layout.setCurrentIndex(0)
|
self.parent().layout.setCurrentIndex(0)
|
||||||
|
|
||||||
|
|
||||||
class GameInfo(QWidget):
|
class GameInfo(QScrollArea):
|
||||||
igame: InstalledGame
|
igame: InstalledGame
|
||||||
game: Game
|
game: Game
|
||||||
update_list = pyqtSignal()
|
update_list = pyqtSignal()
|
||||||
|
@ -51,8 +51,10 @@ class GameInfo(QWidget):
|
||||||
|
|
||||||
def __init__(self, core: LegendaryCore):
|
def __init__(self, core: LegendaryCore):
|
||||||
super(GameInfo, self).__init__()
|
super(GameInfo, self).__init__()
|
||||||
|
self.widget = QWidget()
|
||||||
self.core = core
|
self.core = core
|
||||||
self.layout = QVBoxLayout()
|
self.layout = QVBoxLayout()
|
||||||
|
self.setWidgetResizable(True)
|
||||||
|
|
||||||
# TODO More Information: Image text settings needs_verification platform
|
# TODO More Information: Image text settings needs_verification platform
|
||||||
top_layout = QHBoxLayout()
|
top_layout = QHBoxLayout()
|
||||||
|
@ -86,7 +88,6 @@ class GameInfo(QWidget):
|
||||||
|
|
||||||
top_layout.addLayout(right_layout)
|
top_layout.addLayout(right_layout)
|
||||||
top_layout.addStretch()
|
top_layout.addStretch()
|
||||||
|
|
||||||
self.game_actions = GameActions()
|
self.game_actions = GameActions()
|
||||||
|
|
||||||
self.game_actions.uninstall_button.clicked.connect(self.uninstall)
|
self.game_actions.uninstall_button.clicked.connect(self.uninstall)
|
||||||
|
@ -96,7 +97,8 @@ class GameInfo(QWidget):
|
||||||
self.layout.addLayout(top_layout)
|
self.layout.addLayout(top_layout)
|
||||||
self.layout.addWidget(self.game_actions)
|
self.layout.addWidget(self.game_actions)
|
||||||
self.layout.addStretch()
|
self.layout.addStretch()
|
||||||
self.setLayout(self.layout)
|
self.widget.setLayout(self.layout)
|
||||||
|
self.setWidget(self.widget)
|
||||||
|
|
||||||
def uninstall(self):
|
def uninstall(self):
|
||||||
infos = UninstallDialog(self.game).get_information()
|
infos = UninstallDialog(self.game).get_information()
|
||||||
|
|
|
@ -1,6 +1,7 @@
|
||||||
import os
|
import os
|
||||||
|
|
||||||
from PyQt5.QtWidgets import QWidget, QLabel, QVBoxLayout, QComboBox, QFileDialog, QPushButton, QMessageBox, QLineEdit
|
from PyQt5.QtWidgets import QWidget, QLabel, QVBoxLayout, QComboBox, QFileDialog, QPushButton, QMessageBox, QLineEdit, \
|
||||||
|
QScrollArea
|
||||||
|
|
||||||
from rare.components.tabs.settings.linux import LinuxSettings
|
from rare.components.tabs.settings.linux import LinuxSettings
|
||||||
from rare.components.tabs.settings.settings_widget import SettingsWidget
|
from rare.components.tabs.settings.settings_widget import SettingsWidget
|
||||||
|
@ -9,7 +10,7 @@ from custom_legendary.core import LegendaryCore
|
||||||
from custom_legendary.models.game import InstalledGame, Game
|
from custom_legendary.models.game import InstalledGame, Game
|
||||||
|
|
||||||
|
|
||||||
class GameSettings(QWidget):
|
class GameSettings(QScrollArea):
|
||||||
game: Game
|
game: Game
|
||||||
igame: InstalledGame
|
igame: InstalledGame
|
||||||
# variable to no update when changing game
|
# variable to no update when changing game
|
||||||
|
@ -18,6 +19,8 @@ class GameSettings(QWidget):
|
||||||
def __init__(self, core: LegendaryCore):
|
def __init__(self, core: LegendaryCore):
|
||||||
super(GameSettings, self).__init__()
|
super(GameSettings, self).__init__()
|
||||||
self.core = core
|
self.core = core
|
||||||
|
self.widget = QWidget()
|
||||||
|
self.setWidgetResizable(True)
|
||||||
self.layout = QVBoxLayout()
|
self.layout = QVBoxLayout()
|
||||||
self.title = QLabel("Error")
|
self.title = QLabel("Error")
|
||||||
self.layout.addWidget(self.title)
|
self.layout.addWidget(self.title)
|
||||||
|
@ -71,7 +74,8 @@ class GameSettings(QWidget):
|
||||||
# startparams, skip_update_check
|
# startparams, skip_update_check
|
||||||
|
|
||||||
self.layout.addStretch(1)
|
self.layout.addStretch(1)
|
||||||
self.setLayout(self.layout)
|
self.widget.setLayout(self.layout)
|
||||||
|
self.setWidget(self.widget)
|
||||||
|
|
||||||
def update_wrapper(self):
|
def update_wrapper(self):
|
||||||
wrapper = self.wrapper.text()
|
wrapper = self.wrapper.text()
|
||||||
|
|
|
@ -44,6 +44,7 @@ class ImportWidget(QWidget):
|
||||||
self.gb_layout.addWidget(self.import_game_info)
|
self.gb_layout.addWidget(self.import_game_info)
|
||||||
|
|
||||||
self.override_app_name_label = QLabel(self.tr("Override app name (Only if imported game from legendary or the app could not find the app name)"))
|
self.override_app_name_label = QLabel(self.tr("Override app name (Only if imported game from legendary or the app could not find the app name)"))
|
||||||
|
self.override_app_name_label.setWordWrap(True)
|
||||||
self.app_name_input = QLineEdit()
|
self.app_name_input = QLineEdit()
|
||||||
self.app_name_input.setFixedHeight(32)
|
self.app_name_input.setFixedHeight(32)
|
||||||
minilayout = QHBoxLayout()
|
minilayout = QHBoxLayout()
|
||||||
|
|
Loading…
Reference in a new issue