summaryrefslogtreecommitdiff
path: root/sfx2
diff options
context:
space:
mode:
authorCaolán McNamara <caolanm@redhat.com>2018-06-17 21:19:46 +0100
committerCaolán McNamara <caolanm@redhat.com>2018-06-18 11:34:35 +0200
commit41012a1cc244cdc230120fce4b3a29e55b247b11 (patch)
tree4b28719fc9666fbc5df2515364e4f9fc6e8bdf1e /sfx2
parentc34f8c317e351859daba00a3e2150126636f8aa7 (diff)
weld SfxDocumentFontsPage
Change-Id: I09bb788455053c266ce18d21055157147668263e Reviewed-on: https://gerrit.libreoffice.org/55982 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
Diffstat (limited to 'sfx2')
-rw-r--r--sfx2/source/dialog/documentfontsdialog.cxx21
-rw-r--r--sfx2/source/inc/documentfontsdialog.hxx6
2 files changed, 9 insertions, 18 deletions
diff --git a/sfx2/source/dialog/documentfontsdialog.cxx b/sfx2/source/dialog/documentfontsdialog.cxx
index 77177c7f3eeb..7e5e7f51c6e9 100644
--- a/sfx2/source/dialog/documentfontsdialog.cxx
+++ b/sfx2/source/dialog/documentfontsdialog.cxx
@@ -23,26 +23,19 @@
using namespace ::com::sun::star;
-VclPtr<SfxTabPage> SfxDocumentFontsPage::Create(TabPageParent parent, const SfxItemSet* set)
+VclPtr<SfxTabPage> SfxDocumentFontsPage::Create(TabPageParent pParent, const SfxItemSet* set)
{
- return VclPtr<SfxDocumentFontsPage>::Create( parent.pParent, *set );
+ return VclPtr<SfxDocumentFontsPage>::Create(pParent, *set);
}
-SfxDocumentFontsPage::SfxDocumentFontsPage( vcl::Window* parent, const SfxItemSet& set )
- : SfxTabPage( parent, "DocumentFontsPage", "sfx/ui/documentfontspage.ui", &set )
+SfxDocumentFontsPage::SfxDocumentFontsPage(TabPageParent parent, const SfxItemSet& set)
+ : SfxTabPage(parent, "sfx/ui/documentfontspage.ui", "DocumentFontsPage", &set)
+ , embedFontsCheckbox(m_xBuilder->weld_check_button("embedFonts"))
{
- get( embedFontsCheckbox, "embedFonts" );
}
SfxDocumentFontsPage::~SfxDocumentFontsPage()
{
- disposeOnce();
-}
-
-void SfxDocumentFontsPage::dispose()
-{
- embedFontsCheckbox.clear();
- SfxTabPage::dispose();
}
void SfxDocumentFontsPage::Reset( const SfxItemSet* )
@@ -61,12 +54,12 @@ void SfxDocumentFontsPage::Reset( const SfxItemSet* )
{
}
}
- embedFontsCheckbox->Check( bVal );
+ embedFontsCheckbox->set_active(bVal);
}
bool SfxDocumentFontsPage::FillItemSet( SfxItemSet* )
{
- bool bVal = embedFontsCheckbox->IsChecked();
+ bool bVal = embedFontsCheckbox->get_active();
SfxObjectShell* pDocSh = SfxObjectShell::Current();
if ( pDocSh )
{
diff --git a/sfx2/source/inc/documentfontsdialog.hxx b/sfx2/source/inc/documentfontsdialog.hxx
index 486055954ab1..1bb9830483dc 100644
--- a/sfx2/source/inc/documentfontsdialog.hxx
+++ b/sfx2/source/inc/documentfontsdialog.hxx
@@ -20,7 +20,6 @@
#define INCLUDED_SFX2_SOURCE_INC_DOCUMENTFONTSDIALOG_HXX
#include <sfx2/tabdlg.hxx>
-#include <vcl/fixed.hxx>
/**
Tab page for document font settings in the document properties dialog.
@@ -28,15 +27,14 @@
class SfxDocumentFontsPage: public SfxTabPage
{
public:
- SfxDocumentFontsPage( vcl::Window* parent, const SfxItemSet& set );
+ SfxDocumentFontsPage(TabPageParent parent, const SfxItemSet& set);
virtual ~SfxDocumentFontsPage() override;
- virtual void dispose() override;
static VclPtr<SfxTabPage> Create(TabPageParent parent, const SfxItemSet* set);
protected:
virtual bool FillItemSet( SfxItemSet* set ) override;
virtual void Reset( const SfxItemSet* set ) override;
private:
- VclPtr<CheckBox> embedFontsCheckbox;
+ std::unique_ptr<weld::CheckButton> embedFontsCheckbox;
};
#endif