[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Adonthell-devel] Event system continued
From: |
ksterker |
Subject: |
Re: [Adonthell-devel] Event system continued |
Date: |
Mon, 19 Apr 2004 11:16:30 +0200 |
Von: Alexandre Courbot <address@hidden>
> Let's leave them for now. Anyway they will most likely be tied to
> objects or delimited areas, since the grid will only be internal
> to the map.
Good.
> Good! So I suppose get_time_name is tied to an abstract class that
> every python passable object should inherit from, right?
No. I thought about that at first, but it's not really neccessary. There are
three macros that can be used, depending on the situation.
GET_TYPE_NAME_ABSTRACT, GET_TYPE_NAME_VIRTUAL and the plain GET_TYPE_NAME. In
your abstract base class, you'd use the first, in classes that will be
subclassed, you'd use the second, and in top level classes the last.
Actually, GET_TYPE_NAME_VIRTUAL would suffice, but then you get ugly compiler
warnings (virtual method in class with non-virtual destructor).
> > This can probably done with a SWIG typemap, or the
> > %feature(shadow) thing.
>
> Yes it is. We already did that for 0.3, I think.
Well, we did something for strings there, not for other things. But it
shouldn't be that hard.
Kai