diff options
author | Tor Lillqvist <tml@iki.fi> | 2020-12-10 18:58:11 +0200 |
---|---|---|
committer | Tor Lillqvist <tml@iki.fi> | 2020-12-10 18:59:32 +0200 |
commit | 5b021965837252f48184d8441f5e19a944e3b287 (patch) | |
tree | 305dbc84cd81f26ae28f116d67d5000488e8e44e | |
parent | 4a4f0f6daa2ce1f4b4a99cdc9b86f48df5d961ea (diff) |
Add comments wondering what some magic numbers might mean
Change-Id: Iece65c9d96561abc0a97726cd4eb642317dc0f9c
-rw-r--r-- | sw/source/uibase/utlui/content.cxx | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/sw/source/uibase/utlui/content.cxx b/sw/source/uibase/utlui/content.cxx index 57ed667d3f98..54b84ee935d9 100644 --- a/sw/source/uibase/utlui/content.cxx +++ b/sw/source/uibase/utlui/content.cxx @@ -1177,6 +1177,9 @@ static bool lcl_InsertExpandCollapseAllItem(const weld::TreeView& rContentTree, static void lcl_SetOutlineContentEntriesSensitivities(SwContentTree* pThis, const weld::TreeView& rContentTree, const weld::TreeIter& rEntry, weld::Menu& rPop) { + // If anybody knows what these magic numbers mean, please either + // add a comment here, or replace them with some suitable symbolic + // names that are defined somewhere else. rPop.set_sensitive(OString::number(1512), false); rPop.set_sensitive(OString::number(1513), false); rPop.set_sensitive(OString::number(1514), false); @@ -1306,6 +1309,8 @@ IMPL_LINK(SwContentTree, CommandHdl, const CommandEvent&, rCEvt, bool) std::unique_ptr<weld::Menu> xSubPopOutlineTracking = xBuilder->weld_menu("outlinetracking"); std::unique_ptr<weld::Menu> xSubPopOutlineContent = xBuilder->weld_menu("outlinecontent"); + + // More magic numbers, huh. xSubPopOutlineContent->append(OUString::number(1512), SwResId(STR_OUTLINE_CONTENT_VISIBILITY_TOGGLE)); xSubPopOutlineContent->append(OUString::number(1513), SwResId(STR_OUTLINE_CONTENT_VISIBILITY_HIDE_ALL)); xSubPopOutlineContent->append(OUString::number(1514), SwResId(STR_OUTLINE_CONTENT_VISIBILITY_SHOW_ALL)); |