summaryrefslogtreecommitdiff
path: root/vcl/source/window/layout.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'vcl/source/window/layout.cxx')
-rw-r--r--vcl/source/window/layout.cxx20
1 files changed, 4 insertions, 16 deletions
diff --git a/vcl/source/window/layout.cxx b/vcl/source/window/layout.cxx
index c38790b6b2df..f4479cc7c6ca 100644
--- a/vcl/source/window/layout.cxx
+++ b/vcl/source/window/layout.cxx
@@ -279,20 +279,8 @@ void VclBox::setAllocation(const Size &rAllocation)
else if (nExpandChildren)
{
Size aRequisition = calculateRequisition();
- nExtraSpace = (getPrimaryDimension(rAllocation) - getPrimaryDimension(aRequisition)) / nExpandChildren;
-// In mobile, the screen size is small and extraSpace can become negative
-// Though the dialogs are rendered in javascript for LOK Android some widgets like weld::DrawingArea
-// is sent as bitmap but it is rendered from only the visible part
-// when it gets negative, it shrinks instead of expands and it becomes invisible
-
- if (nExtraSpace < 0)
- {
- SAL_WARN("vcl.layout", "nExtraSpace went negative for VclBox: " << GetHelpId());
- if (comphelper::LibreOfficeKit::isActive())
- {
- nExtraSpace = 0;
- }
- }
+ tools::Long nPrimaryDimension = getPrimaryDimension(rAllocation);
+ nExtraSpace = (nPrimaryDimension - getPrimaryDimension(aRequisition)) / nExpandChildren;
}
//Split into those we pack from the start onwards, and those we pack from the end backwards
@@ -3006,9 +2994,9 @@ void VclDrawingArea::DumpAsPropertyTree(tools::JsonWriter& rJsonWriter)
if(GraphicConverter::Export(aOStm, aImage, ConvertDataFormat::PNG) == ERRCODE_NONE)
{
css::uno::Sequence<sal_Int8> aSeq( static_cast<sal_Int8 const *>(aOStm.GetData()), aOStm.Tell());
- OUStringBuffer aBuffer("data:image/png;base64,");
+ OStringBuffer aBuffer("data:image/png;base64,");
::comphelper::Base64::encode(aBuffer, aSeq);
- rJsonWriter.put("image", aBuffer.makeStringAndClear());
+ rJsonWriter.put("image", aBuffer);
}
rJsonWriter.put("text", GetQuickHelpText());
}