Fixed mask sliding example
Added test case to reproduce problems from issue #12
Implemented better handling of zIndex ordering, fixes #12