summaryrefslogtreecommitdiff
path: root/include/test/screenshot_test.hxx
diff options
context:
space:
mode:
Diffstat (limited to 'include/test/screenshot_test.hxx')
-rw-r--r--include/test/screenshot_test.hxx18
1 files changed, 16 insertions, 2 deletions
diff --git a/include/test/screenshot_test.hxx b/include/test/screenshot_test.hxx
index f07c29a9e65b..a3b0b0e6eee7 100644
--- a/include/test/screenshot_test.hxx
+++ b/include/test/screenshot_test.hxx
@@ -15,6 +15,7 @@
#include <unotest/macros_test.hxx>
#include <com/sun/star/lang/XComponent.hpp>
#include <osl/file.hxx>
+#include <vcl/dialog.hxx>
class VclAbstractDialog;
@@ -27,10 +28,23 @@ public:
virtual void setUp() override;
virtual void tearDown() override;
- void dumpDialogToPath( VclAbstractDialog& rDialog );
+ /// version for AbstractDialogs, the ones created in AbstractDialogFactories
+ void dumpDialogToPath(VclAbstractDialog& rDialog);
+
+ /// version for pure vcl-based dialogs
+ void dumpDialogToPath(Dialog& rDialog);
+
+ /// fallback version for dialogs for which only the UXMLDescription is known.
+ /// This should be used with care - no active layouting will be done, only the
+ /// VclBuilder will be activated for layouting. Result can thus vary drastically
+ /// compared to the active dialog (can be compared with dialog previewer)
+ void dumpDialogToPath(const OString& rUIXMLDescription);
private:
- void saveScreenshot( VclAbstractDialog& rDialog );
+ void implSaveScreenshot(const Bitmap& rScreenshot, const OString& rScreenshotId);
+ void saveScreenshot(VclAbstractDialog& rDialog);
+ void saveScreenshot(Dialog& rDialog);
+
OUString m_aScreenshotDirectory;
};