EVT_TREE_ITEM_ACTIVATED Not working like wx.EVT_LIST_ITEM_SELECTED

I am having an issue with wx.EVT_TREE_ITEM_ACTIVATED.

    def Event_AddComponent(self, event):
        item = event.GetItem()
        print item.GetId()

During a EVT_LIST_ITEM_SELECTED it returns the correct index value/
line position, however, during a wx.EVT_TREE_ITEM_ACTIVATED it always
returns '0'. However, item.GetText(), returns the proper results.
Possible bug?

wx.TreeItemId does not have a GetId method.

···

On 7/25/10 9:55 AM, CarlVon wrote:

I am having an issue with wx.EVT_TREE_ITEM_ACTIVATED.

     def Event_AddComponent(self, event):
         item = event.GetItem()
         print item.GetId()

During a EVT_LIST_ITEM_SELECTED it returns the correct index value/
line position, however, during a wx.EVT_TREE_ITEM_ACTIVATED it always
returns '0'. However, item.GetText(), returns the proper results.
Possible bug?

--
Robin Dunn
Software Craftsman

AGW's hypertreelist gives you an id with TREE_ITEM_ACTIVATED.

Mark

···

On Jul 27, 3:18 am, Robin Dunn <ro...@alldunn.com> wrote:

On 7/25/10 9:55 AM, CarlVon wrote:

> I am having an issue with wx.EVT_TREE_ITEM_ACTIVATED.

> def Event_AddComponent(self, event):
> item = event.GetItem()
> print item.GetId()

> During a EVT_LIST_ITEM_SELECTED it returns the correct index value/
> line position, however, during a wx.EVT_TREE_ITEM_ACTIVATED it always
> returns '0'. However, item.GetText(), returns the proper results.
> Possible bug?

wx.TreeItemId does not have a GetId method.

--
Robin Dunn
Software Craftsmanhttp://wxPython.org