summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorCaolán McNamara <caolanm@redhat.com>2020-07-07 20:27:51 +0100
committerCaolán McNamara <caolanm@redhat.com>2020-07-08 13:39:11 +0200
commit19fd82ac6e08896bd17169d1b6ea090458fc18da (patch)
treea179a2651dc58d4574833ac39ab0ea70f1dd8110 /test
parent2d8e2813ddc87f7ce03b97e4d603df11613461f0 (diff)
distinguish between dialog screenshoting and rendering a widget
Change-Id: I43ee0c68d72c97a15d26e2ffea577c2a44ba91e8 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/98326 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
Diffstat (limited to 'test')
-rw-r--r--test/source/screenshot_test.cxx3
1 files changed, 1 insertions, 2 deletions
diff --git a/test/source/screenshot_test.cxx b/test/source/screenshot_test.cxx
index 8e6a8775db05..ea26f80c47a6 100644
--- a/test/source/screenshot_test.cxx
+++ b/test/source/screenshot_test.cxx
@@ -112,8 +112,7 @@ void ScreenshotTest::saveScreenshot(VclAbstractDialog const & rDialog)
void ScreenshotTest::saveScreenshot(weld::Window& rDialog)
{
- VclPtr<VirtualDevice> xDialogSurface(VclPtr<VirtualDevice>::Create(DeviceFormat::DEFAULT));
- rDialog.draw(*xDialogSurface);
+ VclPtr<VirtualDevice> xDialogSurface(rDialog.screenshot());
const BitmapEx aScreenshot(xDialogSurface->GetBitmapEx(Point(), xDialogSurface->GetOutputSizePixel()));
if (!aScreenshot.IsEmpty())