added touch handling for custom view