Re: Selection handling in own widget



On Wed, Jan 24, 2001 at 10:43:04AM -0500, Havoc Pennington wrote:

Gert <gs2 node17530 a2000 nl> writes:     
I really hope anyone can help, cause I don't get it anymore :(


You might want to look at GtkEditable as an example of doing this.

One problem I see is your use of GDK_CURRENT_TIME; this results in
race conditions that can cause another client to steal your
selection. Use event->time from the event triggering the selection.

doesn't seem to change anything

Also, you need to reclaim the selection whenever the selection is
changed, in order to update that timestamp, I believe.

same thing :(

The thing is, when the pasting will work, and I am selecting the text,
the gdk_selection_owner_get reports me as the current owner, but
as soon as it doesn't the copying will fail ...

I'll try and see what I can learn from the GtkEditable
             
Havoc

  Gert

--
begin  LOVE-LETTER-FOR-YOU.TXT.vbs
      I'm a signature virus. Copy me!
end




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]