wxPython and PyEditorDialogAdapter

Help
2010-04-13
2013-05-22
  • Jonas Innala

    Jonas Innala - 2010-04-13

    class MonsterSpawnProperty(wx.propgrid.PyEditorDialogAdapter):

        def __init__(self):
            wx.propgrid.PyEditorDialogAdapter.__init__(self)

        def GetEditorDialog(self):
            return MonsterSpawnEditor()

    self.grid = wx.propgrid.PropertyGrid(self, style = wx.propgrid.PG_SPLITTER_AUTO_CENTER)
    self.grid.RegisterEditor (MonsterSpawnProperty)

    This code gives me these errors:

    self.grid.RegisterEditor (MonsterSpawnProperty)
      File "C:\Python26\lib\site-packages\wx-2.8-msw-unicode\wx\propgrid.py", line 2143, in RegisterEditor
        RegisterEditor(editor, editorName)
      File "C:\Python26\lib\site-packages\wx-2.8-msw-unicode\wx\propgrid.py", line 5491, in RegisterEditor
        return _propgrid.RegisterEditor(*args, **kwargs)
    TypeError: expected wxPGEditor

    Is this a bug or something I done wrong?

     
  • Jonas Innala

    Jonas Innala - 2010-04-13

    I fixed it.
    Close this thread.

     

Log in to post a comment.

Get latest updates about Open Source Projects, Conferences and News.

Sign up for the SourceForge newsletter:





No, thanks