Added 'centerFrame' function