⛏️ index : haiku.git

author Axel Dörfler <axeld@pinc-software.de> 2025-12-05 17:35:36.0 +01:00:00
committer Adrien Destugues <pulkomandy@pulkomandy.tk> 2025-12-09 10:18:39.0 +00:00:00
commit
0f7bee148d7d86d4f7e13b44fd6a28cc56c938e8 [patch]
tree
d70981296eacec5a4d9918d9b5d48a0afea75bc9
parent
82755a4c33a6aec549b75c7f61777b5f3eaaad0d
download
0f7bee148d7d86d4f7e13b44fd6a28cc56c938e8.tar.gz

AboutSystem: Open with golden ration window size

* This looks more pleasing than the too flat window before.

Change-Id: I0e97c094abf6f7d71d86cfe28aaf9c2d6960f79c
Reviewed-on: https://review.haiku-os.org/c/haiku/+/10065
Reviewed-by: waddlesplash <waddlesplash@gmail.com>
Tested-by: Commit checker robot <no-reply+buildbot@haiku-os.org>

Diff

 src/apps/aboutsystem/AboutSystem.cpp |  9 ++++++++-
 1 file changed, 8 insertions(+), 1 deletion(-)

diff --git a/src/apps/aboutsystem/AboutSystem.cpp b/src/apps/aboutsystem/AboutSystem.cpp
index abbc899..c5e85f4 100644
--- a/src/apps/aboutsystem/AboutSystem.cpp
+++ b/src/apps/aboutsystem/AboutSystem.cpp
@@ -1,5 +1,5 @@
/*
 * Copyright 2005-2022 Haiku, Inc. All rights reserved.
 * Copyright 2005-2025 Haiku, Inc. All rights reserved.
 * Distributed under the terms of the MIT license.
 *
 * Authors:
@@ -400,6 +400,13 @@

	fAboutView = new AboutView();
	AddChild(fAboutView);

	UpdateSizeLimits();

	// Resize according to golden rule
	float width = Bounds().IntegerWidth();
	if (width * 0.618 > Bounds().Height())
		ResizeTo(width, width * 0.618);

	CenterOnScreen();
}