Added marker boundaries check for drag operation.