Re: [gtkmm] Get parent window of any Widget for use in Dialog constructor
- From: Murray Cumming <murrayc murrayc com>
- To: Christian Neumann <christian altfrau de>
- Cc: gtkmm-list <gtkmm-list gnome org>
- Subject: Re: [gtkmm] Get parent window of any Widget for use in Dialog constructor
- Date: Thu, 03 Jun 2004 21:05:06 +0200
On Thu, 2004-06-03 at 20:00 +0200, Christian Neumann wrote:
> Hi,
> I need to get a reference or pointer to the root window of some
> Gtk::Widget to create a transient Gtk::Dialog.
> Gtk::Widget::get_parent_window() or Gtk::Widget::get_root_window() won't
> work because they return a Glib::RefPtr (which I can't dereference if I
> understood the docs correctly). I can't use *this because the dialog
> creating function is not member of the root window.
> The situation:
> The Widget which creates the dialog is member of some container, which
> itself is member of some other container [...]
> Is there a convenient solution to this problem (other then passing the
> root window pointer to each underlying widget?)?
I think you want Gtk::Widget::get_toplevel().
--
Murray Cumming
murrayc murrayc com
www.murrayc.com
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]