13#include <osl/file.hxx>
17#include <vcl/test/GraphicsRenderTests.hxx>
27 OUString aTestName, OUString aTestStatus,
Bitmap aTestBitmap)
28 : m_xBuilder(
Application::CreateBuilder(pParent,
"cui/ui/graphictestentry.ui"))
30 , m_xTestLabel(m_xBuilder->weld_label(
"gptestlabel"))
31 , m_xTestButton(m_xBuilder->weld_button(
"gptestbutton"))
32 , m_xResultBitmap(aTestBitmap)
39 aTestStatus ==
SvlResId(GRTSTR_PASSED)
41 : aTestStatus ==
SvlResId(GRTSTR_QUIRKY)
50 if (rButton.get_label() ==
SvlResId(GRTSTR_SKIPPED))
55 rButton.get_tooltip_text());
60 : GenericDialogController(pParent,
"cui/ui/graphictestdlg.ui",
"GraphicTestsDialog")
61 , m_xResultLog(m_xBuilder->weld_text_view(
"gptest_txtVW"))
62 , m_xDownloadResults(m_xBuilder->weld_button(
"gptest_downld"))
63 , m_xContainerBox(m_xBuilder->weld_box(
"gptest_box"))
75 aTestObject.
run(
true);
79 sal_Int32 nTestNumber = 0;
83 test.getTestName(),
test.getStatus(
true),
88 return GenericDialogController::run();
93 osl::File::remove(m_xZipFileUrl);
100 catch (
const std::exception&)
102 std::unique_ptr<weld::MessageDialog> xBox(
104 VclButtonsType::Ok,
CuiResId(RID_CUISTR_ZIPFAIL)));
IMPL_LINK(GraphicTestEntry, HandleResultViewRequest, weld::Button &, rButton, void)
IMPL_LINK_NOARG(GraphicsTestsDialog, HandleDownloadRequest, weld::Button &, void)
Reference< XExecutableDialog > m_xDialog
static weld::MessageDialog * CreateMessageDialog(weld::Widget *pParent, VclMessageType eMessageType, VclButtonsType eButtonType, const OUString &rPrimaryMessage, const ILibreOfficeKitNotifier *pNotifier=nullptr)
std::unique_ptr< weld::Button > m_xTestButton
GraphicTestEntry(weld::Container *pParent, weld::Dialog *pDialog, OUString aTestName, OUString aTestStatus, Bitmap aTestBitmap)
std::unique_ptr< weld::Container > m_xContainer
std::unique_ptr< weld::Label > m_xTestLabel
weld::Dialog * m_xParentDialog
std::vector< VclTestResult > & getTestResults()
OUString getResultString(bool bLocalize=false)
void run(bool storeResultBitmap=false)
virtual short run() override
OUString m_xCreateFolderUrl
std::vector< std::unique_ptr< GraphicTestEntry > > m_xGraphicTestEntries
std::unique_ptr< weld::Button > m_xDownloadResults
GraphicsTestsDialog(weld::Container *pParent)
std::unique_ptr< weld::Box > m_xContainerBox
std::unique_ptr< weld::TextView > m_xResultLog
static const OUString & getUserProfileURL()
static bool deleteDirRecursively(const OUString &rDirURL)
void addFolderWithContent(css::uno::Reference< css::uno::XInterface > const &xRootFolder, const OUString &rDirURL)
css::uno::Reference< css::uno::XInterface > & getRootFolder()
std::shared_ptr< weld::Dialog > m_xDialog
constexpr ::Color COL_LIGHTRED(0xFF, 0x00, 0x00)
constexpr ::Color COL_YELLOW(0xFF, 0xFF, 0x00)
constexpr ::Color COL_LIGHTGRAY(0xC0, 0xC0, 0xC0)
constexpr ::Color COL_LIGHTGREEN(0x00, 0xFF, 0x00)
OUString CuiResId(TranslateId aKey)
#define LINK(Instance, Class, Member)
Reference< XComponentContext > getProcessComponentContext()
Reference< XNameAccess > m_xContainer
SVL_DLLPUBLIC OUString SvlResId(TranslateId sContextAndId)