refactoring Firefox OS Building Blocks