From 8c9cf9913320421d132058dcb6e1446c79b7ffc8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Stephan=20A=C3=9Fmus?= Date: Sun, 4 Aug 2013 17:38:04 +0200 Subject: [PATCH] HaikuDepot: Allow to force other size on BitmapView --- src/apps/haiku-depot/PackageInfoView.cpp | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/src/apps/haiku-depot/PackageInfoView.cpp b/src/apps/haiku-depot/PackageInfoView.cpp index 9ded8090ffc..787fc8c47eb 100644 --- a/src/apps/haiku-depot/PackageInfoView.cpp +++ b/src/apps/haiku-depot/PackageInfoView.cpp @@ -14,6 +14,7 @@ #include #include #include +#include #include #include #include @@ -74,12 +75,19 @@ class BitmapView : public BView { size.height = bounds.Height(); } - return size; + return BLayoutUtils::ComposeSize(ExplicitMinSize(), size); } + virtual BSize PreferredSize() + { + BSize size = MinSize(); + return BLayoutUtils::ComposeSize(ExplicitPreferredSize(), size); + } + virtual BSize MaxSize() { - return MinSize(); + BSize size = MinSize(); + return BLayoutUtils::ComposeSize(ExplicitMaxSize(), size); } void SetBitmap(const BBitmap* bitmap)