subclassing GtkMenuItem

[email protected] (Der Starchaser) Sat, 22 Aug 2009 16:34:21 +0200
Newsgroups php.gtk.general
Message-ID <[email protected]>
hello @ all,

when subclassing GtkMenuItem I receive an error : Fatal error: Call to 
undefined method GtkMenuItem::GtkMenuItem() in MenuItem.class on line 128.

Is there any workaround possible ?



class MyAltMenuItem extends GtkMenuItem
{
	function MyAltMenuItem($label, $underscore, $accelgroup)
	{
		GtkMenuItem::GtkMenuItem ( $label );							<------ line 128
		if (strlen($label)!=(strlen($underscore)-1))
			$label = new GtkLabel;
		else
			$label = $this->child;

		$Subitem_key = $label->parse_uline($underscore);
		GtkMenuItem::add_accelerator("activate_item", $accelgroup, $Subitem_key, 
GDK_MOD1_MASK, 0);
	}
}