Re: The use of RefPtr
- From: Hubert Figuiere <hub figuiere net>
- To: Eddie Carle <eddie erctech org>
- Cc: gtkmm-list gnome org
- Subject: Re: The use of RefPtr
- Date: Sat, 07 Mar 2009 01:57:00 -0500
On 03/07/2009 01:07 AM, Eddie Carle wrote:
On Fri, 2009-03-06 at 09:34 +0100, Murray Cumming wrote:
On Thu, 2009-03-05 at 18:29 -0700, Eddie Carle wrote:
Is there any way to assign the
TreeModel to the ComboBox without passing it through a RefPtr?
No.
Actually, in retrospect, it needn't be so complicated. I supposed if one
wants their TreeModel dynamically allocated, they could call reference()
on it manually once and then build a RefPtr from it's address so that no
calls to unreference() by RefPtr ever actually delete it. Then the only
way it can be deconstructed is by going out of scope. Would this be
considered safe or unwise?
Except that it is inconsistent with the rest of Gtkmm, and also what
Gtkmm does is what Gtk+ does.
There is no point in trying to make things more complex to make on case
marginally less complex. It is not like you have to track the model to
delete it when needed.
Also the last bit: even if you idea had an advantage, it woudln't be
feasible without breaking the ABI. That's something the Gtkmm
maintainers have been trying to avoid.
Hub
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]