Fix indents (res & src)

Fix almost all the indents & reorder some methods.