Added view thread functionality