SQL tab on Server's properties dialog? - Mailing list pgadmin-hackers

From Guillaume Lelarge
Subject SQL tab on Server's properties dialog?
Date
Msg-id 488B9AA8.8010905@lelarge.info
Whole thread Raw
Responses Re: SQL tab on Server's properties dialog?  ("Dave Page" <dpage@pgadmin.org>)
List pgadmin-hackers
Hi,

While working on the dialogs' review, I was wondering why we show the
SQL tab for the Server's properties dialog. I think we shouldn't display
this tab on this dialog. The patch enclosed does this.

I'm not sure this qualifies as a bug. But it shouldn't be hard to apply
the patch on the 1.8 branch.

Comments?


--
Guillaume.
  http://www.postgresqlfr.org
  http://dalibo.com
Index: pgadmin/dlg/dlgProperty.cpp
===================================================================
--- pgadmin/dlg/dlgProperty.cpp    (revision 7393)
+++ pgadmin/dlg/dlgProperty.cpp    (working copy)
@@ -311,8 +311,11 @@

 void dlgProperty::CreateAdditionalPages()
 {
-    sqlPane = new ctlSQLBox(nbNotebook, CTL_PROPSQL, wxDefaultPosition, wxDefaultSize, wxTE_MULTILINE |
wxSUNKEN_BORDER| wxTE_READONLY | wxTE_RICH2); 
-    nbNotebook->AddPage(sqlPane, wxT("SQL"));
+    if (wxString(factory->GetTypeName()).Cmp(wxT("Server")))
+    {
+      sqlPane = new ctlSQLBox(nbNotebook, CTL_PROPSQL, wxDefaultPosition, wxDefaultSize, wxTE_MULTILINE |
wxSUNKEN_BORDER| wxTE_READONLY | wxTE_RICH2); 
+      nbNotebook->AddPage(sqlPane, wxT("SQL"));
+    }
 }



pgadmin-hackers by date:

Previous
From: "Dave Page"
Date:
Subject: Re: Dialogs review
Next
From: "Dave Page"
Date:
Subject: Re: SQL tab on Server's properties dialog?