diff options
author | Kohei Yoshida <kohei.yoshida@gmail.com> | 2012-04-19 23:20:53 -0400 |
---|---|---|
committer | Kohei Yoshida <kohei.yoshida@gmail.com> | 2012-05-03 20:28:15 -0400 |
commit | 9b99bf09a25d9c9016a1c6b730fa0ef1cc5bc04a (patch) | |
tree | f9d2e1465b7fe07231907c5900ef82c6e851588d | |
parent | 326d255eaa2cde1d4ffff87a0a3a5074a326513f (diff) |
Initial skeleton for inserting a field into cell.
-rw-r--r-- | officecfg/registry/data/org/openoffice/Office/UI/CalcCommands.xcu | 5 | ||||
-rw-r--r-- | sc/inc/sc.hrc | 2 | ||||
-rw-r--r-- | sc/sdi/editsh.sdi | 2 | ||||
-rw-r--r-- | sc/sdi/scalc.sdi | 23 | ||||
-rw-r--r-- | sc/source/ui/src/popup.src | 16 | ||||
-rw-r--r-- | sc/source/ui/view/editsh.cxx | 7 |
6 files changed, 54 insertions, 1 deletions
diff --git a/officecfg/registry/data/org/openoffice/Office/UI/CalcCommands.xcu b/officecfg/registry/data/org/openoffice/Office/UI/CalcCommands.xcu index c41b80559342..c1f1aa30ea78 100644 --- a/officecfg/registry/data/org/openoffice/Office/UI/CalcCommands.xcu +++ b/officecfg/registry/data/org/openoffice/Office/UI/CalcCommands.xcu @@ -1514,6 +1514,11 @@ <value>1</value> </prop> </node> + <node oor:name=".uno:InsertFieldTest" oor:op="replace"> + <prop oor:name="Label" oor:type="xs:string"> + <value xml:lang="en-US">Insert Field Test</value> + </prop> + </node> </node> <node oor:name="Popups"> <node oor:name=".uno:AuditMenu" oor:op="replace"> diff --git a/sc/inc/sc.hrc b/sc/inc/sc.hrc index f8b187505f31..1e8b0330e1da 100644 --- a/sc/inc/sc.hrc +++ b/sc/inc/sc.hrc @@ -716,6 +716,7 @@ #define SID_DELETE_SCENARIO (SID_NEW_SLOTS+95) #define SID_EDIT_SCENARIO (SID_NEW_SLOTS+96) +#define SID_INSERT_FIELD_TEST (SID_NEW_SLOTS+97) // idl parameter @@ -771,6 +772,7 @@ #define RID_MEDIA_OBJECTBAR (SC_RESOURCE_START+60) #define RID_POPUP_MEDIA (SC_RESOURCE_START+61) #define RID_FUNCTION_CATEGORIES (SC_RESOURCE_START+62) +#define RID_MN_INSERT_FIELDS (SC_RESOURCE_START+63) #define STR_START (SC_RESOURCE_START+100) #define STR_ROWHEIGHT (STR_START) diff --git a/sc/sdi/editsh.sdi b/sc/sdi/editsh.sdi index 1d95f2debdc3..c896cc4bdc7c 100644 --- a/sc/sdi/editsh.sdi +++ b/sc/sdi/editsh.sdi @@ -98,6 +98,8 @@ interface TableText SID_INSERT_LRM [ ExecMethod = Execute; StateMethod = GetState; Export = FALSE; ] SID_INSERT_ZWSP [ ExecMethod = Execute; StateMethod = GetState; Export = FALSE; ] SID_INSERT_ZWNBSP [ ExecMethod = Execute; StateMethod = GetState; Export = FALSE; ] + + SID_INSERT_FIELD_TEST [ ExecMethod = Execute; StateMethod = GetState; ] } diff --git a/sc/sdi/scalc.sdi b/sc/sdi/scalc.sdi index 99976ec30ca2..9ca1858f4ec8 100644 --- a/sc/sdi/scalc.sdi +++ b/sc/sdi/scalc.sdi @@ -8001,3 +8001,26 @@ SfxVoidItem SetTabBgColor FID_TAB_MENU_SET_TAB_BG_COLOR GroupId = GID_FORMAT; ] +SfxVoidItem InsertFieldTest SID_INSERT_FIELD_TEST +() +[ + /* flags: */ + AutoUpdate = FALSE, + Cachable = Cachable, + FastCall = FALSE, + HasCoreId = FALSE, + HasDialog = FALSE, + ReadOnlyDoc = TRUE, + Toggle = FALSE, + Container = FALSE, + RecordAbsolute = FALSE, + RecordPerSet; + Synchron; + + /* config: */ + AccelConfig = TRUE, + MenuConfig = TRUE, + StatusBarConfig = FALSE, + ToolBoxConfig = FALSE, + GroupId = GID_OPTIONS; +] diff --git a/sc/source/ui/src/popup.src b/sc/source/ui/src/popup.src index 6e27ce38ac49..66e84bf61a64 100644 --- a/sc/source/ui/src/popup.src +++ b/sc/source/ui/src/popup.src @@ -430,6 +430,22 @@ Menu RID_POPUP_EDIT //------------------------------ MenuItem { + Text [ en-US ] = "Insert Fields" ; + Identifier = RID_MN_INSERT_FIELDS ; + SubMenu = Menu + { + ItemList = + { + MenuItem + { + Identifier = SID_INSERT_FIELD_TEST ; + Text [ en-US ] = "Test Field"; + }; + }; + }; + }; + MenuItem + { ITEM_FORMAT_CHAR_DLG }; //------------------------------ diff --git a/sc/source/ui/view/editsh.cxx b/sc/source/ui/view/editsh.cxx index 9f3dfe120497..8b05f33ce43b 100644 --- a/sc/source/ui/view/editsh.cxx +++ b/sc/source/ui/view/editsh.cxx @@ -614,6 +614,9 @@ void ScEditShell::Execute( SfxRequest& rReq ) case SID_INSERT_ZWNBSP: lclInsertCharacter( pTableView, pTopView, CHAR_ZWNBSP ); break; + case SID_INSERT_FIELD_TEST: + fprintf(stdout, "ScEditShell::Execute: SID_INSERT_FIELD_TEST\n"); + break; } pHdl->DataChanged(); @@ -714,7 +717,9 @@ void ScEditShell::GetState( SfxItemSet& rSet ) rSet.DisableItem( SID_THES ); } break; - + case SID_INSERT_FIELD_TEST: + fprintf(stdout, "ScEditShell::GetState: SID_INSERT_FIELD_TEST\n"); + break; } nWhich = aIter.NextWhich(); |