summaryrefslogtreecommitdiff
path: root/cui
diff options
context:
space:
mode:
Diffstat (limited to 'cui')
-rw-r--r--cui/source/dialogs/dlgname.cxx13
-rw-r--r--cui/source/inc/dlgname.hxx1
2 files changed, 14 insertions, 0 deletions
diff --git a/cui/source/dialogs/dlgname.cxx b/cui/source/dialogs/dlgname.cxx
index 6772f445f3ea..71bd359b150a 100644
--- a/cui/source/dialogs/dlgname.cxx
+++ b/cui/source/dialogs/dlgname.cxx
@@ -202,6 +202,19 @@ IMPL_LINK_NOARG_TYPED(SvxMessDialog, Button2Hdl, Button*, void)
/*************************************************************************/
+void SvxMessDialog::DisableButton( SvxMessDialogButton nBtnId )
+{
+ switch( nBtnId )
+ {
+ case SvxMessDialogButton::N1:
+ pBtn1->Disable();
+ break;
+ case SvxMessDialogButton::N2:
+ pBtn2->Disable();
+ break;
+ }
+}
+
void SvxMessDialog::SetButtonText( SvxMessDialogButton nBtnId, const OUString& rNewTxt )
{
switch ( nBtnId )
diff --git a/cui/source/inc/dlgname.hxx b/cui/source/inc/dlgname.hxx
index ac183a88e7fc..4b28ed5343bd 100644
--- a/cui/source/inc/dlgname.hxx
+++ b/cui/source/inc/dlgname.hxx
@@ -145,6 +145,7 @@ public:
SvxMessDialog( vcl::Window* pWindow, const OUString& rText, const OUString& rDesc, Image* pImg = nullptr );
virtual ~SvxMessDialog();
virtual void dispose() override;
+ void DisableButton( SvxMessDialogButton nBtnId);
void SetButtonText( SvxMessDialogButton nBtnId, const OUString& rNewTxt );
};