From 0d6b19e963f334ac7280b6fb37af03445e4a3df9 Mon Sep 17 00:00:00 2001 From: Pascal Abresch Date: Tue, 29 Dec 2020 15:38:27 +0100 Subject: [PATCH] DeskCalc: Remove __HAIKU__ ifdef MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit No functional change intended Change-Id: I934bef5c8b09a267c423edf7698bb57170e43945 Reviewed-on: https://review.haiku-os.org/c/haiku/+/3559 Reviewed-by: Adrien Destugues Reviewed-by: Stephan Aßmus --- src/apps/deskcalc/CalcView.cpp | 16 ++-------------- 1 file changed, 2 insertions(+), 14 deletions(-) diff --git a/src/apps/deskcalc/CalcView.cpp b/src/apps/deskcalc/CalcView.cpp index 049ffc40e4..aa1eddeff1 100644 --- a/src/apps/deskcalc/CalcView.cpp +++ b/src/apps/deskcalc/CalcView.cpp @@ -205,11 +205,7 @@ CalcView::CalcView(BRect frame, rgb_color rgbBaseColor, BMessage* settings) fKeypadDescription(kKeypadDescriptionBasic), fKeypad(NULL), -#ifdef __HAIKU__ fCalcIcon(new BBitmap(BRect(0, 0, 15, 15), 0, B_RGBA32)), -#else - fCalcIcon(new BBitmap(BRect(0, 0, 15, 15), 0, B_CMAP8)), -#endif fPopUpMenu(NULL), fAutoNumlockItem(NULL), @@ -243,11 +239,7 @@ CalcView::CalcView(BMessage* archive) fKeypadDescription(kKeypadDescriptionBasic), fKeypad(NULL), -#ifdef __HAIKU__ fCalcIcon(new BBitmap(BRect(0, 0, 15, 15), 0, B_RGBA32)), -#else - fCalcIcon(new BBitmap(BRect(0, 0, 15, 15), 0, B_CMAP8)), -#endif fPopUpMenu(NULL), fAutoNumlockItem(NULL), @@ -496,12 +488,8 @@ CalcView::Draw(BRect updateRect) FillRect(updateRect & expressionRect); } - if (fCalcIcon->ColorSpace() == B_RGBA32) { - SetDrawingMode(B_OP_ALPHA); - SetBlendingMode(B_PIXEL_ALPHA, B_ALPHA_OVERLAY); - } else { - SetDrawingMode(B_OP_OVER); - } + SetDrawingMode(B_OP_ALPHA); + SetBlendingMode(B_PIXEL_ALPHA, B_ALPHA_OVERLAY); BPoint iconPos; iconPos.x = expressionRect.right - (expressionRect.Width()