Hi!
GINT_TO_POINTER() and GPOINTER_TO_INT() might be useful.
Remember, YOU MAY NOT STORE POINTERS IN INTEGERS. THIS IS NOT PORTABLE
IN ANY WAY SHAPE OR FORM. These macros ONLY allow storing integers in
pointers, and only preserve 32 bits of the integer; values outside the
range of a 32-bit
(sorry for the resend Johannes)
This:
gpointer your_pointer;
Gtk::SelectionData::set (your-type-name, 8,
static_castguint8*(your_pointer),
sizeof(your_pointer))
should do it. When getting it you just use:
gpointer * your_pointer =
Actually this is wrong, it should be sizeof(gpointer*).
2008/4/26 Milosz Derezynski [EMAIL PROTECTED]:
(sorry for the resend Johannes)
This:
gpointer your_pointer;
Gtk::SelectionData::set (your-type-name, 8,
static_castguint8*(your_pointer),
sizeof(your_pointer))
should do it.
On Sat, 2008-04-26 at 14:48 +0200, Johannes Schmid wrote:
Hi!
Probably a silly question, but how can I savely store a pointer to an
object in a Gtk::SelectionData. I guess I have to use
Gtk::SelectionData::set (int format, guint8* data, int length)
somehow but I cannot figure out how to
On Sat, 2008-04-26 at 18:29 +0200, Murray Cumming wrote:
On Sat, 2008-04-26 at 14:48 +0200, Johannes Schmid wrote:
Hi!
Probably a silly question, but how can I savely store a pointer to an
object in a Gtk::SelectionData. I guess I have to use
Gtk::SelectionData::set (int format,