Hi Noel,

> It seems to work (but.. /me is not very unfamiliar with gui things ) I
> made it so the SvURLBox thingy now accepts an externally defined
> placeholder ( I hope where I defined the resource for use with the
> formcontrol browser is acceptable ), if the placeholder is displayed,
> the first keypress results in the placeholder getting selected, this
> should ensure it gets immediately replaced with what you type.

looks good to me. Well, sufficiently good - cursor traveling through the
field is not possible with this approach (since a change in selection
implicitly changes the cursor position), but I'd say this is negligible.

>>>> Care needs to be taken here: if the method "hasField()" returns
>> true,
>>>> then the control is bound to a database column, in which case the
>>>> "Link" checkbox should be disabled. If it is "false", it should
>>>>   be enabled (and checked by default?).
> hasField is not accessible here ( it's in the model implementation ) but
> what I did I should work. But... I couldn't test this, you see I am so
> stupid I don't know anything about base and after fiddling for a while I
> couldn't see immediately how to bind the imagecontrol to a dbcolumn. I
> would be really grateful if you could test that bit for me :-)

You enable the "Link" check box the wrong way 'round - it must be
enabled when there is *no* field, since if and only the control is bound
to a field, then the image will be stored in the database, anyway.

> also, I did put in a potential #FIXME in the patch, I wasn't sure about
> the implications of returning early ( you will easily see what I am
> talking about in the patch, just look for '#FIXME?' ) so I took the
> route of 'leave the orig code path alone as much as possible' maybe you
> have some additional input/idea there.

It's correct to not leave early, since there might be listeners which
are interested in the event. However, the correct way for
aNormalizedValue is the current property value then, *not* the place
holder (which is a display value for the user's convenience only,
nothing to be propagated to listeners).

So, only the "setPropertyValue" call has to be conditioned with the
"!isPlaceholder"), the subsequence getPropertyValue should be done in
either case.

One other nit In ImageControl.cxx, handleNewImageURL, asking
GraphicAccess::isSupportedURL *once* is enough :)


Assuming that you fix the two items (enable the link check box if there
is *no* bound field; and using the proper NormalizedValue in ::Commit),
I'm fine with the patch. Do you want to commit, or should I?

Thanks & Ciao
Frank

-- 
- Frank Schönheit, Software Engineer         [EMAIL PROTECTED] -
- Sun Microsystems                      http://www.sun.com/staroffice -
- OpenOffice.org Base                       http://dba.openoffice.org -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to