About: Show repository info

Fixes #832
This commit is contained in:
Jonathan Archer 2019-12-01 18:12:16 -06:00 committed by Andreas Kling
parent 3f45ccffa6
commit f4949fcf83
Notes: sideshowbarker 2024-07-19 17:42:48 +09:00

View File

@ -12,7 +12,7 @@ int main(int argc, char** argv)
auto window = GWindow::construct();
window->set_title("About Serenity");
Rect window_rect { 0, 0, 240, 150 };
Rect window_rect { 0, 0, 240, 180 };
window_rect.center_within(GDesktop::the().rect());
window->set_resizable(false);
window->set_rect(window_rect);
@ -44,6 +44,16 @@ int main(int argc, char** argv)
version_label->set_size_policy(SizePolicy::Fill, SizePolicy::Fixed);
version_label->set_preferred_size(0, 11);
auto git_info_label = GLabel::construct(widget);
git_info_label->set_text(String::format("Built on %s@%s", GIT_BRANCH, GIT_COMMIT));
git_info_label->set_size_policy(SizePolicy::Fill, SizePolicy::Fixed);
git_info_label->set_preferred_size(0, 11);
auto git_changes_label = GLabel::construct(widget);
git_changes_label->set_text(String::format("Changes: %s", GIT_CHANGES));
git_changes_label->set_size_policy(SizePolicy::Fill, SizePolicy::Fixed);
git_changes_label->set_preferred_size(0, 11);
auto quit_button = GButton::construct(widget);
quit_button->set_text("Okay");
quit_button->set_size_policy(SizePolicy::Fixed, SizePolicy::Fixed);