[Libreoffice-commits] core.git: 12 commits - basctl/source basic/source connectivity/source cui/source editeng/source filter/source forms/source fpicker/source idl/inc include/basic include/editeng scripting/source sc/source sd/source sfx2/source sw/source vbahelper/source
Noel Grandin
noel at peralex.com
Mon Jul 27 23:36:18 PDT 2015
basctl/source/basicide/baside2b.cxx | 4
basctl/source/basicide/basobj2.cxx | 2
basic/source/basmgr/basicmanagerrepository.cxx | 2
basic/source/basmgr/basmgr.cxx | 22 -
basic/source/classes/eventatt.cxx | 8
basic/source/classes/propacc.cxx | 2
basic/source/classes/sb.cxx | 354 ++++++++++++------------
basic/source/classes/sb.src | 240 ++++++++--------
basic/source/classes/sbunoobj.cxx | 52 +--
basic/source/classes/sbxmod.cxx | 64 ++--
basic/source/comp/buffer.cxx | 4
basic/source/comp/codegen.cxx | 14
basic/source/comp/dim.cxx | 92 +++---
basic/source/comp/exprgen.cxx | 4
basic/source/comp/exprnode.cxx | 14
basic/source/comp/exprtree.cxx | 44 +-
basic/source/comp/io.cxx | 16 -
basic/source/comp/loops.cxx | 36 +-
basic/source/comp/parser.cxx | 66 ++--
basic/source/comp/sbcomp.cxx | 12
basic/source/comp/scanner.cxx | 26 -
basic/source/comp/symtbl.cxx | 8
basic/source/comp/token.cxx | 2
basic/source/inc/runtime.hxx | 2
basic/source/runtime/ddectrl.cxx | 54 +--
basic/source/runtime/dllmgr-x64.cxx | 4
basic/source/runtime/dllmgr-x86.cxx | 4
basic/source/runtime/inputbox.cxx | 4
basic/source/runtime/iosys.cxx | 38 +-
basic/source/runtime/methods.cxx | 346 +++++++++++------------
basic/source/runtime/methods1.cxx | 220 +++++++-------
basic/source/runtime/runtime.cxx | 226 +++++++--------
basic/source/runtime/stdobj.cxx | 4
basic/source/runtime/stdobj1.cxx | 52 +--
basic/source/sbx/sbxarray.cxx | 70 ++--
basic/source/sbx/sbxbase.cxx | 28 -
basic/source/sbx/sbxbool.cxx | 14
basic/source/sbx/sbxbyte.cxx | 44 +-
basic/source/sbx/sbxchar.cxx | 38 +-
basic/source/sbx/sbxcoll.cxx | 34 +-
basic/source/sbx/sbxcurr.cxx | 48 +--
basic/source/sbx/sbxdate.cxx | 46 +--
basic/source/sbx/sbxdbl.cxx | 58 +--
basic/source/sbx/sbxdec.cxx | 42 +-
basic/source/sbx/sbxexec.cxx | 16 -
basic/source/sbx/sbxint.cxx | 142 ++++-----
basic/source/sbx/sbxlng.cxx | 48 +--
basic/source/sbx/sbxobj.cxx | 32 +-
basic/source/sbx/sbxscan.cxx | 16 -
basic/source/sbx/sbxsng.cxx | 54 +--
basic/source/sbx/sbxstr.cxx | 12
basic/source/sbx/sbxuint.cxx | 46 +--
basic/source/sbx/sbxulng.cxx | 38 +-
basic/source/sbx/sbxvalue.cxx | 132 ++++----
basic/source/sbx/sbxvar.cxx | 20 -
connectivity/source/inc/propertyids.hxx | 20 -
cui/source/customize/cfgutil.cxx | 42 +-
cui/source/dialogs/scriptdlg.cxx | 14
cui/source/inc/cfgutil.hxx | 19 -
cui/source/inc/scriptdlg.hxx | 12
editeng/source/editeng/editeng.cxx | 3
editeng/source/editeng/editview.cxx | 2
editeng/source/editeng/impedit.cxx | 18 -
editeng/source/editeng/impedit.hxx | 3
filter/source/graphicfilter/icgm/chart.hxx | 7
forms/source/richtext/richtextimplcontrol.cxx | 4
fpicker/source/office/OfficeFilePicker.cxx | 3
fpicker/source/office/fpdialogbase.hxx | 1
idl/inc/bastype.hxx | 3
include/basic/sberrors.hxx | 130 --------
include/basic/sbx.hxx | 2
include/basic/sbxcore.hxx | 14
include/basic/sbxdef.hxx | 95 +-----
include/editeng/editdata.hxx | 18 -
include/editeng/editview.hxx | 10
sc/source/ui/docshell/docsh4.cxx | 6
sc/source/ui/vba/vbaapplication.cxx | 6
sc/source/ui/vba/vbaaxes.cxx | 4
sc/source/ui/vba/vbaaxis.cxx | 50 +--
sc/source/ui/vba/vbachart.cxx | 32 +-
sc/source/ui/vba/vbachartobject.cxx | 6
sc/source/ui/vba/vbachartobjects.cxx | 2
sc/source/ui/vba/vbacondition.cxx | 2
sc/source/ui/vba/vbaformat.cxx | 54 +--
sc/source/ui/vba/vbaformatcondition.cxx | 8
sc/source/ui/vba/vbaformatconditions.cxx | 16 -
sc/source/ui/vba/vbapagebreak.cxx | 2
sc/source/ui/vba/vbapagebreaks.cxx | 4
sc/source/ui/vba/vbapagesetup.cxx | 8
sc/source/ui/vba/vbarange.cxx | 30 +-
sc/source/ui/vba/vbastyle.cxx | 16 -
sc/source/ui/vba/vbastyles.cxx | 10
sc/source/ui/vba/vbatitle.hxx | 8
sc/source/ui/vba/vbawindow.cxx | 2
sc/source/ui/vba/vbaworksheet.cxx | 2
sc/source/ui/view/cellsh1.cxx | 4
sc/source/ui/view/cellsh2.cxx | 2
sc/source/ui/view/tabvwshf.cxx | 4
sc/source/ui/view/tabvwshh.cxx | 2
scripting/source/basprov/basscript.cxx | 8
sd/source/ui/view/ViewShellImplementation.cxx | 4
sd/source/ui/view/drviews2.cxx | 12
sd/source/ui/view/drviews3.cxx | 6
sd/source/ui/view/drviews9.cxx | 36 +-
sd/source/ui/view/viewshe3.cxx | 4
sfx2/source/appl/appserv.cxx | 2
sfx2/source/doc/objserv.cxx | 2
sw/source/ui/vba/vbadocument.cxx | 2
sw/source/ui/vba/vbafield.cxx | 2
sw/source/ui/vba/vbaoptions.cxx | 2
sw/source/ui/vba/vbaparagraphformat.cxx | 20 -
sw/source/ui/vba/vbarange.cxx | 6
sw/source/ui/vba/vbarows.cxx | 2
sw/source/ui/vba/vbaselection.cxx | 8
sw/source/ui/vba/vbastyles.cxx | 2
sw/source/ui/vba/vbatabstops.cxx | 2
sw/source/ui/vba/vbaview.cxx | 12
sw/source/ui/vba/vbawrapformat.cxx | 2
vbahelper/source/vbahelper/vbahelper.cxx | 2
vbahelper/source/vbahelper/vbapagesetupbase.cxx | 2
vbahelper/source/vbahelper/vbashape.cxx | 4
121 files changed, 1829 insertions(+), 2033 deletions(-)
New commits:
commit 3274085111409feea8fb54bfb9192851e3b51113
Author: Noel Grandin <noel at peralex.com>
Date: Mon Jul 27 15:54:54 2015 +0200
remove unused STC check
Change-Id: I1d4bcbc5e1a76e4ad6ceb574a8331adada192876
diff --git a/idl/inc/bastype.hxx b/idl/inc/bastype.hxx
index 2252f9a..62052c0 100644
--- a/idl/inc/bastype.hxx
+++ b/idl/inc/bastype.hxx
@@ -55,9 +55,6 @@ public:
SvBOOL & operator = ( bool n ) { nVal = n; bSet = true; return *this; }
operator bool() const { return nVal; }
-#ifdef STC
- operator int() const { return nVal; }
-#endif
bool Is() const { return nVal; }
bool IsSet() const { return bSet; }
commit ab1d07b8bf40939ab08d84781d6a25353a92394b
Author: Noel Grandin <noel at peralex.com>
Date: Mon Jul 27 14:32:55 2015 +0200
remove unused UStringDescription struct
Change-Id: Ib92e64e9a8d14f755edc8866979aa6196d0b61f3
diff --git a/connectivity/source/inc/propertyids.hxx b/connectivity/source/inc/propertyids.hxx
index 45a0f4e..a58fee4 100644
--- a/connectivity/source/inc/propertyids.hxx
+++ b/connectivity/source/inc/propertyids.hxx
@@ -41,26 +41,6 @@ namespace dbtools
};
}
-namespace connectivity
-{
- namespace CONNECTIVITY_PROPERTY_NAME_SPACE
- {
- typedef const sal_Char* (*PVFN)();
-
- struct OOO_DLLPUBLIC_DBTOOLS UStringDescription
- {
- const sal_Char* pZeroTerminatedName;
- sal_Int32 nLength;
-
- UStringDescription(PVFN _fCharFkt);
- operator OUString() const { return OUString(pZeroTerminatedName,nLength,RTL_TEXTENCODING_ASCII_US); }
- ~UStringDescription();
- private:
- UStringDescription();
- };
- }
-}
-
#define PROPERTY_ID_QUERYTIMEOUT 1
#define PROPERTY_ID_MAXFIELDSIZE 2
#define PROPERTY_ID_MAXROWS 3
commit bf84823f89f382852764b0e828d7f53178c14384
Author: Noel Grandin <noel at peralex.com>
Date: Mon Jul 27 14:29:36 2015 +0200
convert SFX_CFG* constants to scoped enum
Change-Id: I7b4769d0616b5685792630bcb82fd0d944505a24
diff --git a/cui/source/customize/cfgutil.cxx b/cui/source/customize/cfgutil.cxx
index 5f86a6e..33b5067 100644
--- a/cui/source/customize/cfgutil.cxx
+++ b/cui/source/customize/cfgutil.cxx
@@ -294,13 +294,13 @@ void SfxConfigFunctionListBox::ClearAll()
{
SfxGroupInfo_Impl *pData = &aArr[i];
- if ( pData->nKind == SFX_CFGFUNCTION_SCRIPT )
+ if ( pData->nKind == SfxCfgKind::FUNCTION_SCRIPT )
{
OUString* pScriptURI = static_cast<OUString*>(pData->pObject);
delete pScriptURI;
}
- if ( pData->nKind == SFX_CFGGROUP_SCRIPTCONTAINER )
+ if ( pData->nKind == SfxCfgKind::GROUP_SCRIPTCONTAINER )
{
XInterface* xi = static_cast<XInterface *>(pData->pObject);
if (xi != NULL)
@@ -320,7 +320,7 @@ OUString SfxConfigFunctionListBox::GetSelectedScriptURI()
if ( pEntry )
{
SfxGroupInfo_Impl *pData = static_cast<SfxGroupInfo_Impl*>(pEntry->GetUserData());
- if ( pData && ( pData->nKind == SFX_CFGFUNCTION_SCRIPT ) )
+ if ( pData && ( pData->nKind == SfxCfgKind::FUNCTION_SCRIPT ) )
return *static_cast<OUString*>(pData->pObject);
}
return OUString();
@@ -428,7 +428,7 @@ void SfxConfigGroupListBox::ClearAll()
for ( sal_uInt16 i=0; i<nCount; ++i )
{
SfxGroupInfo_Impl *pData = &aArr[i];
- if (pData->nKind == SFX_CFGGROUP_SCRIPTCONTAINER)
+ if (pData->nKind == SfxCfgKind::GROUP_SCRIPTCONTAINER)
{
XInterface* xi = static_cast<XInterface *>(pData->pObject);
if (xi != NULL)
@@ -473,7 +473,7 @@ void SfxConfigGroupListBox::InitModule()
{ continue; }
SvTreeListEntry* pEntry = InsertEntry(sGroupName, NULL);
- SfxGroupInfo_Impl* pInfo = new SfxGroupInfo_Impl(SFX_CFGGROUP_FUNCTION, rGroupID);
+ SfxGroupInfo_Impl* pInfo = new SfxGroupInfo_Impl(SfxCfgKind::GROUP_FUNCTION, rGroupID);
pEntry->SetUserData(pInfo);
}
}
@@ -584,7 +584,7 @@ void SfxConfigGroupListBox::Init(const css::uno::Reference< css::uno::XComponent
rootNode->acquire();
SfxGroupInfo_Impl *pInfo =
- new SfxGroupInfo_Impl( SFX_CFGGROUP_SCRIPTCONTAINER, 0,
+ new SfxGroupInfo_Impl( SfxCfgKind::GROUP_SCRIPTCONTAINER, 0,
static_cast<void *>(rootNode.get()));
OUString aTitle(pImp->m_sDlgMacros);
@@ -655,7 +655,7 @@ void SfxConfigGroupListBox::Init(const css::uno::Reference< css::uno::XComponent
theChild->acquire();
SfxGroupInfo_Impl* pInfo =
- new SfxGroupInfo_Impl(SFX_CFGGROUP_SCRIPTCONTAINER,
+ new SfxGroupInfo_Impl(SfxCfgKind::GROUP_SCRIPTCONTAINER,
0, static_cast<void *>( theChild.get()));
Image aImage = GetImage( theChild, xCtx, bIsRootNode );
@@ -696,7 +696,7 @@ void SfxConfigGroupListBox::Init(const css::uno::Reference< css::uno::XComponent
{
OUString sStyle( pImp->m_aStrGroupStyles );
SvTreeListEntry *pEntry = InsertEntry( sStyle, 0 );
- SfxGroupInfo_Impl *pInfo = new SfxGroupInfo_Impl( SFX_CFGGROUP_STYLES, 0, 0 ); // TODO last parameter should contain user data
+ SfxGroupInfo_Impl *pInfo = new SfxGroupInfo_Impl( SfxCfgKind::GROUP_STYLES, 0, 0 ); // TODO last parameter should contain user data
aArr.push_back( pInfo );
pEntry->SetUserData( pInfo );
pEntry->EnableChildrenOnDemand( true );
@@ -837,9 +837,9 @@ void SfxConfigGroupListBox::GroupSelected()
SfxGroupInfo_Impl *pInfo = static_cast<SfxGroupInfo_Impl*>(pEntry->GetUserData());
pFunctionListBox->SetUpdateMode(false);
pFunctionListBox->ClearAll();
- if ( pInfo->nKind != SFX_CFGGROUP_FUNCTION &&
- pInfo->nKind != SFX_CFGGROUP_SCRIPTCONTAINER &&
- pInfo->nKind != SFX_CFGGROUP_STYLES )
+ if ( pInfo->nKind != SfxCfgKind::GROUP_FUNCTION &&
+ pInfo->nKind != SfxCfgKind::GROUP_SCRIPTCONTAINER &&
+ pInfo->nKind != SfxCfgKind::GROUP_STYLES )
{
pFunctionListBox->SetUpdateMode(true);
return;
@@ -847,7 +847,7 @@ void SfxConfigGroupListBox::GroupSelected()
switch ( pInfo->nKind )
{
- case SFX_CFGGROUP_FUNCTION :
+ case SfxCfgKind::GROUP_FUNCTION :
{
sal_uInt16 nGroup = pInfo->nUniqueID;
css::uno::Reference< css::frame::XDispatchInformationProvider > xProvider (m_xFrame, css::uno::UNO_QUERY_THROW);
@@ -860,7 +860,7 @@ void SfxConfigGroupListBox::GroupSelected()
const css::frame::DispatchInformation& rInfo = lCommands[i];
OUString sUIName = MapCommand2UIName(rInfo.Command);
SvTreeListEntry* pFuncEntry = pFunctionListBox->InsertEntry(sUIName, NULL);
- SfxGroupInfo_Impl* pGrpInfo = new SfxGroupInfo_Impl(SFX_CFGFUNCTION_SLOT, 0);
+ SfxGroupInfo_Impl* pGrpInfo = new SfxGroupInfo_Impl(SfxCfgKind::FUNCTION_SLOT, 0);
pGrpInfo->sCommand = rInfo.Command;
pGrpInfo->sLabel = sUIName;
pFuncEntry->SetUserData(pGrpInfo);
@@ -869,7 +869,7 @@ void SfxConfigGroupListBox::GroupSelected()
break;
}
- case SFX_CFGGROUP_SCRIPTCONTAINER:
+ case SfxCfgKind::GROUP_SCRIPTCONTAINER:
{
if ( !GetChildCount( pEntry ) )
{
@@ -899,7 +899,7 @@ void SfxConfigGroupListBox::GroupSelected()
value >>= uri;
OUString* pScriptURI = new OUString( uri );
- SfxGroupInfo_Impl* pGrpInfo = new SfxGroupInfo_Impl( SFX_CFGFUNCTION_SCRIPT, 0, pScriptURI );
+ SfxGroupInfo_Impl* pGrpInfo = new SfxGroupInfo_Impl( SfxCfgKind::FUNCTION_SCRIPT, 0, pScriptURI );
Image aImage = GetImage( children[n], Reference< XComponentContext >(), false );
SvTreeListEntry* pNewEntry =
@@ -924,7 +924,7 @@ void SfxConfigGroupListBox::GroupSelected()
break;
}
- case SFX_CFGGROUP_STYLES :
+ case SfxCfgKind::GROUP_STYLES :
{
SfxStyleInfo_Impl* pFamily = static_cast<SfxStyleInfo_Impl*>(pInfo->pObject);
if (pFamily)
@@ -937,7 +937,7 @@ void SfxConfigGroupListBox::GroupSelected()
{
SfxStyleInfo_Impl* pStyle = new SfxStyleInfo_Impl(*pIt);
SvTreeListEntry* pFuncEntry = pFunctionListBox->InsertEntry( pStyle->sLabel, NULL );
- SfxGroupInfo_Impl *pGrpInfo = new SfxGroupInfo_Impl( SFX_CFGGROUP_STYLES, 0, pStyle );
+ SfxGroupInfo_Impl *pGrpInfo = new SfxGroupInfo_Impl( SfxCfgKind::GROUP_STYLES, 0, pStyle );
pFunctionListBox->aArr.push_back( pGrpInfo );
pGrpInfo->sCommand = pStyle->sCommand;
pGrpInfo->sLabel = pStyle->sLabel;
@@ -997,7 +997,7 @@ void SfxConfigGroupListBox::RequestingChildren( SvTreeListEntry *pEntry )
pInfo->bWasOpened = true;
switch ( pInfo->nKind )
{
- case SFX_CFGGROUP_SCRIPTCONTAINER:
+ case SfxCfgKind::GROUP_SCRIPTCONTAINER:
{
if ( !GetChildCount( pEntry ) )
{
@@ -1052,7 +1052,7 @@ void SfxConfigGroupListBox::RequestingChildren( SvTreeListEntry *pEntry )
theChild->acquire();
SfxGroupInfo_Impl* pGrpInfo =
- new SfxGroupInfo_Impl(SFX_CFGGROUP_SCRIPTCONTAINER,
+ new SfxGroupInfo_Impl(SfxCfgKind::GROUP_SCRIPTCONTAINER,
0, static_cast<void *>( theChild.get()));
Image aImage = GetImage( theChild, Reference< XComponentContext >(), false );
@@ -1089,7 +1089,7 @@ void SfxConfigGroupListBox::RequestingChildren( SvTreeListEntry *pEntry )
break;
}
- case SFX_CFGGROUP_STYLES:
+ case SfxCfgKind::GROUP_STYLES:
{
if ( !GetChildCount( pEntry ) )
{
@@ -1101,7 +1101,7 @@ void SfxConfigGroupListBox::RequestingChildren( SvTreeListEntry *pEntry )
{
SfxStyleInfo_Impl* pFamily = new SfxStyleInfo_Impl(*pIt);
SvTreeListEntry* pStyleEntry = InsertEntry( pFamily->sLabel, pEntry );
- SfxGroupInfo_Impl *pGrpInfo = new SfxGroupInfo_Impl( SFX_CFGGROUP_STYLES, 0, pFamily );
+ SfxGroupInfo_Impl *pGrpInfo = new SfxGroupInfo_Impl( SfxCfgKind::GROUP_STYLES, 0, pFamily );
aArr.push_back( pGrpInfo );
pStyleEntry->SetUserData( pGrpInfo );
pStyleEntry->EnableChildrenOnDemand( false );
diff --git a/cui/source/inc/cfgutil.hxx b/cui/source/inc/cfgutil.hxx
index 93d151d..a84277f 100644
--- a/cui/source/inc/cfgutil.hxx
+++ b/cui/source/inc/cfgutil.hxx
@@ -74,22 +74,25 @@ struct SfxStylesInfo_Impl
static OUString generateCommand(const OUString& sFamily, const OUString& sStyle);
};
-#define SFX_CFGGROUP_FUNCTION 1
-#define SFX_CFGFUNCTION_SLOT 2
-#define SFX_CFGGROUP_SCRIPTCONTAINER 3
-#define SFX_CFGFUNCTION_SCRIPT 4
-#define SFX_CFGGROUP_STYLES 5
+enum class SfxCfgKind
+{
+ GROUP_FUNCTION = 1,
+ FUNCTION_SLOT = 2,
+ GROUP_SCRIPTCONTAINER = 3,
+ FUNCTION_SCRIPT = 4,
+ GROUP_STYLES = 5,
+};
struct SfxGroupInfo_Impl
{
- sal_uInt16 nKind;
+ SfxCfgKind nKind;
sal_uInt16 nUniqueID;
void* pObject;
- bool bWasOpened;
+ bool bWasOpened;
OUString sCommand;
OUString sLabel;
- SfxGroupInfo_Impl( sal_uInt16 n, sal_uInt16 nr, void* pObj = 0 ) :
+ SfxGroupInfo_Impl( SfxCfgKind n, sal_uInt16 nr, void* pObj = 0 ) :
nKind( n ), nUniqueID( nr ), pObject( pObj ), bWasOpened(false) {}
};
commit 7d6d18e74a406a462de6fffac05a9d5f722cc2cd
Author: Noel Grandin <noel at peralex.com>
Date: Mon Jul 27 14:22:18 2015 +0200
convert INPUTMODE_ constants to scoped enum
Change-Id: Ib2e37bb320c1edba7246a6611df3b89b764346db
diff --git a/cui/source/dialogs/scriptdlg.cxx b/cui/source/dialogs/scriptdlg.cxx
index 3e90388..8fbf409 100644
--- a/cui/source/dialogs/scriptdlg.cxx
+++ b/cui/source/dialogs/scriptdlg.cxx
@@ -416,7 +416,7 @@ void SFTreeListBox::ExpandedHdl()
// CuiInputDialog ------------------------------------------------------------
-CuiInputDialog::CuiInputDialog(vcl::Window * pParent, sal_uInt16 nMode )
+CuiInputDialog::CuiInputDialog(vcl::Window * pParent, InputDialogMode nMode )
: ModalDialog(pParent, "NewLibDialog",
"cui/ui/newlibdialog.ui")
{
@@ -425,14 +425,14 @@ CuiInputDialog::CuiInputDialog(vcl::Window * pParent, sal_uInt16 nMode )
FixedText *pNewLibFT = get<FixedText>("newlibft");
- if ( nMode == INPUTMODE_NEWMACRO )
+ if ( nMode == InputDialogMode::NEWMACRO )
{
pNewLibFT->Hide();
FixedText *pNewMacroFT = get<FixedText>("newmacroft");
pNewMacroFT->Show();
SetText(get<FixedText>("altmacrotitle")->GetText());
}
- else if ( nMode == INPUTMODE_RENAME )
+ else if ( nMode == InputDialogMode::RENAME )
{
pNewLibFT->Hide();
FixedText *pRenameFT = get<FixedText>("renameft");
@@ -840,7 +840,7 @@ void SvxScriptOrgDialog::createEntry( SvTreeListEntry* pEntry )
{
OUString aNewName;
OUString aNewStdName;
- sal_uInt16 nMode = INPUTMODE_NEWLIB;
+ InputDialogMode nMode = InputDialogMode::NEWLIB;
if( m_pScriptsBox->GetModel()->GetDepth( pEntry ) == 0 )
{
aNewStdName = "Library" ;
@@ -848,7 +848,7 @@ void SvxScriptOrgDialog::createEntry( SvTreeListEntry* pEntry )
else
{
aNewStdName = "Macro" ;
- nMode = INPUTMODE_NEWMACRO;
+ nMode = InputDialogMode::NEWMACRO;
}
//do we need L10N for this? ie something like:
//String aNewStdName( ResId( STR_STDMODULENAME ) );
@@ -1025,9 +1025,7 @@ void SvxScriptOrgDialog::renameEntry( SvTreeListEntry* pEntry )
extn = aNewName.copy(extnPos);
aNewName = aNewName.copy(0,extnPos);
}
- sal_uInt16 nMode = INPUTMODE_RENAME;
-
- ScopedVclPtrInstance< CuiInputDialog > xNewDlg( static_cast<vcl::Window*>(this), nMode );
+ ScopedVclPtrInstance< CuiInputDialog > xNewDlg( static_cast<vcl::Window*>(this), InputDialogMode::RENAME );
xNewDlg->SetObjectName( aNewName );
bool bValid;
diff --git a/cui/source/inc/scriptdlg.hxx b/cui/source/inc/scriptdlg.hxx
index 2e0227a..9a6354d 100644
--- a/cui/source/inc/scriptdlg.hxx
+++ b/cui/source/inc/scriptdlg.hxx
@@ -38,10 +38,6 @@
#define OBJTYPE_SCRIPTCONTAINER 3L
#define OBJTYPE_SFROOT 4L
-#define INPUTMODE_NEWLIB 1
-#define INPUTMODE_NEWMACRO 2
-#define INPUTMODE_RENAME 3
-
typedef std::unordered_map < OUString, OUString,
OUStringHash, std::equal_to< OUString > > Selection_hash;
@@ -91,12 +87,18 @@ public:
void deleteAllTree( );
};
+enum class InputDialogMode {
+ NEWLIB = 1,
+ NEWMACRO = 2,
+ RENAME = 3,
+};
+
class CuiInputDialog : public ModalDialog
{
private:
VclPtr<Edit> m_pEdit;
public:
- CuiInputDialog(vcl::Window * pParent, sal_uInt16 nMode);
+ CuiInputDialog(vcl::Window * pParent, InputDialogMode nMode);
virtual ~CuiInputDialog();
virtual void dispose() SAL_OVERRIDE;
commit 92196183a76c255f7111c04ac94ea104a657f458
Author: Noel Grandin <noel at peralex.com>
Date: Mon Jul 27 14:18:40 2015 +0200
remove unused ALLCHART constants
Change-Id: I8fbc3ff0b8427c3aa18527f8da2a339b82407309
diff --git a/filter/source/graphicfilter/icgm/chart.hxx b/filter/source/graphicfilter/icgm/chart.hxx
index 5b8e441..8a5067d 100644
--- a/filter/source/graphicfilter/icgm/chart.hxx
+++ b/filter/source/graphicfilter/icgm/chart.hxx
@@ -28,13 +28,6 @@
#define AUTOBULCHT 96 /* Autobuild BUL CHT */
#define AUTOTABCHT 97 /* Autobuild TAB CHT */
-/* FNC 10/11/93: for the chart stream, ALLCHART was added. */
-/* It is used specifically by PPT in its Template to let */
-/* us know that the template applies to all charts, not to */
-/* one specific chart type. */
-#define ALLCHART 127 /* Applies to all chart types */
-#define ALLCHART_TPL 255 /* Applies to all chart types */
-
typedef struct TextAttribute
{
sal_uInt16 nTextAttribCount;
commit a69f8f9082d1eca4f807d14e2ce9d570f02aa2d7
Author: Noel Grandin <noel at peralex.com>
Date: Mon Jul 27 14:17:38 2015 +0200
remove unused HELP_REQUESTED constant
Change-Id: I1dc6ee6d267d0be82e6af81c21bb5f0920300256
diff --git a/fpicker/source/office/OfficeFilePicker.cxx b/fpicker/source/office/OfficeFilePicker.cxx
index 917a520..3e2d345 100644
--- a/fpicker/source/office/OfficeFilePicker.cxx
+++ b/fpicker/source/office/OfficeFilePicker.cxx
@@ -323,9 +323,6 @@ void SvtFilePicker::notify( sal_Int16 _nEventId, sal_Int16 _nControlId )
case DIRECTORY_CHANGED:
m_xListener->directoryChanged( aEvent );
break;
- case HELP_REQUESTED:
- m_xListener->helpRequested( aEvent );
- break;
case CTRL_STATE_CHANGED:
m_xListener->controlStateChanged( aEvent );
break;
diff --git a/fpicker/source/office/fpdialogbase.hxx b/fpicker/source/office/fpdialogbase.hxx
index 19a26a4..7496701 100644
--- a/fpicker/source/office/fpdialogbase.hxx
+++ b/fpicker/source/office/fpdialogbase.hxx
@@ -110,7 +110,6 @@ public:
#define FILE_SELECTION_CHANGED 1
#define DIRECTORY_CHANGED 2
-#define HELP_REQUESTED 3
#define CTRL_STATE_CHANGED 4
#define DIALOG_SIZE_CHANGED 5
commit b1c25a0d8fa2f8effc501cc100b0c07f79437e8e
Author: Noel Grandin <noel at peralex.com>
Date: Mon Jul 27 13:04:00 2015 +0200
inline "old" SbERR constants
Change-Id: I3e6665351de97692ae70207e8b623ad008ca8c9a
diff --git a/basic/source/classes/eventatt.cxx b/basic/source/classes/eventatt.cxx
index 9f53f89..2744f44 100644
--- a/basic/source/classes/eventatt.cxx
+++ b/basic/source/classes/eventatt.cxx
@@ -426,7 +426,7 @@ void RTL_Impl_CreateUnoDialog( StarBASIC* pBasic, SbxArray& rPar, bool bWrite )
// We need at least 1 parameter
if ( rPar.Count() < 2 )
{
- StarBASIC::Error( SbERR_BAD_ARGUMENT );
+ StarBASIC::Error( ERRCODE_BASIC_BAD_ARGUMENT );
return;
}
@@ -434,7 +434,7 @@ void RTL_Impl_CreateUnoDialog( StarBASIC* pBasic, SbxArray& rPar, bool bWrite )
SbxBaseRef pObj = rPar.Get( 1 )->GetObject();
if( !(pObj && pObj->ISA(SbUnoObject)) )
{
- StarBASIC::Error( SbERR_BAD_ARGUMENT );
+ StarBASIC::Error( ERRCODE_BASIC_BAD_ARGUMENT );
return;
}
SbUnoObject* pUnoObj = static_cast<SbUnoObject*>(static_cast<SbxBase*>(pObj));
@@ -443,7 +443,7 @@ void RTL_Impl_CreateUnoDialog( StarBASIC* pBasic, SbxArray& rPar, bool bWrite )
if( eType != TypeClass_INTERFACE )
{
- StarBASIC::Error( SbERR_BAD_ARGUMENT );
+ StarBASIC::Error( ERRCODE_BASIC_BAD_ARGUMENT );
return;
}
diff --git a/basic/source/classes/propacc.cxx b/basic/source/classes/propacc.cxx
index 9f3fc9e..b093e50 100644
--- a/basic/source/classes/propacc.cxx
+++ b/basic/source/classes/propacc.cxx
@@ -272,7 +272,7 @@ void RTL_Impl_CreatePropertySet( StarBASIC* pBasic, SbxArray& rPar, bool bWrite
// TODO: In this case < 2 is not correct ;-)
if ( rPar.Count() < 2 )
{
- StarBASIC::Error( SbERR_BAD_ARGUMENT );
+ StarBASIC::Error( ERRCODE_BASIC_BAD_ARGUMENT );
return;
}
diff --git a/basic/source/classes/sb.cxx b/basic/source/classes/sb.cxx
index fb8fd46..c4d76ce 100644
--- a/basic/source/classes/sb.cxx
+++ b/basic/source/classes/sb.cxx
@@ -281,128 +281,128 @@ struct SFX_VB_ErrorItem
const SFX_VB_ErrorItem SFX_VB_ErrorTab[] =
{
- { 1, SbERR_BASIC_EXCEPTION }, // #87844 Map exception to error code 1
- { 2, SbERR_SYNTAX },
- { 3, SbERR_NO_GOSUB },
- { 4, SbERR_REDO_FROM_START },
- { 5, SbERR_BAD_ARGUMENT },
- { 6, SbERR_MATH_OVERFLOW },
- { 7, SbERR_NO_MEMORY },
- { 8, SbERR_ALREADY_DIM },
- { 9, SbERR_OUT_OF_RANGE },
- { 10, SbERR_DUPLICATE_DEF },
- { 11, SbERR_ZERODIV },
- { 12, SbERR_VAR_UNDEFINED },
- { 13, SbERR_CONVERSION },
- { 14, SbERR_BAD_PARAMETER },
- { 18, SbERR_USER_ABORT },
- { 20, SbERR_BAD_RESUME },
- { 28, SbERR_STACK_OVERFLOW },
- { 35, SbERR_PROC_UNDEFINED },
- { 48, SbERR_BAD_DLL_LOAD },
- { 49, SbERR_BAD_DLL_CALL },
- { 51, SbERR_INTERNAL_ERROR },
- { 52, SbERR_BAD_CHANNEL },
- { 53, SbERR_FILE_NOT_FOUND },
- { 54, SbERR_BAD_FILE_MODE },
- { 55, SbERR_FILE_ALREADY_OPEN },
- { 57, SbERR_IO_ERROR },
- { 58, SbERR_FILE_EXISTS },
- { 59, SbERR_BAD_RECORD_LENGTH },
- { 61, SbERR_DISK_FULL },
- { 62, SbERR_READ_PAST_EOF },
- { 63, SbERR_BAD_RECORD_NUMBER },
- { 67, SbERR_TOO_MANY_FILES },
- { 68, SbERR_NO_DEVICE },
- { 70, SbERR_ACCESS_DENIED },
- { 71, SbERR_NOT_READY },
- { 73, SbERR_NOT_IMPLEMENTED },
- { 74, SbERR_DIFFERENT_DRIVE },
- { 75, SbERR_ACCESS_ERROR },
- { 76, SbERR_PATH_NOT_FOUND },
- { 91, SbERR_NO_OBJECT },
- { 93, SbERR_BAD_PATTERN },
- { 94, SBERR_IS_NULL },
- { 250, SbERR_DDE_ERROR },
- { 280, SbERR_DDE_WAITINGACK },
- { 281, SbERR_DDE_OUTOFCHANNELS },
- { 282, SbERR_DDE_NO_RESPONSE },
- { 283, SbERR_DDE_MULT_RESPONSES },
- { 284, SbERR_DDE_CHANNEL_LOCKED },
- { 285, SbERR_DDE_NOTPROCESSED },
- { 286, SbERR_DDE_TIMEOUT },
- { 287, SbERR_DDE_USER_INTERRUPT },
- { 288, SbERR_DDE_BUSY },
- { 289, SbERR_DDE_NO_DATA },
- { 290, SbERR_DDE_WRONG_DATA_FORMAT },
- { 291, SbERR_DDE_PARTNER_QUIT },
- { 292, SbERR_DDE_CONV_CLOSED },
- { 293, SbERR_DDE_NO_CHANNEL },
- { 294, SbERR_DDE_INVALID_LINK },
- { 295, SbERR_DDE_QUEUE_OVERFLOW },
- { 296, SbERR_DDE_LINK_ALREADY_EST },
- { 297, SbERR_DDE_LINK_INV_TOPIC },
- { 298, SbERR_DDE_DLL_NOT_FOUND },
- { 323, SbERR_CANNOT_LOAD },
- { 341, SbERR_BAD_INDEX },
- { 366, SbERR_NO_ACTIVE_OBJECT },
- { 380, SbERR_BAD_PROP_VALUE },
- { 382, SbERR_PROP_READONLY },
- { 394, SbERR_PROP_WRITEONLY },
- { 420, SbERR_INVALID_OBJECT },
- { 423, SbERR_NO_METHOD },
- { 424, SbERR_NEEDS_OBJECT },
- { 425, SbERR_INVALID_USAGE_OBJECT },
- { 430, SbERR_NO_OLE },
- { 438, SbERR_BAD_METHOD },
- { 440, SbERR_OLE_ERROR },
- { 445, SbERR_BAD_ACTION },
- { 446, SbERR_NO_NAMED_ARGS },
- { 447, SbERR_BAD_LOCALE },
- { 448, SbERR_NAMED_NOT_FOUND },
- { 449, SbERR_NOT_OPTIONAL },
- { 450, SbERR_WRONG_ARGS },
- { 451, SbERR_NOT_A_COLL },
- { 452, SbERR_BAD_ORDINAL },
- { 453, SbERR_DLLPROC_NOT_FOUND },
- { 460, SbERR_BAD_CLIPBD_FORMAT },
- { 951, SbERR_UNEXPECTED },
- { 952, SbERR_EXPECTED },
- { 953, SbERR_SYMBOL_EXPECTED },
- { 954, SbERR_VAR_EXPECTED },
- { 955, SbERR_LABEL_EXPECTED },
- { 956, SbERR_LVALUE_EXPECTED },
- { 957, SbERR_VAR_DEFINED },
- { 958, SbERR_PROC_DEFINED },
- { 959, SbERR_LABEL_DEFINED },
- { 960, SbERR_UNDEF_VAR },
- { 961, SbERR_UNDEF_ARRAY },
- { 962, SbERR_UNDEF_PROC },
- { 963, SbERR_UNDEF_LABEL },
- { 964, SbERR_UNDEF_TYPE },
- { 965, SbERR_BAD_EXIT },
- { 966, SbERR_BAD_BLOCK },
- { 967, SbERR_BAD_BRACKETS },
- { 968, SbERR_BAD_DECLARATION },
- { 969, SbERR_BAD_PARAMETERS },
- { 970, SbERR_BAD_CHAR_IN_NUMBER },
- { 971, SbERR_MUST_HAVE_DIMS },
- { 972, SbERR_NO_IF },
- { 973, SbERR_NOT_IN_SUBR },
- { 974, SbERR_NOT_IN_MAIN },
- { 975, SbERR_WRONG_DIMS },
- { 976, SbERR_BAD_OPTION },
- { 977, SbERR_CONSTANT_REDECLARED },
- { 978, SbERR_PROG_TOO_LARGE },
- { 979, SbERR_NO_STRINGS_ARRAYS },
- { 1000, SbERR_PROPERTY_NOT_FOUND },
- { 1001, SbERR_METHOD_NOT_FOUND },
- { 1002, SbERR_ARG_MISSING },
- { 1003, SbERR_BAD_NUMBER_OF_ARGS },
- { 1004, SbERR_METHOD_FAILED },
- { 1005, SbERR_SETPROP_FAILED },
- { 1006, SbERR_GETPROP_FAILED },
- { 1007, SbERR_BASIC_COMPAT },
+ { 1, ERRCODE_BASIC_EXCEPTION }, // #87844 Map exception to error code 1
+ { 2, ERRCODE_BASIC_SYNTAX },
+ { 3, ERRCODE_BASIC_NO_GOSUB },
+ { 4, ERRCODE_BASIC_REDO_FROM_START },
+ { 5, ERRCODE_BASIC_BAD_ARGUMENT },
+ { 6, ERRCODE_BASIC_MATH_OVERFLOW },
+ { 7, ERRCODE_BASIC_NO_MEMORY },
+ { 8, ERRCODE_BASIC_ALREADY_DIM },
+ { 9, ERRCODE_BASIC_OUT_OF_RANGE },
+ { 10, ERRCODE_BASIC_DUPLICATE_DEF },
+ { 11, ERRCODE_BASIC_ZERODIV },
+ { 12, ERRCODE_BASIC_VAR_UNDEFINED },
+ { 13, ERRCODE_BASIC_CONVERSION },
+ { 14, ERRCODE_BASIC_BAD_PARAMETER },
+ { 18, ERRCODE_BASIC_USER_ABORT },
+ { 20, ERRCODE_BASIC_BAD_RESUME },
+ { 28, ERRCODE_BASIC_STACK_OVERFLOW },
+ { 35, ERRCODE_BASIC_PROC_UNDEFINED },
+ { 48, ERRCODE_BASIC_BAD_DLL_LOAD },
+ { 49, ERRCODE_BASIC_BAD_DLL_CALL },
+ { 51, ERRCODE_BASIC_INTERNAL_ERROR },
+ { 52, ERRCODE_BASIC_BAD_CHANNEL },
+ { 53, ERRCODE_BASIC_FILE_NOT_FOUND },
+ { 54, ERRCODE_BASIC_BAD_FILE_MODE },
+ { 55, ERRCODE_BASIC_FILE_ALREADY_OPEN },
+ { 57, ERRCODE_BASIC_IO_ERROR },
+ { 58, ERRCODE_BASIC_FILE_EXISTS },
+ { 59, ERRCODE_BASIC_BAD_RECORD_LENGTH },
+ { 61, ERRCODE_BASIC_DISK_FULL },
+ { 62, ERRCODE_BASIC_READ_PAST_EOF },
+ { 63, ERRCODE_BASIC_BAD_RECORD_NUMBER },
+ { 67, ERRCODE_BASIC_TOO_MANY_FILES },
+ { 68, ERRCODE_BASIC_NO_DEVICE },
+ { 70, ERRCODE_BASIC_ACCESS_DENIED },
+ { 71, ERRCODE_BASIC_NOT_READY },
+ { 73, ERRCODE_BASIC_NOT_IMPLEMENTED },
+ { 74, ERRCODE_BASIC_DIFFERENT_DRIVE },
+ { 75, ERRCODE_BASIC_ACCESS_ERROR },
+ { 76, ERRCODE_BASIC_PATH_NOT_FOUND },
+ { 91, ERRCODE_BASIC_NO_OBJECT },
+ { 93, ERRCODE_BASIC_BAD_PATTERN },
+ { 94, ERRCODE_BASIC_IS_NULL },
+ { 250, ERRCODE_BASIC_DDE_ERROR },
+ { 280, ERRCODE_BASIC_DDE_WAITINGACK },
+ { 281, ERRCODE_BASIC_DDE_OUTOFCHANNELS },
+ { 282, ERRCODE_BASIC_DDE_NO_RESPONSE },
+ { 283, ERRCODE_BASIC_DDE_MULT_RESPONSES },
+ { 284, ERRCODE_BASIC_DDE_CHANNEL_LOCKED },
+ { 285, ERRCODE_BASIC_DDE_NOTPROCESSED },
+ { 286, ERRCODE_BASIC_DDE_TIMEOUT },
+ { 287, ERRCODE_BASIC_DDE_USER_INTERRUPT },
+ { 288, ERRCODE_BASIC_DDE_BUSY },
+ { 289, ERRCODE_BASIC_DDE_NO_DATA },
+ { 290, ERRCODE_BASIC_DDE_WRONG_DATA_FORMAT },
+ { 291, ERRCODE_BASIC_DDE_PARTNER_QUIT },
+ { 292, ERRCODE_BASIC_DDE_CONV_CLOSED },
+ { 293, ERRCODE_BASIC_DDE_NO_CHANNEL },
+ { 294, ERRCODE_BASIC_DDE_INVALID_LINK },
+ { 295, ERRCODE_BASIC_DDE_QUEUE_OVERFLOW },
+ { 296, ERRCODE_BASIC_DDE_LINK_ALREADY_EST },
+ { 297, ERRCODE_BASIC_DDE_LINK_INV_TOPIC },
+ { 298, ERRCODE_BASIC_DDE_DLL_NOT_FOUND },
+ { 323, ERRCODE_BASIC_CANNOT_LOAD },
+ { 341, ERRCODE_BASIC_BAD_INDEX },
+ { 366, ERRCODE_BASIC_NO_ACTIVE_OBJECT },
+ { 380, ERRCODE_BASIC_BAD_PROP_VALUE },
+ { 382, ERRCODE_BASIC_PROP_READONLY },
+ { 394, ERRCODE_BASIC_PROP_WRITEONLY },
+ { 420, ERRCODE_BASIC_INVALID_OBJECT },
+ { 423, ERRCODE_BASIC_NO_METHOD },
+ { 424, ERRCODE_BASIC_NEEDS_OBJECT },
+ { 425, ERRCODE_BASIC_INVALID_USAGE_OBJECT },
+ { 430, ERRCODE_BASIC_NO_OLE },
+ { 438, ERRCODE_BASIC_BAD_METHOD },
+ { 440, ERRCODE_BASIC_OLE_ERROR },
+ { 445, ERRCODE_BASIC_BAD_ACTION },
+ { 446, ERRCODE_BASIC_NO_NAMED_ARGS },
+ { 447, ERRCODE_BASIC_BAD_LOCALE },
+ { 448, ERRCODE_BASIC_NAMED_NOT_FOUND },
+ { 449, ERRCODE_BASIC_NOT_OPTIONAL },
+ { 450, ERRCODE_BASIC_WRONG_ARGS },
+ { 451, ERRCODE_BASIC_NOT_A_COLL },
+ { 452, ERRCODE_BASIC_BAD_ORDINAL },
+ { 453, ERRCODE_BASIC_DLLPROC_NOT_FOUND },
+ { 460, ERRCODE_BASIC_BAD_CLIPBD_FORMAT },
+ { 951, ERRCODE_BASIC_UNEXPECTED },
+ { 952, ERRCODE_BASIC_EXPECTED },
+ { 953, ERRCODE_BASIC_SYMBOL_EXPECTED },
+ { 954, ERRCODE_BASIC_VAR_EXPECTED },
+ { 955, ERRCODE_BASIC_LABEL_EXPECTED },
+ { 956, ERRCODE_BASIC_LVALUE_EXPECTED },
+ { 957, ERRCODE_BASIC_VAR_DEFINED },
+ { 958, ERRCODE_BASIC_PROC_DEFINED },
+ { 959, ERRCODE_BASIC_LABEL_DEFINED },
+ { 960, ERRCODE_BASIC_UNDEF_VAR },
+ { 961, ERRCODE_BASIC_UNDEF_ARRAY },
+ { 962, ERRCODE_BASIC_UNDEF_PROC },
+ { 963, ERRCODE_BASIC_UNDEF_LABEL },
+ { 964, ERRCODE_BASIC_UNDEF_TYPE },
+ { 965, ERRCODE_BASIC_BAD_EXIT },
+ { 966, ERRCODE_BASIC_BAD_BLOCK },
+ { 967, ERRCODE_BASIC_BAD_BRACKETS },
+ { 968, ERRCODE_BASIC_BAD_DECLARATION },
+ { 969, ERRCODE_BASIC_BAD_PARAMETERS },
+ { 970, ERRCODE_BASIC_BAD_CHAR_IN_NUMBER },
+ { 971, ERRCODE_BASIC_MUST_HAVE_DIMS },
+ { 972, ERRCODE_BASIC_NO_IF },
+ { 973, ERRCODE_BASIC_NOT_IN_SUBR },
+ { 974, ERRCODE_BASIC_NOT_IN_MAIN },
+ { 975, ERRCODE_BASIC_WRONG_DIMS },
+ { 976, ERRCODE_BASIC_BAD_OPTION },
+ { 977, ERRCODE_BASIC_CONSTANT_REDECLARED },
+ { 978, ERRCODE_BASIC_PROG_TOO_LARGE },
+ { 979, ERRCODE_BASIC_NO_STRINGS_ARRAYS },
+ { 1000, ERRCODE_BASIC_PROPERTY_NOT_FOUND },
+ { 1001, ERRCODE_BASIC_METHOD_NOT_FOUND },
+ { 1002, ERRCODE_BASIC_ARG_MISSING },
+ { 1003, ERRCODE_BASIC_BAD_NUMBER_OF_ARGS },
+ { 1004, ERRCODE_BASIC_METHOD_FAILED },
+ { 1005, ERRCODE_BASIC_SETPROP_FAILED },
+ { 1006, ERRCODE_BASIC_GETPROP_FAILED },
+ { 1007, ERRCODE_BASIC_COMPAT },
{ 0xFFFF, 0xFFFFFFFFL } // End mark
};
@@ -1538,17 +1538,17 @@ sal_uInt16 StarBASIC::GetVBErrorCode( SbError nError )
{
switch( nError )
{
- case SbERR_BASIC_ARRAY_FIX:
+ case ERRCODE_BASIC_ARRAY_FIX:
return 10;
- case SbERR_BASIC_STRING_OVERFLOW:
+ case ERRCODE_BASIC_STRING_OVERFLOW:
return 14;
- case SbERR_BASIC_EXPR_TOO_COMPLEX:
+ case ERRCODE_BASIC_EXPR_TOO_COMPLEX:
return 16;
- case SbERR_BASIC_OPER_NOT_PERFORM:
+ case ERRCODE_BASIC_OPER_NOT_PERFORM:
return 17;
- case SbERR_BASIC_TOO_MANY_DLL:
+ case ERRCODE_BASIC_TOO_MANY_DLL:
return 47;
- case SbERR_BASIC_LOOP_NOT_INIT:
+ case ERRCODE_BASIC_LOOP_NOT_INIT:
return 92;
default:
nRet = 0;
@@ -1588,17 +1588,17 @@ SbError StarBASIC::GetSfxFromVBError( sal_uInt16 nError )
case 73:
return 0L;
case 10:
- return SbERR_BASIC_ARRAY_FIX;
+ return ERRCODE_BASIC_ARRAY_FIX;
case 14:
- return SbERR_BASIC_STRING_OVERFLOW;
+ return ERRCODE_BASIC_STRING_OVERFLOW;
case 16:
- return SbERR_BASIC_EXPR_TOO_COMPLEX;
+ return ERRCODE_BASIC_EXPR_TOO_COMPLEX;
case 17:
- return SbERR_BASIC_OPER_NOT_PERFORM;
+ return ERRCODE_BASIC_OPER_NOT_PERFORM;
case 47:
- return SbERR_BASIC_TOO_MANY_DLL;
+ return ERRCODE_BASIC_TOO_MANY_DLL;
case 92:
- return SbERR_BASIC_LOOP_NOT_INIT;
+ return ERRCODE_BASIC_LOOP_NOT_INIT;
default:
nRet = 0L;
}
@@ -1753,7 +1753,7 @@ bool StarBASIC::RTError( SbError code, const OUString& rMsg, sal_Int32 l, sal_In
// seems that this is not used ( if rMsg already has content )
// In the case of VBA MakeErrorText also formats the error to be a little more
// like vba ( adds an error number etc )
- if ( SbiRuntime::isVBAEnabled() && ( code == SbERR_BASIC_COMPAT ) )
+ if ( SbiRuntime::isVBAEnabled() && ( code == ERRCODE_BASIC_COMPAT ) )
{
OUString aTmp = "\'" + OUString::number(SbxErrObject::getUnoErrObject()->getNumber()) +
"\'\n" + OUString(!GetSbData()->aErrMsg.isEmpty() ? GetSbData()->aErrMsg : rMsg);
@@ -2232,14 +2232,14 @@ void BasicCollection::CollAdd( SbxArray* pPar_ )
{
if( !( pBefore->IsErr() || ( pBefore->GetType() == SbxEMPTY ) ) )
{
- SetError( SbERR_BAD_ARGUMENT );
+ SetError( ERRCODE_BASIC_BAD_ARGUMENT );
return;
}
SbxVariable* pAfter = pPar_->Get(4);
sal_Int32 nAfterIndex = implGetIndex( pAfter );
if( nAfterIndex == -1 )
{
- SetError( SbERR_BAD_ARGUMENT );
+ SetError( ERRCODE_BASIC_BAD_ARGUMENT );
return;
}
nNextIndex = nAfterIndex + 1;
@@ -2249,7 +2249,7 @@ void BasicCollection::CollAdd( SbxArray* pPar_ )
sal_Int32 nBeforeIndex = implGetIndex( pBefore );
if( nBeforeIndex == -1 )
{
- SetError( SbERR_BAD_ARGUMENT );
+ SetError( ERRCODE_BASIC_BAD_ARGUMENT );
return;
}
nNextIndex = nBeforeIndex;
@@ -2264,13 +2264,13 @@ void BasicCollection::CollAdd( SbxArray* pPar_ )
{
if( pKey->GetType() != SbxSTRING )
{
- SetError( SbERR_BAD_ARGUMENT );
+ SetError( ERRCODE_BASIC_BAD_ARGUMENT );
return;
}
OUString aKey = pKey->GetOUString();
if( implGetIndexForName( aKey ) != -1 )
{
- SetError( SbERR_BAD_ARGUMENT );
+ SetError( ERRCODE_BASIC_BAD_ARGUMENT );
return;
}
pNewItem->SetName( aKey );
@@ -2281,7 +2281,7 @@ void BasicCollection::CollAdd( SbxArray* pPar_ )
}
else
{
- SetError( SbERR_BAD_ARGUMENT );
+ SetError( ERRCODE_BASIC_BAD_ARGUMENT );
return;
}
}
@@ -2302,7 +2302,7 @@ void BasicCollection::CollItem( SbxArray* pPar_ )
}
if( !pRes )
{
- SetError( SbERR_BAD_ARGUMENT );
+ SetError( ERRCODE_BASIC_BAD_ARGUMENT );
}
else
{
@@ -2341,7 +2341,7 @@ void BasicCollection::CollRemove( SbxArray* pPar_ )
}
else
{
- SetError( SbERR_BAD_ARGUMENT );
+ SetError( ERRCODE_BASIC_BAD_ARGUMENT );
}
}
diff --git a/basic/source/classes/sb.src b/basic/source/classes/sb.src
index 50d8e14..e3da1c4 100644
--- a/basic/source/classes/sb.src
+++ b/basic/source/classes/sb.src
@@ -23,484 +23,484 @@
Resource RID_BASIC_START
{
- String SbERR_SYNTAX & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_SYNTAX & ERRCODE_RES_MASK
{
Text [ en-US ] = "Syntax error." ;
};
- String SbERR_NO_GOSUB & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_NO_GOSUB & ERRCODE_RES_MASK
{
Text [ en-US ] = "Return without Gosub." ;
};
- String SbERR_REDO_FROM_START & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_REDO_FROM_START & ERRCODE_RES_MASK
{
Text [ en-US ] = "Incorrect entry; please retry." ;
};
- String SbERR_BAD_ARGUMENT & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_BAD_ARGUMENT & ERRCODE_RES_MASK
{
Text [ en-US ] = "Invalid procedure call." ;
};
- String SbERR_MATH_OVERFLOW & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_MATH_OVERFLOW & ERRCODE_RES_MASK
{
Text [ en-US ] = "Overflow." ;
};
- String SbERR_NO_MEMORY & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_NO_MEMORY & ERRCODE_RES_MASK
{
Text [ en-US ] = "Not enough memory." ;
};
- String SbERR_ALREADY_DIM & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_ALREADY_DIM & ERRCODE_RES_MASK
{
Text [ en-US ] = "Array already dimensioned." ;
};
- String SbERR_OUT_OF_RANGE & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_OUT_OF_RANGE & ERRCODE_RES_MASK
{
Text [ en-US ] = "Index out of defined range." ;
};
- String SbERR_DUPLICATE_DEF & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_DUPLICATE_DEF & ERRCODE_RES_MASK
{
Text [ en-US ] = "Duplicate definition." ;
};
- String SbERR_ZERODIV & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_ZERODIV & ERRCODE_RES_MASK
{
Text [ en-US ] = "Division by zero." ;
};
- String SbERR_VAR_UNDEFINED & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_VAR_UNDEFINED & ERRCODE_RES_MASK
{
Text [ en-US ] = "Variable not defined." ;
};
- String SbERR_CONVERSION & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_CONVERSION & ERRCODE_RES_MASK
{
Text [ en-US ] = "Data type mismatch." ;
};
- String SbERR_BAD_PARAMETER & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_BAD_PARAMETER & ERRCODE_RES_MASK
{
Text [ en-US ] = "Invalid parameter." ;
};
- String SbERR_USER_ABORT & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_USER_ABORT & ERRCODE_RES_MASK
{
Text [ en-US ] = "Process interrupted by user." ;
};
- String SbERR_BAD_RESUME & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_BAD_RESUME & ERRCODE_RES_MASK
{
Text [ en-US ] = "Resume without error." ;
};
- String SbERR_STACK_OVERFLOW & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_STACK_OVERFLOW & ERRCODE_RES_MASK
{
Text [ en-US ] = "Not enough stack memory." ;
};
- String SbERR_PROC_UNDEFINED & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_PROC_UNDEFINED & ERRCODE_RES_MASK
{
Text [ en-US ] = "Sub-procedure or function procedure not defined." ;
};
- String SbERR_BAD_DLL_LOAD & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_BAD_DLL_LOAD & ERRCODE_RES_MASK
{
Text [ en-US ] = "Error loading DLL file." ;
};
- String SbERR_BAD_DLL_CALL & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_BAD_DLL_CALL & ERRCODE_RES_MASK
{
Text [ en-US ] = "Wrong DLL call convention." ;
};
- String SbERR_INTERNAL_ERROR & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_INTERNAL_ERROR & ERRCODE_RES_MASK
{
Text [ en-US ] = "Internal error $(ARG1)." ;
};
- String SbERR_BAD_CHANNEL & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_BAD_CHANNEL & ERRCODE_RES_MASK
{
Text [ en-US ] = "Invalid file name or file number." ;
};
- String SbERR_FILE_NOT_FOUND & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_FILE_NOT_FOUND & ERRCODE_RES_MASK
{
Text [ en-US ] = "File not found." ;
};
- String SbERR_BAD_FILE_MODE & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_BAD_FILE_MODE & ERRCODE_RES_MASK
{
Text [ en-US ] = "Incorrect file mode." ;
};
- String SbERR_FILE_ALREADY_OPEN & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_FILE_ALREADY_OPEN & ERRCODE_RES_MASK
{
Text [ en-US ] = "File already open." ;
};
- String SbERR_IO_ERROR & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_IO_ERROR & ERRCODE_RES_MASK
{
Text [ en-US ] = "Device I/O error." ;
};
- String SbERR_FILE_EXISTS & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_FILE_EXISTS & ERRCODE_RES_MASK
{
Text [ en-US ] = "File already exists." ;
};
- String SbERR_BAD_RECORD_LENGTH & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_BAD_RECORD_LENGTH & ERRCODE_RES_MASK
{
Text [ en-US ] = "Incorrect record length." ;
};
- String SbERR_DISK_FULL & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_DISK_FULL & ERRCODE_RES_MASK
{
Text [ en-US ] = "Disk or hard drive full." ;
};
- String SbERR_READ_PAST_EOF & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_READ_PAST_EOF & ERRCODE_RES_MASK
{
Text [ en-US ] = "Reading exceeds EOF." ;
};
- String SbERR_BAD_RECORD_NUMBER & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_BAD_RECORD_NUMBER & ERRCODE_RES_MASK
{
Text [ en-US ] = "Incorrect record number." ;
};
- String SbERR_TOO_MANY_FILES & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_TOO_MANY_FILES & ERRCODE_RES_MASK
{
Text [ en-US ] = "Too many files." ;
};
- String SbERR_NO_DEVICE & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_NO_DEVICE & ERRCODE_RES_MASK
{
Text [ en-US ] = "Device not available." ;
};
- String SbERR_ACCESS_DENIED & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_ACCESS_DENIED & ERRCODE_RES_MASK
{
Text [ en-US ] = "Access denied." ;
};
- String SbERR_NOT_READY & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_NOT_READY & ERRCODE_RES_MASK
{
Text [ en-US ] = "Disk not ready." ;
};
- String SbERR_NOT_IMPLEMENTED & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_NOT_IMPLEMENTED & ERRCODE_RES_MASK
{
Text [ en-US ] = "Not implemented." ;
};
- String SbERR_DIFFERENT_DRIVE & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_DIFFERENT_DRIVE & ERRCODE_RES_MASK
{
Text [ en-US ] = "Renaming on different drives impossible." ;
};
- String SbERR_ACCESS_ERROR & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_ACCESS_ERROR & ERRCODE_RES_MASK
{
Text [ en-US ] = "Path/File access error." ;
};
- String SbERR_PATH_NOT_FOUND & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_PATH_NOT_FOUND & ERRCODE_RES_MASK
{
Text [ en-US ] = "Path not found." ;
};
- String SbERR_NO_OBJECT & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_NO_OBJECT & ERRCODE_RES_MASK
{
Text [ en-US ] = "Object variable not set." ;
};
- String SbERR_BAD_PATTERN & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_BAD_PATTERN & ERRCODE_RES_MASK
{
Text [ en-US ] = "Invalid string pattern." ;
};
- String SBERR_IS_NULL & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_IS_NULL & ERRCODE_RES_MASK
{
Text [ en-US ] = "Use of zero not permitted." ;
};
- String SbERR_DDE_ERROR & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_DDE_ERROR & ERRCODE_RES_MASK
{
Text [ en-US ] = "DDE Error." ;
};
- String SbERR_DDE_WAITINGACK & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_DDE_WAITINGACK & ERRCODE_RES_MASK
{
Text [ en-US ] = "Awaiting response to DDE connection." ;
};
- String SbERR_DDE_OUTOFCHANNELS & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_DDE_OUTOFCHANNELS & ERRCODE_RES_MASK
{
Text [ en-US ] = "No DDE channels available." ;
};
- String SbERR_DDE_NO_RESPONSE & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_DDE_NO_RESPONSE & ERRCODE_RES_MASK
{
Text [ en-US ] = "No application responded to DDE connect initiation." ;
};
- String SbERR_DDE_MULT_RESPONSES & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_DDE_MULT_RESPONSES & ERRCODE_RES_MASK
{
Text [ en-US ] = "Too many applications responded to DDE connect initiation." ;
};
- String SbERR_DDE_CHANNEL_LOCKED & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_DDE_CHANNEL_LOCKED & ERRCODE_RES_MASK
{
Text [ en-US ] = "DDE channel locked." ;
};
- String SbERR_DDE_NOTPROCESSED & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_DDE_NOTPROCESSED & ERRCODE_RES_MASK
{
Text [ en-US ] = "External application cannot execute DDE operation." ;
};
- String SbERR_DDE_TIMEOUT & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_DDE_TIMEOUT & ERRCODE_RES_MASK
{
Text [ en-US ] = "Timeout while waiting for DDE response." ;
};
- String SbERR_DDE_USER_INTERRUPT & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_DDE_USER_INTERRUPT & ERRCODE_RES_MASK
{
Text [ en-US ] = "User pressed ESCAPE during DDE operation." ;
};
- String SbERR_DDE_BUSY & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_DDE_BUSY & ERRCODE_RES_MASK
{
Text [ en-US ] = "External application busy." ;
};
- String SbERR_DDE_NO_DATA & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_DDE_NO_DATA & ERRCODE_RES_MASK
{
Text [ en-US ] = "DDE operation without data." ;
};
- String SbERR_DDE_WRONG_DATA_FORMAT & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_DDE_WRONG_DATA_FORMAT & ERRCODE_RES_MASK
{
Text [ en-US ] = "Data are in wrong format." ;
};
- String SbERR_DDE_PARTNER_QUIT & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_DDE_PARTNER_QUIT & ERRCODE_RES_MASK
{
Text [ en-US ] = "External application has been terminated." ;
};
- String SbERR_DDE_CONV_CLOSED & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_DDE_CONV_CLOSED & ERRCODE_RES_MASK
{
Text [ en-US ] = "DDE connection interrupted or modified." ;
};
- String SbERR_DDE_NO_CHANNEL & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_DDE_NO_CHANNEL & ERRCODE_RES_MASK
{
Text [ en-US ] = "DDE method invoked with no channel open." ;
};
- String SbERR_DDE_INVALID_LINK & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_DDE_INVALID_LINK & ERRCODE_RES_MASK
{
Text [ en-US ] = "Invalid DDE link format." ;
};
- String SbERR_DDE_QUEUE_OVERFLOW & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_DDE_QUEUE_OVERFLOW & ERRCODE_RES_MASK
{
Text [ en-US ] = "DDE message has been lost." ;
};
- String SbERR_DDE_LINK_ALREADY_EST & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_DDE_LINK_ALREADY_EST & ERRCODE_RES_MASK
{
Text [ en-US ] = "Paste link already performed." ;
};
- String SbERR_DDE_LINK_INV_TOPIC & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_DDE_LINK_INV_TOPIC & ERRCODE_RES_MASK
{
Text [ en-US ] = "Link mode cannot be set due to invalid link topic." ;
};
- String SbERR_DDE_DLL_NOT_FOUND & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_DDE_DLL_NOT_FOUND & ERRCODE_RES_MASK
{
Text [ en-US ] = "DDE requires the DDEML.DLL file." ;
};
- String SbERR_CANNOT_LOAD & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_CANNOT_LOAD & ERRCODE_RES_MASK
{
Text [ en-US ] = "Module cannot be loaded; invalid format." ;
};
- String SbERR_BAD_INDEX & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_BAD_INDEX & ERRCODE_RES_MASK
{
Text [ en-US ] = "Invalid object index." ;
};
- String SbERR_NO_ACTIVE_OBJECT & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_NO_ACTIVE_OBJECT & ERRCODE_RES_MASK
{
Text [ en-US ] = "Object is not available." ;
};
- String SbERR_BAD_PROP_VALUE & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_BAD_PROP_VALUE & ERRCODE_RES_MASK
{
Text [ en-US ] = "Incorrect property value." ;
};
- String SbERR_PROP_READONLY & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_PROP_READONLY & ERRCODE_RES_MASK
{
Text [ en-US ] = "This property is read-only." ;
};
- String SbERR_PROP_WRITEONLY & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_PROP_WRITEONLY & ERRCODE_RES_MASK
{
Text [ en-US ] = "This property is write only." ;
};
- String SbERR_INVALID_OBJECT & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_INVALID_OBJECT & ERRCODE_RES_MASK
{
Text [ en-US ] = "Invalid object reference." ;
};
- String SbERR_NO_METHOD & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_NO_METHOD & ERRCODE_RES_MASK
{
Text [ en-US ] = "Property or method not found: $(ARG1)." ;
};
- String SbERR_NEEDS_OBJECT & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_NEEDS_OBJECT & ERRCODE_RES_MASK
{
Text [ en-US ] = "Object required." ;
};
- String SbERR_INVALID_USAGE_OBJECT & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_INVALID_USAGE_OBJECT & ERRCODE_RES_MASK
{
Text [ en-US ] = "Invalid use of an object." ;
};
- String SbERR_NO_OLE & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_NO_OLE & ERRCODE_RES_MASK
{
Text [ en-US ] = "OLE Automation is not supported by this object." ;
};
- String SbERR_BAD_METHOD & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_BAD_METHOD & ERRCODE_RES_MASK
{
Text [ en-US ] = "This property or method is not supported by the object." ;
};
- String SbERR_OLE_ERROR & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_OLE_ERROR & ERRCODE_RES_MASK
{
Text [ en-US ] = "OLE Automation Error." ;
};
- String SbERR_BAD_ACTION & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_BAD_ACTION & ERRCODE_RES_MASK
{
Text [ en-US ] = "This action is not supported by given object." ;
};
- String SbERR_NO_NAMED_ARGS & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_NO_NAMED_ARGS & ERRCODE_RES_MASK
{
Text [ en-US ] = "Named arguments are not supported by given object." ;
};
- String SbERR_BAD_LOCALE & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_BAD_LOCALE & ERRCODE_RES_MASK
{
Text [ en-US ] = "The current locale setting is not supported by the given object." ;
};
- String SbERR_NAMED_NOT_FOUND & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_NAMED_NOT_FOUND & ERRCODE_RES_MASK
{
Text [ en-US ] = "Named argument not found." ;
};
- String SbERR_NOT_OPTIONAL & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_NOT_OPTIONAL & ERRCODE_RES_MASK
{
Text [ en-US ] = "Argument is not optional." ;
};
- String SbERR_WRONG_ARGS & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_WRONG_ARGS & ERRCODE_RES_MASK
{
Text [ en-US ] = "Invalid number of arguments." ;
};
- String SbERR_NOT_A_COLL & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_NOT_A_COLL & ERRCODE_RES_MASK
{
Text [ en-US ] = "Object is not a list." ;
};
- String SbERR_BAD_ORDINAL & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_BAD_ORDINAL & ERRCODE_RES_MASK
{
Text [ en-US ] = "Invalid ordinal number." ;
};
- String SbERR_DLLPROC_NOT_FOUND & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_DLLPROC_NOT_FOUND & ERRCODE_RES_MASK
{
Text [ en-US ] = "Specified DLL function not found." ;
};
- String SbERR_BAD_CLIPBD_FORMAT & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_BAD_CLIPBD_FORMAT & ERRCODE_RES_MASK
{
Text [ en-US ] = "Invalid clipboard format." ;
};
- String SbERR_PROPERTY_NOT_FOUND & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_PROPERTY_NOT_FOUND & ERRCODE_RES_MASK
{
Text [ en-US ] = "Object does not have this property." ;
};
- String SbERR_METHOD_NOT_FOUND & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_METHOD_NOT_FOUND & ERRCODE_RES_MASK
{
Text [ en-US ] = "Object does not have this method." ;
};
- String SbERR_ARG_MISSING & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_ARG_MISSING & ERRCODE_RES_MASK
{
Text [ en-US ] = "Required argument lacking." ;
};
- String SbERR_BAD_NUMBER_OF_ARGS & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_BAD_NUMBER_OF_ARGS & ERRCODE_RES_MASK
{
Text [ en-US ] = "Invalid number of arguments." ;
};
- String SbERR_METHOD_FAILED & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_METHOD_FAILED & ERRCODE_RES_MASK
{
Text [ en-US ] = "Error executing a method." ;
};
- String SbERR_SETPROP_FAILED & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_SETPROP_FAILED & ERRCODE_RES_MASK
{
Text [ en-US ] = "Unable to set property." ;
};
- String SbERR_GETPROP_FAILED & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_GETPROP_FAILED & ERRCODE_RES_MASK
{
Text [ en-US ] = "Unable to determine property." ;
};
// Compiler errors. These are not runtime errors.
- String SbERR_UNEXPECTED & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_UNEXPECTED & ERRCODE_RES_MASK
{
Text [ en-US ] = "Unexpected symbol: $(ARG1)." ;
};
- String SbERR_EXPECTED & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_EXPECTED & ERRCODE_RES_MASK
{
Text [ en-US ] = "Expected: $(ARG1)." ;
};
- String SbERR_SYMBOL_EXPECTED & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_SYMBOL_EXPECTED & ERRCODE_RES_MASK
{
Text [ en-US ] = "Symbol expected." ;
};
- String SbERR_VAR_EXPECTED & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_VAR_EXPECTED & ERRCODE_RES_MASK
{
Text [ en-US ] = "Variable expected." ;
};
- String SbERR_LABEL_EXPECTED & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_LABEL_EXPECTED & ERRCODE_RES_MASK
{
Text [ en-US ] = "Label expected." ;
};
- String SbERR_LVALUE_EXPECTED & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_LVALUE_EXPECTED & ERRCODE_RES_MASK
{
Text [ en-US ] = "Value cannot be applied." ;
};
- String SbERR_VAR_DEFINED & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_VAR_DEFINED & ERRCODE_RES_MASK
{
Text [ en-US ] = "Variable $(ARG1) already defined." ;
};
- String SbERR_PROC_DEFINED & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_PROC_DEFINED & ERRCODE_RES_MASK
{
Text [ en-US ] = "Sub procedure or function procedure $(ARG1) already defined." ;
};
- String SbERR_LABEL_DEFINED & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_LABEL_DEFINED & ERRCODE_RES_MASK
{
Text [ en-US ] = "Label $(ARG1) already defined." ;
};
- String SbERR_UNDEF_VAR & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_UNDEF_VAR & ERRCODE_RES_MASK
{
Text [ en-US ] = "Variable $(ARG1) not found." ;
};
- String SbERR_UNDEF_ARRAY & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_UNDEF_ARRAY & ERRCODE_RES_MASK
{
Text [ en-US ] = "Array or procedure $(ARG1) not found." ;
};
- String SbERR_UNDEF_PROC & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_UNDEF_PROC & ERRCODE_RES_MASK
{
Text [ en-US ] = "Procedure $(ARG1) not found." ;
};
- String SbERR_UNDEF_LABEL & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_UNDEF_LABEL & ERRCODE_RES_MASK
{
Text [ en-US ] = "Label $(ARG1) undefined." ;
};
- String SbERR_UNDEF_TYPE & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_UNDEF_TYPE & ERRCODE_RES_MASK
{
Text [ en-US ] = "Unknown data type $(ARG1)." ;
};
- String SbERR_BAD_EXIT & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_BAD_EXIT & ERRCODE_RES_MASK
{
Text [ en-US ] = "Exit $(ARG1) expected." ;
};
- String SbERR_BAD_BLOCK & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_BAD_BLOCK & ERRCODE_RES_MASK
{
Text [ en-US ] = "Statement block still open: $(ARG1) missing." ;
};
- String SbERR_BAD_BRACKETS & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_BAD_BRACKETS & ERRCODE_RES_MASK
{
Text [ en-US ] = "Parentheses do not match." ;
};
- String SbERR_BAD_DECLARATION & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_BAD_DECLARATION & ERRCODE_RES_MASK
{
Text [ en-US ] = "Symbol $(ARG1) already defined differently." ;
};
- String SbERR_BAD_PARAMETERS & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_BAD_PARAMETERS & ERRCODE_RES_MASK
{
Text [ en-US ] = "Parameters do not correspond to procedure." ;
};
- String SbERR_BAD_CHAR_IN_NUMBER & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_BAD_CHAR_IN_NUMBER & ERRCODE_RES_MASK
{
Text [ en-US ] = "Invalid character in number." ;
};
- String SbERR_MUST_HAVE_DIMS & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_MUST_HAVE_DIMS & ERRCODE_RES_MASK
{
Text [ en-US ] = "Array must be dimensioned." ;
};
- String SbERR_NO_IF & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_NO_IF & ERRCODE_RES_MASK
{
Text [ en-US ] = "Else/Endif without If." ;
};
- String SbERR_NOT_IN_SUBR & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_NOT_IN_SUBR & ERRCODE_RES_MASK
{
Text [ en-US ] = "$(ARG1) not allowed within a procedure." ;
};
- String SbERR_NOT_IN_MAIN & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_NOT_IN_MAIN & ERRCODE_RES_MASK
{
Text [ en-US ] = "$(ARG1) not allowed outside a procedure." ;
};
- String SbERR_WRONG_DIMS & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_WRONG_DIMS & ERRCODE_RES_MASK
{
Text [ en-US ] = "Dimension specifications do not match." ;
};
- String SbERR_BAD_OPTION & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_BAD_OPTION & ERRCODE_RES_MASK
{
Text [ en-US ] = "Unknown option: $(ARG1)." ;
};
- String SbERR_CONSTANT_REDECLARED & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_CONSTANT_REDECLARED & ERRCODE_RES_MASK
{
Text [ en-US ] = "Constant $(ARG1) redefined." ;
};
- String SbERR_PROG_TOO_LARGE & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_PROG_TOO_LARGE & ERRCODE_RES_MASK
{
Text [ en-US ] = "Program too large." ;
};
- String SbERR_NO_STRINGS_ARRAYS & ERRCODE_RES_MASK
+ String ERRCODE_BASIC_NO_STRINGS_ARRAYS & ERRCODE_RES_MASK
{
Text [ en-US ] = "Strings or arrays not permitted." ;
};
diff --git a/basic/source/classes/sbunoobj.cxx b/basic/source/classes/sbunoobj.cxx
index 1812ac4..92d5952 100644
--- a/basic/source/classes/sbunoobj.cxx
+++ b/basic/source/classes/sbunoobj.cxx
@@ -585,7 +585,7 @@ static void implSequenceToMultiDimArray( SbxDimArray*& pArray, Sequence< sal_Int
// should equal number of dimensions in the array )
// And that should at least be 1 !
// #QUESTION is there a better error?
- StarBASIC::Error( SbERR_INVALID_OBJECT );
+ StarBASIC::Error( ERRCODE_BASIC_INVALID_OBJECT );
return;
}
@@ -1152,7 +1152,7 @@ static Any implRekMultiDimArrayToSequence( SbxDimArray* pArray,
}
catch (const IndexOutOfBoundsException&)
{
- StarBASIC::Error( SbERR_OUT_OF_RANGE );
+ StarBASIC::Error( ERRCODE_BASIC_OUT_OF_RANGE );
}
}
return aRetVal;
@@ -1368,7 +1368,7 @@ Any sbxToUnoValue( const SbxValue* pVar, const Type& rType, Property* pUnoProper
}
catch (const IndexOutOfBoundsException&)
{
- StarBASIC::Error( SbERR_OUT_OF_RANGE );
+ StarBASIC::Error( ERRCODE_BASIC_OUT_OF_RANGE );
}
}
}
@@ -2080,7 +2080,7 @@ void SbUnoObject::Notify( SfxBroadcaster& rBC, const SfxHint& rHint )
StructRefInfo aMember = maStructInfo->getStructMember( pProp->GetName() );
if ( aMember.isEmpty() )
{
- StarBASIC::Error( SbERR_PROPERTY_NOT_FOUND );
+ StarBASIC::Error( ERRCODE_BASIC_PROPERTY_NOT_FOUND );
}
else
{
@@ -2149,7 +2149,7 @@ void SbUnoObject::Notify( SfxBroadcaster& rBC, const SfxHint& rHint )
{
if( pProp->aUnoProp.Attributes & PropertyAttribute::READONLY )
{
- StarBASIC::Error( SbERR_PROP_READONLY );
+ StarBASIC::Error( ERRCODE_BASIC_PROP_READONLY );
return;
}
if ( maStructInfo.get() )
@@ -2157,7 +2157,7 @@ void SbUnoObject::Notify( SfxBroadcaster& rBC, const SfxHint& rHint )
StructRefInfo aMember = maStructInfo->getStructMember( pProp->GetName() );
if ( aMember.isEmpty() )
{
- StarBASIC::Error( SbERR_PROPERTY_NOT_FOUND );
+ StarBASIC::Error( ERRCODE_BASIC_PROPERTY_NOT_FOUND );
}
else
{
@@ -2237,7 +2237,7 @@ void SbUnoObject::Notify( SfxBroadcaster& rBC, const SfxHint& rHint )
if( rxClass->getTypeClass() != TypeClass_ANY )
{
bError = true;
- StarBASIC::Error( SbERR_NOT_OPTIONAL );
+ StarBASIC::Error( ERRCODE_BASIC_NOT_OPTIONAL );
}
}
if( !bError )
@@ -2969,7 +2969,7 @@ void RTL_Impl_CreateUnoStruct( StarBASIC* pBasic, SbxArray& rPar, bool bWrite )
// We need 1 parameter minimum
if ( rPar.Count() < 2 )
{
- StarBASIC::Error( SbERR_BAD_ARGUMENT );
+ StarBASIC::Error( ERRCODE_BASIC_BAD_ARGUMENT );
return;
}
@@ -2995,7 +2995,7 @@ void RTL_Impl_CreateUnoService( StarBASIC* pBasic, SbxArray& rPar, bool bWrite )
// We need 1 Parameter minimum
if ( rPar.Count() < 2 )
{
- StarBASIC::Error( SbERR_BAD_ARGUMENT );
+ StarBASIC::Error( ERRCODE_BASIC_BAD_ARGUMENT );
return;
}
@@ -3046,7 +3046,7 @@ void RTL_Impl_CreateUnoServiceWithArguments( StarBASIC* pBasic, SbxArray& rPar,
// We need 2 parameter minimum
if ( rPar.Count() < 3 )
{
- StarBASIC::Error( SbERR_BAD_ARGUMENT );
+ StarBASIC::Error( ERRCODE_BASIC_BAD_ARGUMENT );
return;
}
@@ -3119,7 +3119,7 @@ void RTL_Impl_HasInterfaces( StarBASIC* pBasic, SbxArray& rPar, bool bWrite )
sal_uInt16 nParCount = rPar.Count();
if( nParCount < 3 )
{
- StarBASIC::Error( SbERR_BAD_ARGUMENT );
+ StarBASIC::Error( ERRCODE_BASIC_BAD_ARGUMENT );
return;
}
@@ -3180,7 +3180,7 @@ void RTL_Impl_IsUnoStruct( StarBASIC* pBasic, SbxArray& rPar, bool bWrite )
// We need 1 parameter minimum
if ( rPar.Count() < 2 )
{
- StarBASIC::Error( SbERR_BAD_ARGUMENT );
+ StarBASIC::Error( ERRCODE_BASIC_BAD_ARGUMENT );
return;
}
@@ -3215,7 +3215,7 @@ void RTL_Impl_EqualUnoObjects( StarBASIC* pBasic, SbxArray& rPar, bool bWrite )
if ( rPar.Count() < 3 )
{
- StarBASIC::Error( SbERR_BAD_ARGUMENT );
+ StarBASIC::Error( ERRCODE_BASIC_BAD_ARGUMENT );
return;
}
@@ -3673,7 +3673,7 @@ void SbUnoService::Notify( SfxBroadcaster& rBC, const SfxHint& rHint )
if( !bRestParameterMode || nDiff > 1 )
{
bParameterError = true;
- StarBASIC::Error( SbERR_NOT_OPTIONAL );
+ StarBASIC::Error( ERRCODE_BASIC_NOT_OPTIONAL );
}
}
@@ -3856,7 +3856,7 @@ void SbUnoSingleton::Notify( SfxBroadcaster& rBC, const SfxHint& rHint )
if( nParamCount > nAllowedParamCount )
{
- StarBASIC::Error( SbERR_BAD_ARGUMENT );
+ StarBASIC::Error( ERRCODE_BASIC_BAD_ARGUMENT );
return;
}
@@ -4157,7 +4157,7 @@ void SbRtl_CreateUnoListener( StarBASIC* pBasic, SbxArray& rPar, bool bWrite )
// We need 2 parameters
if ( rPar.Count() != 3 )
{
- StarBASIC::Error( SbERR_BAD_ARGUMENT );
+ StarBASIC::Error( ERRCODE_BASIC_BAD_ARGUMENT );
return;
}
@@ -4237,7 +4237,7 @@ void RTL_Impl_CreateUnoValue( StarBASIC* pBasic, SbxArray& rPar, bool bWrite )
// 2 parameters needed
if ( rPar.Count() != 3 )
{
- StarBASIC::Error( SbERR_BAD_ARGUMENT );
+ StarBASIC::Error( ERRCODE_BASIC_BAD_ARGUMENT );
return;
}
@@ -4390,7 +4390,7 @@ void SAL_CALL ModuleInvocationProxy::setValue(const OUString& rProperty, const A
if( pMeth == NULL )
{
// TODO: Check vba behavior concernig missing function
- //StarBASIC::Error( SbERR_NO_METHOD, aFunctionName );
+ //StarBASIC::Error( ERRCODE_BASIC_NO_METHOD, aFunctionName );
throw UnknownPropertyException();
}
@@ -4430,7 +4430,7 @@ Any SAL_CALL ModuleInvocationProxy::getValue(const OUString& rProperty)
if( pMeth == NULL )
{
// TODO: Check vba behavior concernig missing function
- //StarBASIC::Error( SbERR_NO_METHOD, aFunctionName );
+ //StarBASIC::Error( ERRCODE_BASIC_NO_METHOD, aFunctionName );
throw UnknownPropertyException();
}
@@ -4487,7 +4487,7 @@ Any SAL_CALL ModuleInvocationProxy::invoke( const OUString& rFunction,
if( pMeth == NULL )
{
// TODO: Check vba behavior concernig missing function
- //StarBASIC::Error( SbERR_NO_METHOD, aFunctionName );
+ //StarBASIC::Error( ERRCODE_BASIC_NO_METHOD, aFunctionName );
return aRet;
}
@@ -5055,7 +5055,7 @@ void SbUnoStructRefObject::Notify( SfxBroadcaster& rBC, const SfxHint& rHint )
unoToSbxValue( pVar, aRetAny );
}
else
- StarBASIC::Error( SbERR_PROPERTY_NOT_FOUND );
+ StarBASIC::Error( ERRCODE_BASIC_PROPERTY_NOT_FOUND );
}
else if( pHint->GetId() == SBX_HINT_DATACHANGED )
{
@@ -5066,7 +5066,7 @@ void SbUnoStructRefObject::Notify( SfxBroadcaster& rBC, const SfxHint& rHint )
it->second->setValue( aAnyValue );
}
else
- StarBASIC::Error( SbERR_PROPERTY_NOT_FOUND );
+ StarBASIC::Error( ERRCODE_BASIC_PROPERTY_NOT_FOUND );
}
}
else
diff --git a/basic/source/classes/sbxmod.cxx b/basic/source/classes/sbxmod.cxx
index 7e04ce1..3ced494 100644
--- a/basic/source/classes/sbxmod.cxx
+++ b/basic/source/classes/sbxmod.cxx
@@ -833,7 +833,7 @@ void SbModule::Notify( SfxBroadcaster& rBC, const SfxHint& rHint )
if( pMeth->bInvalid && !Compile() )
{
// auto compile has not worked!
- StarBASIC::Error( SbERR_BAD_PROP_VALUE );
+ StarBASIC::Error( ERRCODE_BASIC_BAD_PROP_VALUE );
}
else
{
@@ -1245,7 +1245,7 @@ void SbModule::Run( SbMethod* pMeth )
else
{
GetSbData()->pInst->nCallLvl--; // Call-Level down again
- StarBASIC::FatalError( SbERR_STACK_OVERFLOW );
+ StarBASIC::FatalError( ERRCODE_BASIC_STACK_OVERFLOW );
}
StarBASIC* pBasic = PTR_CAST(StarBASIC,GetParent());
@@ -1517,7 +1517,7 @@ const sal_uInt8* SbModule::FindNextStmnt( const sal_uInt8* p, sal_uInt16& nLine,
p += 8, nPC += 8;
else if( !( eOp >= SbOP0_START && eOp <= SbOP0_END ) )
{
- StarBASIC::FatalError( SbERR_INTERNAL_ERROR );
+ StarBASIC::FatalError( ERRCODE_BASIC_INTERNAL_ERROR );
break;
}
}
@@ -2097,7 +2097,7 @@ ErrCode SbMethod::Call( SbxValue* pRet, SbxVariable* pCaller )
// #104083: Compile BEFORE get
if( bInvalid && !pMod_->Compile() )
- StarBASIC::Error( SbERR_BAD_PROP_VALUE );
+ StarBASIC::Error( ERRCODE_BASIC_BAD_PROP_VALUE );
Get( aVals );
if ( pRet )
diff --git a/basic/source/comp/buffer.cxx b/basic/source/comp/buffer.cxx
index a21ad03..141186f 100644
--- a/basic/source/comp/buffer.cxx
+++ b/basic/source/comp/buffer.cxx
@@ -87,7 +87,7 @@ bool SbiBuffer::Check( sal_Int32 n )
}
if( !p )
{
- pParser->Error( SbERR_PROG_TOO_LARGE );
+ pParser->Error( ERRCODE_BASIC_PROG_TOO_LARGE );
nInc = 0;
delete[] pBuf; pBuf = NULL;
return false;
@@ -140,7 +140,7 @@ void SbiBuffer::Chain( sal_uInt32 off )
if( i >= nOff )
{
- pParser->Error( SbERR_INTERNAL_ERROR, "BACKCHAIN" );
+ pParser->Error( ERRCODE_BASIC_INTERNAL_ERROR, "BACKCHAIN" );
break;
}
*ip++ = (char) ( val1 & 0xFF );
diff --git a/basic/source/comp/codegen.cxx b/basic/source/comp/codegen.cxx
index 7a9dc02..cd7c197 100644
--- a/basic/source/comp/codegen.cxx
+++ b/basic/source/comp/codegen.cxx
@@ -85,7 +85,7 @@ sal_uInt32 SbiCodeGen::Gen( SbiOpcode eOpcode )
#ifdef DBG_UTIL
if( eOpcode < SbOP0_START || eOpcode > SbOP0_END )
- pParser->Error( SbERR_INTERNAL_ERROR, "OPCODE1" );
+ pParser->Error( ERRCODE_BASIC_INTERNAL_ERROR, "OPCODE1" );
#endif
GenStmnt();
aCode += (sal_uInt8) eOpcode;
@@ -99,7 +99,7 @@ sal_uInt32 SbiCodeGen::Gen( SbiOpcode eOpcode, sal_uInt32 nOpnd )
#ifdef DBG_UTIL
if( eOpcode < SbOP1_START || eOpcode > SbOP1_END )
- pParser->Error( SbERR_INTERNAL_ERROR, "OPCODE2" );
+ pParser->Error( ERRCODE_BASIC_INTERNAL_ERROR, "OPCODE2" );
#endif
GenStmnt();
aCode += (sal_uInt8) eOpcode;
@@ -115,7 +115,7 @@ sal_uInt32 SbiCodeGen::Gen( SbiOpcode eOpcode, sal_uInt32 nOpnd1, sal_uInt32 nOp
#ifdef DBG_UTIL
if( eOpcode < SbOP2_START || eOpcode > SbOP2_END )
- pParser->Error( SbERR_INTERNAL_ERROR, "OPCODE3" );
+ pParser->Error( ERRCODE_BASIC_INTERNAL_ERROR, "OPCODE3" );
#endif
GenStmnt();
aCode += (sal_uInt8) eOpcode;
diff --git a/basic/source/comp/dim.cxx b/basic/source/comp/dim.cxx
index b9f7aef..eaeea2c 100644
--- a/basic/source/comp/dim.cxx
+++ b/basic/source/comp/dim.cxx
@@ -67,7 +67,7 @@ SbiSymDef* SbiParser::VarDecl( SbiDimList** ppDim, bool bStatic, bool bConst )
if( !ppDim && pDim )
{
if(pDim->GetDims() )
- Error( SbERR_EXPECTED, "()" );
+ Error( ERRCODE_BASIC_EXPECTED, "()" );
delete pDim;
}
else if( ppDim )
@@ -97,7 +97,7 @@ void SbiParser::TypeDecl( SbiSymDef& rDef, bool bAsNewAlreadyParsed )
{
case ANY:
if( rDef.IsNew() )
- Error( SbERR_SYNTAX );
+ Error( ERRCODE_BASIC_SYNTAX );
eType = SbxVARIANT; break;
case TINTEGER:
case TLONG:
@@ -112,7 +112,7 @@ void SbiParser::TypeDecl( SbiSymDef& rDef, bool bAsNewAlreadyParsed )
case TVARIANT:
case TBYTE:
if( rDef.IsNew() )
- Error( SbERR_SYNTAX );
+ Error( ERRCODE_BASIC_SYNTAX );
eType = (eTok==TBYTE) ? SbxBYTE : SbxDataType( eTok - TINTEGER + SbxINTEGER );
if( eType == SbxSTRING )
{
@@ -123,7 +123,7 @@ void SbiParser::TypeDecl( SbiSymDef& rDef, bool bAsNewAlreadyParsed )
SbiConstExpression aSize( this );
nSize = aSize.GetShortValue();
if( nSize < 0 || (bVBASupportOn && nSize <= 0) )
- Error( SbERR_OUT_OF_RANGE );
+ Error( ERRCODE_BASIC_OUT_OF_RANGE );
else
rDef.SetFixedStringLength( nSize );
}
@@ -131,7 +131,7 @@ void SbiParser::TypeDecl( SbiSymDef& rDef, bool bAsNewAlreadyParsed )
break;
case SYMBOL: // can only be a TYPE or a object class!
if( eScanType != SbxVARIANT )
- Error( SbERR_SYNTAX );
+ Error( ERRCODE_BASIC_SYNTAX );
else
{
OUString aCompleteName = aSym;
@@ -153,7 +153,7 @@ void SbiParser::TypeDecl( SbiSymDef& rDef, bool bAsNewAlreadyParsed )
else
{
Next();
- Error( SbERR_UNEXPECTED, SYMBOL );
+ Error( ERRCODE_BASIC_UNEXPECTED, SYMBOL );
break;
}
}
@@ -177,16 +177,16 @@ void SbiParser::TypeDecl( SbiSymDef& rDef, bool bAsNewAlreadyParsed )
eType = SbxOBJECT;
break;
default:
- Error( SbERR_UNEXPECTED, eTok );
+ Error( ERRCODE_BASIC_UNEXPECTED, eTok );
Next();
}
// The variable could have been declared with a suffix
if( rDef.GetType() != SbxVARIANT )
{
if( rDef.GetType() != eType )
- Error( SbERR_VAR_DEFINED, rDef.GetName() );
+ Error( ERRCODE_BASIC_VAR_DEFINED, rDef.GetName() );
else if( eType == SbxSTRING && rDef.GetLen() != nSize )
- Error( SbERR_VAR_DEFINED, rDef.GetName() );
+ Error( ERRCODE_BASIC_VAR_DEFINED, rDef.GetName() );
}
rDef.SetType( eType );
rDef.SetLen( nSize );
@@ -209,7 +209,7 @@ void SbiParser::DefVar( SbiOpcode eOp, bool bStatic )
SbiToken eFirstTok = eCurTok;
if( pProc && ( eCurTok == GLOBAL || eCurTok == PUBLIC || eCurTok == PRIVATE ) )
- Error( SbERR_NOT_IN_SUBR, eCurTok );
+ Error( ERRCODE_BASIC_NOT_IN_SUBR, eCurTok );
if( eCurTok == PUBLIC || eCurTok == GLOBAL )
{
bSwitchPool = true; // at the right moment switch to the global pool
@@ -291,7 +291,7 @@ void SbiParser::DefVar( SbiOpcode eOp, bool bStatic )
if( eOp == _REDIM )
eOp = _REDIMP;
else
- Error( SbERR_UNEXPECTED, eCurTok );
+ Error( ERRCODE_BASIC_UNEXPECTED, eCurTok );
}
SbiSymDef* pDef;
SbiDimList* pDim;
@@ -346,10 +346,10 @@ void SbiParser::DefVar( SbiOpcode eOp, bool bStatic )
bError_ = true;
}
if( bError_ )
- Error( SbERR_VAR_DEFINED, pDef->GetName() );
+ Error( ERRCODE_BASIC_VAR_DEFINED, pDef->GetName() );
}
else
- Error( SbERR_VAR_DEFINED, pDef->GetName() );
+ Error( ERRCODE_BASIC_VAR_DEFINED, pDef->GetName() );
delete pDef; pDef = pOld;
}
else
@@ -409,16 +409,16 @@ void SbiParser::DefVar( SbiOpcode eOp, bool bStatic )
if( CodeCompleteOptions::IsExtendedTypeDeclaration() )
{
if(!IsUnoInterface(aTypeName))
- Error( SbERR_UNDEF_TYPE, aTypeName );
+ Error( ERRCODE_BASIC_UNDEF_TYPE, aTypeName );
}
else
- Error( SbERR_UNDEF_TYPE, aTypeName );
+ Error( ERRCODE_BASIC_UNDEF_TYPE, aTypeName );
}
}
if( bConst )
{
- Error( SbERR_SYNTAX );
+ Error( ERRCODE_BASIC_SYNTAX );
}
if( pDim )
@@ -461,7 +461,7 @@ void SbiParser::DefVar( SbiOpcode eOp, bool bStatic )
// Definition of the constants
if( pDim )
{
- Error( SbERR_SYNTAX );
+ Error( ERRCODE_BASIC_SYNTAX );
delete pDim;
}
SbiExpression aVar( this, *pDef );
@@ -582,7 +582,7 @@ void SbiParser::DefType( bool bPrivate )
if (rTypeArray->Find(aSym,SbxCLASS_OBJECT))
{
- Error( SbERR_VAR_DEFINED, aSym );
+ Error( ERRCODE_BASIC_VAR_DEFINED, aSym );
return;
}
@@ -617,7 +617,7 @@ void SbiParser::DefType( bool bPrivate )
OUString aElemName = pElem->GetName();
if( pTypeMembers->Find( aElemName, SbxCLASS_DONTCARE) )
{
- Error (SbERR_VAR_DEFINED);
+ Error (ERRCODE_BASIC_VAR_DEFINED);
}
else
{
@@ -638,7 +638,7 @@ void SbiParser::DefType( bool bPrivate )
if ( !pDim->Get( i )->IsBased() ) // each dim is low/up
{
if ( ++i >= pDim->GetSize() ) // trouble
- StarBASIC::FatalError( SbERR_INTERNAL_ERROR );
+ StarBASIC::FatalError( ERRCODE_BASIC_INTERNAL_ERROR );
pNode = pDim->Get(i)->GetExprNode();
lb = ub;
ub = pNode->GetNumber();
@@ -703,7 +703,7 @@ void SbiParser::DefEnum( bool bPrivate )
OUString aEnumName = aSym;
if( rEnumArray->Find(aEnumName,SbxCLASS_OBJECT) )
{
- Error( SbERR_VAR_DEFINED, aSym );
+ Error( ERRCODE_BASIC_VAR_DEFINED, aSym );
return;
}
@@ -747,7 +747,7 @@ void SbiParser::DefEnum( bool bPrivate )
else if( pDim )
{
delete pDim;
- Error( SbERR_SYNTAX );
+ Error( ERRCODE_BASIC_SYNTAX );
bDone = true; // Error occurred
break;
}
@@ -777,7 +777,7 @@ void SbiParser::DefEnum( bool bPrivate )
SbiSymDef* pOld = pPoolToUse->Find( pElem->GetName() );
if( pOld )
{
- Error( SbERR_VAR_DEFINED, pElem->GetName() );
+ Error( ERRCODE_BASIC_VAR_DEFINED, pElem->GetName() );
bDone = true; // Error occurred
break;
}
@@ -848,7 +848,7 @@ SbiProcDef* SbiParser::ProcDecl( bool bDecl )
}
else
{
- Error( SbERR_SYNTAX );
+ Error( ERRCODE_BASIC_SYNTAX );
}
}
if( Peek() == ALIAS )
@@ -860,7 +860,7 @@ SbiProcDef* SbiParser::ProcDecl( bool bDecl )
}
else
{
- Error( SbERR_SYNTAX );
+ Error( ERRCODE_BASIC_SYNTAX );
}
}
if( !bDecl )
@@ -868,15 +868,15 @@ SbiProcDef* SbiParser::ProcDecl( bool bDecl )
// CDECL, LIB and ALIAS are invalid
if( !pDef->GetLib().isEmpty() )
{
- Error( SbERR_UNEXPECTED, LIB );
+ Error( ERRCODE_BASIC_UNEXPECTED, LIB );
}
if( !pDef->GetAlias().isEmpty() )
{
- Error( SbERR_UNEXPECTED, ALIAS );
+ Error( ERRCODE_BASIC_UNEXPECTED, ALIAS );
}
if( pDef->IsCdecl() )
{
- Error( SbERR_UNEXPECTED, _CDECL_ );
+ Error( ERRCODE_BASIC_UNEXPECTED, _CDECL_ );
}
pDef->SetCdecl( false );
pDef->GetLib().clear();
@@ -887,11 +887,11 @@ SbiProcDef* SbiParser::ProcDecl( bool bDecl )
// ALIAS and CDECL only together with LIB
if( !pDef->GetAlias().isEmpty() )
{
- Error( SbERR_UNEXPECTED, ALIAS );
+ Error( ERRCODE_BASIC_UNEXPECTED, ALIAS );
}
if( pDef->IsCdecl() )
{
- Error( SbERR_UNEXPECTED, _CDECL_ );
+ Error( ERRCODE_BASIC_UNEXPECTED, _CDECL_ );
}
pDef->SetCdecl( false );
pDef->GetAlias().clear();
@@ -931,7 +931,7 @@ SbiProcDef* SbiParser::ProcDecl( bool bDecl )
{
if( bByVal || bOptional )
{
- Error( SbERR_UNEXPECTED, PARAMARRAY );
+ Error( ERRCODE_BASIC_UNEXPECTED, PARAMARRAY );
}
Next();
bParamArray = true;
@@ -983,7 +983,7 @@ SbiProcDef* SbiParser::ProcDecl( bool bDecl )
}
if( bError2 )
{
- Error( SbERR_EXPECTED, RPAREN );
+ Error( ERRCODE_BASIC_EXPECTED, RPAREN );
break;
}
}
@@ -997,7 +997,7 @@ SbiProcDef* SbiParser::ProcDecl( bool bDecl )
TypeDecl( *pDef );
if( eType != SbxVARIANT && pDef->GetType() != eType )
{
- Error( SbERR_BAD_DECLARATION, aName );
+ Error( ERRCODE_BASIC_BAD_DECLARATION, aName );
}
if( pDef->GetType() == SbxVARIANT && !( bFunc || bProp ) )
{
@@ -1018,7 +1018,7 @@ void SbiParser::DefDeclare( bool bPrivate )
Next();
if( eCurTok != SUB && eCurTok != FUNCTION )
{
- Error( SbERR_UNEXPECTED, eCurTok );
+ Error( ERRCODE_BASIC_UNEXPECTED, eCurTok );
}
else
{
@@ -1029,7 +1029,7 @@ void SbiParser::DefDeclare( bool bPrivate )
{
if( pDef->GetLib().isEmpty() )
{
- Error( SbERR_EXPECTED, LIB );
+ Error( ERRCODE_BASIC_EXPECTED, LIB );
}
// Is it already there?
SbiSymDef* pOld = aPublics.Find( pDef->GetName() );
@@ -1039,7 +1039,7 @@ void SbiParser::DefDeclare( bool bPrivate )
if( !p )
{
// Declared as a variable
- Error( SbERR_BAD_DECLARATION, pDef->GetName() );
+ Error( ERRCODE_BASIC_BAD_DECLARATION, pDef->GetName() );
delete pDef;
pDef = NULL;
}
@@ -1140,7 +1140,7 @@ void SbiParser::Attribute()
if( eCurTok != EQ )
{
- Error( SbERR_SYNTAX );
+ Error( ERRCODE_BASIC_SYNTAX );
}
else
{
@@ -1190,7 +1190,7 @@ void SbiParser::DefProc( bool bStatic, bool bPrivate )
}
else
{
- Error( SbERR_EXPECTED, "Get or Let or Set" );
+ Error( ERRCODE_BASIC_EXPECTED, "Get or Let or Set" );
}
}
@@ -1212,7 +1212,7 @@ void SbiParser::DefProc( bool bStatic, bool bPrivate )
if( !pProc )
{
// Declared as a variable
- Error( SbERR_BAD_DECLARATION, pDef->GetName() );
+ Error( ERRCODE_BASIC_BAD_DECLARATION, pDef->GetName() );
delete pDef;
pProc = NULL;
bError_ = true;
@@ -1224,7 +1224,7 @@ void SbiParser::DefProc( bool bStatic, bool bPrivate )
PropertyMode ePropMode = pDef->getPropertyMode();
if( ePropMode == PropertyMode::NONE || ePropMode == pProc->getPropertyMode() )
{
- Error( SbERR_PROC_DEFINED, pDef->GetName() );
+ Error( ERRCODE_BASIC_PROC_DEFINED, pDef->GetName() );
delete pDef;
pProc = NULL;
bError_ = true;
@@ -1259,7 +1259,7 @@ void SbiParser::DefProc( bool bStatic, bool bPrivate )
}
else
{
- Error( SbERR_NOT_IMPLEMENTED ); // STATIC SUB ...
+ Error( ERRCODE_BASIC_NOT_IMPLEMENTED ); // STATIC SUB ...
}
}
else
@@ -1314,7 +1314,7 @@ void SbiParser::DefStatic( bool bPrivate )
default:
if( !pProc )
{
- Error( SbERR_NOT_IN_SUBR );
+ Error( ERRCODE_BASIC_NOT_IN_SUBR );
}
// Reset the Pool, so that STATIC-Declarations go into the
// global Pool
diff --git a/basic/source/comp/exprgen.cxx b/basic/source/comp/exprgen.cxx
index c0e619c..cfce006 100644
--- a/basic/source/comp/exprgen.cxx
+++ b/basic/source/comp/exprgen.cxx
@@ -173,7 +173,7 @@ void SbiExprNode::GenElement( SbiCodeGen& rGen, SbiOpcode eOp )
{
#ifdef DBG_UTIL
if ((eOp < _RTL || eOp > _CALLC) && eOp != _FIND_G && eOp != _FIND_CM && eOp != _FIND_STATIC)
- rGen.GetParser()->Error( SbERR_INTERNAL_ERROR, "Opcode" );
+ rGen.GetParser()->Error( ERRCODE_BASIC_INTERNAL_ERROR, "Opcode" );
#endif
SbiSymDef* pDef = aVar.pDef;
// The ID is either the position or the String-ID
@@ -228,7 +228,7 @@ void SbiExprList::Gen()
if( pProc )
{
// For the present: trigger an error
- pParser->Error( SbERR_NO_NAMED_ARGS );
+ pParser->Error( ERRCODE_BASIC_NO_NAMED_ARGS );
// Later, if Named Args at DECLARE is possible
//for( sal_uInt16 i = 1 ; i < nParAnz ; i++ )
diff --git a/basic/source/comp/exprnode.cxx b/basic/source/comp/exprnode.cxx
index fecf642..cb1f429 100644
--- a/basic/source/comp/exprnode.cxx
+++ b/basic/source/comp/exprnode.cxx
@@ -288,7 +288,7 @@ void SbiExprNode::FoldConstants(SbiParser* pParser)
nVal = ( eRes >= 0 ) ? SbxTRUE : SbxFALSE;
break;
default:
- pParser->Error( SbERR_CONVERSION );
+ pParser->Error( ERRCODE_BASIC_CONVERSION );
bError = true;
break;
}
@@ -314,7 +314,7 @@ void SbiExprNode::FoldConstants(SbiParser* pParser)
lrMod = static_cast<long>(nr);
if( err )
{
- pParser->Error( SbERR_MATH_OVERFLOW );
+ pParser->Error( ERRCODE_BASIC_MATH_OVERFLOW );
bError = true;
}
}
@@ -336,7 +336,7 @@ void SbiExprNode::FoldConstants(SbiParser* pParser)
case DIV:
if( !nr )
{
- pParser->Error( SbERR_ZERODIV ); nVal = HUGE_VAL;
+ pParser->Error( ERRCODE_BASIC_ZERODIV ); nVal = HUGE_VAL;
bError = true;
} else nVal = nl / nr;
break;
@@ -367,14 +367,14 @@ void SbiExprNode::FoldConstants(SbiParser* pParser)
case IDIV:
if( !lr )
{
- pParser->Error( SbERR_ZERODIV ); nVal = HUGE_VAL;
+ pParser->Error( ERRCODE_BASIC_ZERODIV ); nVal = HUGE_VAL;
bError = true;
} else nVal = ll / lr;
eType = SbxLONG; break;
case MOD:
if( !lr )
{
- pParser->Error( SbERR_ZERODIV ); nVal = HUGE_VAL;
+ pParser->Error( ERRCODE_BASIC_ZERODIV ); nVal = HUGE_VAL;
bError = true;
} else nVal = llMod - lrMod * (llMod/lrMod);
eType = SbxLONG; break;
@@ -392,7 +392,7 @@ void SbiExprNode::FoldConstants(SbiParser* pParser)
}
if( !::rtl::math::isFinite( nVal ) )
- pParser->Error( SbERR_MATH_OVERFLOW );
+ pParser->Error( ERRCODE_BASIC_MATH_OVERFLOW );
// Recover the data type to kill rounding error
if( bCheckType && bBothInt
@@ -424,7 +424,7 @@ void SbiExprNode::FoldConstants(SbiParser* pParser)
else if( nVal < SbxMINLNG ) err = true, nVal = SbxMINLNG;
if( err )
{
- pParser->Error( SbERR_MATH_OVERFLOW );
+ pParser->Error( ERRCODE_BASIC_MATH_OVERFLOW );
bError = true;
}
nVal = (double) ~((long) nVal);
diff --git a/basic/source/comp/exprtree.cxx b/basic/source/comp/exprtree.cxx
index f5483f6..190822c 100644
--- a/basic/source/comp/exprtree.cxx
+++ b/basic/source/comp/exprtree.cxx
@@ -44,11 +44,11 @@ SbiExpression::SbiExpression( SbiParser* p, SbiExprType t,
}
if( t == SbLVALUE && !pExpr->IsLvalue() )
{
- p->Error( SbERR_LVALUE_EXPECTED );
+ p->Error( ERRCODE_BASIC_LVALUE_EXPECTED );
}
if( t == SbOPERAND && !IsVariable() )
{
- p->Error( SbERR_VAR_EXPECTED );
+ p->Error( ERRCODE_BASIC_VAR_EXPECTED );
}
}
@@ -191,7 +191,7 @@ SbiExprNode* SbiExpression::Term( const KeywordSymbolInfo* pKeywordSymbolInfo )
}
if( !pNd )
{
- pParser->Error( SbERR_UNEXPECTED, DOT );
+ pParser->Error( ERRCODE_BASIC_UNEXPECTED, DOT );
pNd = new SbiExprNode( 1.0, SbxDOUBLE );
}
return pNd;
@@ -223,7 +223,7 @@ SbiExprNode* SbiExpression::Term( const KeywordSymbolInfo* pKeywordSymbolInfo )
}
else
{
- pParser->Error( SbERR_SYNTAX );
+ pParser->Error( ERRCODE_BASIC_SYNTAX );
bError = true;
}
}
@@ -265,7 +265,7 @@ SbiExprNode* SbiExpression::Term( const KeywordSymbolInfo* pKeywordSymbolInfo )
else
{
// Name%. really does not work!
- pParser->Error( SbERR_BAD_DECLARATION, aSym );
+ pParser->Error( ERRCODE_BASIC_BAD_DECLARATION, aSym );
bError = true;
}
}
@@ -324,7 +324,7 @@ SbiExprNode* SbiExpression::Term( const KeywordSymbolInfo* pKeywordSymbolInfo )
{
if( pPar && pPar->GetSize() && pPar->GetSize() != pDef->GetDims() )
{
- pParser->Error( SbERR_WRONG_DIMS );
+ pParser->Error( ERRCODE_BASIC_WRONG_DIMS );
}
}
if( pDef->IsDefinedAs() )
@@ -334,7 +334,7 @@ SbiExprNode* SbiExpression::Term( const KeywordSymbolInfo* pKeywordSymbolInfo )
if( eType >= SbxINTEGER && eType <= SbxSTRING && eType != eDefType )
{
// How? Define with AS first and take a Suffix then?
- pParser->Error( SbERR_BAD_DECLARATION, aSym );
+ pParser->Error( ERRCODE_BASIC_BAD_DECLARATION, aSym );
bError = true;
}
else if ( eType == SbxVARIANT )
@@ -361,7 +361,7 @@ SbiExprNode* SbiExpression::Term( const KeywordSymbolInfo* pKeywordSymbolInfo )
}
else
{
- pParser->Error( SbERR_BAD_DECLARATION, aSym );
+ pParser->Error( ERRCODE_BASIC_BAD_DECLARATION, aSym );
bError = true;
}
}
@@ -385,7 +385,7 @@ SbiExprNode* SbiExpression::Term( const KeywordSymbolInfo* pKeywordSymbolInfo )
// defer error until runtime if in vba mode
if ( !pParser->IsVBASupportOn() )
{
- pParser->Error( SbERR_BAD_DECLARATION, aSym );
+ pParser->Error( ERRCODE_BASIC_BAD_DECLARATION, aSym );
bError = true;
}
}
@@ -413,7 +413,7 @@ SbiExprNode* SbiExpression::ObjTerm( SbiSymDef& rObj )
if( eTok != MOD && eTok != NOT && eTok != AND && eTok != OR &&
eTok != XOR && eTok != EQV && eTok != IMP && eTok != IS )
{
- pParser->Error( SbERR_VAR_EXPECTED );
+ pParser->Error( ERRCODE_BASIC_VAR_EXPECTED );
bError = true;
}
}
@@ -458,7 +458,7 @@ SbiExprNode* SbiExpression::ObjTerm( SbiSymDef& rObj )
else
{
// Name%. does really not work!
- pParser->Error( SbERR_BAD_DECLARATION, aSym );
+ pParser->Error( ERRCODE_BASIC_BAD_DECLARATION, aSym );
bError = true;
}
}
@@ -484,7 +484,7 @@ SbiExprNode* SbiExpression::ObjTerm( SbiSymDef& rObj )
}
if( pDef->GetType() != SbxOBJECT )
{
- pParser->Error( SbERR_BAD_DECLARATION, aSym );
+ pParser->Error( ERRCODE_BASIC_BAD_DECLARATION, aSym );
bError = true;
}
if( !bError )
@@ -550,7 +550,7 @@ SbiExprNode* SbiExpression::Operand( bool bUsedForTypeOf )
}
else
{
- pParser->Error( SbERR_BAD_BRACKETS );
+ pParser->Error( ERRCODE_BASIC_BAD_BRACKETS );
}
}
else
@@ -581,7 +581,7 @@ SbiExprNode* SbiExpression::Operand( bool bUsedForTypeOf )
{
pParser->Next();
pRes = new SbiExprNode( 1.0, SbxDOUBLE );
- pParser->Error( SbERR_UNEXPECTED, eTok );
+ pParser->Error( ERRCODE_BASIC_UNEXPECTED, eTok );
}
break;
}
@@ -798,7 +798,7 @@ SbiExprNode* SbiExpression::Like()
// multiple operands in a row does not work
if( nCount > 1 && !pParser->IsVBASupportOn() )
{
- pParser->Error( SbERR_SYNTAX );
+ pParser->Error( ERRCODE_BASIC_SYNTAX );
bError = true;
}
}
@@ -879,7 +879,7 @@ SbiConstExpression::SbiConstExpression( SbiParser* p ) : SbiExpression( p )
if( !bIsBool )
{
- pParser->Error( SbERR_SYNTAX );
+ pParser->Error( ERRCODE_BASIC_SYNTAX );
eType = SbxDOUBLE;
nVal = 0;
}
@@ -908,12 +908,12 @@ short SbiConstExpression::GetShortValue()
if( n > SbxMAXINT )
{
n = SbxMAXINT;
- pParser->Error( SbERR_OUT_OF_RANGE );
+ pParser->Error( ERRCODE_BASIC_OUT_OF_RANGE );
}
else if( n < SbxMININT )
{
n = SbxMININT;
- pParser->Error( SbERR_OUT_OF_RANGE );
+ pParser->Error( ERRCODE_BASIC_OUT_OF_RANGE );
}
return (short) n;
@@ -1120,7 +1120,7 @@ SbiParameters::SbiParameters( SbiParser* p, bool bStandaloneExpression, bool bPa
{
break;
}
- pParser->Error( bBracket ? SbERR_BAD_BRACKETS : SbERR_EXPECTED, COMMA );
+ pParser->Error( bBracket ? ERRCODE_BASIC_BAD_BRACKETS : ERRCODE_BASIC_EXPECTED, COMMA );
bError = true;
}
else
@@ -1140,7 +1140,7 @@ SbiParameters::SbiParameters( SbiParser* p, bool bStandaloneExpression, bool bPa
pParser->Peek();
if( !bBracket )
{
- pParser->Error( SbERR_BAD_BRACKETS );
+ pParser->Error( ERRCODE_BASIC_BAD_BRACKETS );
bError = true;
}
}
@@ -1163,7 +1163,7 @@ SbiDimList::SbiDimList( SbiParser* p ) : SbiExprList( p )
if( pParser->Next() != LPAREN )
{
- pParser->Error( SbERR_EXPECTED, LPAREN );
+ pParser->Error( ERRCODE_BASIC_EXPECTED, LPAREN );
bError = true; return;
}
@@ -1213,7 +1213,7 @@ SbiDimList::SbiDimList( SbiParser* p ) : SbiExprList( p )
if( eTok == RPAREN ) break;
if( eTok != COMMA )
{
- pParser->Error( SbERR_BAD_BRACKETS );
+ pParser->Error( ERRCODE_BASIC_BAD_BRACKETS );
pParser->Next();
break;
}
diff --git a/basic/source/comp/io.cxx b/basic/source/comp/io.cxx
index d1dd481..45b3caf 100644
--- a/basic/source/comp/io.cxx
+++ b/basic/source/comp/io.cxx
@@ -37,7 +37,7 @@ bool SbiParser::Channel( bool bAlways )
bRes = true;
}
else if( bAlways )
- Error( SbERR_EXPECTED, "#" );
+ Error( ERRCODE_BASIC_EXPECTED, "#" );
return bRes;
}
@@ -132,9 +132,9 @@ void SbiParser::LineInput()
Channel( true );
boost::scoped_ptr<SbiExpression> pExpr(new SbiExpression( this, SbOPERAND ));
if( !pExpr->IsVariable() )
- Error( SbERR_VAR_EXPECTED );
+ Error( ERRCODE_BASIC_VAR_EXPECTED );
if( pExpr->GetType() != SbxVARIANT && pExpr->GetType() != SbxSTRING )
- Error( SbERR_CONVERSION );
+ Error( ERRCODE_BASIC_CONVERSION );
pExpr->Gen();
aGen.Gen( _LINPUT );
pExpr.reset();
@@ -151,7 +151,7 @@ void SbiParser::Input()
while( !bAbort )
{
if( !pExpr->IsVariable() )
- Error( SbERR_VAR_EXPECTED );
+ Error( ERRCODE_BASIC_VAR_EXPECTED );
pExpr->Gen();
aGen.Gen( _INPUT );
if( Peek() == COMMA )
@@ -188,7 +188,7 @@ void SbiParser::Open()
case BINARY:
nMode = StreamMode::READ | StreamMode::WRITE; nFlags |= SBSTRM_BINARY; break;
default:
- Error( SbERR_SYNTAX );
+ Error( ERRCODE_BASIC_SYNTAX );
}
if( Peek() == ACCESS )
{
@@ -209,7 +209,7 @@ void SbiParser::Open()
else if( eTok == WRITE )
nMode |= StreamMode::WRITE;
else
- Error( SbERR_SYNTAX );
+ Error( ERRCODE_BASIC_SYNTAX );
}
switch( Peek() )
{
@@ -234,7 +234,7 @@ void SbiParser::Open()
else if( eTok == WRITE )
nMode |= StreamMode::SHARE_DENYWRITE;
else
- Error( SbERR_SYNTAX );
+ Error( ERRCODE_BASIC_SYNTAX );
break;
default: break;
}
@@ -242,7 +242,7 @@ void SbiParser::Open()
// channel number
boost::scoped_ptr<SbiExpression> pChan(new SbiExpression( this ));
if( !pChan )
- Error( SbERR_SYNTAX );
+ Error( ERRCODE_BASIC_SYNTAX );
boost::scoped_ptr<SbiExpression> pLen;
if( Peek() == SYMBOL )
{
diff --git a/basic/source/comp/loops.cxx b/basic/source/comp/loops.cxx
index b545ae7..cdc3f21 100644
--- a/basic/source/comp/loops.cxx
+++ b/basic/source/comp/loops.cxx
@@ -49,7 +49,7 @@ void SbiParser::If()
eTok = Peek();
if( IsEof() )
{
- Error( SbERR_BAD_BLOCK, IF ); bAbort = true; return;
+ Error( ERRCODE_BASIC_BAD_BLOCK, IF ); bAbort = true; return;
}
}
while( eTok == ELSEIF )
@@ -57,7 +57,7 @@ void SbiParser::If()
// jump to ENDIF in case of a successful IF/ELSEIF
if( iJmp >= JMP_TABLE_SIZE )
{
- Error( SbERR_PROG_TOO_LARGE ); bAbort = true; return;
+ Error( ERRCODE_BASIC_PROG_TOO_LARGE ); bAbort = true; return;
}
pnJmpToEndLbl[iJmp++] = aGen.Gen( _JUMP, 0 );
@@ -77,7 +77,7 @@ void SbiParser::If()
eTok = Peek();
if( IsEof() )
{
- Error( SbERR_BAD_BLOCK, ELSEIF ); bAbort = true; return;
+ Error( ERRCODE_BASIC_BAD_BLOCK, ELSEIF ); bAbort = true; return;
}
}
}
@@ -137,7 +137,7 @@ void SbiParser::If()
void SbiParser::NoIf()
{
- Error( SbERR_NO_IF );
+ Error( ERRCODE_BASIC_NO_IF );
StmntBlock( ENDIF );
}
@@ -163,7 +163,7 @@ void SbiParser::DoLoop()
if (eTok == EOLN || eTok == REM)
aGen.Gen (_JUMP, nStartLbl);
else
- Error( SbERR_EXPECTED, WHILE );
+ Error( ERRCODE_BASIC_EXPECTED, WHILE );
}
else
{
@@ -250,7 +250,7 @@ void SbiParser::For()
{
SbiExpression aVar( this, SbOPERAND );
if( aVar.GetRealVar() != aLvalue.GetRealVar() )
- Error( SbERR_EXPECTED, aLvalue.GetRealVar()->GetName() );
+ Error( ERRCODE_BASIC_EXPECTED, aLvalue.GetRealVar()->GetName() );
}
aGen.BackChain( nEndTarget );
CloseBlock();
@@ -268,7 +268,7 @@ void SbiParser::With()
if( pDef->GetType() == SbxVARIANT || pDef->GetType() == SbxEMPTY )
pDef->SetType( SbxOBJECT );
else if( pDef->GetType() != SbxOBJECT )
- Error( SbERR_NEEDS_OBJECT );
+ Error( ERRCODE_BASIC_NEEDS_OBJECT );
pNode->SetType( SbxOBJECT );
@@ -283,9 +283,9 @@ void SbiParser::With()
void SbiParser::BadBlock()
{
if( eEndTok )
- Error( SbERR_BAD_BLOCK, eEndTok );
+ Error( ERRCODE_BASIC_BAD_BLOCK, eEndTok );
else
- Error( SbERR_BAD_BLOCK, "Loop/Next/Wend" );
+ Error( ERRCODE_BASIC_BAD_BLOCK, "Loop/Next/Wend" );
}
// On expr Goto/Gosub n,n,n...
@@ -298,7 +298,7 @@ void SbiParser::OnGoto()
SbiToken eTok = Next();
if( eTok != GOTO && eTok != GOSUB )
{
- Error( SbERR_EXPECTED, "GoTo/GoSub" );
+ Error( ERRCODE_BASIC_EXPECTED, "GoTo/GoSub" );
eTok = GOTO;
}
@@ -312,7 +312,7 @@ void SbiParser::OnGoto()
aGen.Gen( _JUMP, nOff );
nLbl++;
... etc. - the rest is truncated
More information about the Libreoffice-commits
mailing list