Thread: dlgType.cpp - set connection missing

dlgType.cpp - set connection missing

From
Vladimir Kokovic
Date:
Hi,

# This patch file was generated by NetBeans IDE
# It uses platform neutral UTF-8 encoding and \n newlines.
--- Index
+++ Modified In Working Tree
@@ -99,6 +99,13 @@
    seclabelPage = new ctlSeclabelPanel(nbNotebook);

+    connection = schema->GetConnection();
+    if (connection->BackendMinimumVersion(9, 1))
+    {
+        seclabelPage->SetConnection(connection);
+        seclabelPage->SetObject(type);
+    }
+    lstMembers->CreateColumns(0, _("Member"), _("Data type"), _("Collation"), -1);    lstLabels->InsertColumn(0,
_("Label"),wxLIST_FORMAT_LEFT,
 
GetClientSize().GetWidth());


Best regards,
Vladimir Kokovic, DP senior, Belgrade, Serbia


Re: dlgType.cpp - set connection missing

From
Guillaume Lelarge
Date:
Hi,

On Tue, 2011-09-27 at 04:12 +0200, Vladimir Kokovic wrote:
> [...]
> # This patch file was generated by NetBeans IDE
> # It uses platform neutral UTF-8 encoding and \n newlines.
> --- Index
> +++ Modified In Working Tree
> @@ -99,6 +99,13 @@
> 
>      seclabelPage = new ctlSeclabelPanel(nbNotebook);
> 
> +    connection = schema->GetConnection();
> +    if (connection->BackendMinimumVersion(9, 1))
> +    {
> +        seclabelPage->SetConnection(connection);
> +        seclabelPage->SetObject(type);
> +    }
> +
>      lstMembers->CreateColumns(0, _("Member"), _("Data type"), _("Collation"), -1);
>      lstLabels->InsertColumn(0, _("Label"), wxLIST_FORMAT_LEFT,
> GetClientSize().GetWidth());
> 

Good catch. I didn't apply your patch because I think there's no need to
call CheckChange before calling Go (which already set the connection
variable).

Anyway, thank you for your patch, and report.

By the way, it would be great if you adds a few words in your mail to
explain what you are trying to do. Only sending a patch is not great.
It's good because it helps us. It's not great because I have to guess
what it does, and why it does it this way (and, no, the subject isn't
enough).

Anyway, thanks again.


-- 
Guillaume http://blog.guillaume.lelarge.info http://www.dalibo.com