added extend function for more intuitive inheritance. BB10View uses this now