Fix some issues
This commit is contained in:
parent
cc54474e75
commit
9048e4790e
2 changed files with 5 additions and 6 deletions
|
@ -89,11 +89,11 @@ class ShopGameInfo(QWidget, Ui_shop_info):
|
|||
self.game = ShopGame.from_json(game, self.data)
|
||||
self.title.setText(self.game.title)
|
||||
self.price.setFont(QFont())
|
||||
if self.game.price != "0":
|
||||
self.price.setText(self.game.price)
|
||||
else:
|
||||
print(type(self.game.price))
|
||||
if self.game.price == "0" or self.game.price == 0:
|
||||
self.price.setText(self.tr("Free"))
|
||||
|
||||
else:
|
||||
self.price.setText(self.game.price)
|
||||
if self.game.price != self.game.discount_price:
|
||||
font = QFont()
|
||||
font.setStrikeOut(True)
|
||||
|
@ -136,7 +136,6 @@ class ShopGameInfo(QWidget, Ui_shop_info):
|
|||
except KeyError:
|
||||
pass
|
||||
self.tags.setText(", ".join(self.game.tags))
|
||||
self.price.setText(self.game.price)
|
||||
|
||||
def add_wishlist_items(self, wishlist):
|
||||
wishlist = wishlist["data"]["Wishlist"]["wishlistItems"]["elements"]
|
||||
|
|
|
@ -44,7 +44,7 @@ class ShopWidget(QScrollArea, Ui_ShopWidget):
|
|||
self.free_widget.layout().addWidget(self.free_games_now)
|
||||
self.coming_free_games = QGroupBox(self.tr("Free Games next week"))
|
||||
self.coming_free_games.setLayout(QHBoxLayout())
|
||||
self.free_game_group_box.layout().addWidget(self.coming_free_games)
|
||||
self.free_widget.layout().addWidget(self.coming_free_games)
|
||||
self.free_stack.addWidget(WaitingSpinner())
|
||||
self.free_stack.setCurrentIndex(1)
|
||||
|
||||
|
|
Loading…
Reference in a new issue