Ripped out old code in preparation of rewrite

The program compiles, but doesn't work right now.
Source code reorganization
Rewrite (WIP): simple drawing

Simple drawing (brushes) now work in local mode.
Rewrite (WIP): drawing progress.

Image loading now goes through the network
Rewrite (WIP): layers work again
Moved brushpreview to widgets/ directory
Better canvas caching