summaryrefslogtreecommitdiff
path: root/chart2
diff options
context:
space:
mode:
authorRafael Dominguez <venccsralph@gmail.com>2012-03-16 17:17:58 +0000
committerMarkus Mohrhard <markus.mohrhard@googlemail.com>2012-03-23 02:55:30 +0100
commit34cadd6397c6d1767bba431450976d4f4f0b100c (patch)
tree62018e3d3976f7b9d0313276de00221c46f2d652 /chart2
parent701efd06e852c7fa956205cf59154a39621b31a4 (diff)
Specialize STR_OBJECT_ERROR_BARS for each errobar type.
Diffstat (limited to 'chart2')
-rw-r--r--chart2/source/controller/dialogs/ObjectNameProvider.cxx8
-rw-r--r--chart2/source/controller/dialogs/Strings.src14
-rw-r--r--chart2/source/controller/main/ChartController_Insert.cxx3
-rw-r--r--chart2/source/controller/main/ChartController_Tools.cxx2
-rw-r--r--chart2/source/inc/Strings.hrc6
5 files changed, 23 insertions, 10 deletions
diff --git a/chart2/source/controller/dialogs/ObjectNameProvider.cxx b/chart2/source/controller/dialogs/ObjectNameProvider.cxx
index cc9e6f6c740c..8ede4c949aef 100644
--- a/chart2/source/controller/dialogs/ObjectNameProvider.cxx
+++ b/chart2/source/controller/dialogs/ObjectNameProvider.cxx
@@ -284,16 +284,16 @@ rtl::OUString ObjectNameProvider::getName( ObjectType eObjectType, bool bPlural
aRet=String(SchResId(STR_OBJECT_LABEL));
break;
case OBJECTTYPE_DATA_ERRORS:
- aRet=String(SchResId(STR_OBJECT_ERROR_BARS));//@todo? maybe distinguish plural singular
+ aRet=String(SchResId(STR_OBJECT_ERROR_BARS_Y));
break;
case OBJECTTYPE_DATA_ERRORS_X:
- aRet=String(SchResId(STR_OBJECT_ERROR_BARS));//@todo? maybe specialize in future
+ aRet=String(SchResId(STR_OBJECT_ERROR_BARS_X));
break;
case OBJECTTYPE_DATA_ERRORS_Y:
- aRet=String(SchResId(STR_OBJECT_ERROR_BARS));//@todo? maybe specialize in future
+ aRet=String(SchResId(STR_OBJECT_ERROR_BARS_Y));
break;
case OBJECTTYPE_DATA_ERRORS_Z:
- aRet=String(SchResId(STR_OBJECT_ERROR_BARS));//@todo? maybe specialize in future
+ aRet=String(SchResId(STR_OBJECT_ERROR_BARS_Z));
break;
case OBJECTTYPE_DATA_AVERAGE_LINE:
aRet=String(SchResId(STR_OBJECT_AVERAGE_LINE));
diff --git a/chart2/source/controller/dialogs/Strings.src b/chart2/source/controller/dialogs/Strings.src
index 5a3a500ff849..067c106fa874 100644
--- a/chart2/source/controller/dialogs/Strings.src
+++ b/chart2/source/controller/dialogs/Strings.src
@@ -331,9 +331,19 @@ String STR_OBJECT_CURVE_EQUATION
Text[ en-US ] = "Equation";
};
-String STR_OBJECT_ERROR_BARS
+String STR_OBJECT_ERROR_BARS_X
{
- Text [ en-US ] = "Error Bars";
+ Text [ en-US ] = "X Error Bars";
+};
+
+String STR_OBJECT_ERROR_BARS_Y
+{
+ Text [ en-US ] = "Y Error Bars";
+};
+
+String STR_OBJECT_ERROR_BARS_Z
+{
+ Text [ en-US ] = "Z Error Bars";
};
String STR_OBJECT_STOCK_LOSS
{
diff --git a/chart2/source/controller/main/ChartController_Insert.cxx b/chart2/source/controller/main/ChartController_Insert.cxx
index 9fc38dda011e..c4efa902fd44 100644
--- a/chart2/source/controller/main/ChartController_Insert.cxx
+++ b/chart2/source/controller/main/ChartController_Insert.cxx
@@ -484,7 +484,8 @@ void ChartController::executeDispatch_InsertErrorBars( bool bYError )
{
UndoLiveUpdateGuard aUndoGuard(
ActionDescriptionProvider::createDescription(
- ActionDescriptionProvider::INSERT, String( SchResId( STR_OBJECT_ERROR_BARS ))),
+ ActionDescriptionProvider::INSERT,
+ String( SchResId( bYError ? STR_OBJECT_ERROR_BARS_Y : STR_OBJECT_ERROR_BARS_X ))),
m_xUndoManager );
// add error bars with standard deviation
diff --git a/chart2/source/controller/main/ChartController_Tools.cxx b/chart2/source/controller/main/ChartController_Tools.cxx
index e1a22797157d..9da159cffee5 100644
--- a/chart2/source/controller/main/ChartController_Tools.cxx
+++ b/chart2/source/controller/main/ChartController_Tools.cxx
@@ -723,7 +723,7 @@ bool ChartController::executeDispatch_Delete()
// using assignment for broken gcc 3.3
UndoGuard aUndoGuard = UndoGuard(
ActionDescriptionProvider::createDescription(
- ActionDescriptionProvider::DELETE, String( SchResId( STR_OBJECT_ERROR_BARS ))),
+ ActionDescriptionProvider::DELETE, String( SchResId( STR_OBJECT_ERROR_BARS_Y ))),
m_xUndoManager );
{
ControllerLockGuard aCtlLockGuard( xModel );
diff --git a/chart2/source/inc/Strings.hrc b/chart2/source/inc/Strings.hrc
index e1af6d6b223b..82f69377b27a 100644
--- a/chart2/source/inc/Strings.hrc
+++ b/chart2/source/inc/Strings.hrc
@@ -30,7 +30,7 @@
// this includes no link dependency
#include <svl/solar.hrc>
-//next free is 295
+//next free is 297
//single free: 139
//-----------------------------------------------------------------------------
@@ -179,7 +179,9 @@
#define STR_OBJECT_FOR_ALL_SERIES (RID_APP_START + 289)
#define STR_OBJECT_AVERAGE_LINE (RID_APP_START + 174)
-#define STR_OBJECT_ERROR_BARS (RID_APP_START + 175)
+#define STR_OBJECT_ERROR_BARS_X (RID_APP_START + 175)
+#define STR_OBJECT_ERROR_BARS_Y (RID_APP_START + 295)
+#define STR_OBJECT_ERROR_BARS_Z (RID_APP_START + 296)
#define STR_OBJECT_CURVE (RID_APP_START + 176)
#define STR_OBJECT_CURVES (RID_APP_START + 130)