Fix the settings screen layout so the back button is always visible

This commit is contained in:
Henrik Rydgard 2013-08-17 13:08:32 +02:00
parent 0d048edb5e
commit b89af62143

View File

@ -186,17 +186,14 @@ void GameSettingsScreen::CreateViews() {
I18NCategory *s = GetI18NCategory("System");
I18NCategory *ms = GetI18NCategory("MainSettings");
Margins actionMenuMargins(0, 0, 15, 0);
root_ = new LinearLayout(ORIENT_HORIZONTAL);
root_ = new AnchorLayout(new LayoutParams(FILL_PARENT, FILL_PARENT));
ViewGroup *leftColumn = new AnchorLayout(new LinearLayoutParams(1.0f));
root_->Add(leftColumn);
leftColumn->Add(new Spacer(new LinearLayoutParams(1.0)));
leftColumn->Add(new Choice(g->T("Back"), "", false, new AnchorLayoutParams(150, WRAP_CONTENT, 10, NONE, NONE, 10)))->OnClick.Handle(this, &GameSettingsScreen::OnBack);
root_->Add(new Choice(g->T("Back"), "", false, new AnchorLayoutParams(150, WRAP_CONTENT, 10, NONE, NONE, 10)))->OnClick.Handle(this, &GameSettingsScreen::OnBack);
TabHolder *tabHolder = new TabHolder(ORIENT_VERTICAL, 200, new LinearLayoutParams(800, FILL_PARENT, actionMenuMargins));
TabHolder *tabHolder = new TabHolder(ORIENT_VERTICAL, 200, new AnchorLayoutParams(10, 0, 10, 0, false));
root_->Add(tabHolder);