working on fixing layout change mechanism