TGMainFrame / TGListBox / TGComboBox refresh

From: Costas Andreopoulos <>
Date: Tue, 25 Jan 2005 13:22:44 +0000


I have a TGMainFrame which contains some TGListBox'es and TGComboBox'es. I use TGCheckButtons to 'select all' or 'un-select all' list-box and combo-box entries at once.

Everything worked fine until I moved my SelectAllListBoxEntries(...) and similar methods (that were used from the method responding to the TGCheckButton Clicked() event) outside the TGMainFrame class and into a gui ultilities namespace.

Now, it still does what it is supposed to do to the list/combo-boxes, but I can not get the TGMainFrame to refresh itself and show the new list/combo-box selections, unless I perform some other action (eg click on the list-box scrollbar etc...).

Unfortunatelly, mylistbox->SelectionChanged(); does not seem to cause a refresh.

I end up moving the scrollbar a litle bit

mylistbox->GetVScrollbar()->SetPosition(1); mylistbox->GetVScrollbar()->SetPosition(0);

which forces the GUI window to refresh.

But this is certainly not the correct way and I found nothing similar to do for combo-boxes.

Any suggestion?



Dr. Constantinos Andreopoulos, CCLRC - Rutherford Lab.
Received on Tue Jan 25 2005 - 14:23:33 MET

This archive was generated by hypermail 2.2.0 : Tue Jan 02 2007 - 14:45:04 MET