summaryrefslogtreecommitdiff
path: root/include/sfx2/tabdlg.hxx
diff options
context:
space:
mode:
authorNoel Grandin <noelgrandin@gmail.com>2016-06-05 15:15:56 +0200
committerNoel Grandin <noelgrandin@gmail.com>2016-06-06 07:02:20 +0000
commit11b4a6ddce31f173f10b703eb63fde2c88c0bc70 (patch)
tree5f635db51172fd421dffbcadfa021530634567cd /include/sfx2/tabdlg.hxx
parent7d1b01070c330d45212cd69ea692b2263c23c2a6 (diff)
Convert DeactivePage return code to scoped enum
Change-Id: Idd5372ad20fc6676864b31b3796f8b9bc0ad73dd Reviewed-on: https://gerrit.libreoffice.org/25918 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
Diffstat (limited to 'include/sfx2/tabdlg.hxx')
-rw-r--r--include/sfx2/tabdlg.hxx24
1 files changed, 14 insertions, 10 deletions
diff --git a/include/sfx2/tabdlg.hxx b/include/sfx2/tabdlg.hxx
index 1b3b63c5e4d6..8325722893a5 100644
--- a/include/sfx2/tabdlg.hxx
+++ b/include/sfx2/tabdlg.hxx
@@ -30,6 +30,7 @@
#include <svl/itempool.hxx>
#include <svl/itemset.hxx>
#include <com/sun/star/frame/XFrame.hpp>
+#include <o3tl/typed_flags_set.hxx>
class SfxPoolItem;
class SfxTabDialog;
@@ -201,6 +202,18 @@ public:
namespace sfx { class ItemConnectionBase; }
+enum class DeactivateRC {
+ KeepPage = 0x00, // Error handling; page does not change
+ // 2. Fill an itemset for update
+ // parent examples, this pointer can be NULL all the time!
+ LeavePage = 0x01,
+ // Set, refresh and update other Page
+ RefreshSet = 0x02
+};
+namespace o3tl {
+ template<> struct typed_flags<DeactivateRC> : is_typed_flags<DeactivateRC, 0x03> {};
+}
+
class SFX2_DLLPUBLIC SfxTabPage: public TabPage
{
friend class SfxTabDialog;
@@ -235,19 +248,10 @@ public:
void SetExchangeSupport()
{ bHasExchangeSupport = true; }
- enum sfxpg {
- KEEP_PAGE = 0x0000, // Error handling; page does not change
- // 2. Fill an itemset for update
- // parent examples, this pointer can be NULL all the time!
- LEAVE_PAGE = 0x0001,
- // Set, refresh and update other Page
- REFRESH_SET = 0x0002
- };
-
using TabPage::ActivatePage;
using TabPage::DeactivatePage;
virtual void ActivatePage( const SfxItemSet& );
- virtual sfxpg DeactivatePage( SfxItemSet* pSet );
+ virtual DeactivateRC DeactivatePage( SfxItemSet* pSet );
void SetUserData(const OUString& rString)
{ aUserString = rString; }
const OUString& GetUserData() { return aUserString; }