summaryrefslogtreecommitdiff
path: root/sw/inc
diff options
context:
space:
mode:
authorJan Holesovsky <kendy@collabora.com>2015-12-30 00:00:37 +0100
committerMiklos Vajna <vmiklos@collabora.co.uk>2016-03-18 09:13:56 +0100
commit16e248bec76f2c1587383d26581ecc8241c755f8 (patch)
treea468153e1583d66c46ca79ff5d1159737a9a76d0 /sw/inc
parent1f1cff03c4f15ee9fe7786a98ba8259a64823e0a (diff)
mailmerge: Implement toolbar controller to exclude entries.
This can be used as a "How to implement a custom widget / control in the toolbar" example: * the Controller.xcu change introduces a .uno:MailMergeExcludeEntry command so that it can be added in the toolbar .xml description (in this case mailmerge.xml) * the swriter.sdi introduces the .uno:MailMergeExcludeEntry command for the sfx2 handling - so that it can get notifications about enable/disable changes, invalidates, etc. * wrtapp.sdi + associated apphdl.cxx change make it possible to forward command invalidates (the rBindings.Invalidate(FN_MAILMERGE_EXCLUDE_ENTRY);) to the MMExcludeEntryController::statusChanged() for further handling (in this case setting the checked state according to the current data) * MMExcludeEntryController::createItemWindow() implements the custom widget itself (in this case a checkbox, but can be any VCL widget, even a custom one) * the rest (sw.component and the associated getImplementationName(), supportsService(), etc.) takes care of the instantiation of the controller. Change-Id: I68269538f779a6680b0ba98395b7985d3f1ab95a
Diffstat (limited to 'sw/inc')
-rw-r--r--sw/inc/cmdid.h1
-rw-r--r--sw/inc/dbui.hrc2
2 files changed, 2 insertions, 1 deletions
diff --git a/sw/inc/cmdid.h b/sw/inc/cmdid.h
index 908d5c8e3893..0bb0cd469725 100644
--- a/sw/inc/cmdid.h
+++ b/sw/inc/cmdid.h
@@ -256,6 +256,7 @@
#define FN_MAILMERGE_PREV_ENTRY (FN_INSERT + 71) /* mail merge toolbar - go to the previous entry */
#define FN_MAILMERGE_NEXT_ENTRY (FN_INSERT + 72) /* mail merge toolbar - go to the next entry */
#define FN_MAILMERGE_LAST_ENTRY (FN_INSERT + 73) /* mail merge toolbar - go to the next entry */
+#define FN_MAILMERGE_EXCLUDE_ENTRY (FN_INSERT + 75) /* mail merge toolbar - checkbox to exclude the current entry */
#define FN_DRAWTEXT_ATTR_DLG (FN_INSERT + 76) /* position DrawText */
diff --git a/sw/inc/dbui.hrc b/sw/inc/dbui.hrc
index 8aeb2c7c509a..9bb616852b86 100644
--- a/sw/inc/dbui.hrc
+++ b/sw/inc/dbui.hrc
@@ -81,7 +81,7 @@
#define ST_LAYOUT (RC_DBUI_BEGIN + 56)
#define ST_PREPAREMERGE (RC_DBUI_BEGIN + 57)
#define ST_MERGE (RC_DBUI_BEGIN + 58)
-#define ST_OUTPUT (RC_DBUI_BEGIN + 59)
+#define ST_EXCLUDE (RC_DBUI_BEGIN + 59)
#define ST_FINISH (RC_DBUI_BEGIN + 60)
#define ST_ADDRESSLIST (RC_DBUI_BEGIN + 61)