public override void Initialize(IComponent component)
{
Debug.Assert(component != null);
// Validate the parameter reference
if (component == null) throw new ArgumentNullException("component");
// Let base class do standard stuff
base.Initialize(component);
// Cast to correct type
_ribbon = (KryptonRibbon)component;
// Hook into ribbon events
_ribbon.GetViewManager().MouseUpProcessed += new MouseEventHandler(OnRibbonMouseUp);
_ribbon.GetViewManager().DoubleClickProcessed += new PointHandler(OnRibbonDoubleClick);
_ribbon.SelectedTabChanged += new EventHandler(OnSelectedTabChanged);
_ribbon.DesignTimeAddTab += new EventHandler(OnAddTab);
// Get access to the services
_designerHost = (IDesignerHost)GetService(typeof(IDesignerHost));
_changeService = (IComponentChangeService)GetService(typeof(IComponentChangeService));
_selectionService = (ISelectionService)GetService(typeof(ISelectionService));
// We need to know when we are being removed
_changeService.ComponentRemoving += new ComponentEventHandler(OnComponentRemoving);
_changeService.ComponentChanged += new ComponentChangedEventHandler(OnComponentChanged);
}