void InternalWindow::keyPressed(const KeyEventUnrecPtr e)
{
    if(!getLockInput())
    {
        //Check for Accelerator Keys
        UInt32 RelevantModifiers = (e->getModifiers() & KeyEvent::KEY_MODIFIER_ALT) |
            (e->getModifiers() & KeyEvent::KEY_MODIFIER_CONTROL) |
            (e->getModifiers() & KeyEvent::KEY_MODIFIER_SHIFT) |
            (e->getModifiers() & KeyEvent::KEY_MODIFIER_META);
        KeyAcceleratorMapItor MapItor = _KeyAcceleratorMap.find(KeyEvent::getHashable(e->getKey(), RelevantModifiers));
        if(MapItor != _KeyAcceleratorMap.end())
        {
            (*MapItor).second->acceleratorTyped(KeyAcceleratorEvent::create(InternalWindowRefPtr(this), e->getTimeStamp(), e->getKey(), e->getModifiers()));
        }
        //Send Key event to Component that has Focus
        //If there is not Focused Component then do nothing
        if(getFocusedComponent() != NULL &&
           getFocusedComponent() != this)
        {
            getFocusedComponent()->keyPressed(e);
            ComponentContainerRefPtr ParentContainer(getFocusedComponent()->getParentContainer());
            while(ParentContainer != NULL &&
                  ParentContainer != this)
            {
                ParentContainer->keyPressed(e);
                ParentContainer = dynamic_cast<ComponentContainer*>(ParentContainer->getParentContainer());
            }
        }
        Component::keyPressed(e);
    }
}