Fix setScene() bug; Seperate client from the framework