summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMaxim Monastirsky <momonasmon@gmail.com>2015-12-18 13:19:28 +0200
committerMaxim Monastirsky <momonasmon@gmail.com>2015-12-18 13:26:38 +0200
commit8a664fd83f70282d000aaedc626f1fa09a99161e (patch)
tree24e4a72551000b3e0393c0daecff58b64f60a3df
parent3b685bffc9af809109ee777f2d5a29cd907c7faa (diff)
tdf#93837 Convert RID_POPUP_TAB to xml
Change-Id: Ia05fb0a568c29d7990a8a837e1df953358acfa1f
-rw-r--r--officecfg/registry/data/org/openoffice/Office/UI/CalcCommands.xcu6
-rw-r--r--officecfg/registry/data/org/openoffice/Office/UI/CalcWindowState.xcu5
-rw-r--r--sc/AllLangResTarget_sc.mk1
-rw-r--r--sc/UIConfig_scalc.mk1
-rw-r--r--sc/inc/sc.hrc23
-rw-r--r--sc/inc/sccommands.h12
-rw-r--r--sc/source/ui/src/popup.src123
-rw-r--r--sc/source/ui/view/tabcont.cxx2
-rw-r--r--sc/uiconfig/scalc/popupmenu/sheettab.xml31
9 files changed, 55 insertions, 149 deletions
diff --git a/officecfg/registry/data/org/openoffice/Office/UI/CalcCommands.xcu b/officecfg/registry/data/org/openoffice/Office/UI/CalcCommands.xcu
index 4da1213d07f1..ff1091f85c0d 100644
--- a/officecfg/registry/data/org/openoffice/Office/UI/CalcCommands.xcu
+++ b/officecfg/registry/data/org/openoffice/Office/UI/CalcCommands.xcu
@@ -1602,6 +1602,9 @@
<prop oor:name="Label" oor:type="xs:string">
<value xml:lang="en-US">Sheet ~Tab Color...</value>
</prop>
+ <prop oor:name="PopupLabel" oor:type="xs:string">
+ <value xml:lang="en-US">~Tab Color...</value>
+ </prop>
</node>
<node oor:name=".uno:TabBgColor" oor:op="replace">
<prop oor:name="Label" oor:type="xs:string">
@@ -1826,6 +1829,9 @@
<prop oor:name="ContextLabel" oor:type="xs:string">
<value xml:lang="en-US">R~ight-To-Left</value>
</prop>
+ <prop oor:name="PopupLabel" oor:type="xs:string">
+ <value xml:lang="en-US">Sheet R~ight-To-Left</value>
+ </prop>
</node>
<node oor:name=".uno:SetAnchorToPage" oor:op="replace">
<prop oor:name="Label" oor:type="xs:string">
diff --git a/officecfg/registry/data/org/openoffice/Office/UI/CalcWindowState.xcu b/officecfg/registry/data/org/openoffice/Office/UI/CalcWindowState.xcu
index 64caade0503b..9adc27edb95b 100644
--- a/officecfg/registry/data/org/openoffice/Office/UI/CalcWindowState.xcu
+++ b/officecfg/registry/data/org/openoffice/Office/UI/CalcWindowState.xcu
@@ -85,6 +85,11 @@
<value xml:lang="en-US">Print Preview</value>
</prop>
</node>
+ <node oor:name="private:resource/popupmenu/sheettab" oor:op="replace">
+ <prop oor:name="UIName" oor:type="xs:string">
+ <value xml:lang="en-US">Sheet Tabs Bar</value>
+ </prop>
+ </node>
<node oor:name="private:resource/toolbar/graffilterbar" oor:op="replace">
<prop oor:name="Docked" oor:type="xs:boolean">
<value>false</value>
diff --git a/sc/AllLangResTarget_sc.mk b/sc/AllLangResTarget_sc.mk
index 11dffec306ae..57035f01c56a 100644
--- a/sc/AllLangResTarget_sc.mk
+++ b/sc/AllLangResTarget_sc.mk
@@ -33,7 +33,6 @@ $(eval $(call gb_SrsTarget_set_include,sc/res,\
))
$(eval $(call gb_SrsTarget_add_files,sc/res,\
- sc/source/ui/src/popup.src \
sc/source/ui/src/globstr.src \
sc/source/ui/src/toolbox.src \
sc/source/ui/src/scfuncs.src \
diff --git a/sc/UIConfig_scalc.mk b/sc/UIConfig_scalc.mk
index c1246659d7f1..f5ec631e1264 100644
--- a/sc/UIConfig_scalc.mk
+++ b/sc/UIConfig_scalc.mk
@@ -33,6 +33,7 @@ $(eval $(call gb_UIConfig_add_popupmenufiles,modules/scalc,\
sc/uiconfig/scalc/popupmenu/pagebreak \
sc/uiconfig/scalc/popupmenu/pivot \
sc/uiconfig/scalc/popupmenu/preview \
+ sc/uiconfig/scalc/popupmenu/sheettab \
))
$(eval $(call gb_UIConfig_add_statusbarfiles,modules/scalc,\
diff --git a/sc/inc/sc.hrc b/sc/inc/sc.hrc
index 4241157e9587..e9a5f61c3797 100644
--- a/sc/inc/sc.hrc
+++ b/sc/inc/sc.hrc
@@ -411,18 +411,17 @@
#define DATA_MENU_END (DATA_MENU_START + 29)
#define TAB_POPUP_START (DATA_MENU_END)
-#define RID_POPUP_TAB (TAB_POPUP_START)
-#define FID_TAB_MENU_RENAME (TAB_POPUP_START+1)
-#define FID_TAB_RENAME (TAB_POPUP_START+2)
-#define FID_TAB_MOVE (TAB_POPUP_START+3)
-#define FID_TAB_SELECTALL (TAB_POPUP_START+4)
-#define FID_TAB_APPEND (TAB_POPUP_START+5)
-#define FID_TAB_INDEX (TAB_POPUP_START+6)
-#define FID_TAB_RTL (TAB_POPUP_START+7)
-#define FID_TAB_DESELECTALL (TAB_POPUP_START+8)
-#define FID_TAB_MENU_SET_TAB_BG_COLOR (TAB_POPUP_START + 9)
-#define FID_TAB_SET_TAB_BG_COLOR (TAB_POPUP_START + 10)
-#define FID_TAB_EVENTS (TAB_POPUP_START+11)
+#define FID_TAB_MENU_RENAME (TAB_POPUP_START)
+#define FID_TAB_RENAME (TAB_POPUP_START+1)
+#define FID_TAB_MOVE (TAB_POPUP_START+2)
+#define FID_TAB_SELECTALL (TAB_POPUP_START+3)
+#define FID_TAB_APPEND (TAB_POPUP_START+4)
+#define FID_TAB_INDEX (TAB_POPUP_START+5)
+#define FID_TAB_RTL (TAB_POPUP_START+6)
+#define FID_TAB_DESELECTALL (TAB_POPUP_START+7)
+#define FID_TAB_MENU_SET_TAB_BG_COLOR (TAB_POPUP_START + 8)
+#define FID_TAB_SET_TAB_BG_COLOR (TAB_POPUP_START + 9)
+#define FID_TAB_EVENTS (TAB_POPUP_START+10)
#define TAB_POPUP_END (TAB_POPUP_START + 20)
diff --git a/sc/inc/sccommands.h b/sc/inc/sccommands.h
index 009621f4a5d2..706555d44511 100644
--- a/sc/inc/sccommands.h
+++ b/sc/inc/sccommands.h
@@ -24,10 +24,8 @@
#define CMD_SID_DEL_COLS ".uno:DeleteColumns"
#define CMD_SID_DEL_ROWS ".uno:DeleteRows"
#define CMD_FID_CELL_FORMAT ".uno:FormatCellDialog"
-#define CMD_FID_TABLE_HIDE ".uno:Hide"
#define CMD_FID_COL_HIDE ".uno:HideColumn"
#define CMD_FID_ROW_HIDE ".uno:HideRow"
-#define CMD_FID_INS_TABLE ".uno:Insert"
#define CMD_FID_INS_COLUMNS_AFTER ".uno:InsertColumnsAfter"
#define CMD_FID_INS_COLUMN ".uno:InsertColumns"
#define CMD_FID_INS_COLUMNS_BEFORE ".uno:InsertColumnsBefore"
@@ -35,22 +33,12 @@
#define CMD_FID_INS_ROW ".uno:InsertRows"
#define CMD_FID_INS_ROWS_BEFORE ".uno:InsertRowsBefore"
#define CMD_SID_OBJECT_MIRROR ".uno:Mirror"
-#define CMD_FID_TAB_MOVE ".uno:Move"
-#define CMD_FID_PROTECT_TABLE ".uno:Protect"
-#define CMD_FID_DELETE_TABLE ".uno:Remove"
#define CMD_FID_ROW_HEIGHT ".uno:RowHeight"
#define CMD_FID_COL_OPT_WIDTH ".uno:SetOptimalColumnWidth"
#define CMD_FID_ROW_OPT_HEIGHT ".uno:SetOptimalRowHeight"
-#define CMD_FID_TABLE_SHOW ".uno:Show"
#define CMD_FID_COL_SHOW ".uno:ShowColumn"
#define CMD_FID_ROW_SHOW ".uno:ShowRow"
-#define CMD_FID_TAB_MENU_RENAME ".uno:RenameTable"
-#define CMD_FID_TAB_SELECTALL ".uno:TableSelectAll"
-#define CMD_FID_TAB_DESELECTALL ".uno:TableDeselectAll"
#define CMD_SID_ULINE_VAL_DOUBLE ".uno:UnderlineDouble"
-#define CMD_FID_TAB_RTL ".uno:SheetRightToLeft"
-#define CMD_FID_TAB_EVENTS ".uno:TableEvents"
-#define CMD_FID_TAB_MENU_SET_TAB_BG_COLOR ".uno:SetTabBgColor"
#define CMD_FID_TAB_SET_TAB_BG_COLOR ".uno:TabBgColor"
#endif
diff --git a/sc/source/ui/src/popup.src b/sc/source/ui/src/popup.src
deleted file mode 100644
index b506e027e523..000000000000
--- a/sc/source/ui/src/popup.src
+++ /dev/null
@@ -1,123 +0,0 @@
-/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
-/*
- * This file is part of the LibreOffice project.
- *
- * This Source Code Form is subject to the terms of the Mozilla Public
- * License, v. 2.0. If a copy of the MPL was not distributed with this
- * file, You can obtain one at http://mozilla.org/MPL/2.0/.
- *
- * This file incorporates work covered by the following license notice:
- *
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements. See the NOTICE file distributed
- * with this work for additional information regarding copyright
- * ownership. The ASF licenses this file to you under the Apache
- * License, Version 2.0 (the "License"); you may not use this file
- * except in compliance with the License. You may obtain a copy of
- * the License at http://www.apache.org/licenses/LICENSE-2.0 .
- */
-
-#include "sc.hrc"
-#include <svx/globlmn.hrc>
-
- // Popup-Menues ----------------------------------------------------------------
-
-String RID_POPUP_TAB
-{
- Text [ en-US ] = "Sheet bar pop-up menu" ;
-};
-
-Menu RID_POPUP_TAB
-{
- ItemList =
- {
- MenuItem
- {
- Identifier = FID_INS_TABLE ;
- HelpId = CMD_FID_INS_TABLE ;
- Text [ en-US ] = "~Insert Sheet..." ;
- };
- MenuItem
- {
- Identifier = FID_DELETE_TABLE ;
- HelpId = CMD_FID_DELETE_TABLE ;
- Text [ en-US ] = "~Delete Sheet..." ;
- };
- MenuItem
- {
- Identifier = FID_TAB_MENU_RENAME ;
- HelpId = CMD_FID_TAB_MENU_RENAME ;
- Text [ en-US ] = "~Rename Sheet..." ;
- };
- MenuItem
- {
- Identifier = FID_TAB_MOVE ;
- HelpId = CMD_FID_TAB_MOVE ;
- Text [ en-US ] = "~Move/Copy Sheet..." ;
- };
-
- MenuItem { Separator = TRUE ; };
-
- MenuItem
- {
- Identifier = FID_TAB_MENU_SET_TAB_BG_COLOR ;
- HelpId = CMD_FID_TAB_MENU_SET_TAB_BG_COLOR ;
- Text [ en-US ] = "~Tab Color..." ;
- };
- MenuItem
- {
- Identifier = FID_PROTECT_TABLE ;
- HelpId = CMD_FID_PROTECT_TABLE ;
- Text [ en-US ] = "~Protect Sheet..." ;
- };
- MenuItem
- {
- Identifier = FID_TAB_TOGGLE_GRID ;
- Text [ en-US ] = "Sheet ~Gridlines" ;
- };
- MenuItem
- {
- Identifier = FID_TAB_RTL ;
- HelpId = CMD_FID_TAB_RTL ;
- Text [ en-US ] = "S~heet Right-To-Left" ;
- };
- MenuItem
- {
- Identifier = FID_TAB_EVENTS ;
- HelpId = CMD_FID_TAB_EVENTS ;
- Text [ en-US ] = "Sheet E~vents..." ;
- };
-
- MenuItem { Separator = TRUE ; };
-
- MenuItem
- {
- Identifier = FID_TABLE_HIDE ;
- HelpId = CMD_FID_TABLE_HIDE ;
- Text [ en-US ] = "~Hide" ;
- };
- MenuItem
- {
- Identifier = FID_TABLE_SHOW ;
- HelpId = CMD_FID_TABLE_SHOW ;
- Text [ en-US ] = "~Show..." ;
- };
-
- MenuItem { Separator = TRUE ; };
-
- MenuItem
- {
- Identifier = FID_TAB_SELECTALL ;
- HelpId = CMD_FID_TAB_SELECTALL ;
- Text [ en-US ] = "Select All S~heets" ;
- };
- MenuItem
- {
- Identifier = FID_TAB_DESELECTALL ;
- HelpId = CMD_FID_TAB_DESELECTALL ;
- Text [ en-US ] = "D~eselect All Sheets" ;
- };
- };
-};
-
-/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sc/source/ui/view/tabcont.cxx b/sc/source/ui/view/tabcont.cxx
index 70fecfa92c0c..7926f724d16a 100644
--- a/sc/source/ui/view/tabcont.cxx
+++ b/sc/source/ui/view/tabcont.cxx
@@ -430,7 +430,7 @@ void ScTabControl::Command( const CommandEvent& rCEvt )
// Popup-Menu:
// get Dispatcher from ViewData (ViewFrame) instead of Shell (Frame), so it can't be null
- pViewData->GetDispatcher().ExecutePopup( ScResId(RID_POPUP_TAB) );
+ pViewData->GetDispatcher().ExecutePopup( "sheettab" );
}
}
diff --git a/sc/uiconfig/scalc/popupmenu/sheettab.xml b/sc/uiconfig/scalc/popupmenu/sheettab.xml
new file mode 100644
index 000000000000..fea1a32da913
--- /dev/null
+++ b/sc/uiconfig/scalc/popupmenu/sheettab.xml
@@ -0,0 +1,31 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ * This file is part of the LibreOffice project.
+ *
+ * This Source Code Form is subject to the terms of the Mozilla Public
+ * License, v. 2.0. If a copy of the MPL was not distributed with this
+ * file, You can obtain one at http://mozilla.org/MPL/2.0/.
+ *
+-->
+<menu:menupopup xmlns:menu="http://openoffice.org/2001/menu">
+ <menu:menuitem menu:id=".uno:Cut"/>
+ <menu:menuitem menu:id=".uno:Copy"/>
+ <menu:menuitem menu:id=".uno:Paste"/>
+ <menu:menuseparator/>
+ <menu:menuitem menu:id=".uno:Insert"/>
+ <menu:menuitem menu:id=".uno:Remove"/>
+ <menu:menuitem menu:id=".uno:RenameTable"/>
+ <menu:menuitem menu:id=".uno:Move"/>
+ <menu:menuseparator/>
+ <menu:menuitem menu:id=".uno:SetTabBgColor"/>
+ <menu:menuitem menu:id=".uno:Protect"/>
+ <menu:menuitem menu:id=".uno:ToggleSheetGrid"/>
+ <menu:menuitem menu:id=".uno:SheetRightToLeft"/>
+ <menu:menuitem menu:id=".uno:TableEvents"/>
+ <menu:menuseparator/>
+ <menu:menuitem menu:id=".uno:Hide"/>
+ <menu:menuitem menu:id=".uno:Show"/>
+ <menu:menuseparator/>
+ <menu:menuitem menu:id=".uno:TableSelectAll"/>
+ <menu:menuitem menu:id=".uno:TableDeselectAll"/>
+</menu:menupopup>