[Gambas-devel] Inheritance broken in 1.9.42

Benoit Minisini gambas at ...1...
Fri Sep 15 22:27:03 CEST 2006


On Friday 15 September 2006 22:03, Daniel Campos wrote:
> Hi:
>
> This code worked in previous versions (into a form):
>
> PUBLIC SUB Button1_Click()
>
>   DIM hC AS Control
>
>   hC = ME
>   PRINT hC.Title
>
> END
>
> Now it raises an error ( Unknown Symbol). Is it a bug or did the
> inheritance changed in 1.9.42?

It is a bug fix. 'Title' is not a property of the Control class. If you need 
dynamic symbol matching, you must use the Object class. Otherwise, symbol 
matching must be static, which was not always the case in previous versions. 
This was fixed in 1.9.34.

>
> And... any plans to stabilize qb.qt? :-) gb.gtk probably will be
> different in the future if there's not any defined interface to
> follow, and gb.qt is growing and changing in each version :-) May be
> it is time to stop a bit, I think...

I change gb.qt only to stabilize it. :-) 

As you may have notice, there is a share directory in the gb.qt source 
directory, where I'm beginning to put class description include files. I 
think you can start to use it, by making a 'share' symbolic link in gb.gtk 
that points at this directory.

I use a '#ifdef GB_QT_COMPONENT" inside for gb.qt specific parts: sometimes, 
QT strangeness needs some common properties to be overridden in some classes, 
which may not be needed in gb.gtk.

You can look in the Makefile.am file of ./gb.qt/src to see how to define a 
GB_GTK_COMPONENT for doing the same thing.

If you want us to start to make gb.gtk and gb.qt behave the same, I suggest 
making a page on the wiki where I will put all implementation details of 
gb.qt controls and where we can freeze this implementation. 

Are you agree? 

Give me a few controls you will start to work on, and I will start to fill 
this page. 

Note that we will have to do the opposite job for GridView, as the gb.gtk one 
is more advanced than the gb.qt one now.

Regards,

-- 
Benoit Minisini





More information about the Devel mailing list