Example #1
0
void ArpMenuField::copy_attrs(BMenu* menu)
{
	if( !menu ) return;
	int32 num = menu->CountItems();
	for( int32 i=0; i<num; i++ ) {
		BMenu* child = menu->SubmenuAt(i);
		if( child ) {
			copy_attrs(child);
			// the menu doesn't seem to see this.
			child->SetFont(&PV_MenuFont);
			child->SetHighColor(PV_MenuForeColor);
			child->SetLowColor(PV_MenuBackColor);
			child->SetViewColor(PV_MenuBackColor);
			child->InvalidateLayout();
		}
	}
}