Patch : "Change the panel in tabs was setting the top switches to SQL Editor"

Поиск
Список
Период
Сортировка
От Ashesh Vashi
Тема Patch : "Change the panel in tabs was setting the top switches to SQL Editor"
Дата
Msg-id 4937B2BE.9010001@enterprisedb.com
обсуждение исходный текст
Ответы Re: Patch : "Change the panel in tabs was setting the top switches to SQL Editor"  ("Dave Page" <dpage@pgadmin.org>)
Список pgadmin-hackers
Hi Dave Page,
> I think - this is a bug from a while, I can reproduce the same for the
> "Criteria Panel".
> If I make any changes in the "Criteria Panel", and then click "Columns
> Panel", the main
> tab set at the top switches to "SQL Editor". :(
>
> I will send a patch for it.
As I have told you, this was a bug introduced earlier.
The object sqlNoteBook (in frmQuery class) and the object tabs (in the
gqbController class)
both were using the same id (CTL_NTBKCENTER).
And in frmQuery class, an event handler - OnChangeNotebook is registered
with this id.

I changed the id for the object tabs of gqbController to CTL_NTBKPANELS.

Please find the patch for the same.

Regards,
Ashesh
Index: gqb/gqbController.cpp
===================================================================
--- gqb/gqbController.cpp    (revision 7506)
+++ gqb/gqbController.cpp    (working copy)
@@ -27,6 +27,8 @@
 #include "gqb/gqbEvents.h"
 #include "gqb/gqbViewPanels.h"
 
+wxWindowID CTL_NTBKPANELS = ::wxNewId();
+
 gqbController::gqbController(gqbModel *_model, wxWindow *gqbParent, wxNotebook *gridParent, wxSize
size=wxSize(800,1280)):
 wxObject()
 {
@@ -36,7 +38,7 @@
 
     // Initialize Main Splitter
     gqbMainContainer = new wxSplitterWindow(gqbParent,GQB_HORZ_SASH,wxDefaultPosition,wxDefaultSize,wxSP_3D);
-    tabs = new wxNotebook(gqbMainContainer, CTL_NTBKCENTER, wxDefaultPosition, wxDefaultSize);
+    tabs = new wxNotebook(gqbMainContainer, CTL_NTBKPANELS, wxDefaultPosition, wxDefaultSize);
 
     // Initialize view container with tables browser
     // GQB-TODO: change 976 with a enum value of events.h

В списке pgadmin-hackers по дате отправления:

Предыдущее
От: Ashesh Vashi
Дата:
Сообщение: Re: Patch for "Panel for Joins in the Graphic Query Builder"
Следующее
От: svn@pgadmin.org
Дата:
Сообщение: SVN Commit by dpage: r7507 - in trunk/pgadmin3/pgadmin: . gqb include/gqb include/images