[Libreoffice-commits] .: 2 commits - officecfg/registry sc/inc sc/source sc/uiconfig
Markus Mohrhard
mmohrhard at kemper.freedesktop.org
Mon Sep 26 09:15:16 PDT 2011
officecfg/registry/data/org/openoffice/Office/UI/CalcCommands.xcu | 4 +-
sc/inc/globstr.hrc | 7 ++-
sc/source/ui/app/inputwin.cxx | 19 ++++++++--
sc/source/ui/src/globstr.src | 4 ++
sc/uiconfig/scalc/menubar/menubar.xml | 1
5 files changed, 29 insertions(+), 6 deletions(-)
New commits:
commit 2abdc04993e6b23d2c5514caca66371ff2df7bea
Author: Markus Mohrhard <markus.mohrhard at googlemail.com>
Date: Mon Sep 26 00:59:04 2011 +0200
Manage Names: adapt menu to changes
diff --git a/officecfg/registry/data/org/openoffice/Office/UI/CalcCommands.xcu b/officecfg/registry/data/org/openoffice/Office/UI/CalcCommands.xcu
index ce25934..3929f59 100644
--- a/officecfg/registry/data/org/openoffice/Office/UI/CalcCommands.xcu
+++ b/officecfg/registry/data/org/openoffice/Office/UI/CalcCommands.xcu
@@ -900,10 +900,10 @@
</node>
<node oor:name=".uno:DefineName" oor:op="replace">
<prop oor:name="Label" oor:type="xs:string">
- <value xml:lang="en-US">~Define Name...</value>
+ <value xml:lang="en-US">~Manage Names...</value>
</prop>
<prop oor:name="ContextLabel" oor:type="xs:string">
- <value xml:lang="en-US">~Define...</value>
+ <value xml:lang="en-US">~Manage...</value>
</prop>
<prop oor:name="Properties" oor:type="xs:int">
<value>1</value>
diff --git a/sc/uiconfig/scalc/menubar/menubar.xml b/sc/uiconfig/scalc/menubar/menubar.xml
index f595499..06f7652 100644
--- a/sc/uiconfig/scalc/menubar/menubar.xml
+++ b/sc/uiconfig/scalc/menubar/menubar.xml
@@ -165,6 +165,7 @@
<menu:menupopup>
<menu:menuitem menu:id=".uno:DefineName"/>
<menu:menuitem menu:id=".uno:InsertName"/>
+ <menu:menuseparator/>
<menu:menuitem menu:id=".uno:CreateNames"/>
<menu:menuitem menu:id=".uno:DefineLabelRange"/>
</menu:menupopup>
commit 74d3dd420bd80f88dd7e1078dd500aba8841aa44
Author: Markus Mohrhard <markus.mohrhard at googlemail.com>
Date: Mon Sep 26 00:34:14 2011 +0200
add "Manage Names..." entry to Name Box/ScPosWnd
diff --git a/sc/inc/globstr.hrc b/sc/inc/globstr.hrc
index 6717045..4e88a8e 100644
--- a/sc/inc/globstr.hrc
+++ b/sc/inc/globstr.hrc
@@ -588,8 +588,11 @@
#define STR_FORM_SPINNER 455
#define STR_FORM_SCROLLBAR 456
-#define STR_PGNUM 457
+#define STR_PGNUM 457
+
+#define STR_MANAGE_NAMES 458
+
+#define STR_COUNT 459
-#define STR_COUNT 458
#endif
diff --git a/sc/source/ui/app/inputwin.cxx b/sc/source/ui/app/inputwin.cxx
index 6c26f3d..1ae6f33 100644
--- a/sc/source/ui/app/inputwin.cxx
+++ b/sc/source/ui/app/inputwin.cxx
@@ -60,6 +60,7 @@
#include "scresid.hxx"
#include "sc.hrc"
#include "globstr.hrc"
+#include "reffact.hxx"
#include "editutil.hxx"
#include "inputhdl.hxx"
#include "tabvwsh.hxx"
@@ -95,7 +96,8 @@ enum ScNameInputType
SC_NAME_INPUT_SHEET,
SC_NAME_INPUT_DEFINE,
SC_NAME_INPUT_BAD_NAME,
- SC_NAME_INPUT_BAD_SELECTION
+ SC_NAME_INPUT_BAD_SELECTION,
+ SC_MANAGE_NAMES
};
@@ -1832,6 +1834,9 @@ void ScPosWnd::FillRangeNames()
{
ScDocument* pDoc = ((ScDocShell*)pObjSh)->GetDocument();
+ InsertEntry(ScGlobal::GetRscString( STR_MANAGE_NAMES ));
+ SetSeparatorPos(0);
+
ScRange aDummy;
std::set<rtl::OUString> aSet;
ScRangeName* pRangeNames = pDoc->GetRangeName();
@@ -1958,7 +1963,9 @@ ScNameInputType lcl_GetInputType( const String& rText )
SCTAB nNameTab;
sal_Int32 nNumeric;
- if ( aRange.Parse( rText, pDoc, eConv ) & SCA_VALID )
+ if (rText == ScGlobal::GetRscString(STR_MANAGE_NAMES))
+ eRet = SC_MANAGE_NAMES;
+ else if ( aRange.Parse( rText, pDoc, eConv ) & SCA_VALID )
eRet = SC_NAME_INPUT_RANGE;
else if ( aAddress.Parse( rText, pDoc, eConv ) & SCA_VALID )
eRet = SC_NAME_INPUT_CELL;
@@ -2118,6 +2125,14 @@ void ScPosWnd::DoEnter()
}
}
}
+ else if (eType == SC_MANAGE_NAMES)
+ {
+ sal_uInt16 nId = ScNameDlgWrapper::GetChildWindowId();
+ SfxViewFrame* pViewFrm = pViewSh->GetViewFrame();
+ SfxChildWindow* pWnd = pViewFrm->GetChildWindow( nId );
+
+ SC_MOD()->SetRefDialog( nId, pWnd ? false : sal_True );
+ }
else
{
// for all selection types, excecute the SID_CURRENTCELL slot.
diff --git a/sc/source/ui/src/globstr.src b/sc/source/ui/src/globstr.src
index fa9a9df..9a1a42f 100644
--- a/sc/source/ui/src/globstr.src
+++ b/sc/source/ui/src/globstr.src
@@ -1823,5 +1823,9 @@ Resource RID_GLOBSTR
{
Text [ en-US ] = "Insert Current Time";
};
+ String STR_MANAGE_NAMES
+ {
+ Text [ en-US ] = "Manage Names...";
+ };
};
More information about the Libreoffice-commits
mailing list