[Libreoffice-commits] .: Branch 'libreoffice-3-4' - sc/source
Kohei Yoshida
kohei at kemper.freedesktop.org
Tue May 3 14:17:45 PDT 2011
sc/source/ui/dbgui/pvlaydlg.cxx | 13 +++++++++++++
1 file changed, 13 insertions(+)
New commits:
commit ae86fba1c98b16e0d98258d35265fd3ab50af710
Author: Kohei Yoshida <kyoshida at novell.com>
Date: Tue May 3 17:16:41 2011 -0400
fdo#36721: Fixed a crash on datapilot while editing the source range.
diff --git a/sc/source/ui/dbgui/pvlaydlg.cxx b/sc/source/ui/dbgui/pvlaydlg.cxx
index 0ff9928..6616595 100644
--- a/sc/source/ui/dbgui/pvlaydlg.cxx
+++ b/sc/source/ui/dbgui/pvlaydlg.cxx
@@ -1450,11 +1450,24 @@ void ScDPLayoutDlg::UpdateSrcRange()
switch (eSrcType)
{
case SRC_REF:
+ {
// data source is a range reference.
if (inSheet.GetSourceRange() == aNewRange)
// new range is identical to the current range. Nothing to do.
return;
inSheet.SetSourceRange(aNewRange);
+ sal_uLong nError = inSheet.CheckSourceRange();
+ if (nError)
+ {
+ // The error number corresponds with string ID for the error
+ // message. In the future we should display the error message
+ // somewhere in the dialog to let the user know of the reason
+ // for error.
+ aEdInPos.SetRefValid(false);
+ aBtnOk.Disable();
+ return;
+ }
+ }
break;
case SRC_NAME:
// data source is a range name.
More information about the Libreoffice-commits
mailing list