Re: Enabling SQL text field in the SQL tab of object dialog

From: Guillaume Lelarge <guillaume(at)lelarge(dot)info>
To: Dave Page <dpage(at)postgresql(dot)org>
Cc: pgadmin-hackers(at)postgresql(dot)org
Subject: Re: Enabling SQL text field in the SQL tab of object dialog
Date: 2008-06-19 23:48:55
Message-ID: 485AF067.1060208@lelarge.info
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgadmin-hackers

Dave Page a écrit :
> On Tue, Jun 17, 2008 at 10:51 PM, Guillaume Lelarge
> <guillaume(at)lelarge(dot)info> wrote:
>> Dave Page a écrit :
>>> When you open a properties dialogue, it gets passed a pointer to the
>>> pgObject which it may use right up until it is closed. If you refresh
>>> part of the tree, you delete and recreate all the pgObjects under the
>>> node you refresh, so the dialogue can end up with a pointer to an
>>> object that's been deleted.
>>>
>> OK, but this is already an issue.
>
> Right, but my point is that this is going to make it more likely to occur.
>
> I wonder if we need some reference counting on objects in the tree,
> and only allow any kind of refresh if all child nodes have a ref count
> of zero. I'm not entirely sure how we'd implement that.
>
>> Here is patch revision 2. It creates a new textfield for the second SQL
>> query, and it takes care of the refresh of the tree. This patch seems to
>> resolve all issues I could find (apart from the one above).
>>
>> Comments?
>
> - Can we only have the dual textboxes on the dialogues that actually
> need them please?
>

Done. I thought we didn't hide UI objects, only disable them, to get a
more consistant UI.

> - The 'do you want to lose your changes' prompt should only be shown
> if changes have actually been made.
>

Done too.

> - There is a drawing artifact on Mac. I may have to look at that after
> you commit if you have no access to suitable hardware (maybe you can
> get JPA to spring for a Mac Mini - they're nice and cheap :-p )
>

I forwarded this mail to jpa and damien, just to know what they think
about your great idea :) Unfortunately, no answer yet.

The button text doesn't please me. Neither do the message box text. If
one has a better idea, I'll be glad to know about it.

Cheers.

--
Guillaume.
http://www.postgresqlfr.org
http://dalibo.com

Attachment Content-Type Size
enablingsqltextfield_v3.patch text/x-patch 8.1 KB

In response to

Responses

Browse pgadmin-hackers by date

  From Date Subject
Next Message svn 2008-06-20 08:57:39 SVN Commit by dpage: r7377 - in trunk/pgadmin3/pgadmin: dlg ui
Previous Message Devrim GÜNDÜZ 2008-06-19 12:54:23 Re: Building pgadmin3 against PostgreSQL 7.4