added functionality of views. fixed checkLine func in Algorithm