Class: Gtk::ObjectExpression

Inherits:
Expression show all
Defined in:
(unknown)

Overview

A GObject value in a GtkExpression.

Instance Method Summary collapse

Methods inherited from Expression

#bind, #evaluate, #is_static, #ref, #unref, #value_type, #watch

Constructor Details

#initialize(object) ⇒ Gtk::ObjectExpression

Creates an expression evaluating to the given object with a weak reference.

Once the object is disposed, it will fail to evaluate.

This expression is meant to break reference cycles.

If you want to keep a reference to object, use [ctorGtk.ConstantExpression.new].

Parameters:

  • object (GObject::Object)

    object to watch

Instance Method Details

#objectGObject::Object

Gets the object that the expression evaluates to.

Returns:

  • (GObject::Object)

    the object, or NULL