Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions config.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,8 @@
import requests
import wx # required for colour codes in DARK_MODE

import re # for wxPython version dentification

import optstore
# cSpell Checker - Correct Words****************************************
# // cSpell:words MEIPASS, datefmt, russsian, pyinstaller, posix, pyspy
Expand All @@ -34,6 +36,9 @@ def resource_path(relative_path):

return os.path.join(base_path, relative_path)

# Identify wxPython version (not wxWidgets version).
wx_major, wx_minor, wx_rev = \
map(int, re.match(r"([0-9]+)\.([0-9]+)(?:\.([0-9]+))", wx.__version__).groups())

# If application is frozen executable
if getattr(sys, 'frozen', False):
Expand Down
13 changes: 10 additions & 3 deletions gui.py
Original file line number Diff line number Diff line change
Expand Up @@ -356,8 +356,12 @@ def __do_layout(self):
sizer_bottom.Add(self.status_label, 1, wx.ALIGN_CENTER_VERTICAL, 0)
static_line = wx.StaticLine(self, wx.ID_ANY, style=wx.LI_VERTICAL)
sizer_bottom.Add(static_line, 0, wx.EXPAND, 0)
sizer_bottom.Add(self.alpha_slider, 0, wx.ALIGN_RIGHT, 0)
sizer_main.Add(sizer_bottom, 0, wx.ALIGN_BOTTOM | wx.ALL | wx.EXPAND, 1)
if config.wx_minor < 1:
sizer_bottom.Add(self.alpha_slider, 0, wx.ALIGN_RIGHT, 0)
sizer_main.Add(sizer_bottom, 0, wx.ALIGN_BOTTOM | wx.ALL | wx.EXPAND, 1)
else:
sizer_bottom.Add(self.alpha_slider)
sizer_main.Add(sizer_bottom, 0, wx.ALL | wx.EXPAND, 1)
self.SetSizer(sizer_main)
self.Layout()
self._restoreColWidth()
Expand Down Expand Up @@ -640,7 +644,10 @@ def updateList(self, outlist, duration=None):
for value in out:
color = False
self.grid.SetCellValue(rowidx, colidx, str(value))
self.grid.SetCellAlignment(self.columns[colidx][2], rowidx, colidx)
if config.wx_minor < 1:
self.grid.SetCellAlignment(self.columns[colidx][2], rowidx, colidx)
else:
self.grid.SetCellAlignment(rowidx, colidx, self.columns[colidx][2], wx.ALIGN_CENTER)
if hl_blops and r[9] is not None and r[11] > 0: # Highlight BLOPS chars
self.grid.SetCellTextColour(rowidx, colidx, self.hl1_colour)
color = True
Expand Down
5 changes: 4 additions & 1 deletion highlightdialog.py
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,10 @@ def __do_layout(self):
buttonSizer.Add(self.appBtn, 1, wx.RIGHT, 5)
buttonSizer.Add(self.cnclBtn, 1, wx.LEFT, 5)
self.buttonPanel.SetSizer(buttonSizer)
main.Add(self.buttonPanel, 0, wx.ALIGN_BOTTOM | wx.BOTTOM | wx.EXPAND | wx.LEFT | wx.RIGHT, 10)
if config.wx_minor < 1:
main.Add(self.buttonPanel, 0, wx.ALIGN_BOTTOM | wx.BOTTOM | wx.EXPAND | wx.LEFT | wx.RIGHT, 10)
else:
main.Add(self.buttonPanel, 0, wx.BOTTOM | wx.EXPAND | wx.LEFT | wx.RIGHT, 10)
self.SetSizer(main)
self.Layout()
self.Centre()
Expand Down
5 changes: 4 additions & 1 deletion ignoredialog.py
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,10 @@ def __do_layout(self):
buttonSizer.Add(self.appBtn, 1, wx.RIGHT, 5)
buttonSizer.Add(self.cnclBtn, 1, wx.LEFT, 5)
self.buttonPanel.SetSizer(buttonSizer)
main.Add(self.buttonPanel, 0, wx.ALIGN_BOTTOM | wx.BOTTOM | wx.EXPAND | wx.LEFT | wx.RIGHT, 10)
if config.wx_minor < 1:
main.Add(self.buttonPanel, 0, wx.ALIGN_BOTTOM | wx.BOTTOM | wx.EXPAND | wx.LEFT | wx.RIGHT, 10)
else:
main.Add(self.buttonPanel, 0, wx.BOTTOM | wx.EXPAND | wx.LEFT | wx.RIGHT, 10)
self.SetSizer(main)
self.Layout()
self.Centre()
Expand Down