Fix codacy issues
This commit is contained in:
@@ -78,7 +78,7 @@ class CopySelectDialog(wx.Dialog):
|
|||||||
bsizer = wx.BoxSizer(wx.VERTICAL)
|
bsizer = wx.BoxSizer(wx.VERTICAL)
|
||||||
self.options[formatId] = {}
|
self.options[formatId] = {}
|
||||||
|
|
||||||
for optId, optName, optDesc, optDefault in formatOptions:
|
for optId, optName, optDesc, _ in formatOptions:
|
||||||
checkbox = wx.CheckBox(self, -1, optName)
|
checkbox = wx.CheckBox(self, -1, optName)
|
||||||
self.options[formatId][optId] = checkbox
|
self.options[formatId][optId] = checkbox
|
||||||
if self.settings['options'].get(formatId, {}).get(optId, defaultFormatOptions.get(formatId, {}).get(optId)):
|
if self.settings['options'].get(formatId, {}).get(optId, defaultFormatOptions.get(formatId, {}).get(optId)):
|
||||||
@@ -104,7 +104,7 @@ class CopySelectDialog(wx.Dialog):
|
|||||||
|
|
||||||
def toggleOptions(self):
|
def toggleOptions(self):
|
||||||
for formatId in self.options:
|
for formatId in self.options:
|
||||||
for optId, checkbox in self.options[formatId].items():
|
for checkbox in self.options[formatId].values():
|
||||||
checkbox.Enable(self.GetSelected() == formatId)
|
checkbox.Enable(self.GetSelected() == formatId)
|
||||||
|
|
||||||
def GetSelected(self):
|
def GetSelected(self):
|
||||||
|
|||||||
@@ -747,7 +747,7 @@ class MainFrame(wx.Frame):
|
|||||||
CopySelectDialog.copyFormatEfs: self.clipboardEfs}
|
CopySelectDialog.copyFormatEfs: self.clipboardEfs}
|
||||||
dlg = CopySelectDialog(self)
|
dlg = CopySelectDialog(self)
|
||||||
btnPressed = dlg.ShowModal()
|
btnPressed = dlg.ShowModal()
|
||||||
|
|
||||||
if btnPressed == wx.ID_OK:
|
if btnPressed == wx.ID_OK:
|
||||||
selected = dlg.GetSelected()
|
selected = dlg.GetSelected()
|
||||||
options = dlg.GetOptions()
|
options = dlg.GetOptions()
|
||||||
|
|||||||
Reference in New Issue
Block a user