MCPcopy Create free account
hub / github.com/Eve-PySpy/PySpy / __init__

Method __init__

ignoredialog.py:34–63  ·  view source on GitHub ↗
(self, parent, *args, **kwds)

Source from the content-addressed store, hash-verified

32
33class IgnoreDialog(wx.Frame):
34 def __init__(self, parent, *args, **kwds):
35 kwds["style"] = (kwds.get("style", 0) | wx.CAPTION | wx.CLIP_CHILDREN |
36 wx.CLOSE_BOX | wx.FRAME_FLOAT_ON_PARENT | wx.RESIZE_BORDER)
37 wx.Frame.__init__(self, parent, *args, **kwds)
38
39 self.Font = self.Font.Scaled(config.OPTIONS_OBJECT.Get("FontScale", 1))
40 self.SetName("IgnoreDialog")
41 self.SetSize((400, 300))
42
43 self.ignoredList = CheckListCtrl(self)
44 self.ignoredList.InsertColumn(0, 'Name', width=180)
45 self.ignoredList.InsertColumn(1, 'ID', width=0)
46 self.ignoredList.InsertColumn(2, 'Type')
47 self.buttonPanel = wx.Panel(self, wx.ID_ANY)
48 self.appBtn = wx.Button(self.buttonPanel, wx.ID_OK, "Delete Selected Entries")
49 self.cnclBtn = wx.Button(self.buttonPanel, wx.ID_CANCEL, "Cancel Changes")
50
51 self.Bind(wx.EVT_BUTTON, self.OnApply, id=self.appBtn.GetId())
52 self.Bind(wx.EVT_BUTTON, self.OnCancel, id=self.cnclBtn.GetId())
53 self.Bind(wx.EVT_CHAR_HOOK, self.OnHook)
54
55 self.ignored_entities = config.OPTIONS_OBJECT.Get("ignoredList", default=[])
56 self._populateList()
57
58 self.__set_properties()
59 self.__do_layout()
60
61 if config.OPTIONS_OBJECT.Get("StayOnTop", True):
62 self.Parent.ToggleWindowStyle(wx.STAY_ON_TOP)
63 self.ToggleWindowStyle(wx.STAY_ON_TOP)
64
65 def __set_properties(self):
66 self.SetTitle("Review Ignored Entities")

Callers 1

__init__Method · 0.45

Calls 5

_populateListMethod · 0.95
__set_propertiesMethod · 0.95
__do_layoutMethod · 0.95
GetMethod · 0.80
CheckListCtrlClass · 0.70

Tested by

no test coverage detected