Jump to content

How to xhange hint on a TUniFileUploadButton


Didier

Recommended Posts

6 minutes ago, Didier said:

when i pass my mouse over it, i want to put a tooltip 'Add a file' for example.

I do not see a problem when using the Hint property

UniFileUploadButton1.Hint -> 'Add a file...'
UniFileUploadButton1.ShowHint -> True

 

Link to comment
Share on other sites

23 minutes ago, Didier said:

But on firefox it doesn't work. version : 71.0 (64 bits)

Can you try this approach?

procedure TMainForm.UniFormCreate(Sender: TObject);
begin
  with UniFileUploadButton1 do
    if (ShowHint) and (Hint <> '') then
      JSInterface.JSAddListener('afterrender', 'function(){this.fileInputEl.el.dom.title="'+ Hint +'"}');
end;

 

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...