summaryrefslogtreecommitdiff
path: root/basic
diff options
context:
space:
mode:
authorXisco Faulí <anistenis@gmail.com>2011-03-21 12:55:40 +0100
committerChristina Rossmanith <ChrRossmanith@web.de>2011-03-21 12:55:58 +0100
commitf6e0527033be682dbf6b60bd9b060fdd853ffe33 (patch)
tree2d5ee2a7bface7ce26de0ac42eeb55d6d8050475 /basic
parent41aed87d074878c3a38a7f982f5c2aaad9400189 (diff)
Remove most of dead code inlibs-core (basic)
Diffstat (limited to 'basic')
-rwxr-xr-xbasic/inc/basic/basmgr.hxx2
-rwxr-xr-xbasic/inc/basic/sbdef.hxx1
-rwxr-xr-xbasic/inc/basic/sbx.hxx2
-rwxr-xr-xbasic/inc/basic/sbxform.hxx2
-rwxr-xr-xbasic/inc/basic/sbxobj.hxx1
-rwxr-xr-xbasic/inc/basic/testtool.hxx2
-rwxr-xr-xbasic/source/app/app.cxx5
-rwxr-xr-xbasic/source/app/app.hxx1
-rwxr-xr-xbasic/source/app/apperror.cxx7
-rwxr-xr-xbasic/source/app/apperror.hxx1
-rwxr-xr-xbasic/source/app/appwin.cxx19
-rwxr-xr-xbasic/source/app/basic.src124
-rwxr-xr-xbasic/source/app/basmsg.src2
-rwxr-xr-xbasic/source/app/brkpnts.hxx1
-rwxr-xr-xbasic/source/app/dialogs.cxx73
-rwxr-xr-xbasic/source/app/dialogs.hxx1
-rwxr-xr-xbasic/source/app/msgedit.cxx73
-rwxr-xr-xbasic/source/app/msgedit.hxx5
-rwxr-xr-xbasic/source/app/mybasic.cxx3
-rwxr-xr-xbasic/source/app/process.cxx1
-rwxr-xr-xbasic/source/app/processw.cxx2
-rwxr-xr-xbasic/source/app/svtmsg.src2
-rwxr-xr-xbasic/source/app/testtool.src2
-rwxr-xr-xbasic/source/app/textedit.cxx5
-rwxr-xr-xbasic/source/app/textedit.hxx3
-rwxr-xr-xbasic/source/app/ttmsg.src20
-rwxr-xr-xbasic/source/basmgr/basicmanagerrepository.cxx7
-rwxr-xr-xbasic/source/basmgr/basmgr.cxx14
-rwxr-xr-xbasic/source/classes/disas.cxx2
-rwxr-xr-xbasic/source/classes/eventatt.cxx2
-rwxr-xr-xbasic/source/classes/image.cxx9
-rwxr-xr-xbasic/source/classes/sb.cxx4
-rwxr-xr-xbasic/source/classes/sbunoobj.cxx117
-rwxr-xr-xbasic/source/classes/sbxmod.cxx37
-rwxr-xr-xbasic/source/comp/codegen.cxx1
-rwxr-xr-xbasic/source/comp/dim.cxx17
-rwxr-xr-xbasic/source/comp/exprgen.cxx10
-rwxr-xr-xbasic/source/comp/exprnode.cxx1
-rwxr-xr-xbasic/source/comp/exprtree.cxx16
-rwxr-xr-xbasic/source/comp/io.cxx28
-rwxr-xr-xbasic/source/comp/loops.cxx8
-rwxr-xr-xbasic/source/comp/parser.cxx6
-rwxr-xr-xbasic/source/comp/scanner.cxx11
-rwxr-xr-xbasic/source/comp/symtbl.cxx2
-rwxr-xr-xbasic/source/comp/token.cxx164
-rwxr-xr-xbasic/source/inc/filefmt.hxx1
-rwxr-xr-xbasic/source/inc/image.hxx1
-rwxr-xr-xbasic/source/inc/runtime.hxx7
-rwxr-xr-xbasic/source/inc/sbunoobj.hxx2
-rwxr-xr-xbasic/source/inc/symtbl.hxx3
-rwxr-xr-xbasic/source/runtime/inputbox.cxx1
-rwxr-xr-xbasic/source/runtime/iosys.cxx40
-rwxr-xr-xbasic/source/runtime/methods.cxx44
-rwxr-xr-xbasic/source/runtime/methods1.cxx20
-rwxr-xr-xbasic/source/runtime/runtime.cxx30
-rwxr-xr-xbasic/source/runtime/stdobj.cxx2
-rwxr-xr-xbasic/source/runtime/stdobj1.cxx68
-rwxr-xr-xbasic/source/runtime/step0.cxx42
-rwxr-xr-xbasic/source/runtime/step1.cxx4
-rwxr-xr-xbasic/source/runtime/step2.cxx15
-rwxr-xr-xbasic/source/sample/object.cxx7
-rwxr-xr-xbasic/source/sbx/sbxarray.cxx9
-rwxr-xr-xbasic/source/sbx/sbxcoll.cxx2
-rwxr-xr-xbasic/source/sbx/sbxdec.cxx4
-rwxr-xr-xbasic/source/sbx/sbxform.cxx54
-rwxr-xr-xbasic/source/sbx/sbxobj.cxx54
-rwxr-xr-xbasic/source/sbx/sbxscan.cxx4
-rwxr-xr-xbasic/source/sbx/sbxvalue.cxx7
-rwxr-xr-xbasic/source/sbx/sbxvar.cxx2
-rwxr-xr-xbasic/source/uno/namecont.cxx38
-rwxr-xr-xbasic/source/uno/scriptcont.cxx11
71 files changed, 52 insertions, 1236 deletions
diff --git a/basic/inc/basic/basmgr.hxx b/basic/inc/basic/basmgr.hxx
index 51550eab5700..8dc90817c936 100755
--- a/basic/inc/basic/basmgr.hxx
+++ b/basic/inc/basic/basmgr.hxx
@@ -25,7 +25,6 @@
* for a copy of the LGPLv3 License.
*
************************************************************************/
-//
#ifndef _BASMGR_HXX
#define _BASMGR_HXX
@@ -88,7 +87,6 @@ public:
};
-//
class BasicLibs;
class ErrorManager;
diff --git a/basic/inc/basic/sbdef.hxx b/basic/inc/basic/sbdef.hxx
index 1b0b6a3f65b4..85218a34965f 100755
--- a/basic/inc/basic/sbdef.hxx
+++ b/basic/inc/basic/sbdef.hxx
@@ -99,7 +99,6 @@ void setBasicWatchMode( bool bOn );
#define SBX_HINT_BASICSTART SFX_HINT_USER04
#define SBX_HINT_BASICSTOP SFX_HINT_USER05
-// #115826
enum PropertyMode
{
PROPERTY_MODE_NONE,
diff --git a/basic/inc/basic/sbx.hxx b/basic/inc/basic/sbx.hxx
index ec2f9a1b3335..ea8cc1e4f24e 100755
--- a/basic/inc/basic/sbx.hxx
+++ b/basic/inc/basic/sbx.hxx
@@ -55,9 +55,7 @@ class SbxFactory;
class SfxBroadcaster;
class SvDispatch;
-///////////////////////////////////////////////////////////////////////////
-////////////////////////////////////////////////////////////////////////////
#ifndef __SBX_SBXPARAMINFO
#define __SBX_SBXPARAMINFO
diff --git a/basic/inc/basic/sbxform.hxx b/basic/inc/basic/sbxform.hxx
index 77921a0ce77e..27d372d8ccf1 100755
--- a/basic/inc/basic/sbxform.hxx
+++ b/basic/inc/basic/sbxform.hxx
@@ -115,8 +115,6 @@ class SbxBasicFormater {
static sal_Bool isBasicFormat( String sFormatStrg );
private:
- //*** some helper methods ***
- //void ShowError( char *sErrMsg );
inline void ShiftString( String& sStrg, sal_uInt16 nStartPos );
inline void StrAppendChar( String& sStrg, sal_Unicode ch );
void AppendDigit( String& sStrg, short nDigit );
diff --git a/basic/inc/basic/sbxobj.hxx b/basic/inc/basic/sbxobj.hxx
index 867cf6e2bd07..ab2b46422209 100755
--- a/basic/inc/basic/sbxobj.hxx
+++ b/basic/inc/basic/sbxobj.hxx
@@ -32,7 +32,6 @@
#include <svl/lstner.hxx>
#include <basic/sbxvar.hxx>
-///////////////////////////////////////////////////////////////////////////
class SbxProperty;
class SvDispatch;
diff --git a/basic/inc/basic/testtool.hxx b/basic/inc/basic/testtool.hxx
index ee0bd25f8ab4..b7de4a88b007 100755
--- a/basic/inc/basic/testtool.hxx
+++ b/basic/inc/basic/testtool.hxx
@@ -39,7 +39,7 @@
#define ASSERTION_STACK_PREFIX "Backtrace:"
-// #94145# Due to a tab in TT_SIGNATURE_FOR_UNICODE_TEXTFILES which is changed to blanks by some editors
+// Due to a tab in TT_SIGNATURE_FOR_UNICODE_TEXTFILES which is changed to blanks by some editors
// this routine became necessary
sal_Bool IsTTSignatureForUnicodeTextfile( String aLine );
diff --git a/basic/source/app/app.cxx b/basic/source/app/app.cxx
index 7ed2f518334f..544b0f177eaa 100755
--- a/basic/source/app/app.cxx
+++ b/basic/source/app/app.cxx
@@ -172,7 +172,7 @@ extern "C" void SAL_CALL osl_TestToolDebugMessageFilter( const sal_Char *pString
#endif
-// #94145# Due to a tab in TT_SIGNATURE_FOR_UNICODE_TEXTFILES which is changed to blanks by some editors
+// Due to a tab in TT_SIGNATURE_FOR_UNICODE_TEXTFILES which is changed to blanks by some editors
// this routine became necessary
sal_Bool IsTTSignatureForUnicodeTextfile( String aLine )
{
@@ -416,7 +416,6 @@ IMPL_LINK( BasicApp, LateInit, void *, pDummy )
return 0;
}
-//////////////////////////////////////////////////////////////////////////
class FloatingExecutionStatus : public FloatingWindow
{
@@ -467,7 +466,6 @@ IMPL_LINK(FloatingExecutionStatus, HideNow, FloatingExecutionStatus*, pFLC )
return 0;
}
-//////////////////////////////////////////////////////////////////////////
TYPEINIT1(TTExecutionStatusHint, SfxSimpleHint);
@@ -492,7 +490,6 @@ BasicFrame::BasicFrame() : WorkWindow( NULL,
bInBreak = sal_False;
bDisas = sal_False;
nFlags = 0;
-// Icon aAppIcon;
if ( pBasic->pTestObject ) // Are we the testtool?
{
diff --git a/basic/source/app/app.hxx b/basic/source/app/app.hxx
index 983e979c5021..af1b95714683 100755
--- a/basic/source/app/app.hxx
+++ b/basic/source/app/app.hxx
@@ -102,7 +102,6 @@ using Window::Command;
sal_Bool bIsAutoRun;
DisplayHidDlg* pDisplayHidDlg;
-// BreakPoint *pRunToCursorBP;
SbxVariable *pEditVar;
diff --git a/basic/source/app/apperror.cxx b/basic/source/app/apperror.cxx
index 48781eab1767..04b9e8e34f0f 100755
--- a/basic/source/app/apperror.cxx
+++ b/basic/source/app/apperror.cxx
@@ -44,9 +44,6 @@ AppError::AppError( BasicFrame* pParent, String aFileName )
bHasFile = pDataEdit->Load( aFileName );
DirEntry aEntry( aFileName );
UpdateFileInfo( HAS_BEEN_LOADED );
- // Define icon
-// pIcon = new Icon( ResId( RID_WORKICON ) );
-// if( pIcon ) SetIcon( *pIcon );
pDataEdit->Show();
GrabFocus();
@@ -102,14 +99,10 @@ void AppError::LoadIniFile()
String aFontStyle = String( aConf.ReadKey( "ScriptFontStyle", "normal" ), RTL_TEXTENCODING_UTF8 );
String aFontSize = String( aConf.ReadKey( "ScriptFontSize", "12" ), RTL_TEXTENCODING_UTF8 );
Font aFont = aFontList.Get( aFontName, aFontStyle );
-// sal_uIntPtr nFontSize = aFontSize.GetValue( FUNIT_POINT );
sal_uIntPtr nFontSize = aFontSize.ToInt32();
-// aFont.SetSize( Size( nFontSize, nFontSize ) );
aFont.SetHeight( nFontSize );
aFont.SetTransparent( sal_False );
-// aFont.SetAlign( ALIGN_BOTTOM );
-// aFont.SetHeight( aFont.GetHeight()+2 );
pDataEdit->SetFont( aFont );
}
diff --git a/basic/source/app/apperror.hxx b/basic/source/app/apperror.hxx
index c55015a1964d..a56645a262d8 100755
--- a/basic/source/app/apperror.hxx
+++ b/basic/source/app/apperror.hxx
@@ -37,7 +37,6 @@ public:
TYPEINFO();
AppError( BasicFrame*, String );
~AppError();
-// long Command( short nID );
virtual long InitMenu( Menu* );
virtual long DeInitMenu( Menu* );
sal_uInt16 GetLineNr();
diff --git a/basic/source/app/appwin.cxx b/basic/source/app/appwin.cxx
index 984637af5178..d2f8869fd7d8 100755
--- a/basic/source/app/appwin.cxx
+++ b/basic/source/app/appwin.cxx
@@ -193,11 +193,9 @@ void AppWin::Help()
// Trim leading whitespaces
while( s.GetChar(0) == ' ' )
s.Erase( 0, 1 );
-// aBasicApp.pHelp->Start( s );
}
else
{
-// aBasicApp.pHelp->Start( OOO_HELP_INDEX );
}
}
@@ -216,7 +214,6 @@ void AppWin::GetFocus()
if( pDataEdit ) // GetFocus is called by the destructor, so this check
{
pDataEdit->GrabFocus();
-// InitMenu(GetpApp()->GetAppMenu()->GetPopupMenu( RID_APPEDIT ));
}
}
@@ -254,7 +251,6 @@ long AppWin::InitMenu( Menu* pMenu )
pMenu->EnableItem( RID_EDITCOPY, bMarked );
pMenu->EnableItem( RID_EDITPASTE, ( ::svt::OStringTransfer::PasteString( aTemp, this ) ) );
pMenu->EnableItem( RID_EDITDEL, bMarked );
-// pMenu->EnableItem( RID_HELPTOPIC, bMarked );
sal_Bool bHasText;
if( pDataEdit )
@@ -322,7 +318,7 @@ void AppWin::Command( const CommandEvent& rCEvt )
}
break;
case RID_EDITDEL:
- /*if( bHasMark ) */pDataEdit->Delete();
+ pDataEdit->Delete();
break;
case RID_EDITUNDO:
pDataEdit->Undo();
@@ -375,8 +371,6 @@ sal_Bool AppWin::DiskFileChanged( sal_uInt16 nWhat )
else
return DiskFileChanged( SINCE_LAST_ASK_RELOAD );
}
-// uncomment to avoid compiler warning
-// break;
case SINCE_LAST_ASK_RELOAD:
{
String aFilename( GetText() );
@@ -387,8 +381,6 @@ sal_Bool AppWin::DiskFileChanged( sal_uInt16 nWhat )
return ( !aLastAccess.GetError() != !aStat.GetError() )
|| aLastAccess.IsYounger( aStat ) || aStat.IsYounger( aLastAccess );
}
-// uncomment to avoid compiler warning
-// break;
default:
OSL_FAIL("Not Implemented in AppWin::DiskFileChanged");
}
@@ -432,7 +424,6 @@ void AppWin::CheckReload()
if ( !aFile.Exists() )
return;
-// FileStat aStat( aFile );
if ( DiskFileChanged( SINCE_LAST_ASK_RELOAD ) && ReloadAllowed() )
{
@@ -466,8 +457,6 @@ sal_Bool AppWin::Load( const String& aName )
SkipReload();
sal_Bool bErr;
-// if( !QuerySave() )
-// return;
bErr = !pDataEdit->Load( aName );
if( bErr )
{
@@ -608,16 +597,10 @@ sal_Bool AppWin::Close()
delete this;
return sal_True;
}
-// uncomment to avoid compiler warning
-// break;
case SAVE_RES_ERROR:
return sal_False;
-// uncomment to avoid compiler warning
-// break;
case SAVE_RES_CANCEL:
return sal_False;
-// uncomment to avoid compiler warning
-// break;
default:
OSL_FAIL("Not Implemented in AppWin::Close");
return sal_False;
diff --git a/basic/source/app/basic.src b/basic/source/app/basic.src
index 28cffcbae5b7..754b35e1b56f 100755
--- a/basic/source/app/basic.src
+++ b/basic/source/app/basic.src
@@ -34,12 +34,6 @@ ModalDialog RID_CALLDLG {
SVLook = TRUE;
MOVEABLE = TRUE;
CLOSEABLE = TRUE;
-// WinChilds = {
-// FixedText {
-// Text = "Aktuelle Parameter";
-// PosSize = MAP_SYSFONT (10,10,120,8);
-// };
-// };
FixedText RID_RETTYPE {
PosSize = MAP_SYSFONT (10,70,120,8);
};
@@ -68,41 +62,6 @@ ModalDialog IDD_ABOUT_DIALOG {
Pos = MAP_APPFONT( 58, 17 );
Size = MAP_APPFONT( 155, 106 );
SVLook = TRUE;
-/*
- WINCHILDS = {
- FixedText {
- Pos = MAP_APPFONT( 40, 5 );
- Size = MAP_APPFONT( 110, 10 );
- TEXT = "Testtool";
- CENTER = TRUE;
- };
- FixedText {
- Pos = MAP_APPFONT( 40, 20 );
- Size = MAP_APPFONT( 110, 20 );
- TEXT = "Ojektorientiertes BASIC-Entwicklungssystem";
- CENTER = TRUE;
- };
- FixedText {
- Pos = MAP_APPFONT( 40, 45 );
- Size = MAP_APPFONT( 110, 10 );
- TEXT = "Version 2.0 May 2002";
- CENTER = TRUE;
- };
- FixedText {
- Pos = MAP_APPFONT( 40, 60 );
- Size = MAP_APPFONT( 110, 10 );
- TEXT = "�1995-2010 Oracle";
- CENTER = TRUE;
- };
- };
-*/
-// FixedIcon RID_ICON {
-// Pos = MAP_APPFONT( 20, 26 );
-// Size = MAP_APPFONT( 20, 20 );
-// FIXED = Icon {
-// FILE = "basic.ico";
-// };
-// };
OKButton RID_OK {
Pos = MAP_APPFONT( 55, 80 );
Size = MAP_APPFONT( 40, 14 );
@@ -148,7 +107,6 @@ ModalDialog IDD_FIND_DIALOG {
Size = MAP_APPFONT( 185, 70 );
SVLook = TRUE;
MOVEABLE = TRUE;
- // CLOSEABLE = TRUE; // It has a cancelbutton
FixedText RID_FIXEDTEXT1 {
Pos = MAP_APPFONT( 5, 10 );
@@ -184,7 +142,6 @@ ModalDialog IDD_REPLACE_DIALOG {
Size = MAP_APPFONT( 185, 88 );
SVLook = TRUE;
MOVEABLE = TRUE;
- // CLOSEABLE = TRUE; // It has a cancelbutton
FixedText RID_FIXEDTEXT1 {
Pos = MAP_APPFONT( 5, 10 );
Size = MAP_APPFONT( 55, 10 );
@@ -425,15 +382,6 @@ String IDS_CANCEL {
String IDS_DISASWIN {
TEXT[ en-US ] = "Disassembly";
};
-//Icon RID_APPICON {
-// FILE = "basic.ico";
-//};
-//Icon RID_APPICON2 {
-// FILE = "testtool.ico";
-//};
-//Icon RID_WORKICON {
-// FILE = "work.ico";
-//};
Bitmap MBP_PLUS {
File = "plus.bmp";
@@ -542,12 +490,10 @@ Menu RID_EDIT {
MenuItem {
Identifier = RID_EDITUNDO;
TEXT[ en-US ] = "~Undo";
-// AccelKey = KeyCode { Function = KEYFUNC_CUT; };
};
MenuItem {
Identifier = RID_EDITREDO;
TEXT[ en-US ] = "~Redo";
-// AccelKey = KeyCode { Function = KEYFUNC_CUT; };
};
MenuItem {
SEPARATOR = TRUE;
@@ -588,7 +534,6 @@ Menu RID_EDIT {
Identifier = RID_EDITREPEAT;
TEXT[ en-US ] = "Repeat S~earch";
AccelKey = KeyCode { Code = KEY_F3; };
-// AccelKey = KeyCode { Function = KEYFUNC_REPEAT; };
};
};
};
@@ -617,11 +562,6 @@ Menu RID_RUN {
TEXT[ en-US ] = "Si~ngle Step over Procedure";
AccelKey = KeyCode { Code = KEY_F10; };
};
-// MenuItem {
-// Identifier = RID_RUNTOCURSOR;
-// TEXT = "Run to cursor";
-// AccelKey = KeyCode { Code = KEY_F7; };
-// };
MenuItem {
Identifier = RID_TOGLEBRKPNT;
TEXT[ en-US ] = "Set / Delete Break Point";
@@ -675,52 +615,11 @@ Menu RID_TT_EXTRAS {
};
Menu RID_WINDOW {
ITEMLIST = {
-/* MenuItem {
- Identifier = RID_WINCASCADE;
- TEXT[ en-US ] = "~Cascade";
- };
- MenuItem {
- Identifier = RID_WINTILE;
- TEXT[ en-US ] = "~Tile";
- };
- MenuItem {
- Identifier = RID_WINTILEHORZ;
- TEXT[ en-US ] = "~Arrange Horizontally";
- };
- MenuItem {
- Identifier = RID_WINTILEVERT;
- TEXT[ en-US ] = "~Arrange Vertically";
- };*/
};
};
Menu RID_HELP {
ITEMLIST = {
-/* MenuItem {
- Identifier = RID_HELPINDEX;
- TEXT = "~Index";
- };
MenuItem {
- SEPARATOR = TRUE;
- };
- MenuItem {
- Identifier = RID_HELPKEYS;
- TEXT = "~Tastaturbelegung";
- };
- MenuItem {
- Identifier = RID_HELPINTRO;
- TEXT = "~Anleitung";
- };
- MenuItem {
- SEPARATOR = TRUE;
- };
- MenuItem {
- Identifier = RID_HELPTOPIC;
- TEXT = "~Markierter Text";
- };
- MenuItem {
- SEPARATOR = TRUE;
- };
-*/ MenuItem {
ABOUT = TRUE;
Identifier = RID_HELPABOUT;
TEXT[ en-US ] = "~About...";
@@ -1243,12 +1142,6 @@ FloatingWindow IDD_DISPLAY_HID {
Border = TRUE;
Pos = MAP_APPFONT( 0, 0 );
Size = MAP_APPFONT( 260, 14 );
-/* ItemList = {
- ToolBoxItem {
- Text = "erster der Toolbox";
- };
- };*/
-// Hide = TRUE;
};
FixedText RID_FT_CONTROLS {
Pos = MAP_APPFONT( 4, 16 );
@@ -1335,22 +1228,6 @@ Accelerator MAIN_ACCEL {
Identifier = RID_QUIT;
Key = KeyCode { Function = KEYFUNC_QUIT; };
};
-// AcceleratorItem {
-// Identifier = RID_EDITCUT;
-// Key = KeyCode { Function = KEYFUNC_CUT; };
-// };
-// AcceleratorItem {
-// Identifier = RID_EDITCOPY;
-// Key = KeyCode { Function = KEYFUNC_COPY; };
-// };
-// AcceleratorItem {
-// Identifier = RID_EDITPASTE;
-// Key = KeyCode { Function = KEYFUNC_PASTE; };
-// };
-// AcceleratorItem {
-// Identifier = RID_EDITDEL;
-// Key = KeyCode { Function = KEYFUNC_DELETE; };
-// };
AcceleratorItem {
Identifier = RID_EDITSEARCH;
Key = KeyCode { Function = KEYFUNC_FIND; };
@@ -1358,7 +1235,6 @@ Accelerator MAIN_ACCEL {
AcceleratorItem {
Identifier = RID_EDITREPEAT;
Key = KeyCode { Code = KEY_F3; };
-// Key = KeyCode { Function = KEYFUNC_REPEAT; };
};
AcceleratorItem {
Identifier = RID_RUNSTART;
diff --git a/basic/source/app/basmsg.src b/basic/source/app/basmsg.src
index e2179afd4c34..1e0e3f5799e7 100755
--- a/basic/source/app/basmsg.src
+++ b/basic/source/app/basmsg.src
@@ -30,7 +30,6 @@
// Here are included the messages of the folder /basic/source/app
-///////////////////////////////
// Error messages which go to the result file.
// *********************
// *** !!ATTENTION!! ***
@@ -38,7 +37,6 @@
// The numbers must NEVER(!) change,
// because they are saved in the result files and a renewed display
// would display new strings or no strings.
-///////////////////////////////
String S_PROG_START
{
diff --git a/basic/source/app/brkpnts.hxx b/basic/source/app/brkpnts.hxx
index 0ea0fc9b45ad..5ea60c8e7608 100755
--- a/basic/source/app/brkpnts.hxx
+++ b/basic/source/app/brkpnts.hxx
@@ -41,7 +41,6 @@ using Window::Scroll;
public:
BreakpointWindow( Window *pParent );
-// ~BreakpointWindow();
void Reset();
diff --git a/basic/source/app/dialogs.cxx b/basic/source/app/dialogs.cxx
index dc8a57516b20..e0c2b37bd06d 100755
--- a/basic/source/app/dialogs.cxx
+++ b/basic/source/app/dialogs.cxx
@@ -74,7 +74,6 @@ AboutDialog::AboutDialog( Window* pParent, const ResId& id )
FreeResource();
}
-////////////////////////////////////////////////////////////////////
FindDialog::FindDialog( Window* pParent, const ResId& id, String& Text )
: ModalDialog( pParent, id )
@@ -130,7 +129,6 @@ IMPL_LINK( ReplaceDialog, ButtonClick, Button *, pB )
return sal_True;
}
-////////////////////////////////////////////////////////////////////
void CheckButtons( ComboBox &aCB, Button &aNewB, Button &aDelB )
@@ -677,9 +675,6 @@ FontOptions::FontOptions( Window* pParent, Config &aConfig )
aFontName.EnableWYSIWYG();
aFontName.EnableSymbols();
-// aFontSize.SetUnit( FUNIT_POINT );
-// MapMode aMode( MAP_POINT );
-// aFTPreview.SetMapMode( aMode );
aFontName.SetModifyHdl( LINK( this, FontOptions, FontNameChanged ) );
aFontStyle.SetModifyHdl( LINK( this, FontOptions, FontStyleChanged ) );
@@ -722,7 +717,6 @@ IMPL_LINK( FontOptions, FontSizeChanged, void*, EMPTYARG )
void FontOptions::UpdatePreview()
{
Font aFont = aFontList.Get( aFontName.GetText(), aFontStyle.GetText() );
-// sal_uIntPtr nFontSize = aFontSize.GetValue( FUNIT_POINT );
sal_uIntPtr nFontSize = static_cast<sal_uIntPtr>((aFontSize.GetValue() + 5) / 10);
aFont.SetHeight( nFontSize );
aFTPreview.SetFont( aFont );
@@ -1081,15 +1075,6 @@ DisplayHidDlg::DisplayHidDlg( Window * pParent )
{
FreeResource();
-/* ResMgr* pRM = CREATERESMGR( svt );
- ToolBox aOrig( this, ResId( 12345, pRM ) );
- delete pRM;
-
- aTbConf.CopyItem( aOrig, 4 );
- aTbConf.InsertSeparator();
- aTbConf.CopyItem( aOrig, 5 );
- aTbConf.CopyItem( aOrig, 6 );
- aTbConf.CopyItem( aOrig, 7 ); */
aTbConf.SetOutStyle( TOOLBOX_STYLE_FLAT );
#if OSL_DEBUG_LEVEL < 2
@@ -1249,8 +1234,6 @@ void DisplayHidDlg::Resize()
}
else
{
-// SetUpdateMode( sal_False );
-
// Minimum size
Size aSize( GetOutputSizePixel() );
aSize.Width() = std::max( aSize.Width(), (long)(aOKClose.GetSizePixel().Width() * 3 ));
@@ -1304,9 +1287,6 @@ void DisplayHidDlg::Resize()
aPos.Move( nSpace, -aOKClose.GetSizePixel().Height() );
aPos.Move( pSplit->GetSizePixel().Width(), pSplit->GetSizePixel().Height() );
aOKClose.SetPosPixel( aPos );
-
-// SetUpdateMode( sal_True );
-// Invalidate();
}
FloatingWindow::Resize();
}
@@ -1346,9 +1326,6 @@ VarEditDialog::VarEditDialog( Window * pParent, SbxVariable *pPVar )
else
aRadioButtonRID_RB_NEW_BOOL_F.Check();
break;
-// case SbxCURRENCY:
-// case SbxDATE:
-// break;
case SbxINTEGER:
aNumericFieldRID_NF_NEW_INTEGER.Show();
aNumericFieldRID_NF_NEW_INTEGER.SetText( pVar->GetString() );
@@ -1362,8 +1339,6 @@ VarEditDialog::VarEditDialog( Window * pParent, SbxVariable *pPVar )
aNumericFieldRID_NF_NEW_LONG.SetMin( -aNumericFieldRID_NF_NEW_LONG.GetMax()-1 );
aNumericFieldRID_NF_NEW_LONG.SetFirst( -aNumericFieldRID_NF_NEW_LONG.GetLast()-1 );
break;
-// case SbxOBJECT: // cannot be edited
-// break;
case SbxSINGLE:
case SbxDOUBLE:
case SbxSTRING:
@@ -1389,41 +1364,6 @@ IMPL_LINK( VarEditDialog, OKClick, Button *, pButton )
SbxDataType eType = pVar->GetType();
-/*
-Boolean
-Currency
-Date
-Double
-Integer
-Long
-Object
-Single
-String
-Variant
-
-
-atof
-
- ecvt
- f
- gcvt
-
-SvNumberformat::
- static double StringToDouble( const xub_Unicode* pStr,
- const International& rIntl,
- int& nErrno,
- const xub_Unicode** ppEnd = NULL );
- // Converts just as strtod a decimal string to a double.
- // Decimal and thousand separators come from International,
- // leading spaces are omitted.
- // If ppEnd!=NULL then *ppEnd is set after the parsed data.
- // If pStr contains only the String to be parsed, then if success:
- // **ppEnd=='\0' and *ppEnd-pStr==strlen(pStr).
- // If overflow fVal=+/-HUGE_VAL, if underflow 0,
- // nErrno is in this cases set to ERANGE otherwise 0.
- // "+/-1.#INF" are recognized as +/-HUGE_VAL.
-
- */
@@ -1434,12 +1374,6 @@ SvNumberformat::
case SbxBOOL:
pVar->PutBool( aRadioButtonRID_RB_NEW_BOOL_T.IsChecked() );
break;
-// case SbxCURRENCY:
-// pVar->PutCurrency( aContent );
-// break;
-// case SbxDATE:
-// pVar->PutDate( aContent );
-// break;
case SbxINTEGER:
pVar->PutInteger( (sal_Int16)aNumericFieldRID_NF_NEW_INTEGER.GetValue() );
break;
@@ -1462,7 +1396,6 @@ SvNumberformat::
}
-// pVar->PutStringExt( aEditRID_ED_NEW_STRING.GetText() );
if ( !bWasError && SbxBase::IsError() )
{
bError = sal_True;
@@ -1475,12 +1408,6 @@ SvNumberformat::
return 1;
}
-// if ( aEditRID_ED_NEW_STRING.GetText().Compare( pVar->GetString() ) != COMPARE_EQUAL )
-// {
-// aFixedTextRID_FT_CONTENT_VALUE.SetText( pVar->GetString() );
-// aEditRID_ED_NEW_STRING.SetText( pVar->GetString() );
-// return 1;
-// }
Close();
return 0;
diff --git a/basic/source/app/dialogs.hxx b/basic/source/app/dialogs.hxx
index 108aaa5de062..ce06a1154420 100755
--- a/basic/source/app/dialogs.hxx
+++ b/basic/source/app/dialogs.hxx
@@ -81,7 +81,6 @@ public:
ReplaceDialog (Window*, const ResId&, String&, String&);
};
-////////////////////////////////////////////////////////////////////
class ConfEdit : public PushButton
{
diff --git a/basic/source/app/msgedit.cxx b/basic/source/app/msgedit.cxx
index 1ebc24d560a0..90d617321419 100755
--- a/basic/source/app/msgedit.cxx
+++ b/basic/source/app/msgedit.cxx
@@ -75,7 +75,6 @@ MsgEdit::MsgEdit( AppError* pParent, BasicFrame *pBF, const WinBits& aBits )
, pAppError( pParent )
, aEditTree( pParent, pBF, aBits | WB_HASBUTTONS | WB_HASLINES | WB_HASBUTTONSATROOT )
{
-// SetFont( aEditTree.GetDefaultFont( DEFAULTFONT_FIXED, aEditTree.GetSettings().GetLanguage(), 0, &aEditTree ) );
aEditTree.SetNodeBitmaps( Bitmap( SttResId (MBP_PLUS) ), Bitmap( SttResId (MBP_MINUS) ) );
aEditTree.SetSelectionMode( MULTIPLE_SELECTION );
if ( aEditTree.GetModel()->GetSortMode() != SortNone )
@@ -422,36 +421,6 @@ void MsgEdit::AddQAError( String aMsg, TTDebugData aDebugData )
aEditTree.InvalidateEntry( pThisEntry );
}
-/*
- SvLBoxEntry* GetEntry( SvLBoxEntry* pParent, sal_uIntPtr nPos ) const { return SvLBox::GetEntry(pParent,nPos); }
- SvLBoxEntry* GetEntry( sal_uIntPtr nRootPos ) const { return SvLBox::GetEntry(nRootPos);}
-
-
-
- SvLBoxEntry* FirstChild(SvLBoxEntry* pParent ) const { return (SvLBoxEntry*)(pModel->FirstChild(pParent)); }
- SvLBoxEntry* NextSibling(SvLBoxEntry* pEntry ) const { return (SvLBoxEntry*)(pModel->NextSibling( pEntry )); }
- SvLBoxEntry* PrevSibling(SvLBoxEntry* pEntry ) const { return (SvLBoxEntry*)(pModel->PrevSibling( pEntry )); }
-
- SvLBoxEntry* FirstSelected() const { return (SvLBoxEntry*)SvListView::FirstSelected(); }
- SvLBoxEntry* NextSelected( SvLBoxEntry* pEntry ) const { return (SvLBoxEntry*)(SvListView::NextSelected(pEntry)); }
- SvLBoxEntry* PrevSelected( SvLBoxEntry* pEntry ) const { return (SvLBoxEntry*)(SvListView::PrevSelected(pEntry)); }
- SvLBoxEntry* LastSelected() const { return (SvLBoxEntry*)(SvListView::LastSelected()); }
-
- SvLBoxEntry* GetEntry( SvLBoxEntry* pParent, sal_uIntPtr nPos ) const { return (SvLBoxEntry*)(pModel->GetEntry(pParent,nPos)); }
- SvLBoxEntry* GetEntry( sal_uIntPtr nRootPos ) const { return (SvLBoxEntry*)(pModel->GetEntry(nRootPos)); }
-
- SvLBoxEntry* GetParent( SvLBoxEntry* pEntry ) const { return (SvLBoxEntry*)(pModel->GetParent(pEntry)); }
- SvLBoxEntry* GetRootLevelParent(SvLBoxEntry* pEntry ) const { return (SvLBoxEntry*)(pModel->GetRootLevelParent( pEntry ));}
-
- sal_Bool IsInChildList( SvListEntry* pParent, SvListEntry* pChild) const;
- SvListEntry* GetEntry( SvListEntry* pParent, sal_uIntPtr nPos ) const;
- SvListEntry* GetEntry( sal_uIntPtr nRootPos ) const;
- SvListEntry* GetEntryAtAbsPos( sal_uIntPtr nAbsPos ) const;
- SvListEntry* GetParent( SvListEntry* pEntry ) const;
- SvListEntry* GetRootLevelParent( SvListEntry* pEntry ) const;
-*/
-
-//#define CHECK( pMemo ) if ( pMemo && !aEditTree.GetViewData( pMemo ) ) pMemo = NULL
#define CHECK( pMemo ) if ( pMemo && !aEditTree.GetModel()->IsInChildList( NULL, pMemo ) ) pMemo = NULL
void MsgEdit::Delete()
{
@@ -771,7 +740,6 @@ TTTreeListBox::TTTreeListBox( AppError* pParent, BasicFrame* pBF, WinBits nWinSt
: SvTreeListBox( pParent, nWinStyle )
, pBasicFrame(pBF)
, pAppError( pParent )
-//, nDeselectParent(0)
{}
sal_Bool TTTreeListBox::JumpToSourcecode( SvLBoxEntry *pThisEntry )
@@ -820,47 +788,6 @@ sal_Bool TTTreeListBox::DoubleClickHdl()
return JumpToSourcecode( GetHdlEntry() );
}
-/*sal_uIntPtr TTTreeListBox::SelectChildren( SvLBoxEntry* pParent, sal_Bool bSelect )
-{
- SvLBoxEntry *pEntry = FirstChild( pParent );
- sal_uIntPtr nRet = 0;
- while ( pEntry )
- {
- nRet++;
- Select( pEntry, bSelect );
- pEntry = NextSibling( pEntry );
- }
- return nRet;
-}
-
-
-void TTTreeListBox::SelectHdl()
-{
- SvLBoxEntry* pHdlEntry = GetHdlEntry();
-
- SelectChildren( pHdlEntry, sal_True );
- Select( pHdlEntry, sal_True );
-// InitMenu(pApp->GetAppMenu()->GetPopupMenu( RID_APPEDIT )); // so that delete works correct
-}
-
-void TTTreeListBox::DeselectHdl()
-{
- SvLBoxEntry* pHdlEntry = GetHdlEntry();
- if ( GetParent( pHdlEntry ) )
- {
- nDeselectParent++;
- Select( GetParent( pHdlEntry ), sal_False );
- nDeselectParent--;
- }
- if ( !nDeselectParent )
- {
- SelectChildren( pHdlEntry, sal_False );
- Select( pHdlEntry, sal_False );
- }
- Invalidate();
-} */
-
-
void TTTreeListBox::KeyInput( const KeyEvent& rKEvt )
{
switch ( rKEvt.GetKeyCode().GetFunction() )
diff --git a/basic/source/app/msgedit.hxx b/basic/source/app/msgedit.hxx
index 442ff3034c19..0da878cf48f5 100755
--- a/basic/source/app/msgedit.hxx
+++ b/basic/source/app/msgedit.hxx
@@ -49,8 +49,6 @@ typedef sal_uInt16 TTFeatures; // Bitfield for features of the entries
class TTTreeListBox : public SvTreeListBox
{
protected:
-// virtual void Command( const CommandEvent& rCEvt );
-// sal_uInt16 nDeselectParent;
BasicFrame *pBasicFrame;
void InitEntry( SvLBoxEntry*, const String&, const Image&,
const Image&, SvLBoxButtonKind eButtonKind );
@@ -62,13 +60,10 @@ public:
TTTreeListBox( AppError* pParent, BasicFrame* pBF, WinBits nWinStyle=0 );
~TTTreeListBox(){}
-// virtual void SelectHdl();
-// virtual void DeselectHdl();
virtual sal_Bool DoubleClickHdl();
virtual void KeyInput( const KeyEvent& rKEvt );
-// sal_uIntPtr SelectChildren( SvLBoxEntry* pParent, sal_Bool bSelect );
TTFeatures GetFeatures( SvLBoxEntry* );
};
diff --git a/basic/source/app/mybasic.cxx b/basic/source/app/mybasic.cxx
index 9e2a32fe751f..12e902e53c79 100755
--- a/basic/source/app/mybasic.cxx
+++ b/basic/source/app/mybasic.cxx
@@ -101,7 +101,6 @@ MyBasic::MyBasic() : StarBASIC()
// Box object into SbUnoObject
String aName( "UnoObject" );
SbxObjectRef xSbUnoObj = GetSbUnoObject( aName, aObjAny );
- //SbxObjectRef xSbUnoObj = new SbUnoObject( aName, aObjAny );
Insert( (SbxObject*)xSbUnoObj );
#endif
@@ -282,8 +281,6 @@ sal_uInt16 MyBasic::BreakHdl()
if( IsBreak() ) // If Breakpoint (or "Run to Cursor")
{
-// if ( GetActiveModule()->IsBP(GetLine()) )
-// GetActiveModule()->ClearBP(GetLine());
return aBasicApp.pFrame->BreakHandler();
}
else
diff --git a/basic/source/app/process.cxx b/basic/source/app/process.cxx
index 5dda13c145d0..6289b5d8eac3 100755
--- a/basic/source/app/process.cxx
+++ b/basic/source/app/process.cxx
@@ -110,7 +110,6 @@ long Process::ImplGetExitCode()
}
-////////////////////////////////////////////////////////////////////////////
void Process::SetImage( const String &aAppPath, const String &aAppParams, const Environment *pEnv )
{ // Set image file of executable
diff --git a/basic/source/app/processw.cxx b/basic/source/app/processw.cxx
index 4bf428b6a0ac..5c1b66f81079 100755
--- a/basic/source/app/processw.cxx
+++ b/basic/source/app/processw.cxx
@@ -216,10 +216,8 @@ SbxInfo* ProcessWrapper::GetInfo( short nIdx )
}
-////////////////////////////////////////////////////////////////////////////
-////////////////////////////////////////////////////////////////////////////
// Properties and methods save the return value in argv[0] (Get, bPut = sal_False)
// and store the value from argv[0] (Put, bPut = sal_True)
diff --git a/basic/source/app/svtmsg.src b/basic/source/app/svtmsg.src
index 365f5f3d4ee6..68c2930236b8 100755
--- a/basic/source/app/svtmsg.src
+++ b/basic/source/app/svtmsg.src
@@ -30,7 +30,6 @@
// Here are included the messages of the folder /basic/source/app
-///////////////////////////////
// Error messages which go to the result file.
// *********************
// *** !!ATTENTION!! ***
@@ -38,7 +37,6 @@
// The numbers must NEVER(!) change,
// because they are saved in the result files and a renewed display
// would display new strings or no strings.
-///////////////////////////////
String S_GPF_ABORT
{
Text[ en-US ] = "Program aborted with GPF";
diff --git a/basic/source/app/testtool.src b/basic/source/app/testtool.src
index 090cb735c139..9b89f6da14b1 100755
--- a/basic/source/app/testtool.src
+++ b/basic/source/app/testtool.src
@@ -27,9 +27,7 @@
#include "basic/testtool.hrc"
-///////////////////////////////
// Strings
-///////////////////////////////
String S_INVALID_KEYCODE
{
Text[ en-US ] = "Is an invalid KeyCode!";
diff --git a/basic/source/app/textedit.cxx b/basic/source/app/textedit.cxx
index 4ffbef7121f8..8c8ea6873033 100755
--- a/basic/source/app/textedit.cxx
+++ b/basic/source/app/textedit.cxx
@@ -620,12 +620,9 @@ Variant(Empty)
switch ( eType )
{
case SbxBOOL:
-// case SbxCURRENCY:
-// case SbxDATE:
case SbxDOUBLE:
case SbxINTEGER:
case SbxLONG:
-// case SbxOBJECT: // cannot be edited
case SbxSINGLE:
case SbxSTRING:
@@ -707,7 +704,7 @@ void TextEdit::Highlight( sal_uIntPtr nLine, xub_StrLen nCol1, xub_StrLen nCol2
aEdit.pTextView->SetSelection( TextSelection(TextPaM(nLine,nCol2+1), TextPaM(nLine,nCol1)) );
if ( aEdit.ViewMoved() )
{
- aEdit.pTextView->SetSelection( TextSelection(TextPaM(TEXT_PARA_ALL,1)) ); // fix #105169#
+ aEdit.pTextView->SetSelection( TextSelection(TextPaM(TEXT_PARA_ALL,1)) );
aEdit.pTextView->SetSelection( TextSelection(TextPaM((nLine>=2?nLine-2:0),nCol2+1)) );
aEdit.pTextView->SetSelection( TextSelection(TextPaM(nLine,nCol2+1), TextPaM(nLine,nCol1)) );
}
diff --git a/basic/source/app/textedit.hxx b/basic/source/app/textedit.hxx
index 21044c75e4bf..2d68d11541db 100755
--- a/basic/source/app/textedit.hxx
+++ b/basic/source/app/textedit.hxx
@@ -97,10 +97,7 @@ public:
void Paint( const Rectangle& rRect );
void MouseButtonUp( const MouseEvent& rMouseEvent );
void MouseButtonDown( const MouseEvent& rMouseEvent );
-// void MouseMove( const MouseEvent& rMouseEvent );
void Command( const CommandEvent& rCEvt );
- //sal_Bool Drop( const DropEvent& rEvt );
- //sal_Bool QueryDrop( DropEvent& rEvt );
sal_Bool ViewMoved();
diff --git a/basic/source/app/ttmsg.src b/basic/source/app/ttmsg.src
index c2c017b167ca..d5ac293e5115 100755
--- a/basic/source/app/ttmsg.src
+++ b/basic/source/app/ttmsg.src
@@ -30,7 +30,6 @@
// Here are included the messages of the folder /basic/source/testtool
-///////////////////////////////
// Error messages which go to the result file.
// *********************
// *** !!ATTENTION!! ***
@@ -38,7 +37,6 @@
// The numbers must NEVER(!) change,
// because they are saved in the result files and a renewed display
// would display new strings or no strings.
-///////////////////////////////
String S_NAME_NOT_THERE
{
@@ -140,22 +138,4 @@ String S_UNKNOWN_METHOD
{
Text[ en-US ] = "Unknown method on object :($Arg1).($Arg2)";
};
-/*
-String
-{
- Text[ en-US ] = ;
-};
-String
-{
- Text[ en-US ] = ;
-};
-String
-{
- Text[ en-US ] = ;
-};
-String
-{
- Text[ en-US ] = ;
-};
-*/
diff --git a/basic/source/basmgr/basicmanagerrepository.cxx b/basic/source/basmgr/basicmanagerrepository.cxx
index 58114be70f5f..b24c232626f8 100755
--- a/basic/source/basmgr/basicmanagerrepository.cxx
+++ b/basic/source/basmgr/basicmanagerrepository.cxx
@@ -301,11 +301,11 @@ namespace basic
if ( !aAppBasicDir.Len() )
aPathCFG.SetBasicPath( String::CreateFromAscii("$(prog)") );
- // #58293# soffice.new search only in user dir => first dir
+ // soffice.new search only in user dir => first dir
String aAppFirstBasicDir = aAppBasicDir.GetToken(1);
// Create basic and load it
- // MT: #47347# AppBasicDir is now a PATH
+ // AppBasicDir is now a PATH
INetURLObject aAppBasic( SvtPathOptions().SubstituteVariable( String::CreateFromAscii("$(progurl)") ) );
aAppBasic.insertName( Application::GetAppName() );
@@ -483,9 +483,6 @@ namespace basic
LibraryContainerInfo aInfo( xBasicLibs, xDialogLibs, dynamic_cast< OldBasicPassword* >( xBasicLibs.get() ) );
OSL_ENSURE( aInfo.mpOldBasicPassword, "ImplRepository::impl_createManagerForModel: wrong BasicLibraries implementation!" );
_out_rpBasicManager->SetLibraryContainerInfo( aInfo );
- //pBasicCont->setBasicManager( _out_rpBasicManager );
- // that's not needed anymore today. The containers will retrieve their associated
- // BasicManager from the BasicManagerRepository, when needed.
// initialize the containers
impl_initDocLibraryContainers_nothrow( xBasicLibs, xDialogLibs );
diff --git a/basic/source/basmgr/basmgr.cxx b/basic/source/basmgr/basmgr.cxx
index a2aa4b53207c..bd73970b118e 100755
--- a/basic/source/basmgr/basmgr.cxx
+++ b/basic/source/basmgr/basmgr.cxx
@@ -804,11 +804,6 @@ BasicManager::BasicManager( SotStorage& rStorage, const String& rBaseURL, StarBA
String aStorName( rStorage.GetName() );
maStorageName = INetURLObject(aStorName, INET_PROT_FILE).GetMainURL( INetURLObject::NO_DECODE );
- // #91251: Storage name not longer available for documents < 5.0
- // Should be no real problem, because only relative storage names
- // (links) can be affected.
- // DBG_ASSERT( aStorName.Len(), "No Storage Name!" );
- // DBG_ASSERT(aStorageName.Len() != 0, "Bad storage name");
// If there is no Manager Stream, no further actions are necessary
if ( rStorage.IsStream( String(RTL_CONSTASCII_USTRINGPARAM(szManagerStream)) ) )
@@ -840,7 +835,6 @@ BasicManager::BasicManager( SotStorage& rStorage, const String& rBaseURL, StarBA
StarBASIC* pBasic = GetLib( nBasic );
if ( pBasic )
{
-// pBasic->SetParent( pStdLib );
pStdLib->Insert( pBasic );
pBasic->SetFlag( SBX_EXTSEARCH );
}
@@ -1063,7 +1057,6 @@ void BasicManager::LoadBasicManager( SotStorage& rStorage, const String& rBaseUR
{
DBG_CHKTHIS( BasicManager, 0 );
-// StreamMode eStreamMode = STREAM_READ | STREAM_NOCREATE | STREAM_SHARE_DENYWRITE;
SotStorageStreamRef xManagerStream = rStorage.OpenSotStream
( String(RTL_CONSTASCII_USTRINGPARAM(szManagerStream)), eStreamReadMode );
@@ -1082,8 +1075,6 @@ void BasicManager::LoadBasicManager( SotStorage& rStorage, const String& rBaseUR
String aRealStorageName = maStorageName; // for relative paths, can be modified through BaseURL
- // If loaded from template, only BaseURL is used:
- //String aBaseURL = INetURLObject::GetBaseURL();
if ( rBaseURL.Len() )
{
INetURLObject aObj( rBaseURL );
@@ -1119,9 +1110,6 @@ void BasicManager::LoadBasicManager( SotStorage& rStorage, const String& rBaseUR
aObj = aObj.smartRel2Abs( pInfo->GetRelStorageName(), bWasAbsolute );
//*** TODO: Replace if still necessary
- /* if ( SfxContentHelper::Exists( aObj.GetMainURL() ) )
- pInfo->SetStorageName( aObj.GetMainURL() );
- else */
//*** TODO-End
if ( pLibs->aBasicLibPath.Len() )
{
@@ -1155,7 +1143,6 @@ void BasicManager::LoadOldBasicManager( SotStorage& rStorage )
{
DBG_CHKTHIS( BasicManager, 0 );
-// StreamMode eStreamMode = STREAM_READ | STREAM_NOCREATE | STREAM_SHARE_DENYWRITE;
SotStorageStreamRef xManagerStream = rStorage.OpenSotStream
( String::CreateFromAscii(szOldManagerStream), eStreamReadMode );
@@ -1549,7 +1536,6 @@ sal_Bool BasicManager::RemoveLib( sal_uInt16 nLib, sal_Bool bDelBasicFromStorage
if ( !pLibInfo || !nLib )
{
-// String aErrorText( BasicResId( IDS_SBERR_REMOVELIB ) );
StringErrorInfo* pErrInf = new StringErrorInfo( ERRCODE_BASMGR_REMOVELIB, String(), ERRCODE_BUTTON_OK );
pErrorMgr->InsertError( BasicError( *pErrInf, BASERR_REASON_STDLIB, pLibInfo->GetLibName() ) );
return sal_False;
diff --git a/basic/source/classes/disas.cxx b/basic/source/classes/disas.cxx
index a06c0d05ed18..df48e94dfd16 100755
--- a/basic/source/classes/disas.cxx
+++ b/basic/source/classes/disas.cxx
@@ -390,8 +390,6 @@ sal_Bool SbiDisas::DisasLine( String& rText )
n = s.Search( '\n' );
if( n != STRING_NOTFOUND ) bDone = sal_False, s.Erase( n, 1 );
} while( !bDone );
-// snprintf( cBuf, sizeof(cBuf), pMask[ 0 ], nPC );
-// rText += cBuf;
rText.AppendAscii( "; " );
rText += s;
rText.AppendAscii( _crlf() );
diff --git a/basic/source/classes/eventatt.cxx b/basic/source/classes/eventatt.cxx
index bb26b99129dd..ceb4ea9230ab 100755
--- a/basic/source/classes/eventatt.cxx
+++ b/basic/source/classes/eventatt.cxx
@@ -214,8 +214,6 @@ void BasicScriptListener_Impl::disposing(const EventObject& ) throw ( RuntimeExc
void BasicScriptListener_Impl::firing_impl( const ScriptEvent& aScriptEvent, Any* pRet )
{
- //Guard< Mutex > aGuard( Mutex::getGlobalMutex() );
- //{
if( aScriptEvent.ScriptType.compareToAscii( "StarBasic" ) == 0 )
{
// Full qualified name?
diff --git a/basic/source/classes/image.cxx b/basic/source/classes/image.cxx
index d9e7bc521af1..84c6a25dab39 100755
--- a/basic/source/classes/image.cxx
+++ b/basic/source/classes/image.cxx
@@ -157,18 +157,15 @@ sal_Bool SbiImage::Load( SvStream& r, sal_uInt32& nVersion )
{
case B_NAME:
r.ReadByteString( aName, eCharSet );
- //r >> aName;
break;
case B_COMMENT:
r.ReadByteString( aComment, eCharSet );
- //r >> aComment;
break;
case B_SOURCE:
{
String aTmp;
r.ReadByteString( aTmp, eCharSet );
aOUSource = aTmp;
- //r >> aSource;
break;
}
#ifdef EXTENDED_BINARY_MODULES
@@ -250,8 +247,6 @@ sal_Bool SbiImage::Load( SvStream& r, sal_uInt32& nVersion )
}
done:
r.Seek( nLast );
- //if( eCharSet != ::GetSystemCharSet() )
- //ConvertStrings();
if( !SbiGood( r ) )
bError = sal_True;
return sal_Bool( !bError );
@@ -291,7 +286,6 @@ sal_Bool SbiImage::Save( SvStream& r, sal_uInt32 nVer )
{
nPos = SbiOpenRecord( r, B_NAME, 1 );
r.WriteByteString( aName, eCharSet );
- //r << aName;
SbiCloseRecord( r, nPos );
}
// Comment?
@@ -299,7 +293,6 @@ sal_Bool SbiImage::Save( SvStream& r, sal_uInt32 nVer )
{
nPos = SbiOpenRecord( r, B_COMMENT, 1 );
r.WriteByteString( aComment, eCharSet );
- //r << aComment;
SbiCloseRecord( r, nPos );
}
// Source?
@@ -314,7 +307,6 @@ sal_Bool SbiImage::Save( SvStream& r, sal_uInt32 nVer )
else
aTmp = aOUSource;
r.WriteByteString( aTmp, eCharSet );
- //r << aSource;
SbiCloseRecord( r, nPos );
#ifdef EXTENDED_BINARY_MODULES
@@ -440,7 +432,6 @@ void SbiImage::AddString( const String& r )
if( !bError )
{
pStringOff[ nStringIdx++ ] = nStringOff;
- //ByteString aByteStr( r, eCharSet );
memcpy( pStrings + nStringOff, r.GetBuffer(), len * sizeof( sal_Unicode ) );
nStringOff = nStringOff + len;
// Last String? The update the size of the buffer
diff --git a/basic/source/classes/sb.cxx b/basic/source/classes/sb.cxx
index bb65b0c8b82b..5cfdc1dcea4f 100755
--- a/basic/source/classes/sb.cxx
+++ b/basic/source/classes/sb.cxx
@@ -688,7 +688,6 @@ SbClassModuleObject::SbClassModuleObject( SbModule* pClassModule )
pProcedureProp->SetFlag( SBX_NO_BROADCAST );
SbProcedureProperty* pNewProp = new SbProcedureProperty
( pProcedureProp->GetName(), pProcedureProp->GetType() );
- // ( pProcedureProp->GetName(), pProcedureProp->GetType(), this );
pNewProp->SetFlags( nFlags_ ); // Copy flags
pNewProp->ResetFlag( SBX_NO_BROADCAST ); // except the Broadcast if it was set
pProcedureProp->SetFlags( nFlags_ );
@@ -994,7 +993,6 @@ void* StarBASIC::operator new( size_t n )
{
if( n < sizeof( StarBASIC ) )
{
-// DBG_ASSERT( sal_False, "Warnung: inkompatibler BASIC-Stand!" );
n = sizeof( StarBASIC );
}
return ::operator new( n );
@@ -1141,7 +1139,6 @@ struct ClassModuleRunInitItem
SbModule* m_pModule;
bool m_bProcessing;
bool m_bRunInitDone;
- //ModuleVector m_vModulesDependingOnThisModule;
ClassModuleRunInitItem( void )
: m_pModule( NULL )
@@ -1166,7 +1163,6 @@ void SbModule::implProcessModuleRunInit( ModuleInitDependencyMap& rMap, ClassMod
{
rItem.m_bProcessing = true;
- //bool bAnyDependencies = true;
SbModule* pModule = rItem.m_pModule;
if( pModule->pClassData != NULL )
{
diff --git a/basic/source/classes/sbunoobj.cxx b/basic/source/classes/sbunoobj.cxx
index 28765880c6e4..7695f73a317f 100755
--- a/basic/source/classes/sbunoobj.cxx
+++ b/basic/source/classes/sbunoobj.cxx
@@ -605,22 +605,11 @@ SbxDataType unoToSbxType( TypeClass eType )
case TypeClass_STRUCT:
case TypeClass_EXCEPTION: eRetType = SbxOBJECT; break;
- /* first we leave the following types out
- case TypeClass_SERVICE: break;
- case TypeClass_CLASS: break;
- case TypeClass_TYPEDEF: break;
- case TypeClass_UNION: break;
- case TypeClass_ARRAY: break;
- */
case TypeClass_ENUM: eRetType = SbxLONG; break;
case TypeClass_SEQUENCE:
eRetType = (SbxDataType) ( SbxOBJECT | SbxARRAY );
break;
- /*
- case TypeClass_VOID: break;
- case TypeClass_UNKNOWN: break;
- */
case TypeClass_ANY: eRetType = SbxVARIANT; break;
case TypeClass_BOOLEAN: eRetType = SbxBOOL; break;
@@ -628,18 +617,13 @@ SbxDataType unoToSbxType( TypeClass eType )
case TypeClass_STRING: eRetType = SbxSTRING; break;
case TypeClass_FLOAT: eRetType = SbxSINGLE; break;
case TypeClass_DOUBLE: eRetType = SbxDOUBLE; break;
- //case TypeClass_OCTET: break;
case TypeClass_BYTE: eRetType = SbxINTEGER; break;
- //case TypeClass_INT: eRetType = SbxINT; break;
case TypeClass_SHORT: eRetType = SbxINTEGER; break;
case TypeClass_LONG: eRetType = SbxLONG; break;
case TypeClass_HYPER: eRetType = SbxSALINT64; break;
- //case TypeClass_UNSIGNED_OCTET: break;
case TypeClass_UNSIGNED_SHORT: eRetType = SbxUSHORT; break;
case TypeClass_UNSIGNED_LONG: eRetType = SbxULONG; break;
case TypeClass_UNSIGNED_HYPER: eRetType = SbxSALUINT64;break;
- //case TypeClass_UNSIGNED_INT: eRetType = SbxUINT; break;
- //case TypeClass_UNSIGNED_BYTE: eRetType = SbxUSHORT; break;
default: break;
}
return eRetType;
@@ -869,14 +853,6 @@ void unoToSbxValue( SbxVariable* pVar, const Any& aValue )
}
break;
- /* folgende Typen lassen wir erstmal weg
- case TypeClass_SERVICE: break;
- case TypeClass_CLASS: break;
- case TypeClass_TYPEDEF: break;
- case TypeClass_UNION: break;
- case TypeClass_ENUM: break;
- case TypeClass_ARRAY: break;
- */
case TypeClass_ENUM:
{
@@ -929,24 +905,9 @@ void unoToSbxValue( SbxVariable* pVar, const Any& aValue )
pVar->PutObject( (SbxDimArray*)xArray );
pVar->SetFlags( nFlags );
- // The parameter mustn't deleted here
- //pVar->SetParameters( NULL );
}
break;
- /*
- case TypeClass_VOID: break;
- case TypeClass_UNKNOWN: break;
-
- case TypeClass_ANY:
- {
- // get Any and convert it
- //Any* pAny = (Any*)aValue.get();
- //if( pAny )
- //unoToSbxValue( pVar, *pAny );
- }
- break;
- */
case TypeClass_BOOLEAN: pVar->PutBool( *(sal_Bool*)aValue.getValue() ); break;
case TypeClass_CHAR:
@@ -957,18 +918,13 @@ void unoToSbxValue( SbxVariable* pVar, const Any& aValue )
case TypeClass_STRING: { ::rtl::OUString val; aValue >>= val; pVar->PutString( String( val ) ); } break;
case TypeClass_FLOAT: { float val = 0; aValue >>= val; pVar->PutSingle( val ); } break;
case TypeClass_DOUBLE: { double val = 0; aValue >>= val; pVar->PutDouble( val ); } break;
- //case TypeClass_OCTET: break;
case TypeClass_BYTE: { sal_Int8 val = 0; aValue >>= val; pVar->PutInteger( val ); } break;
- //case TypeClass_INT: break;
case TypeClass_SHORT: { sal_Int16 val = 0; aValue >>= val; pVar->PutInteger( val ); } break;
case TypeClass_LONG: { sal_Int32 val = 0; aValue >>= val; pVar->PutLong( val ); } break;
case TypeClass_HYPER: { sal_Int64 val = 0; aValue >>= val; pVar->PutInt64( val ); } break;
- //case TypeClass_UNSIGNED_OCTET:break;
case TypeClass_UNSIGNED_SHORT: { sal_uInt16 val = 0; aValue >>= val; pVar->PutUShort( val ); } break;
case TypeClass_UNSIGNED_LONG: { sal_uInt32 val = 0; aValue >>= val; pVar->PutULong( val ); } break;
case TypeClass_UNSIGNED_HYPER: { sal_uInt64 val = 0; aValue >>= val; pVar->PutUInt64( val ); } break;
- //case TypeClass_UNSIGNED_INT: break;
- //case TypeClass_UNSIGNED_BYTE: break;
default: pVar->PutEmpty(); break;
}
}
@@ -979,7 +935,6 @@ Type getUnoTypeForSbxBaseType( SbxDataType eType )
Type aRetType = getCppuVoidType();
switch( eType )
{
- //case SbxEMPTY: eRet = TypeClass_VOID; break;
case SbxNULL: aRetType = ::getCppuType( (const Reference< XInterface > *)0 ); break;
case SbxINTEGER: aRetType = ::getCppuType( (sal_Int16*)0 ); break;
case SbxLONG: aRetType = ::getCppuType( (sal_Int32*)0 ); break;
@@ -995,13 +950,9 @@ Type getUnoTypeForSbxBaseType( SbxDataType eType )
aRetType = ::getCppuType( (oleautomation::Date*)0 );
}
break;
- // case SbxDATE: aRetType = ::getCppuType( (double*)0 ); break;
case SbxSTRING: aRetType = ::getCppuType( (::rtl::OUString*)0 ); break;
- //case SbxOBJECT: break;
- //case SbxERROR: break;
case SbxBOOL: aRetType = ::getCppuType( (sal_Bool*)0 ); break;
case SbxVARIANT: aRetType = ::getCppuType( (Any*)0 ); break;
- //case SbxDATAOBJECT: break;
case SbxCHAR: aRetType = ::getCppuType( (sal_Unicode*)0 ); break;
case SbxBYTE: aRetType = ::getCppuType( (sal_Int8*)0 ); break;
case SbxUSHORT: aRetType = ::getCppuType( (sal_uInt16*)0 ); break;
@@ -1009,15 +960,6 @@ Type getUnoTypeForSbxBaseType( SbxDataType eType )
// map machine-dependent ones on hyper for secureness
case SbxINT: aRetType = ::getCppuType( (sal_Int32*)0 ); break;
case SbxUINT: aRetType = ::getCppuType( (sal_uInt32*)0 ); break;
- //case SbxVOID: break;
- //case SbxHRESULT: break;
- //case SbxPOINTER: break;
- //case SbxDIMARRAY: break;
- //case SbxCARRAY: break;
- //case SbxUSERDEF: break;
- //case SbxLPSTR: break;
- //case SbxLPWSTR: break;
- //case SbxCoreSTRING: break;
default: break;
}
return aRetType;
@@ -1037,8 +979,6 @@ Type getUnoTypeForSbxValue( SbxValue* pVal )
SbxBaseRef xObj = (SbxBase*)pVal->GetObject();
if( !xObj )
{
- // #109936 No error any more
- // StarBASIC::Error( SbERR_INVALID_OBJECT );
aRetType = getCppuType( static_cast<Reference<XInterface> *>(0) );
return aRetType;
}
@@ -1072,7 +1012,6 @@ Type getUnoTypeForSbxValue( SbxValue* pVal )
{
if( aType.getTypeClass() == TypeClass_VOID )
{
- // #88522
// if only first element is void: different types -> []any
// if all elements are void: []void is not allowed -> []any
aElementType = getCppuType( (Any*)0 );
@@ -1468,13 +1407,6 @@ Any sbxToUnoValue( SbxVariable* pVar, const Type& rType, Property* pUnoProperty
}
break;
- /* we leave out the following types
- case TypeClass_SERVICE: break;
- case TypeClass_CLASS: break;
- case TypeClass_TYPEDEF: break;
- case TypeClass_UNION: break;
- case TypeClass_ARRAY: break;
- */
case TypeClass_ENUM:
{
@@ -1510,7 +1442,6 @@ Any sbxToUnoValue( SbxVariable* pVar, const Type& rType, Property* pUnoProperty
typelib_typedescription_getByName( &pSeqTD, aClassName.pData );
OSL_ASSERT( pSeqTD );
Type aElemType( ((typelib_IndirectTypeDescription *)pSeqTD)->pType );
- // Reference< XIdlClass > xElementClass = TypeToIdlClass( aElemType );
// convert all array member and register them
sal_Int32 nIdx = nLower;
@@ -1590,10 +1521,6 @@ Any sbxToUnoValue( SbxVariable* pVar, const Type& rType, Property* pUnoProperty
}
break;
- /*
- case TypeClass_VOID: break;
- case TypeClass_UNKNOWN: break;
- */
// Use for Any the class indipendent converting routine
case TypeClass_ANY:
@@ -1617,7 +1544,6 @@ Any sbxToUnoValue( SbxVariable* pVar, const Type& rType, Property* pUnoProperty
case TypeClass_STRING: aRetVal <<= pVar->GetOUString(); break;
case TypeClass_FLOAT: aRetVal <<= pVar->GetSingle(); break;
case TypeClass_DOUBLE: aRetVal <<= pVar->GetDouble(); break;
- //case TypeClass_OCTET: break;
case TypeClass_BYTE:
{
@@ -1640,16 +1566,12 @@ Any sbxToUnoValue( SbxVariable* pVar, const Type& rType, Property* pUnoProperty
aRetVal <<= nByteVal;
break;
}
- //case TypeClass_INT: break;
case TypeClass_SHORT: aRetVal <<= (sal_Int16)( pVar->GetInteger() ); break;
case TypeClass_LONG: aRetVal <<= (sal_Int32)( pVar->GetLong() ); break;
case TypeClass_HYPER: aRetVal <<= (sal_Int64)( pVar->GetInt64() ); break;
- //case TypeClass_UNSIGNED_OCTET:break;
case TypeClass_UNSIGNED_SHORT: aRetVal <<= (sal_uInt16)( pVar->GetUShort() ); break;
case TypeClass_UNSIGNED_LONG: aRetVal <<= (sal_uInt32)( pVar->GetULong() ); break;
case TypeClass_UNSIGNED_HYPER: aRetVal <<= (sal_uInt64)( pVar->GetUInt64() ); break;
- //case TypeClass_UNSIGNED_INT: break;
- //case TypeClass_UNSIGNED_BYTE: break;
default: break;
}
@@ -2377,7 +2299,6 @@ void SbUnoObject::SFX_NOTIFY( SfxBroadcaster& rBC, const TypeId& rBCType,
{
const ParamInfo& rInfo = pParamInfos[i];
const Reference< XIdlClass >& rxClass = rInfo.aType;
- //const XIdlClassRef& rxClass = pUnoParams[i];
com::sun::star::uno::Type aType( rxClass->getTypeClass(), rxClass->getName() );
@@ -2494,10 +2415,6 @@ SbUnoObject::SbUnoObject( const String& aName_, const Any& aUnoObj_ )
if( mxInvocation.is() )
{
- // #94670: This is WRONG because then the MaterialHolder doesn't refer
- // to the object implementing XInvocation but to the object passed to
- // the invocation service!!!
- // mxMaterialHolder = Reference< XMaterialHolder >::query( mxInvocation );
// get the ExactName
mxExactNameInvocation = Reference< XExactName >::query( mxInvocation );
@@ -2599,7 +2516,6 @@ void SbUnoObject::doIntrospection( void )
Reference< XInterface > xI = xFactory->createInstance( rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.beans.Introspection")) );
if (xI.is())
xIntrospection = Reference< XIntrospection >::query( xI );
- //xI->queryInterface( ::getCppuType( (const Reference< XIntrospection > *)0 ), xIntrospection );
}
}
if( !xIntrospection.is() )
@@ -2742,7 +2658,6 @@ SbxInfo* SbUnoMethod::GetInfo()
const ParamInfo& rInfo = pParamInfos[i];
::rtl::OUString aParamName = rInfo.aName;
- // const Reference< XIdlClass >& rxClass = rInfo.aType;
SbxDataType t = SbxVARIANT;
sal_uInt16 nFlags_ = SBX_READ;
pInfo->AddParam( aParamName, t, nFlags_ );
@@ -3376,7 +3291,6 @@ void RTL_Impl_EqualUnoObjects( StarBASIC* pBasic, SbxArray& rPar, sal_Bool bWrit
return;
Reference< XInterface > x1;
aAny1 >>= x1;
- //XInterfaceRef x1 = *(XInterfaceRef*)aAny1.get();
SbxVariableRef xParam2 = rPar.Get( 2 );
if( !xParam2->IsObject() )
@@ -3390,7 +3304,6 @@ void RTL_Impl_EqualUnoObjects( StarBASIC* pBasic, SbxArray& rPar, sal_Bool bWrit
return;
Reference< XInterface > x2;
aAny2 >>= x2;
- //XInterfaceRef x2 = *(XInterfaceRef*)aAny2.get();
if( x1 == x2 )
refVar->PutBool( sal_True );
@@ -4019,8 +3932,6 @@ void SbUnoSingleton::SFX_NOTIFY( SfxBroadcaster& rBC, const TypeId& rBCType,
//========================================================================
-//========================================================================
-//========================================================================
// Implementation of an EventAttacher-drawn AllListener, which
// solely transmits several events to an general AllListener
@@ -4035,9 +3946,6 @@ public:
BasicAllListener_Impl( const ::rtl::OUString& aPrefixName );
~BasicAllListener_Impl();
- // Methods of XInterface
- //virtual sal_Bool queryInterface( Uik aUik, Reference< XInterface > & rOut );
-
// Methods of XAllListener
virtual void SAL_CALL firing(const AllEventObject& Event) throw ( RuntimeException );
virtual Any SAL_CALL approveFiring(const AllEventObject& Event) throw ( RuntimeException );
@@ -4465,28 +4373,6 @@ void RTL_Impl_CreateUnoValue( StarBASIC* pBasic, SbxArray& rPar, sal_Bool bWrite
Any aVal = sbxToUnoValueImpl( pVal );
Any aConvertedVal = convertAny( aVal, aDestType );
- /*
- // Convert
- Reference< XTypeConverter > xConverter = getTypeConverter_Impl();
- try
- {
- aConvertedVal = xConverter->convertTo( aVal, aDestType );
- }
- catch( IllegalArgumentException& e1 )
- {
- StarBASIC::Error( ERRCODE_BASIC_EXCEPTION,
- implGetExceptionMsg( ::cppu::getCaughtException() ) );
- return;
- }
- catch( CannotConvertException& e2 )
- {
- String aCannotConvertExceptionName
- ( RTL_CONSTASCII_USTRINGPARAM("com.sun.star.lang.IllegalArgumentException" ) );
- StarBASIC::Error( ERRCODE_BASIC_EXCEPTION,
- implGetExceptionMsg( e2, aCannotConvertExceptionName ) );
- return;
- }
- */
SbxVariableRef refVar = rPar.Get(0);
SbxObjectRef xUnoAnyObject = new SbUnoAnyObject( aConvertedVal );
@@ -4584,14 +4470,11 @@ void SAL_CALL ModuleInvocationProxy::setValue( const ::rtl::OUString& rProperty,
SbxVariableRef xValue = new SbxVariable;
pMeth->SetParameters( xArray );
pMeth->Call( xValue );
- //aRet = sbxToUnoValue( xValue );
pMeth->SetParameters( NULL );
// TODO: OutParameter?
- // throw InvocationTargetException();
- //return aRet;
}
diff --git a/basic/source/classes/sbxmod.cxx b/basic/source/classes/sbxmod.cxx
index 9b5383dd2577..4ee2cbf5b9af 100755
--- a/basic/source/classes/sbxmod.cxx
+++ b/basic/source/classes/sbxmod.cxx
@@ -511,7 +511,6 @@ void VBAUnlockDocuments( StarBASIC* pBasic )
}
}
-/////////////////////////////////////////////////////////////////////////////
// A Basic module has set EXTSEARCH, so that the elements, that the modul contains,
// could be found from other module.
@@ -765,8 +764,6 @@ const String& SbModule::GetSource() const
void SbModule::SetParent( SbxObject* p )
{
- // #118083: Assertion is not valid any more
- // DBG_ASSERT( !p || p->IsA( TYPE(StarBASIC) ), "Register SbModules only in BASIC" );
pParent = p;
}
@@ -1123,7 +1120,6 @@ sal_uInt16 SbModule::Run( SbMethod* pMeth )
#ifdef UNX
struct rlimit rl;
getrlimit ( RLIMIT_STACK, &rl );
- // printf( "RLIMIT_STACK = %ld\n", rl.rlim_cur );
#endif
#if defined LINUX
// Empiric value, 900 = needed bytes/Basic call level
@@ -1269,9 +1265,6 @@ void SbModule::RunInit()
// Set flag, so that RunInit get activ (Testtool)
GetSbData()->bRunInit = sal_True;
- // sal_Bool bDelInst = sal_Bool( pINST == NULL );
- // if( bDelInst )
- // pINST = new SbiInstance( (StarBASIC*) GetParent() );
SbModule* pOldMod = pMOD;
pMOD = this;
// The init code starts always here
@@ -1284,8 +1277,6 @@ void SbModule::RunInit()
pINST->pRun = pRt->pNext;
delete pRt;
pMOD = pOldMod;
- // if( bDelInst )
- // delete pINST, pINST = NULL;
pImage->bInit = sal_True;
pImage->bFirstInit = sal_False;
@@ -1339,24 +1330,12 @@ void SbModule::ClearPrivateVars()
{
SbxVariable* pj = PTR_CAST(SbxVariable,pArray->Get( j ));
pj->SbxValue::Clear();
- /*
- sal_uInt16 nFlags = pj->GetFlags();
- pj->SetFlags( (nFlags | SBX_WRITE) & (~SBX_FIXED) );
- pj->PutEmpty();
- pj->SetFlags( nFlags );
- */
}
}
}
else
{
p->SbxValue::Clear();
- /*
- sal_uInt16 nFlags = p->GetFlags();
- p->SetFlags( (nFlags | SBX_WRITE) & (~SBX_FIXED) );
- p->PutEmpty();
- p->SetFlags( nFlags );
- */
}
}
}
@@ -1825,7 +1804,6 @@ sal_Bool SbModule::StoreBinaryData( SvStream& rStrm, sal_uInt16 nVer )
}
// Called for >= OO 1.0 passwd protected libraries only
-//
sal_Bool SbModule::LoadBinaryData( SvStream& rStrm )
{
@@ -1948,7 +1926,6 @@ void SbModule::handleProcedureProperties( SfxBroadcaster& rBC, const SfxHint& rH
}
-/////////////////////////////////////////////////////////////////////////
// Implementation SbJScriptModule (Basic-Modul fuer JavaScript-Sourcen)
SbJScriptModule::SbJScriptModule( const String& rName )
:SbModule( rName )
@@ -1967,7 +1944,6 @@ sal_Bool SbJScriptModule::LoadData( SvStream& rStrm, sal_uInt16 nVer )
String aTmp;
rStrm.ReadByteString( aTmp, gsl_getSystemTextEncoding() );
aOUSource = aTmp;
- //rStrm >> aSource;
return sal_True;
}
@@ -1979,7 +1955,6 @@ sal_Bool SbJScriptModule::StoreData( SvStream& rStrm ) const
// Write the source string
String aTmp = aOUSource;
rStrm.WriteByteString( aTmp, gsl_getSystemTextEncoding() );
- //rStrm << aSource;
return sal_True;
}
@@ -1996,7 +1971,7 @@ SbMethod::SbMethod( const String& r, SbxDataType t, SbModule* p )
nLine2 = 0;
refStatics = new SbxArray;
mCaller = 0;
- // From: 1996-07.02: HACK due to 'Referenz could not be saved'
+ // HACK due to 'Referenz could not be saved'
SetFlag( SBX_NO_MODIFY );
}
@@ -2043,10 +2018,9 @@ sal_Bool SbMethod::LoadData( SvStream& rStrm, sal_uInt16 nVer )
sal_Int16 n;
rStrm >> n;
sal_Int16 nTempStart = (sal_Int16)nStart;
- // nDebugFlags = n; // From 1996-01-16: no longer take over
if( nVer == 2 )
rStrm >> nLine1 >> nLine2 >> nTempStart >> bInvalid;
- // From: 1996-07-02: HACK ue to 'Referenz could not be saved'
+ // HACK ue to 'Referenz could not be saved'
SetFlag( SBX_NO_MODIFY );
nStart = nTempStart;
return sal_True;
@@ -2077,7 +2051,7 @@ SbxInfo* SbMethod::GetInfo()
}
// Interface to execute a method of the applications
-// #34191# With special RefCounting, damit so that the Basic was not fired of by CloseDocument()
+// With special RefCounting, so that the Basic was not fired of by CloseDocument()
// The return value will be delivered as string.
ErrCode SbMethod::Call( SbxValue* pRet, SbxVariable* pCaller )
{
@@ -2160,7 +2134,6 @@ void SbMethod::Broadcast( sal_uIntPtr nHintId )
}
}
-/////////////////////////////////////////////////////////////////////////
// Implementation of SbJScriptMethod (method class as a wrapper for JavaScript-functions)
@@ -2173,7 +2146,6 @@ SbJScriptMethod::~SbJScriptMethod()
{}
-/////////////////////////////////////////////////////////////////////////
SbObjModule::SbObjModule( const String& rName, const com::sun::star::script::ModuleInfo& mInfo, bool bIsVbaCompatible )
: SbModule( rName, bIsVbaCompatible )
{
@@ -2217,7 +2189,6 @@ SbObjModule::GetObject()
SbxVariable*
SbObjModule::Find( const XubString& rName, SbxClassType t )
{
- //OSL_TRACE("SbObjectModule find for %s", rtl::OUStringToOString( rName, RTL_TEXTENCODING_UTF8 ).getStr() );
SbxVariable* pVar = NULL;
if ( pDocObject)
pVar = pDocObject->Find( rName, t );
@@ -2718,7 +2689,6 @@ SbUserFormModule::Find( const XubString& rName, SbxClassType t )
InitObject();
return SbObjModule::Find( rName, t );
}
-/////////////////////////////////////////////////////////////////////////
SbProperty::SbProperty( const String& r, SbxDataType t, SbModule* p )
: SbxProperty( r, t ), pMod( p )
@@ -2729,7 +2699,6 @@ SbProperty::SbProperty( const String& r, SbxDataType t, SbModule* p )
SbProperty::~SbProperty()
{}
-/////////////////////////////////////////////////////////////////////////
SbProcedureProperty::~SbProcedureProperty()
{}
diff --git a/basic/source/comp/codegen.cxx b/basic/source/comp/codegen.cxx
index 0ca6667c88a1..249c37353c84 100755
--- a/basic/source/comp/codegen.cxx
+++ b/basic/source/comp/codegen.cxx
@@ -255,7 +255,6 @@ void SbiCodeGen::Save()
{
pMeth = rMod.GetMethod( aProcName, pProc->GetType() );
- // #110004
if( !pProc->IsPublic() )
pMeth->SetFlag( SBX_PRIVATE );
diff --git a/basic/source/comp/dim.cxx b/basic/source/comp/dim.cxx
index a24f4ea9e7e3..ed166530f319 100755
--- a/basic/source/comp/dim.cxx
+++ b/basic/source/comp/dim.cxx
@@ -293,7 +293,7 @@ void SbiParser::DefVar( SbiOpcode eOp, sal_Bool bStatic )
SbiSymDef* pDef;
SbiDimList* pDim;
- // From 1997-07-09, #40689, Statics -> Modul-Initialising, skip in Sub
+ // #40689, Statics -> Modul-Initialising, skip in Sub
sal_uInt32 nEndOfStaticLbl = 0;
if( !bVBASupportOn && bStatic )
{
@@ -309,7 +309,7 @@ void SbiParser::DefVar( SbiOpcode eOp, sal_Bool bStatic )
if( bSwitchPool )
pPool = &aGlobals;
SbiSymDef* pOld = pPool->Find( pDef->GetName() );
- // From 1996-03-31, #25651#, search also in the Runtime-Library
+ // search also in the Runtime-Library
sal_Bool bRtlSym = sal_False;
if( !pOld )
{
@@ -362,7 +362,7 @@ void SbiParser::DefVar( SbiOpcode eOp, sal_Bool bStatic )
case SbGLOBAL: eOp2 = bPersistantGlobal ? _GLOBAL_P : _GLOBAL;
goto global;
case SbPUBLIC: eOp2 = bPersistantGlobal ? _PUBLIC_P : _PUBLIC;
- // From 1997-07-09, #40689, no own Opcode anymore
+ // #40689, no own Opcode anymore
if( bVBASupportOn && bStatic )
{
eOp2 = _STATIC;
@@ -450,7 +450,7 @@ void SbiParser::DefVar( SbiOpcode eOp, sal_Bool bStatic )
}
SbiExpression aVar( this, *pDef );
if( !TestToken( EQ ) )
- goto MyBreak; // From 1996-06-24 (see below)
+ goto MyBreak; // (see below)
SbiConstExpression aExpr( this );
if( !bDefined && aExpr.IsValid() )
{
@@ -501,9 +501,8 @@ void SbiParser::DefVar( SbiOpcode eOp, sal_Bool bStatic )
}
}
if( !TestComma() )
- goto MyBreak; // From 1996-06-24 (see below)
+ goto MyBreak;
- // #27963# From 1996-06-24
// Implementation of bSwitchPool (see above): pPool must not be set to &aGlobals
// at the VarDecl-Call.
// Apart from that the behavior should be absolutely identical,
@@ -516,7 +515,7 @@ void SbiParser::DefVar( SbiOpcode eOp, sal_Bool bStatic )
break;
}
- // From 1997-07-09, #40689, finalize the jump over statics declarations
+ // #40689, finalize the jump over statics declarations
if( !bVBASupportOn && bStatic )
{
// maintain the global chain
@@ -527,7 +526,6 @@ void SbiParser::DefVar( SbiOpcode eOp, sal_Bool bStatic )
aGen.BackChain( nEndOfStaticLbl );
}
- //pPool = pOldPool;
}
// Here were Arrays redimensioned.
@@ -936,9 +934,6 @@ SbiProcDef* SbiParser::ProcDecl( sal_Bool bDecl )
TypeDecl( *pDef );
if( eType != SbxVARIANT && pDef->GetType() != eType )
Error( SbERR_BAD_DECLARATION, aName );
-// if( pDef->GetType() == SbxOBJECT )
-// pDef->SetType( SbxVARIANT ),
-// Error( SbERR_SYNTAX );
if( pDef->GetType() == SbxVARIANT && !( bFunc || bProp ) )
pDef->SetType( SbxEMPTY );
return pDef;
diff --git a/basic/source/comp/exprgen.cxx b/basic/source/comp/exprgen.cxx
index 1dcd5fc73e59..214653f501d7 100755
--- a/basic/source/comp/exprgen.cxx
+++ b/basic/source/comp/exprgen.cxx
@@ -109,7 +109,7 @@ void SbiExprNode::Gen( RecursiveMode eRecMode )
eOp = aVar.pDef->IsGlobal() ? _FIND_G : _FIND;
}
}
- // From 1995-12-17, special treatment for WITH
+ // special treatment for WITH
else if( (pWithParent_ = GetWithParent()) != NULL )
{
eOp = _ELEM; // .-Term in in WITH
@@ -207,9 +207,9 @@ void SbiExprList::Gen()
if( pFirst )
{
pParser->aGen.Gen( _ARGC );
- // From 1996-01-10: Type adjustment at DECLARE
- sal_uInt16 nCount = 1 /*, nParAnz = 0*/;
-// SbiSymPool* pPool = NULL;
+ // Type adjustment at DECLARE
+ sal_uInt16 nCount = 1;
+
for( SbiExpression* pExpr = pFirst; pExpr; pExpr = pExpr->pNext,nCount++ )
{
pExpr->Gen();
@@ -254,7 +254,7 @@ void SbiExprList::Gen()
void SbiExpression::Gen( RecursiveMode eRecMode )
{
- // From 1995-12-17, special treatment for WITH
+ // special treatment for WITH
// If pExpr == .-term in With, approximately Gen for Basis-Object
pExpr->Gen( eRecMode );
if( bByVal )
diff --git a/basic/source/comp/exprnode.cxx b/basic/source/comp/exprnode.cxx
index f454071c0377..5c7bb0b51a88 100755
--- a/basic/source/comp/exprnode.cxx
+++ b/basic/source/comp/exprnode.cxx
@@ -35,7 +35,6 @@
#include "sbcomp.hxx"
#include "expr.hxx"
-//////////////////////////////////////////////////////////////////////////
SbiExprNode::SbiExprNode( void )
{
diff --git a/basic/source/comp/exprtree.cxx b/basic/source/comp/exprtree.cxx
index cef0542c43bc..8efd468ca05c 100755
--- a/basic/source/comp/exprtree.cxx
+++ b/basic/source/comp/exprtree.cxx
@@ -407,13 +407,7 @@ SbiExprNode* SbiExpression::ObjTerm( SbiSymDef& rObj )
bError = sal_True;
}
}
- /* #118410 Allow type for Class methods and RTL object, e.g. RTL.Chr$(97)
- else
- {
- if( pParser->GetType() != SbxVARIANT )
- pParser->Error( SbERR_SYNTAX ), bError = sal_True;
- }
- */
+
if( bError )
return NULL;
@@ -473,7 +467,6 @@ SbiExprNode* SbiExpression::ObjTerm( SbiSymDef& rObj )
// Falls wir etwas mit Punkt einscannen, muss der
// Typ SbxOBJECT sein
- // AB, 3.1.96
// Es kann sein, dass pDef ein Objekt beschreibt, das bisher
// nur als SbxVARIANT erkannt wurde, dann Typ von pDef aendern
if( pDef->GetType() == SbxVARIANT )
@@ -918,7 +911,6 @@ SbiConstExpression::SbiConstExpression( SbiParser* p ) : SbiExpression( p )
// Ist es eine sal_Bool-Konstante?
sal_Bool bBoolVal = sal_False;
if( pVarDef->GetName().EqualsIgnoreCaseAscii( "true" ) )
- //if( pVarDef->GetName().ICompare( "true" ) == COMPARE_EQUAL )
{
bIsBool = sal_True;
bBoolVal = sal_True;
@@ -1074,8 +1066,6 @@ SbiParameters::SbiParameters( SbiParser* p, sal_Bool bStandaloneExpression, sal_
if( eTok == COMMA )
{
pExpr = new SbiExpression( pParser, 0, SbxEMPTY );
- //if( bConst )
- // pParser->Error( SbERR_SYNTAX ), bError = sal_True;
}
// Benannte Argumente: entweder .name= oder name:=
else
@@ -1122,8 +1112,6 @@ SbiParameters::SbiParameters( SbiParser* p, sal_Bool bStandaloneExpression, sal_
if( bByVal && pExpr->IsLvalue() )
pExpr->SetByVal();
- //pExpr = bConst ? new SbiConstExpression( pParser )
- // : new SbiExpression( pParser );
if( !bAssumeArrayMode )
{
if( pParser->Peek() == ASSIGN )
@@ -1134,8 +1122,6 @@ SbiParameters::SbiParameters( SbiParser* p, sal_Bool bStandaloneExpression, sal_
delete pExpr;
pParser->Next();
pExpr = new SbiExpression( pParser );
- //if( bConst )
- // pParser->Error( SbERR_SYNTAX ), bError = sal_True;
}
pExpr->GetName() = aName;
}
diff --git a/basic/source/comp/io.cxx b/basic/source/comp/io.cxx
index 5c4abc680826..bc458e54305f 100755
--- a/basic/source/comp/io.cxx
+++ b/basic/source/comp/io.cxx
@@ -145,27 +145,7 @@ void SbiParser::Line()
void SbiParser::LineInput()
{
Channel( sal_True );
- // sal_Bool bChan = Channel( sal_True );
SbiExpression* pExpr = new SbiExpression( this, SbOPERAND );
- /* AB 15.1.96: Keinen allgemeinen Ausdruck mehr zulassen
- SbiExpression* pExpr = new SbiExpression( this );
- if( !pExpr->IsVariable() )
- {
- SbiToken eTok = Peek();
- if( eTok == COMMA || eTok == SEMICOLON ) Next();
- else Error( SbERR_EXPECTED, COMMA );
- // mit Prompt
- if( !bChan )
- {
- pExpr->Gen();
- aGen.Gen( _PROMPT );
- }
- else
- Error( SbERR_VAR_EXPECTED );
- delete pExpr;
- pExpr = new SbiExpression( this, SbOPERAND );
- }
- */
if( !pExpr->IsVariable() )
Error( SbERR_VAR_EXPECTED );
if( pExpr->GetType() != SbxVARIANT && pExpr->GetType() != SbxSTRING )
@@ -182,13 +162,7 @@ void SbiParser::Input()
{
aGen.Gen( _RESTART );
Channel( sal_True );
- // sal_Bool bChan = Channel( sal_True );
SbiExpression* pExpr = new SbiExpression( this, SbOPERAND );
- /* ALT: Jetzt keinen allgemeinen Ausdruck mehr zulassen
- SbiExpression* pExpr = new SbiExpression( this );
- ...
- siehe LineInput
- */
while( !bAbort )
{
if( !pExpr->IsVariable() )
@@ -235,7 +209,7 @@ void SbiParser::Open()
{
Next();
eTok = Next();
- // #27964# Nur STREAM_READ,STREAM_WRITE-Flags in nMode beeinflussen
+ // Nur STREAM_READ,STREAM_WRITE-Flags in nMode beeinflussen
nMode &= ~(STREAM_READ | STREAM_WRITE); // loeschen
if( eTok == READ )
{
diff --git a/basic/source/comp/loops.cxx b/basic/source/comp/loops.cxx
index f904c9ee51f3..c3e9159dac3b 100755
--- a/basic/source/comp/loops.cxx
+++ b/basic/source/comp/loops.cxx
@@ -43,7 +43,7 @@ void SbiParser::If()
TestToken( THEN );
if( IsEoln( Next() ) )
{
- // AB 13.5.1996: #27720# Am Ende jeden Blocks muss ein Jump zu ENDIF
+ // Am Ende jeden Blocks muss ein Jump zu ENDIF
// eingefuegt werden, damit bei ELSEIF nicht erneut die Bedingung
// ausgewertet wird. Die Tabelle nimmt alle Absprungstellen auf.
#define JMP_TABLE_SIZE 100
@@ -62,10 +62,9 @@ void SbiParser::If()
Error( SbERR_BAD_BLOCK, IF ); bAbort = sal_True; return;
}
}
- // ELSEIF?
while( eTok == ELSEIF )
{
- // #27720# Bei erfolgreichem IF/ELSEIF auf ENDIF springen
+ // Bei erfolgreichem IF/ELSEIF auf ENDIF springen
if( iJmp >= JMP_TABLE_SIZE )
{
Error( SbERR_PROG_TOO_LARGE ); bAbort = sal_True; return;
@@ -105,7 +104,7 @@ void SbiParser::If()
else if( eTok == ENDIF )
Next();
- // #27720# Jmp-Tabelle abarbeiten
+ // Jmp-Tabelle abarbeiten
while( iJmp > 0 )
{
iJmp--;
@@ -473,7 +472,6 @@ void SbiParser::On()
SbiToken eTok = Peek();
String aString = SbiTokenizer::Symbol(eTok);
if (aString.EqualsIgnoreCaseAscii("ERROR"))
- //if (!aString.ICompare("ERROR"))
eTok = _ERROR_; // Error kommt als SYMBOL
if( eTok != _ERROR_ && eTok != LOCAL ) OnGoto();
else
diff --git a/basic/source/comp/parser.cxx b/basic/source/comp/parser.cxx
index 38189bc2025c..2ea78357882f 100755
--- a/basic/source/comp/parser.cxx
+++ b/basic/source/comp/parser.cxx
@@ -195,7 +195,6 @@ sal_Bool SbiParser::HasGlobalCode()
{
aGen.BackChain( nGblChain );
aGen.Gen( _LEAVE );
- // aGen.Gen( _STOP );
nGblChain = 0;
}
return bGblDefs;
@@ -515,7 +514,6 @@ void SbiParser::Symbol( const KeywordSymbolInfo* pKeywordSymbolInfo )
if( aRtlName.EqualsIgnoreCaseAscii("Mid") )
{
SbiExprNode* pExprNode = aVar.GetExprNode();
- // SbiNodeType eNodeType;
if( pExprNode && pExprNode->GetNodeType() == SbxVARVAL )
{
SbiExprList* pPar = pExprNode->GetParameters();
@@ -549,7 +547,6 @@ void SbiParser::Symbol( const KeywordSymbolInfo* pKeywordSymbolInfo )
SbiExpression aExpr( this );
aExpr.Gen();
SbiOpcode eOp = _PUT;
- // SbiSymDef* pDef = aVar.GetRealVar();
if( pDef )
{
if( pDef->GetConstDef() )
@@ -612,7 +609,6 @@ void SbiParser::Set()
TypeDecl( *pTypeDef, sal_True );
aLvalue.Gen();
- // aGen.Gen( _CLASS, pDef->GetTypeId() | 0x8000 );
aGen.Gen( _CREATE, pDef->GetId(), pTypeDef->GetTypeId() );
aGen.Gen( _SETCLASS, pDef->GetTypeId() );
}
@@ -641,7 +637,6 @@ void SbiParser::Set()
aGen.Gen( _SET );
}
}
- // aGen.Gen( _SET );
}
// JSM 07.10.95
@@ -695,7 +690,6 @@ void SbiParser::DefXXX()
else
{
ch2 = aSym.ToUpperAscii().GetBuffer()[0];
- //ch2 = aSym.Upper();
if( ch2 < ch1 ) Error( SbERR_SYNTAX ), ch2 = 0;
}
}
diff --git a/basic/source/comp/scanner.cxx b/basic/source/comp/scanner.cxx
index 6e9b80dde9c0..11c081d1b4b2 100755
--- a/basic/source/comp/scanner.cxx
+++ b/basic/source/comp/scanner.cxx
@@ -319,8 +319,6 @@ sal_Bool SbiScanner::NextSym()
{
pLine++; nCol++; continue;
}
-// if( toupper( *pLine ) == 'D' )
-// eScanType = SbxDOUBLE;
*p++ = 'E'; pLine++; nCol++;
// Vorzeichen hinter Exponent?
if( *pLine == '+' )
@@ -345,7 +343,6 @@ sal_Bool SbiScanner::NextSym()
// #57844 Lokalisierte Funktion benutzen
nVal = rtl_math_uStringToDouble( buf, buf+(p-buf), '.', ',', NULL, NULL );
- // ALT: nVal = atof( buf );
ndig = ndig - comma;
if( !comma && !exp )
@@ -358,12 +355,6 @@ sal_Bool SbiScanner::NextSym()
}
if( bBufOverflow )
GenError( SbERR_MATH_OVERFLOW );
- // zu viele Zahlen fuer SINGLE?
-// if (ndig > 15 || ncdig > 6)
-// eScanType = SbxDOUBLE;
-// else
-// if( nVal > SbxMAXSNG || nVal < SbxMINSNG )
-// eScanType = SbxDOUBLE;
// Typkennung?
SbxDataType t = GetSuffixType( *pLine );
@@ -382,7 +373,6 @@ sal_Bool SbiScanner::NextSym()
sal_Unicode cmp1[] = { '0','1','2','3','4','5','6','7','8','9','A','B','C','D','E','F', 0 };
sal_Unicode cmp2[] = { '0', '1', '2', '3', '4', '5', '6', '7', 0 };
sal_Unicode *cmp = cmp1;
- //char *cmp = "0123456789ABCDEF";
sal_Unicode base = 16;
sal_Unicode ndig = 8;
sal_Unicode xch = *pLine++ & 0xFF; nCol++;
@@ -390,7 +380,6 @@ sal_Bool SbiScanner::NextSym()
{
case 'O':
cmp = cmp2; base = 8; ndig = 11; break;
- //cmp = "01234567"; base = 8; ndig = 11; break;
case 'H':
break;
default :
diff --git a/basic/source/comp/symtbl.cxx b/basic/source/comp/symtbl.cxx
index 8e5badb5330d..00c4b4cd6d87 100755
--- a/basic/source/comp/symtbl.cxx
+++ b/basic/source/comp/symtbl.cxx
@@ -400,7 +400,6 @@ SbiSymScope SbiSymDef::GetScope() const
return pIn ? pIn->GetScope() : SbLOCAL;
}
-////////////////////////////////////////////////////////////////////////////
// Die Prozedur-Definition hat drei Pools:
// 1) aParams: wird durch die Definition gefuellt. Enthaelt die Namen
@@ -510,7 +509,6 @@ void SbiProcDef::setPropertyMode( PropertyMode ePropMode )
}
-//////////////////////////////////////////////////////////////////////////
SbiConstDef::SbiConstDef( const String& rName )
: SbiSymDef( rName )
diff --git a/basic/source/comp/token.cxx b/basic/source/comp/token.cxx
index c3a953118878..7452c775b916 100755
--- a/basic/source/comp/token.cxx
+++ b/basic/source/comp/token.cxx
@@ -193,168 +193,6 @@ static TokenTable aTokTable_Basic [] = { // Token-Tabelle:
{ NIL, "" }
};
-/*
-TokenTable aTokTable_Java [] = { // Token-Tabelle:
-
- { JS_LOG_NOT, "!" },
- { JS_NE, "!=" },
- { JS_MOD, "%" },
- { JS_ASS_MOD, "%=" },
- { JS_BIT_AND, "&" },
- { JS_LOG_AND, "&&" },
- { JS_ASS_AND, "&=" },
- { JS_LPAREN, "(" },
- { JS_RPAREN, ")" },
- { JS_MUL, "*" },
- { JS_ASS_MUL, "*=" },
- { JS_PLUS, "+" },
- { JS_INC, "++" },
- { JS_ASS_PLUS, "+=" },
- { JS_COMMA, "," },
- { JS_MINUS, "-" },
- { JS_DEC, "--" },
- { JS_ASS_MINUS, "-=" },
- { JS_DIV, "/" },
- { JS_ASS_DIV, "/=" },
- { JS_COND_SEL, ":" },
- { JS_LT, "<" },
- { JS_LSHIFT, "<<" },
- { JS_ASS_LSHIFT,"<<=" },
- { JS_LE, "<=" },
- { JS_NE, "<>" },
- { JS_ASSIGNMENT,"=" },
- { JS_EQ, "==" },
- { JS_GT, ">" },
- { JS_RSHIFT, ">>" },
- { JS_ASS_RSHIFT,">>=" },
- { JS_RSHIFT_Z, ">>>" },
- { JS_ASS_RSHIFT_Z,">>>=" },
- { JS_GE, ">=" },
- { JS_COND_QUEST,"?" },
- { ACCESS, "Access" },
- { ALIAS, "Alias" },
- { AND, "And" },
- { ANY, "Any" },
- { APPEND, "Append" },
- { AS, "As" },
- { BASE, "Base" },
- { BINARY, "Binary" },
- { TBOOLEAN, "Boolean" },
- { BYVAL, "ByVal", },
- { CALL, "Call" },
- { CASE, "Case" },
- { _CDECL_, "Cdecl" },
- { CLOSE, "Close" },
- { COMPARE, "Compare" },
- { _CONST_, "Const" },
- { TCURRENCY,"Currency" },
- { TDATE, "Date" },
- { DECLARE, "Declare" },
- { DEFBOOL, "DefBool" },
- { DEFCUR, "DefCur" },
- { DEFDATE, "DefDate" },
- { DEFDBL, "DefDbl" },
- { DEFERR, "DefErr" },
- { DEFINT, "DefInt" },
- { DEFLNG, "DefLng" },
- { DEFOBJ, "DefObj" },
- { DEFSNG, "DefSng" },
- { DEFSTR, "DefStr" },
- { DEFVAR, "DefVar" },
- { DIM, "Dim" },
- { DO, "Do" },
- { TDOUBLE, "Double" },
- { EACH, "Each" },
- { ELSE, "Else" },
- { ELSEIF, "ElseIf" },
- { END, "End" },
- { ENDFUNC, "End Function" },
- { ENDIF, "End If" },
- { ENDSELECT,"End Select" },
- { ENDSUB, "End Sub" },
- { ENDTYPE, "End Type" },
- { ENDIF, "EndIf" },
- { EQV, "Eqv" },
- { ERASE, "Erase" },
- { _ERROR_, "Error" },
- { EXIT, "Exit" },
- { EXPLICIT, "Explicit" },
- { FOR, "For" },
- { FUNCTION, "Function" },
- { GLOBAL, "Global" },
- { GOSUB, "GoSub" },
- { GOTO, "GoTo" },
- { IF, "If" },
- { IMP, "Imp" },
- { _IN_, "In" },
- { INPUT, "Input" }, // auch INPUT #
- { TINTEGER, "Integer" },
- { IS, "Is" },
- { LET, "Let" },
- { LIB, "Lib" },
- { LINE, "Line" },
- { LINEINPUT,"Line Input" },
- { LOCAL, "Local" },
- { LOCK, "Lock" },
- { TLONG, "Long" },
- { LOOP, "Loop" },
- { LPRINT, "LPrint" },
- { LSET, "LSet" }, // JSM
- { MOD, "Mod" },
- { NAME, "Name" },
- { NEW, "New" },
- { NEXT, "Next" },
- { NOT, "Not" },
- { TOBJECT, "Object" },
- { ON, "On" },
- { OPEN, "Open" },
- { OPTION, "Option" },
- { _OPTIONAL_, "Optional" },
- { OR, "Or" },
- { OUTPUT, "Output" },
- { PRESERVE, "Preserve" },
- { PRINT, "Print" },
- { PRIVATE, "Private" },
- { PUBLIC, "Public" },
- { RANDOM, "Random" },
- { READ, "Read" },
- { REDIM, "ReDim" },
- { REM, "Rem" },
- { RESUME, "Resume" },
- { RETURN, "Return" },
- { RSET, "RSet" }, // JSM
- { SELECT, "Select" },
- { SET, "Set" },
- { SHARED, "Shared" },
- { TSINGLE, "Single" },
- { STATIC, "Static" },
- { STEP, "Step" },
- { STOP, "Stop" },
- { TSTRING, "String" },
- { SUB, "Sub" },
- { STOP, "System" },
- { TEXT, "Text" },
- { THEN, "Then" },
- { TO, "To", },
- { TYPE, "Type" },
- { UNTIL, "Until" },
- { TVARIANT, "Variant" },
- { WEND, "Wend" },
- { WHILE, "While" },
- { WITH, "With" },
- { WRITE, "Write" }, // auch WRITE #
- { XOR, "Xor" },
- { JS_LINDEX, "[" },
- { JS_RINDEX, "]" },
- { JS_BIT_XOR, "^" },
- { JS_ASS_XOR, "^=" },
- { JS_BIT_OR, "|" },
- { JS_ASS_OR, "|=" },
- { JS_LOG_OR, "||" },
- { JS_BIT_NOT, "~" },
- { NIL }
-};
-*/
// #i109076
TokenLabelInfo::TokenLabelInfo( void )
@@ -385,8 +223,6 @@ SbiTokenizer::SbiTokenizer( const ::rtl::OUString& rSrc, StarBASIC* pb )
: SbiScanner( rSrc, pb )
{
pTokTable = aTokTable_Basic;
- //if( StarBASIC::GetGlobalLanguageMode() == SB_LANG_JAVASCRIPT )
- // pTokTable = aTokTable_Java;
TokenTable *tp;
bEof = bAs = sal_False;
eCurTok = NIL;
diff --git a/basic/source/inc/filefmt.hxx b/basic/source/inc/filefmt.hxx
index 087581617297..caf6131aa9dd 100755
--- a/basic/source/inc/filefmt.hxx
+++ b/basic/source/inc/filefmt.hxx
@@ -168,7 +168,6 @@ class SvStream;
// sal_uInt16 Anzahl Objekte
// .... Objektdaten
-////////////////////////////////////////////////////////////////////////////
// Service-Routinen (in IMAGE.CXX)
diff --git a/basic/source/inc/image.hxx b/basic/source/inc/image.hxx
index b852ba1e427f..0f0ffdf7df9a 100755
--- a/basic/source/inc/image.hxx
+++ b/basic/source/inc/image.hxx
@@ -87,7 +87,6 @@ public:
::rtl::OUString& GetSource32() { return aOUSource; }
sal_uInt16 GetBase() const { return nDimBase; }
String GetString( short nId ) const;
- //const char* GetString( short nId ) const;
const SbxObject* FindType (String aTypeName) const;
SbxArrayRef GetEnums() { return rEnums; }
diff --git a/basic/source/inc/runtime.hxx b/basic/source/inc/runtime.hxx
index df694e548844..afac6fec2807 100755
--- a/basic/source/inc/runtime.hxx
+++ b/basic/source/inc/runtime.hxx
@@ -66,10 +66,6 @@ class AsciiEncoder
{
public:
static ::rtl::OUString decodeUnoUrlParamValue(const rtl::OUString & rSource);
- //static ::rtl::OUString encodeUnoUrlParamValue(const rtl::OUString & rSource);
- //static ::rtl::ByteSequence decode(const ::rtl::OUString & string);
- //static ::rtl::OUString encode(const ::rtl::ByteSequence & bytes);
- //static void test();
};
}
@@ -244,7 +240,7 @@ public:
sal_uInt32 GetStdTimeIdx() const { return nStdTimeIdx; }
sal_uInt32 GetStdDateTimeIdx() const { return nStdDateTimeIdx; }
- // #39629# NumberFormatter auch statisch anbieten
+ // NumberFormatter auch statisch anbieten
static void PrepareNumberFormatter( SvNumberFormatter*& rpNumberFormatter,
sal_uInt32 &rnStdDateIdx, sal_uInt32 &rnStdTimeIdx, sal_uInt32 &rnStdDateTimeIdx,
LanguageType* peFormatterLangType=NULL, DateFormat* peFormatterDateFormat=NULL );
@@ -380,7 +376,6 @@ class SbiRuntime
// #56204 DIM-Funktionalitaet in Hilfsmethode auslagern (step0.cxx)
void DimImpl( SbxVariableRef refVar );
- // #115829
bool implIsClass( SbxObject* pObj, const String& aClass );
void StepSETCLASS_impl( sal_uInt32 nOp1, bool bHandleDflt = false );
diff --git a/basic/source/inc/sbunoobj.hxx b/basic/source/inc/sbunoobj.hxx
index 5905f7f4640f..ea3d62c80e7f 100755
--- a/basic/source/inc/sbunoobj.hxx
+++ b/basic/source/inc/sbunoobj.hxx
@@ -172,7 +172,6 @@ public:
: SbxObject( aName_ )
, m_xClass( xClass_ )
{}
- //~SbUnoClass();
// Find ueberladen, um Elemente on Demand anzulegen
virtual SbxVariable* Find( const String&, SbxClassType );
@@ -180,7 +179,6 @@ public:
// Wert rausgeben
const ::com::sun::star::uno::Reference< ::com::sun::star::reflection::XIdlClass >& getUnoClass( void ) { return m_xClass; }
- //void SFX_NOTIFY( SfxBroadcaster&, const TypeId&, const SfxHint& rHint, const TypeId& );
};
SV_DECL_IMPL_REF(SbUnoClass);
diff --git a/basic/source/inc/symtbl.hxx b/basic/source/inc/symtbl.hxx
index adfee46b4aed..1d70b0e49e40 100755
--- a/basic/source/inc/symtbl.hxx
+++ b/basic/source/inc/symtbl.hxx
@@ -45,7 +45,6 @@ class SbiParser;
enum SbiSymScope { SbLOCAL, SbPARAM, SbPUBLIC, SbGLOBAL, SbRTL };
-///////////////////////////////////////////////////////////////////////////
// Der String-Pool nimmt String-Eintraege auf und sorgt dafuer,
// dass sie nicht doppelt vorkommen.
@@ -68,7 +67,6 @@ public:
SbiParser* GetParser() { return pParser; }
};
-///////////////////////////////////////////////////////////////////////////
SV_DECL_PTRARR_DEL(SbiSymbols,SbiSymDef*,5,5)
@@ -109,7 +107,6 @@ public:
void CheckRefs(); // offene Referenzen suchen
};
-///////////////////////////////////////////////////////////////////////////
class SbiSymDef { // Allgemeiner Symboleintrag
friend class SbiSymPool;
diff --git a/basic/source/runtime/inputbox.cxx b/basic/source/runtime/inputbox.cxx
index a21d3e794eee..c14afa075155 100755
--- a/basic/source/runtime/inputbox.cxx
+++ b/basic/source/runtime/inputbox.cxx
@@ -152,7 +152,6 @@ IMPL_LINK_INLINE_END( SvRTLInputBox, CancelHdl, Button *, pButton )
// *********************************************************************
// *********************************************************************
-// *********************************************************************
// Syntax: String InputBox( Prompt, [Title], [Default] [, nXpos, nYpos ] )
diff --git a/basic/source/runtime/iosys.cxx b/basic/source/runtime/iosys.cxx
index cea9f7a01d3e..af0f5609be2c 100755
--- a/basic/source/runtime/iosys.cxx
+++ b/basic/source/runtime/iosys.cxx
@@ -139,7 +139,6 @@ IMPL_LINK_INLINE_START( SbiInputDialog, Cancel, Window *, pWindow )
}
IMPL_LINK_INLINE_END( SbiInputDialog, Cancel, Window *, pWindow )
-//////////////////////////////////////////////////////////////////////////
SbiStream::SbiStream()
: pStrm( 0 )
@@ -451,40 +450,6 @@ public:
virtual void SetSize( sal_uIntPtr nSize );
};
-/*
-sal_uIntPtr UCBErrorToSvStramError( ucb::IOErrorCode nError )
-{
- sal_uIntPtr eReturn = ERRCODE_IO_GENERAL;
- switch( nError )
- {
- case ucb::IOErrorCode_ABORT: eReturn = SVSTREAM_GENERALERROR; break;
- case ucb::IOErrorCode_NOT_EXISTING: eReturn = SVSTREAM_FILE_NOT_FOUND; break;
- case ucb::IOErrorCode_NOT_EXISTING_PATH: eReturn = SVSTREAM_PATH_NOT_FOUND; break;
- case ucb::IOErrorCode_OUT_OF_FILE_HANDLES: eReturn = SVSTREAM_TOO_MANY_OPEN_FILES; break;
- case ucb::IOErrorCode_ACCESS_DENIED: eReturn = SVSTREAM_ACCESS_DENIED; break;
- case ucb::IOErrorCode_LOCKING_VIOLATION: eReturn = SVSTREAM_SHARING_VIOLATION; break;
-
- case ucb::IOErrorCode_INVALID_ACCESS: eReturn = SVSTREAM_INVALID_ACCESS; break;
- case ucb::IOErrorCode_CANT_CREATE: eReturn = SVSTREAM_CANNOT_MAKE; break;
- case ucb::IOErrorCode_INVALID_PARAMETER: eReturn = SVSTREAM_INVALID_PARAMETER; break;
-
- case ucb::IOErrorCode_CANT_READ: eReturn = SVSTREAM_READ_ERROR; break;
- case ucb::IOErrorCode_CANT_WRITE: eReturn = SVSTREAM_WRITE_ERROR; break;
- case ucb::IOErrorCode_CANT_SEEK: eReturn = SVSTREAM_SEEK_ERROR; break;
- case ucb::IOErrorCode_CANT_TELL: eReturn = SVSTREAM_TELL_ERROR; break;
-
- case ucb::IOErrorCode_OUT_OF_MEMORY: eReturn = SVSTREAM_OUTOFMEMORY; break;
-
- case SVSTREAM_FILEFORMAT_ERROR: eReturn = SVSTREAM_FILEFORMAT_ERROR; break;
- case ucb::IOErrorCode_WRONG_VERSION: eReturn = SVSTREAM_WRONGVERSION;
- case ucb::IOErrorCode_OUT_OF_DISK_SPACE: eReturn = SVSTREAM_DISK_FULL; break;
-
- case ucb::IOErrorCode_BAD_CRC: eReturn = ERRCODE_IO_BADCRC; break;
- }
- return eReturn;
-}
-*/
-
UCBStream::UCBStream( Reference< XInputStream > & rStm )
: xIS( rStm )
, xSeek( rStm, UNO_QUERY )
@@ -674,9 +639,6 @@ SbError SbiStream::Open
{
Reference< XStream > xIS = xSFI->openFileReadWrite( aNameStr );
pStrm = new UCBStream( xIS );
- // Open for writing is not implemented in ucb yet!!!
- //Reference< XOutputStream > xIS = xSFI->openFileWrite( aNameStr );
- //pStrm = new UCBStream( xIS );
}
else //if( nStrmMode & STREAM_READ )
{
@@ -815,7 +777,6 @@ SbError SbiStream::Write( const ByteString& rBuf, sal_uInt16 n )
return nError;
}
-//////////////////////////////////////////////////////////////////////////
// Zugriff auf das aktuelle I/O-System:
@@ -825,7 +786,6 @@ SbiIoSystem* SbGetIoSystem()
return pInst ? pInst->GetIoSystem() : NULL;
}
-//////////////////////////////////////////////////////////////////////////
SbiIoSystem::SbiIoSystem()
{
diff --git a/basic/source/runtime/methods.cxx b/basic/source/runtime/methods.cxx
index 8335d6f88d26..a8ea4438f652 100755
--- a/basic/source/runtime/methods.cxx
+++ b/basic/source/runtime/methods.cxx
@@ -419,7 +419,6 @@ RTLFUNC(CurDir)
// DirEntry-Funktionalitaet keine Moeglichkeit besteht, das aktuelle so
// zu ermitteln, dass eine virtuelle URL geliefert werden koennte.
-// rPar.Get(0)->PutEmpty();
#if defined (WNT) || defined (OS2)
int nCurDir = 0; // Current dir // JSM
if ( rPar.Count() == 2 )
@@ -600,7 +599,6 @@ RTLFUNC(FileCopy) // JSM
{
String aSource = rPar.Get(1)->GetString();
String aDest = rPar.Get(2)->GetString();
- // <-- UCB
if( hasUno() )
{
com::sun::star::uno::Reference< XSimpleFileAccess3 > xSFI = getFileAccess();
@@ -617,7 +615,6 @@ RTLFUNC(FileCopy) // JSM
}
}
else
- // --> UCB
{
#ifdef _OLD_FILE_IMPL
DirEntry aSourceDirEntry(aSource);
@@ -651,7 +648,6 @@ RTLFUNC(Kill) // JSM
{
String aFileSpec = rPar.Get(1)->GetString();
- // <-- UCB
if( hasUno() )
{
com::sun::star::uno::Reference< XSimpleFileAccess3 > xSFI = getFileAccess();
@@ -674,7 +670,6 @@ RTLFUNC(Kill) // JSM
}
}
else
- // --> UCB
{
#ifdef _OLD_FILE_IMPL
if(DirEntry(aFileSpec).Kill() != FSYS_ERR_OK)
@@ -698,7 +693,6 @@ RTLFUNC(MkDir) // JSM
{
String aPath = rPar.Get(1)->GetString();
- // <-- UCB
if( hasUno() )
{
com::sun::star::uno::Reference< XSimpleFileAccess3 > xSFI = getFileAccess();
@@ -745,7 +739,6 @@ RTLFUNC(MkDir) // JSM
}
}
else
- // --> UCB
{
#ifdef _OLD_FILE_IMPL
if (!DirEntry(aPath).MakeDir())
@@ -829,7 +822,6 @@ RTLFUNC(RmDir) // JSM
if (rPar.Count() == 2)
{
String aPath = rPar.Get(1)->GetString();
- // <-- UCB
if( hasUno() )
{
com::sun::star::uno::Reference< XSimpleFileAccess3 > xSFI = getFileAccess();
@@ -864,7 +856,6 @@ RTLFUNC(RmDir) // JSM
}
}
else
- // --> UCB
{
#ifdef _OLD_FILE_IMPL
DirEntry aDirEntry(aPath);
@@ -916,7 +907,6 @@ RTLFUNC(FileLen)
SbxVariableRef pArg = rPar.Get( 1 );
String aStr( pArg->GetString() );
sal_Int32 nLen = 0;
- // <-- UCB
if( hasUno() )
{
com::sun::star::uno::Reference< XSimpleFileAccess3 > xSFI = getFileAccess();
@@ -933,7 +923,6 @@ RTLFUNC(FileLen)
}
}
else
- // --> UCB
{
#ifdef _OLD_FILE_IMPL
FileStat aStat = DirEntry( aStr );
@@ -1782,9 +1771,6 @@ RTLFUNC(Val)
char* pEndPtr;
String aStr( rPar.Get(1)->GetString() );
-// lt. Mikkysoft bei Kommas abbrechen!
-// for( sal_uInt16 n=0; n < aStr.Len(); n++ )
-// if( aStr[n] == ',' ) aStr[n] = '.';
FilterWhiteSpace( aStr );
if ( aStr.GetBuffer()[0] == '&' && aStr.Len() > 1 )
@@ -1807,7 +1793,6 @@ RTLFUNC(Val)
// #57844 Lokalisierte Funktion benutzen
nResult = ::rtl::math::stringToDouble( aStr, '.', ',', NULL, NULL );
checkArithmeticOverflow( nResult );
- // ATL: nResult = strtod( aStr.GetStr(), &pEndPtr );
}
rPar.Get(0)->PutDouble( nResult );
@@ -2705,7 +2690,6 @@ RTLFUNC(Dir)
if( !pRTLData )
return;
- // <-- UCB
if( hasUno() )
{
com::sun::star::uno::Reference< XSimpleFileAccess3 > xSFI = getFileAccess();
@@ -2776,7 +2760,6 @@ RTLFUNC(Dir)
}
catch( Exception & )
{
- //StarBASIC::Error( ERRCODE_IO_GENERAL );
}
}
@@ -2847,7 +2830,6 @@ RTLFUNC(Dir)
}
}
else
- // --> UCB
{
#ifdef _OLD_FILE_IMPL
if ( nParCount >= 2 )
@@ -3040,7 +3022,6 @@ RTLFUNC(GetAttr)
}
#endif
- // <-- UCB
if( hasUno() )
{
com::sun::star::uno::Reference< XSimpleFileAccess3 > xSFI = getFileAccess();
@@ -3075,7 +3056,6 @@ RTLFUNC(GetAttr)
}
}
else
- // --> UCB
{
DirectoryItem aItem;
DirectoryItem::get( getFullPathUNC( rPar.Get(1)->GetString() ), aItem );
@@ -3107,7 +3087,6 @@ RTLFUNC(FileDateTime)
StarBASIC::Error( SbERR_BAD_ARGUMENT );
else
{
- // <-- UCB
String aPath = rPar.Get(1)->GetString();
Time aTime;
Date aDate;
@@ -3129,7 +3108,6 @@ RTLFUNC(FileDateTime)
}
}
else
- // --> UCB
{
#ifdef _OLD_FILE_IMPL
DirEntry aEntry( aPath );
@@ -3225,8 +3203,7 @@ RTLFUNC(FileAttr)
(void)pBasic;
(void)bWrite;
- // AB 08/16/2000: No changes for UCB
-
+ // No changes for UCB
// #57064 Obwohl diese Funktion nicht mit DirEntry arbeitet, ist sie von
// der Anpassung an virtuelle URLs nich betroffen, da sie nur auf bereits
// geoeffneten Dateien arbeitet und der Name hier keine Rolle spielt.
@@ -3236,7 +3213,6 @@ RTLFUNC(FileAttr)
else
{
sal_Int16 nChannel = rPar.Get(1)->GetInteger();
-// nChannel--;
SbiIoSystem* pIO = pINST->GetIoSystem();
SbiStream* pSbStrm = pIO->GetStream( nChannel );
if ( !pSbStrm )
@@ -3258,7 +3234,7 @@ RTLFUNC(Loc)
(void)pBasic;
(void)bWrite;
- // AB 08/16/2000: No changes for UCB
+ // No changes for UCB
if ( rPar.Count() != 2 )
StarBASIC::Error( SbERR_BAD_ARGUMENT );
else
@@ -3323,7 +3299,7 @@ RTLFUNC(Seek)
(void)pBasic;
(void)bWrite;
- // AB 08/16/2000: No changes for UCB
+ // No changes for UCB
int nArgs = (int)rPar.Count();
if ( nArgs < 2 || nArgs > 3 )
{
@@ -3331,7 +3307,6 @@ RTLFUNC(Seek)
return;
}
sal_Int16 nChannel = rPar.Get(1)->GetInteger();
-// nChannel--;
SbiIoSystem* pIO = pINST->GetIoSystem();
SbiStream* pSbStrm = pIO->GetStream( nChannel );
if ( !pSbStrm )
@@ -3419,17 +3394,13 @@ RTLFUNC(Rnd)
}
-//
// Syntax: Shell("Path",[ Window-Style,[ "Params", [ bSync = sal_False ]]])
-//
// WindowStyles (VBA-kompatibel):
// 2 == Minimized
// 3 == Maximized
// 10 == Full-Screen (Textmodus-Anwendungen OS/2, WIN95, WNT)
-//
// !!!HACK der WindowStyle wird im Creator an Application::StartApp
// uebergeben. Format: "xxxx2"
-//
RTLFUNC(Shell)
@@ -4103,11 +4074,6 @@ RTLFUNC(StrConv)
sal_Int32 nConversion = rPar.Get(2)->GetLong();
sal_uInt16 nLanguage = LANGUAGE_SYSTEM;
- if( nArgCount == 3 )
- {
- // LCID not supported now
- //nLanguage = rPar.Get(3)->GetInteger();
- }
sal_uInt16 nOldLen = aOldStr.Len();
if( nOldLen == 0 )
@@ -4465,7 +4431,6 @@ RTLFUNC(SetAttr) // JSM
String aStr = rPar.Get(1)->GetString();
sal_Int16 nFlags = rPar.Get(2)->GetInteger();
- // <-- UCB
if( hasUno() )
{
com::sun::star::uno::Reference< XSimpleFileAccess3 > xSFI = getFileAccess();
@@ -4485,7 +4450,6 @@ RTLFUNC(SetAttr) // JSM
}
}
else
- // --> UCB
{
#ifdef _OLD_FILE_IMPL
// #57064 Bei virtuellen URLs den Real-Path extrahieren
@@ -4569,7 +4533,6 @@ RTLFUNC(FileExists)
String aStr = rPar.Get(1)->GetString();
sal_Bool bExists = sal_False;
- // <-- UCB
if( hasUno() )
{
com::sun::star::uno::Reference< XSimpleFileAccess3 > xSFI = getFileAccess();
@@ -4586,7 +4549,6 @@ RTLFUNC(FileExists)
}
}
else
- // --> UCB
{
#ifdef _OLD_FILE_IMPL
DirEntry aEntry( aStr );
diff --git a/basic/source/runtime/methods1.cxx b/basic/source/runtime/methods1.cxx
index 4d8b0380ff2f..c12924770fa1 100755
--- a/basic/source/runtime/methods1.cxx
+++ b/basic/source/runtime/methods1.cxx
@@ -895,13 +895,6 @@ RTLFUNC(FindObject)
SbxObject* pFindObj = NULL;
if( pFind )
pFindObj = PTR_CAST(SbxObject,pFind);
- /*
- if( !pFindObj )
- {
- StarBASIC::Error( SbERR_VAR_UNDEFINED );
- return;
- }
- */
// Objekt zurueckliefern
SbxVariableRef refVar = rPar.Get(0);
@@ -933,13 +926,6 @@ RTLFUNC(FindPropertyObject)
SbxBase* pObjVarObj = ((SbxVariable*)pObjVar)->GetObject();
pObj = PTR_CAST(SbxObject,pObjVarObj);
}
- /*
- if( !pObj )
- {
- StarBASIC::Error( SbERR_VAR_UNDEFINED );
- return;
- }
- */
// 2. Parameter ist der Name
String aNameStr = rPar.Get(2)->GetString();
@@ -1027,7 +1013,6 @@ sal_Bool lcl_WriteSbxVariable( const SbxVariable& rVar, SvStream* pStrm,
if( bIsVariant )
*pStrm << (sal_uInt16)SbxSTRING;
pStrm->WriteByteString( rStr, gsl_getSystemTextEncoding() );
- //*pStrm << rStr;
}
else
{
@@ -1035,7 +1020,6 @@ sal_Bool lcl_WriteSbxVariable( const SbxVariable& rVar, SvStream* pStrm,
// What does that mean for Unicode?! Choosing conversion to ByteString...
ByteString aByteStr( rStr, gsl_getSystemTextEncoding() );
*pStrm << (const char*)aByteStr.GetBuffer();
- //*pStrm << (const char*)rStr.GetStr();
}
}
break;
@@ -1398,8 +1382,6 @@ RTLFUNC(ResolvePath)
{
String aStr = rPar.Get(1)->GetString();
DirEntry aEntry( aStr );
- //if( aEntry.IsVirtual() )
- //aStr = aEntry.GetRealPathFromVirtualURL();
rPar.Get(0)->PutString( aStr );
}
else
@@ -2540,7 +2522,6 @@ RTLFUNC(FormatDateTime)
// ShortDate: Display a date using the short date format specified
// in your computer's regional settings.
- // 12/21/2004
// 21.12.2004
case 2:
pSbxVar->PutDate( floor(dDate) );
@@ -3241,7 +3222,6 @@ RTLFUNC(Input)
rPar.Get(0)->PutString( String( aByteBuffer, gsl_getSystemTextEncoding() ) );
}
-// #115824
RTLFUNC(Me)
{
(void)pBasic;
diff --git a/basic/source/runtime/runtime.cxx b/basic/source/runtime/runtime.cxx
index 685ede0848bc..40258844adac 100755
--- a/basic/source/runtime/runtime.cxx
+++ b/basic/source/runtime/runtime.cxx
@@ -223,9 +223,7 @@ SbiRuntime::pStep2 SbiRuntime::aStep2[] = {// Alle Opcodes mit zwei Operanden
};
-//////////////////////////////////////////////////////////////////////////
// SbiRTLData //
-//////////////////////////////////////////////////////////////////////////
SbiRTLData::SbiRTLData()
{
@@ -242,9 +240,7 @@ SbiRTLData::~SbiRTLData()
delete pWildCard;
}
-//////////////////////////////////////////////////////////////////////////
// SbiInstance //
-//////////////////////////////////////////////////////////////////////////
// 16.10.96: #31460 Neues Konzept fuer StepInto/Over/Out
// Die Entscheidung, ob StepPoint aufgerufen werden soll, wird anhand des
@@ -540,9 +536,7 @@ SbxArray* SbiInstance::GetLocals( SbMethod* pMeth )
return NULL;
}
-//////////////////////////////////////////////////////////////////////////
// SbiInstance //
-//////////////////////////////////////////////////////////////////////////
// Achtung: pMeth kann auch NULL sein (beim Aufruf des Init-Codes)
@@ -852,8 +846,6 @@ sal_Bool SbiRuntime::Step()
pInst->Abort();
}
- // ALT: Nur
- // pInst->Abort();
}
}
}
@@ -936,11 +928,7 @@ sal_Int32 SbiRuntime::translateErrorToVba( SbError nError, String& rMsg )
return nVBAErrorNumber;
}
-//////////////////////////////////////////////////////////////////////////
-//
// Parameter, Locals, Caller
-//
-//////////////////////////////////////////////////////////////////////////
SbMethod* SbiRuntime::GetCaller()
{
@@ -957,11 +945,7 @@ SbxArray* SbiRuntime::GetParams()
return refParams;
}
-//////////////////////////////////////////////////////////////////////////
-//
// Stacks
-//
-//////////////////////////////////////////////////////////////////////////
// Der Expression-Stack steht fuer die laufende Auswertung von Expressions
// zur Verfuegung.
@@ -1039,7 +1023,6 @@ void SbiRuntime::TOSMakeTemp()
p = new SbxVariable( *pDflt );
p->SetFlag( SBX_READWRITE );
refExprStk->Put( p, nExprLvl - 1 );
-// return;
}
else if( p->GetRefCount() != 1 )
@@ -1247,11 +1230,7 @@ void SbiRuntime::ClearForStack()
PopFor();
}
-//////////////////////////////////////////////////////////////////////////
-//
// DLL-Aufrufe
-//
-//////////////////////////////////////////////////////////////////////////
void SbiRuntime::DllCall
( const String& aFuncName, // Funktionsname
@@ -1268,15 +1247,6 @@ void SbiRuntime::DllCall
}
// MUSS NOCH IMPLEMENTIERT WERDEN
- /*
- String aMsg;
- aMsg = "FUNC=";
- aMsg += pFunc;
- aMsg += " DLL=";
- aMsg += pDLL;
- MessBox( NULL, WB_OK, String( "DLL-CALL" ), aMsg ).Execute();
- Error( SbERR_NOT_IMPLEMENTED );
- */
SbxVariable* pRes = new SbxVariable( eResType );
SbiDllMgr* pDllMgr = pInst->GetDllMgr();
diff --git a/basic/source/runtime/stdobj.cxx b/basic/source/runtime/stdobj.cxx
index 40a1fa911437..5576c1619f6a 100755
--- a/basic/source/runtime/stdobj.cxx
+++ b/basic/source/runtime/stdobj.cxx
@@ -895,8 +895,6 @@ SbxInfo* SbiStdObject::GetInfo( short nIdx )
if( !nIdx )
return NULL;
Methods* p = &aMethods[ --nIdx ];
- // Wenn mal eine Hilfedatei zur Verfuegung steht:
- // SbxInfo* pInfo_ = new SbxInfo( Hilfedateiname, p->nHelpId );
SbxInfo* pInfo_ = new SbxInfo;
short nPar = p->nArgs & _ARGSMASK;
for( short i = 0; i < nPar; i++ )
diff --git a/basic/source/runtime/stdobj1.cxx b/basic/source/runtime/stdobj1.cxx
index 10b4269227c9..b8759d7826ae 100755
--- a/basic/source/runtime/stdobj1.cxx
+++ b/basic/source/runtime/stdobj1.cxx
@@ -313,41 +313,6 @@ void SbStdFont::SFX_NOTIFY( SfxBroadcaster& rBC, const TypeId& rBCType,
//-----------------------------------------------------------------------------
-/*
-class TransferableHelperImpl : public TransferableHelper
-{
- SotFormatStringId mFormat;
- String mString;
- Graphic mGraphic;
-
- virtual void AddSupportedFormats();
- virtual sal_Bool GetData( const ::com::sun::star::datatransfer::DataFlavor& rFlavor );
-
-public:
- TransferableHelperImpl( void ) { mFormat = 0; }
- TransferableHelperImpl( const String& rStr )
- mFormat( FORMAT_STRING ), mString( rStr ) {}
- TransferableHelperImpl( const Graphic& rGraphic );
- mFormat( FORMAT_BITMAP ), mGraphic( rGraphic ) {}
-
-};
-
-void TransferableHelperImpl::AddSupportedFormats()
-{
-}
-
-sal_Bool TransferableHelperImpl::GetData( const ::com::sun::star::datatransfer::DataFlavor& rFlavor )
-{
- sal_uInt32 nFormat = SotExchange::GetFormat( rFlavor );
- if( nFormat == FORMAT_STRING )
- {
- }
- else if( nFormat == FORMAT_BITMAP ||
- nFormat == FORMAT_GDIMETAFILE )
- {
- }
-}
-*/
void SbStdClipboard::MethClear( SbxVariable*, SbxArray* pPar_, sal_Bool )
{
@@ -357,7 +322,6 @@ void SbStdClipboard::MethClear( SbxVariable*, SbxArray* pPar_, sal_Bool )
return;
}
- //Clipboard::Clear();
}
void SbStdClipboard::MethGetData( SbxVariable* pVar, SbxArray* pPar_, sal_Bool )
@@ -377,20 +341,6 @@ void SbStdClipboard::MethGetData( SbxVariable* pVar, SbxArray* pPar_, sal_Bool )
return;
}
- /*
- if( nFormat == FORMAT_STRING )
- pVar->PutString( Clipboard::PasteString() );
- else
- if( (nFormat == FORMAT_BITMAP) ||
- (nFormat == FORMAT_GDIMETAFILE ) )
- {
- SbxObjectRef xPic = new SbStdPicture;
- Graphic aGraph;
- aGraph.Paste();
- ((SbStdPicture*)(SbxObject*)xPic)->SetGraphic( aGraph );
- pVar->PutObject( xPic );
- }
- */
}
void SbStdClipboard::MethGetFormat( SbxVariable* pVar, SbxArray* pPar_, sal_Bool )
@@ -409,7 +359,6 @@ void SbStdClipboard::MethGetFormat( SbxVariable* pVar, SbxArray* pPar_, sal_Bool
}
pVar->PutBool( sal_False );
- //pVar->PutBool( Clipboard::HasFormat( nFormat ) );
}
void SbStdClipboard::MethGetText( SbxVariable* pVar, SbxArray* pPar_, sal_Bool )
@@ -421,7 +370,6 @@ void SbStdClipboard::MethGetText( SbxVariable* pVar, SbxArray* pPar_, sal_Bool )
}
pVar->PutString( String() );
- //pVar->PutString( Clipboard::PasteString() );
}
void SbStdClipboard::MethSetData( SbxVariable* pVar, SbxArray* pPar_, sal_Bool )
@@ -441,21 +389,6 @@ void SbStdClipboard::MethSetData( SbxVariable* pVar, SbxArray* pPar_, sal_Bool )
return;
}
- /*
- if( nFormat == FORMAT_STRING )
- {
- Clipboard::CopyString( pPar_->Get(1)->GetString() );
- }
- else
- if( (nFormat == FORMAT_BITMAP) ||
- (nFormat == FORMAT_GDIMETAFILE) )
- {
- SbxObject* pObj = (SbxObject*)pPar_->Get(1)->GetObject();
-
- if( pObj && pObj->IsA( TYPE( SbStdPicture ) ) )
- ((SbStdPicture*)(SbxObject*)pObj)->GetGraphic().Copy();
- }
- */
}
void SbStdClipboard::MethSetText( SbxVariable* pVar, SbxArray* pPar_, sal_Bool )
@@ -468,7 +401,6 @@ void SbStdClipboard::MethSetText( SbxVariable* pVar, SbxArray* pPar_, sal_Bool )
return;
}
- // Clipboard::CopyString( pPar_->Get(1)->GetString() );
}
diff --git a/basic/source/runtime/step0.cxx b/basic/source/runtime/step0.cxx
index 520df18ecdd5..0126dd307810 100755
--- a/basic/source/runtime/step0.cxx
+++ b/basic/source/runtime/step0.cxx
@@ -477,7 +477,6 @@ void SbiRuntime::StepSET_Impl( SbxVariableRef& refVal, SbxVariableRef& refVar, b
// Check value, !object is no error for sure if, only if type is fixed
SbxDataType eValType = refVal->GetType();
-// bool bGetValObject = false;
if( !bHandleDefaultProp && eValType != SbxOBJECT && !(eValType & SbxARRAY) && refVal->IsFixed() )
{
Error( SbERR_INVALID_USAGE_OBJECT );
@@ -802,7 +801,7 @@ void SbiRuntime::DimImpl( SbxVariableRef refVar )
{
SbxDataType eType = refVar->IsFixed() ? refVar->GetType() : SbxVARIANT;
SbxDimArray* pArray = new SbxDimArray( eType );
- // AB 2.4.1996, auch Arrays ohne Dimensionsangaben zulassen (VB-komp.)
+ // auch Arrays ohne Dimensionsangaben zulassen (VB-komp.)
if( pDims )
{
for( sal_uInt16 i = 1; i < pDims->Count(); )
@@ -904,27 +903,11 @@ void SbiRuntime::StepREDIMP()
sal_Int32 lBoundOld, uBoundOld;
pNewArray->GetDim32( i, lBoundNew, uBoundNew );
pOldArray->GetDim32( i, lBoundOld, uBoundOld );
-
- /* #69094 Allow all dimensions to be changed
- although Visual Basic is not able to do so.
- // All bounds but the last have to be the same
- if( i < nDims && ( lBoundNew != lBoundOld || uBoundNew != uBoundOld ) )
- {
- bRangeError = sal_True;
- break;
- }
- else
- */
- {
- // #69094: if( i == nDims )
- {
- lBoundNew = std::max( lBoundNew, lBoundOld );
- uBoundNew = std::min( uBoundNew, uBoundOld );
- }
- short j = i - 1;
- pActualIndices[j] = pLowerBounds[j] = lBoundNew;
- pUpperBounds[j] = uBoundNew;
- }
+ lBoundNew = std::max( lBoundNew, lBoundOld );
+ uBoundNew = std::min( uBoundNew, uBoundOld );
+ short j = i - 1;
+ pActualIndices[j] = pLowerBounds[j] = lBoundNew;
+ pUpperBounds[j] = uBoundNew;
}
}
@@ -948,7 +931,6 @@ void SbiRuntime::StepREDIMP()
}
}
- //StarBASIC::FatalError( SbERR_NOT_IMPLEMENTED );
}
// REDIM_COPY
@@ -1015,7 +997,6 @@ void lcl_eraseImpl( SbxVariableRef& refVar, bool bVBAEnabled )
}
}
else
- // AB 2.4.1996
// Arrays haben bei Erase nach VB ein recht komplexes Verhalten. Hier
// werden zunaechst nur die Typ-Probleme bei REDIM (#26295) beseitigt:
// Typ hart auf den Array-Typ setzen, da eine Variable mit Array
@@ -1088,7 +1069,6 @@ void SbiRuntime::StepARGV()
SbxVariableRef pVal = PopVar();
// Before fix of #94916:
- // if( pVal->ISA(SbxMethod) || pVal->ISA(SbxProperty) )
if( pVal->ISA(SbxMethod) || pVal->ISA(SbUnoProperty) || pVal->ISA(SbProcedureProperty) )
{
// Methoden und Properties evaluieren!
@@ -1184,11 +1164,6 @@ void SbiRuntime::StepINPUT()
BasResId aId( IDS_SBERR_START + 4 );
String aMsg( aId );
- //****** DONT CHECK IN, TEST ONLY *******
- //****** DONT CHECK IN, TEST ONLY *******
- // ErrorBox( NULL, WB_OK, aMsg ).Execute();
- //****** DONT CHECK IN, TEST ONLY *******
- //****** DONT CHECK IN, TEST ONLY *******
pCode = pRestart;
}
@@ -1197,7 +1172,6 @@ void SbiRuntime::StepINPUT()
}
else
{
- // pIosys->ResetChannel();
PopVar();
}
}
@@ -1212,7 +1186,6 @@ void SbiRuntime::StepLINPUT()
Error( pIosys->GetError() );
SbxVariableRef p = PopVar();
p->PutString( String( aInput, gsl_getSystemTextEncoding() ) );
- // pIosys->ResetChannel();
}
// Programmende
@@ -1370,13 +1343,11 @@ void SbiRuntime::StepRENAME() // Rename Tos+1 to Tos
String aDest = pTos1->GetString();
String aSource = pTos->GetString();
- // <-- UCB
if( hasUno() )
{
implStepRenameUCB( aSource, aDest );
}
else
- // --> UCB
{
#ifdef _OLD_FILE_IMPL
DirEntry aSourceDirEntry( aSource );
@@ -1420,7 +1391,6 @@ void SbiRuntime::StepEMPTY()
SbxVariableRef xVar = new SbxVariable( SbxVARIANT );
xVar->PutErr( 448 );
PushVar( xVar );
- // ALT: PushVar( new SbxVariable( SbxEMPTY ) );
}
// TOS = Fehlercode
diff --git a/basic/source/runtime/step1.cxx b/basic/source/runtime/step1.cxx
index 659152548e53..53b482b8f22e 100755
--- a/basic/source/runtime/step1.cxx
+++ b/basic/source/runtime/step1.cxx
@@ -213,12 +213,10 @@ void SbiRuntime::StepONJUMP( sal_uInt32 nOp1 )
if( nOp1 & 0x8000 )
{
nOp1 &= 0x7FFF;
- //PushGosub( pCode + 3 * nOp1 );
PushGosub( pCode + 5 * nOp1 );
}
if( n < 1 || static_cast<sal_uInt32>(n) > nOp1 )
n = static_cast<sal_Int16>( nOp1 + 1 );
- //nOp1 = (sal_uInt32) ( (const char*) pCode - pImg->GetCode() ) + 3 * --n;
nOp1 = (sal_uInt32) ( (const char*) pCode - pImg->GetCode() ) + 5 * --n;
StepJUMP( nOp1 );
}
@@ -379,7 +377,7 @@ void SbiRuntime::StepERRHDL( sal_uInt32 nOp1 )
void SbiRuntime::StepRESUME( sal_uInt32 nOp1 )
{
- // AB #32714 Resume ohne Error? -> Fehler
+ // #32714 Resume ohne Error? -> Fehler
if( !bInError )
{
Error( SbERR_BAD_RESUME );
diff --git a/basic/source/runtime/step2.cxx b/basic/source/runtime/step2.cxx
index 2b8dbc71cf03..ebc012c36f99 100755
--- a/basic/source/runtime/step2.cxx
+++ b/basic/source/runtime/step2.cxx
@@ -89,7 +89,6 @@ SbxVariable* SbiRuntime::FindElement
SbxVariable* p = new SbxVariable;
p->PutString( sArg );
PushVar( p );
- //
StepARGV();
nOp1 = nOp1 | 0x8000; // indicate params are present
aName = String::CreateFromAscii("Evaluate");
@@ -181,7 +180,6 @@ SbxVariable* SbiRuntime::FindElement
// Hat das Ding Parameter, nicht einrichten!
if( nOp1 & 0x8000 )
bFatalError = sal_True;
- // ALT: StarBASIC::FatalError( nNotFound );
// Sonst, falls keine Parameter sind, anderen Error Code verwenden
if( !bLocal || pImg->GetFlag( SBIMG_EXPLICIT ) )
@@ -252,7 +250,7 @@ SbxVariable* SbiRuntime::FindElement
// Erst nach dem Setzen anfassen, da z.B. LEFT()
// den Unterschied zwischen Left$() und Left() kennen muss
- // AB 12.8.96: Da in PopVar() die Parameter von Methoden weggehauen
+ // Da in PopVar() die Parameter von Methoden weggehauen
// werden, muessen wir hier explizit eine neue SbxMethod anlegen
SbxVariable* pNew = new SbxMethod( *((SbxMethod*)pElem) ); // das ist der Call!
//ALT: SbxVariable* pNew = new SbxVariable( *pElem ); // das ist der Call!
@@ -286,7 +284,7 @@ SbxVariable* SbiRuntime::FindElement
// Find-Funktion ueber Name fuer aktuellen Scope (z.B. Abfrage aus BASIC-IDE)
SbxBase* SbiRuntime::FindElementExtern( const String& rName )
{
- // Hinweis zu #35281#: Es darf nicht davon ausgegangen werden, dass
+ // Hinweis zu: Es darf nicht davon ausgegangen werden, dass
// pMeth != null, da im RunInit noch keine gesetzt ist.
SbxVariable* pElem = NULL;
@@ -735,7 +733,6 @@ void SbiRuntime::StepPARAM( sal_uInt32 nOp1, sal_uInt32 nOp2 )
p = refParams->Get( i );
if( p->GetType() == SbxERROR && ( i ) )
- //if( p->GetType() == SbxEMPTY && ( i ) )
{
// Wenn ein Parameter fehlt, kann er OPTIONAL sein
sal_Bool bOpt = sal_False;
@@ -846,10 +843,6 @@ void SbiRuntime::StepSTMNT( sal_uInt32 nOp1, sal_uInt32 nOp2 )
// Der Expr-Stack ist nun nicht mehr notwendig
ClearExprStack();
- // #56368 Kuenstliche Referenz fuer StepElem wieder freigeben,
- // damit sie nicht ueber ein Statement hinaus erhalten bleibt
- //refSaveObj = NULL;
- // #74254 Jetzt per Liste
ClearRefs();
// Wir muessen hier hart abbrechen, da sonst Zeile und Spalte nicht mehr
@@ -900,7 +893,6 @@ void SbiRuntime::StepSTMNT( sal_uInt32 nOp1, sal_uInt32 nOp2 )
// 16.10.96: #31460 Neues Konzept fuer StepInto/Over/Out
// Erkl�rung siehe bei _ImplGetBreakCallLevel.
if( pInst->nCallLvl <= pInst->nBreakCallLvl )
- //if( nFlags & SbDEBUG_STEPINTO )
{
StarBASIC* pStepBasic = GetCurrentBasic( &rBasic );
sal_uInt16 nNewFlags = pStepBasic->StepPoint( nLine, nCol1, nCol2 );
@@ -919,9 +911,6 @@ void SbiRuntime::StepSTMNT( sal_uInt32 nOp1, sal_uInt32 nOp2 )
// Neuen BreakCallLevel ermitteln
pInst->CalcBreakCallLevel( nNewFlags );
- //16.10.96, ALT:
- //if( nNewFlags != SbDEBUG_CONTINUE )
- // nFlags = nNewFlags;
}
}
diff --git a/basic/source/sample/object.cxx b/basic/source/sample/object.cxx
index 2c3ca7e29797..4322d5e1fe62 100755
--- a/basic/source/sample/object.cxx
+++ b/basic/source/sample/object.cxx
@@ -59,10 +59,6 @@
// Das Sample-Objekt wird in ..\app\mybasic.cxx wie folgt in StarBASIC
// eingebaut:
-// MyBasic::MyBasic() : StarBASIC()
-// {
-// AddFactory( new SampleObjectFac() );
-// }
// Das nArgs-Feld eines Tabelleneintrags ist wie folgt verschluesselt:
@@ -209,8 +205,6 @@ void SampleObject::SFX_NOTIFY( SfxBroadcaster& rBC, const TypeId& rBCT,
SbxInfo* SampleObject::GetInfo( short nIdx )
{
Methods* p = &aMethods[ nIdx ];
- // Wenn mal eine Hilfedatei zur Verfuegung steht:
- // SbxInfo* pInfo_ = new SbxInfo( Hilfedateiname, p->nHelpId );
SbxInfo* pInfo_ = new SbxInfo;
short nPar = p->nArgs & _ARGSMASK;
for( short i = 0; i < nPar; i++ )
@@ -225,7 +219,6 @@ SbxInfo* SampleObject::GetInfo( short nIdx )
return pInfo_;
}
-////////////////////////////////////////////////////////////////////////////
// Properties und Methoden legen beim Get (bPut = sal_False) den Returnwert
// im Element 0 des Argv ab; beim Put (bPut = sal_True) wird der Wert aus
diff --git a/basic/source/sbx/sbxarray.cxx b/basic/source/sbx/sbxarray.cxx
index f230a6b8ed83..0f9b81f8d479 100755
--- a/basic/source/sbx/sbxarray.cxx
+++ b/basic/source/sbx/sbxarray.cxx
@@ -59,11 +59,7 @@ public:
TYPEINIT1(SbxArray,SbxBase)
TYPEINIT1(SbxDimArray,SbxArray)
-//////////////////////////////////////////////////////////////////////////
-//
// SbxArray
-//
-//////////////////////////////////////////////////////////////////////////
SbxArray::SbxArray( SbxDataType t ) : SbxBase()
{
@@ -355,7 +351,6 @@ void SbxArray::Remove( SbxVariable* pVar )
for( sal_uInt32 i = 0; i < pData->size(); i++ )
{
SbxVariableRef* pRef = (*pData)[i];
- // SbxVariableRef* pRef = pData->GetObject( i );
if( *pRef == pVar )
{
Remove32( i ); break;
@@ -576,11 +571,7 @@ void SbxArray::PutDirect( SbxVariable* pVar, sal_uInt32 nIdx )
}
-//////////////////////////////////////////////////////////////////////////
-//
// SbxArray
-//
-//////////////////////////////////////////////////////////////////////////
SbxDimArray::SbxDimArray( SbxDataType t ) : SbxArray( t ), mbHasFixedSize( false )
{
diff --git a/basic/source/sbx/sbxcoll.cxx b/basic/source/sbx/sbxcoll.cxx
index 7023be059f5e..8cf068d657cb 100755
--- a/basic/source/sbx/sbxcoll.cxx
+++ b/basic/source/sbx/sbxcoll.cxx
@@ -44,7 +44,6 @@ static const char* pItem;
static const char* pRemove;
static sal_uInt16 nCountHash = 0, nAddHash, nItemHash, nRemoveHash;
-/////////////////////////////////////////////////////////////////////////
SbxCollection::SbxCollection( const XubString& rClass )
: SbxObject( rClass )
@@ -223,7 +222,6 @@ sal_Bool SbxCollection::LoadData( SvStream& rStrm, sal_uInt16 nVer )
return bRes;
}
-/////////////////////////////////////////////////////////////////////////
SbxStdCollection::SbxStdCollection
( const XubString& rClass, const XubString& rElem, sal_Bool b )
diff --git a/basic/source/sbx/sbxdec.cxx b/basic/source/sbx/sbxdec.cxx
index 91553270736a..ddf9d68489a5 100755
--- a/basic/source/sbx/sbxdec.cxx
+++ b/basic/source/sbx/sbxdec.cxx
@@ -66,7 +66,6 @@ SbxDecimal::SbxDecimal
(void)rAutomationDec;
#endif
mnRefCount = 0;
- // GnDecCounter++;
}
void SbxDecimal::fillAutomationDecimal
@@ -85,7 +84,6 @@ void SbxDecimal::fillAutomationDecimal
SbxDecimal::~SbxDecimal()
{
- // GnDecCounter--;
}
void releaseDecimalPtr( SbxDecimal*& rpDecimal )
@@ -643,7 +641,6 @@ start:
case SbxBYREF | SbxSTRING:
if( !p->pOUString )
p->pOUString = new ::rtl::OUString;
- // ImpCvtNum( (double) n, 0, *p->pString );
pDec->getString( *p->pOUString );
break;
case SbxOBJECT:
@@ -678,7 +675,6 @@ start:
*p->pInteger = 0;
}
break;
- // *p->pInteger = n; break;
case SbxBYREF | SbxERROR:
case SbxBYREF | SbxUSHORT:
if( !pDec->getUShort( *p->pUShort ) )
diff --git a/basic/source/sbx/sbxform.cxx b/basic/source/sbx/sbxform.cxx
index d1a85cb07d3a..61fbafdd37cf 100755
--- a/basic/source/sbx/sbxform.cxx
+++ b/basic/source/sbx/sbxform.cxx
@@ -142,12 +142,6 @@ SbxBasicFormater::SbxBasicFormater( sal_Unicode _cDecPoint, sal_Unicode _cThousa
}
// Funktion zur Ausgabe eines Fehler-Textes (zum Debuggen)
-/*
-void SbxBasicFormater::ShowError( char * sErrMsg )
-{
-// cout << "ERROR in Format$(): " << sErrMsg << endl;
-}
-*/
// verschiebt alle Zeichen des Strings, angefangen von der nStartPos,
// um eine Position zu gr"osseren Indizes, d.h. es wird Platz f"ur
// ein neues (einzuf"ugendes) Zeichen geschafft.
@@ -379,7 +373,6 @@ TODO: ggf einen 'intelligenten' Peek-Parser um Rundungsfehler bei
// In bFoundFirstDigit wird ggf. ein Flag gesetzt wenn eine Ziffer
// gefunden wurde, dies wird dazu verwendet um 'Fehler' beim Parsen 202
// zu vermeiden, die
-//
// ACHTUNG: anscheinend gibt es manchmal noch Probleme mit Rundungs-Fehlern!
short SbxBasicFormater::GetDigitAtPos( double dNumber, short nPos,
double& dNextNumber, sal_Bool& bFoundFirstDigit )
@@ -615,11 +608,6 @@ short SbxBasicFormater::AnalyseFormatString( const String& sFormatStrg,
break;
case '%':
bPercent = sal_True;
- /* old:
- bPercent++;
- if( bPercent>1 )
- return -2; // ERROR: zu viele Prozent-Zeichen
- */
break;
case '(':
bCurrency = sal_True;
@@ -640,11 +628,6 @@ short SbxBasicFormater::AnalyseFormatString( const String& sFormatStrg,
nState = -1; // breche jetzt das Z"ahlen der Stellen ab
bScientific = sal_True;
}
- /* old:
- bScientific++;
- if( bScientific>1 )
- return -3; // ERROR: zu viele Exponent-Zeichen
- */
break;
// EIGENES Kommando-Zeichen, das die Erzeugung der
// Tausender-Trennzeichen einschaltet
@@ -691,23 +674,11 @@ void SbxBasicFormater::ScanFormatString( double dNumber,
- sonstige Fehler ? mehrfache Dezimalpunkte, E's, etc.
--> Fehler werden zur Zeit einfach ignoriert
*/
- /*nErr =*/ AnalyseFormatString( sFormatStrg,nNoOfDigitsLeft,nNoOfDigitsRight,
+ AnalyseFormatString( sFormatStrg,nNoOfDigitsLeft,nNoOfDigitsRight,
nNoOfOptionalDigitsLeft,nNoOfExponentDigits,
nNoOfOptionalExponentDigits,
bPercent,bCurrency,bScientific,bGenerateThousandSeparator,
nMultipleThousandSeparators );
- /* es werden alle Fehler ignoriert, wie in Visual-Basic
- if( nErr!=0 )
- {
- char sBuffer[512];
-
- //sprintf( sBuffer,"bad format-string >%s< err=%i",sFormatStrg,nErr );
- strcpy( sBuffer,"bad format-string" );
- ShowError( sBuffer );
- }
- else
- */
- {
// Spezialbehandlung f"ur Spezialzeichen
if( bPercent )
dNumber *= 100.0;
@@ -735,8 +706,6 @@ void SbxBasicFormater::ScanFormatString( double dNumber,
bDigitPosNegative = false;
if( bScientific )
{
- //if( nNoOfOptionalDigitsLeft>0 )
- // ShowError( "# in scientific-format in front of the decimal-point has no effect" );
// beim Exponent ggf. "uberz"ahlige Stellen vor dem Komma abziehen
dExponent = dExponent - (double)(nNoOfDigitsLeft-1);
nDigitPos = nMaxDigit;
@@ -780,11 +749,10 @@ void SbxBasicFormater::ScanFormatString( double dNumber,
// Behandlung der Mantisse
if( bFirstDigit )
{
- //org:bFirstDigit = sal_False;
// ggf. Vorzeichen erzeugen
// Bem.: bei bCurrency soll das negative
// Vorzeichen durch () angezeigt werden
- if( bIsNegative && !bCreateSign/*!bCurrency*/ && !bSignHappend )
+ if( bIsNegative && !bCreateSign && !bSignHappend )
{
// nur einmal ein Vorzeichen ausgeben
bSignHappend = sal_True;
@@ -958,19 +926,9 @@ void SbxBasicFormater::ScanFormatString( double dNumber,
else
StrAppendChar( sReturnStrg,'+' );
}
- //else
- // ShowError( "operator e/E did not find + or -" );
}
- //else
- // ShowError( "operator e/E ended with 0" );
break;
case ',':
- // ACHTUNG: nur falls Zahl bisher ausgegeben wurde
- // das Zeichen ausgeben
- ////--> Siehe Kommentar vom 11.7. in AnalyseFormatString()
- ////if( !bFirstDigit )
- //// // gebe Tausender-Trennzeichen aus
- //// StrAppendChar( sReturnStrg,cThousandSep );
break;
case ';':
break;
@@ -1000,12 +958,9 @@ void SbxBasicFormater::ScanFormatString( double dNumber,
ParseBack( sReturnStrg,sFormatStrg,i-1 );
// Sonderzeichen gefunden, gebe N"ACHSTES
// Zeichen direkt aus (falls es existiert)
- // i++;
c = sFormatStrg.GetChar( ++i );
if( c!=0 )
StrAppendChar( sReturnStrg,c );
- //else
- // ShowError( "operator \\ ended with 0" );
break;
case CREATE_1000SEP_CHAR:
// hier ignorieren, Aktion wurde schon in
@@ -1017,9 +972,6 @@ void SbxBasicFormater::ScanFormatString( double dNumber,
( c>='A' && c<='Z' ) ||
( c>='1' && c<='9' ) )
StrAppendChar( sReturnStrg,c );
- // else
- // ignorieren !
- // ehemals: ShowError( "bad character in format-string" );
}
}
// Format-String wurde vollst"andig gescanned,
@@ -1041,7 +993,6 @@ void SbxBasicFormater::ScanFormatString( double dNumber,
// ABER nur Stellen nach dem Dezimal-Punkt k"onnen gel"oscht werden
if( nNoOfDigitsRight>0 )
ParseBack( sReturnStrg,sFormatStrg,sFormatStrg.Len()-1 );
- }
}
String SbxBasicFormater::BasicFormatNull( String sFormatStrg )
@@ -1085,7 +1036,6 @@ String SbxBasicFormater::BasicFormat( double dNumber, String sFormatStrg )
String sPosFormatStrg = GetPosFormatString( sFormatStrg, bPosFormatFound );
String sNegFormatStrg = GetNegFormatString( sFormatStrg, bNegFormatFound );
String s0FormatStrg = Get0FormatString( sFormatStrg, b0FormatFound );
- //String sNullFormatStrg = GetNullFormatString( sFormatStrg, bNullFormatFound );
String sReturnStrg;
String sTempStrg;
diff --git a/basic/source/sbx/sbxobj.cxx b/basic/source/sbx/sbxobj.cxx
index a6d089602ba4..8c1bbbec6119 100755
--- a/basic/source/sbx/sbxobj.cxx
+++ b/basic/source/sbx/sbxobj.cxx
@@ -43,9 +43,7 @@ static const char* pParentProp; // Parent-Property
static sal_uInt16 nNameHash = 0, nParentHash = 0;
-/////////////////////////////////////////////////////////////////////////
-/////////////////////////////////////////////////////////////////////////
SbxObject::SbxObject( const XubString& rClass )
: SbxVariable( SbxOBJECT ), aClassName( rClass )
@@ -401,20 +399,6 @@ SbxVariable* SbxObject::Make( const XubString& rName, SbxClassType ct, SbxDataTy
SbxVariable* pRes = pArray->Find( rName, ct );
if( pRes )
{
-/* Due to often problems (e.g. #67000) first of all completly out
-#ifdef DBG_UTIL
- if( pRes->GetHashCode() != nNameHash
- && pRes->GetHashCode() != nParentHash )
- {
- XubString aMsg( "SBX-Element \"" );
- aMsg += pRes->GetName();
- aMsg += "\"\n in Objekt \"";
- aMsg += GetName();
- aMsg += "\" bereits vorhanden";
- DbgError( (const char*)aMsg.GetStr() );
- }
-#endif
-*/
return pRes;
}
}
@@ -450,20 +434,6 @@ SbxObject* SbxObject::MakeObject( const XubString& rName, const XubString& rClas
SbxVariable* pRes = pObjs->Find( rName, SbxCLASS_OBJECT );
if( pRes )
{
-/* Due to often problems (e.g. #67000) first of all completly out
-#ifdef DBG_UTIL
- if( pRes->GetHashCode() != nNameHash
- && pRes->GetHashCode() != nParentHash )
- {
- XubString aMsg( "SBX-Objekt \"" );
- aMsg += pRes->GetName();
- aMsg += "\"\n in Objekt \"";
- aMsg += GetName();
- aMsg += "\" bereits vorhanden";
- DbgError( (const char*)aMsg.GetStr() );
- }
-#endif
-*/
return PTR_CAST(SbxObject,pRes);
}
}
@@ -501,20 +471,6 @@ void SbxObject::Insert( SbxVariable* pVar )
if( pOld == pVar )
return;
-/* Due to often problems (e.g. #67000) first of all completly out
-#ifdef DBG_UTIL
- if( pOld->GetHashCode() != nNameHash
- && pOld->GetHashCode() != nParentHash )
- {
- XubString aMsg( "SBX-Element \"" );
- aMsg += pVar->GetName();
- aMsg += "\"\n in Objekt \"";
- aMsg += GetName();
- aMsg += "\" bereits vorhanden";
- DbgError( (const char*)aMsg.GetStr() );
- }
-#endif
-*/
EndListening( pOld->GetBroadcaster(), sal_True );
if( pVar->GetClass() == SbxCLASS_PROPERTY )
{
@@ -545,7 +501,7 @@ void SbxObject::Insert( SbxVariable* pVar )
}
}
-// From 1997-04-23, Optimisation, Insertion without checking about
+// Optimisation, Insertion without checking about
// double entry and without broadcasts, will only be used in SO2/auto.cxx
void SbxObject::QuickInsert( SbxVariable* pVar )
{
@@ -585,7 +541,7 @@ void SbxObject::QuickInsert( SbxVariable* pVar )
}
}
-// From 1997-03-23, special method, allow controls of the same name
+// special method, allow controls of the same name
void SbxObject::VCPtrInsert( SbxVariable* pVar )
{
SbxArray* pArray = NULL;
@@ -643,7 +599,7 @@ void SbxObject::Remove( SbxVariable* pVar )
}
}
-// From 1997-03-23, cleanup per Pointer for Controls (double names!)
+// cleanup per Pointer for Controls (double names!)
void SbxObject::VCPtrRemove( SbxVariable* pVar )
{
sal_uInt16 nIdx;
@@ -664,7 +620,7 @@ void SbxObject::VCPtrRemove( SbxVariable* pVar )
}
}
-// From 1997-03-23, associated special method, search only by Pointer
+// associated special method, search only by Pointer
SbxArray* SbxObject::VCPtrFindVar( SbxVariable* pVar, sal_uInt16& nArrayIdx )
{
SbxArray* pArray = NULL;
@@ -709,8 +665,6 @@ void SbxObject::SetPos( SbxVariable* pVar, sal_uInt16 nPos )
pArray->Insert( refVar, nPos );
}
}
-// SetModified( sal_True );
-// Broadcast( SBX_HINT_OBJECTCHANGED );
}
static sal_Bool LoadArray( SvStream& rStrm, SbxObject* pThis, SbxArray* pArray )
diff --git a/basic/source/sbx/sbxscan.cxx b/basic/source/sbx/sbxscan.cxx
index 3b6d37286cd1..95d4b8dbc836 100755
--- a/basic/source/sbx/sbxscan.cxx
+++ b/basic/source/sbx/sbxscan.cxx
@@ -262,7 +262,6 @@ SbxError SbxValue::ScanNumIntnl( const String& rSrc, double& nVal, sal_Bool bSin
return nRetError;
}
-////////////////////////////////////////////////////////////////////////////
static double roundArray[] = {
5.0e+0, 0.5e+0, 0.5e-1, 0.5e-2, 0.5e-3, 0.5e-4, 0.5e-5, 0.5e-6, 0.5e-7,
@@ -606,7 +605,6 @@ static sal_uInt16 printfmtstr( const XubString& rStr, XubString& rRes, const Xub
return (sal_uInt16) ( pFmt - pFmtStart );
}
-/////////////////////////////////////////////////////////////////////////
sal_Bool SbxValue::Scan( const XubString& rSrc, sal_uInt16* pLen )
{
@@ -932,8 +930,6 @@ void SbxValue::Format( XubString& rRes, const XubString* pFmt ) const
rRes = pData->pBasicFormater->BasicFormatNull( *pFmt );
}
- // Die alte Implementierung:
- //old: printfmtnum( GetDouble(), rRes, *pFmt );
}
else
{
diff --git a/basic/source/sbx/sbxvalue.cxx b/basic/source/sbx/sbxvalue.cxx
index 2c3adaa4302d..8b55561d2acf 100755
--- a/basic/source/sbx/sbxvalue.cxx
+++ b/basic/source/sbx/sbxvalue.cxx
@@ -314,7 +314,7 @@ SbxValue* SbxValue::TheRealValue( sal_Bool bObjInObjError ) const
// If this is an object and contains itself,
// we cannot access on it
- // #55226# The old condition to set an error
+ // The old condition to set an error
// is not correct, because e.g. a regular variant variable with an object
// could be affected thereof, if another value should be assigned.
// Therefore with flag.
@@ -331,10 +331,6 @@ SbxValue* SbxValue::TheRealValue( sal_Bool bObjInObjError ) const
}
else if( pDflt )
p = pDflt;
- /* ALT:
- else
- p = pDflt ? pDflt : (SbxVariable*) pObj;
- */
break;
}
// Did we have an array?
@@ -1465,7 +1461,6 @@ sal_Bool SbxValue::Compare( SbxOperator eOp, const SbxValue& rOp ) const
else
{
aL.eType = aR.eType = SbxDOUBLE;
- //if( Get( aL ) && rOp.Get( aR ) )
bool bGetL = Get( aL );
bool bGetR = rOp.Get( aR );
if( bGetL && bGetR )
diff --git a/basic/source/sbx/sbxvar.cxx b/basic/source/sbx/sbxvar.cxx
index 9a981cccc7ca..9a99f06b151c 100755
--- a/basic/source/sbx/sbxvar.cxx
+++ b/basic/source/sbx/sbxvar.cxx
@@ -553,8 +553,6 @@ sal_Bool SbxVariable::StoreData( SvStream& rStrm ) const
bValStore = SbxValue::StoreData( rStrm );
if( !bValStore )
return sal_False;
- // if( !SbxValue::StoreData( rStrm ) )
- // return sal_False;
rStrm.WriteByteString( maName, RTL_TEXTENCODING_ASCII_US );
rStrm << (sal_uInt32)nUserData;
if( pInfo.Is() )
diff --git a/basic/source/uno/namecont.cxx b/basic/source/uno/namecont.cxx
index 4d5ab544e614..e1e7fd3cf5f6 100755
--- a/basic/source/uno/namecont.cxx
+++ b/basic/source/uno/namecont.cxx
@@ -643,7 +643,6 @@ sal_Bool SfxLibraryContainer::init_Impl(
// #110009: Scope to force the StorageRefs to be destructed and
// so the streams to be closed before the preload operation
{
- // #110009
uno::Reference< embed::XStorage > xLibrariesStor;
String aFileName;
@@ -661,9 +660,6 @@ sal_Bool SfxLibraryContainer::init_Impl(
{
uno::Reference< io::XStream > xStream;
xLibrariesStor = xStorage->openStorageElement( maLibrariesDir, embed::ElementModes::READ );
- //if ( !xLibrariesStor.is() )
- // TODO: the method must either return a storage or throw an exception
- //throw uno::RuntimeException();
if ( xLibrariesStor.is() )
{
@@ -936,7 +932,6 @@ sal_Bool SfxLibraryContainer::init_Impl(
// #110009: END Scope to force the StorageRefs to be destructed
}
- // #110009
if( !bStorage && meInitMode == DEFAULT )
{
@@ -951,7 +946,7 @@ sal_Bool SfxLibraryContainer::init_Impl(
}
}
- // #110009 Preload?
+ // Preload?
{
Sequence< OUString > aNames = maNameContainer.getElementNames();
const OUString* pNames = aNames.getConstArray();
@@ -965,7 +960,6 @@ sal_Bool SfxLibraryContainer::init_Impl(
}
}
- // #118803# upgrade installation 7.0 -> 8.0
if( meInitMode == DEFAULT )
{
INetURLObject aUserBasicInetObj( String(maLibraryPath).GetToken(1) );
@@ -987,7 +981,7 @@ sal_Bool SfxLibraryContainer::init_Impl(
String aPrevFolder = aPrevUserBasicInetObj.GetMainURL( INetURLObject::NO_DECODE );
if( mxSFI->isFolder( aPrevFolder ) )
{
- // #110101 Check if Standard folder exists and is complete
+ // Check if Standard folder exists and is complete
INetURLObject aUserBasicStandardInetObj( aUserBasicInetObj );
aUserBasicStandardInetObj.insertName( aStandardStr, sal_True, INetURLObject::LAST_SEGMENT,
sal_True, INetURLObject::ENCODE_ALL );
@@ -1371,7 +1365,6 @@ void SfxLibraryContainer::implStoreLibrary( SfxLibrary* pLib,
OUString aStreamName = aElementName;
aStreamName += String( RTL_CONSTASCII_USTRINGPARAM(".xml") );
- /*Any aElement = pLib->getByName( aElementName );*/
if( !isLibraryElementValid( pLib->getByName( aElementName ) ) )
{
#if OSL_DEBUG_LEVEL > 0
@@ -1387,7 +1380,6 @@ void SfxLibraryContainer::implStoreLibrary( SfxLibrary* pLib,
uno::Reference< io::XStream > xElementStream = xStorage->openStreamElement(
aStreamName,
embed::ElementModes::READWRITE );
- //if ( !xElementStream.is() )
// throw uno::RuntimeException(); // TODO: method must either return the stream or throw an exception
String aPropName( String::CreateFromAscii( RTL_CONSTASCII_STRINGPARAM("MediaType") ) );
@@ -1396,7 +1388,6 @@ void SfxLibraryContainer::implStoreLibrary( SfxLibrary* pLib,
uno::Reference< beans::XPropertySet > xProps( xElementStream, uno::UNO_QUERY );
OSL_ENSURE( xProps.is(), "The StorageStream must implement XPropertySet interface!\n" );
//if ( !xProps.is() ) //TODO
- // throw uno::RuntimeException();
if ( xProps.is() )
{
@@ -1409,8 +1400,6 @@ void SfxLibraryContainer::implStoreLibrary( SfxLibrary* pLib,
Reference< XOutputStream > xOutput = xElementStream->getOutputStream();
Reference< XNameContainer > xLib( pLib );
writeLibraryElement( xLib, aElementName, xOutput );
- // writeLibraryElement closes the stream
- // xOutput->closeOutput();
}
}
catch( uno::Exception& )
@@ -1460,7 +1449,6 @@ void SfxLibraryContainer::implStoreLibrary( SfxLibrary* pLib,
aElementInetObj.setExtension( maLibElementFileExtension );
String aElementPath( aElementInetObj.GetMainURL( INetURLObject::NO_DECODE ) );
- /*Any aElement = pLib->getByName( aElementName );*/
if( !isLibraryElementValid( pLib->getByName( aElementName ) ) )
{
#if OSL_DEBUG_LEVEL > 0
@@ -1540,7 +1528,6 @@ void SfxLibraryContainer::implStoreLibraryIndexFile( SfxLibrary* pLib,
xInfoStream = xStorage->openStreamElement( aStreamName, embed::ElementModes::READWRITE );
OSL_ENSURE( xInfoStream.is(), "No stream!\n" );
uno::Reference< beans::XPropertySet > xProps( xInfoStream, uno::UNO_QUERY );
- //if ( !xProps.is() )
// throw uno::RuntimeException(); // TODO
if ( xProps.is() )
@@ -1683,7 +1670,6 @@ sal_Bool SfxLibraryContainer::implLoadLibraryIndexFile( SfxLibrary* pLib,
}
if( !xInput.is() )
{
- // OSL_FAIL( "### couln't open input stream\n" );
return sal_False;
}
@@ -2933,21 +2919,11 @@ Any SAL_CALL SfxLibrary::queryInterface( const Type& rType )
{
Any aRet;
- /*
- if( mbReadOnly )
- {
- aRet = Any( ::cppu::queryInterface( rType,
- static_cast< XContainer * >( this ),
- static_cast< XNameAccess * >( this ) ) );
- }
- else
- {
- */
- aRet = Any( ::cppu::queryInterface( rType,
- static_cast< XContainer * >( this ),
- static_cast< XNameContainer * >( this ),
- static_cast< XNameAccess * >( this ) ) );
- //}
+ aRet = Any( ::cppu::queryInterface( rType,
+ static_cast< XContainer * >( this ),
+ static_cast< XNameContainer * >( this ),
+ static_cast< XNameAccess * >( this ) ) );
+
if( !aRet.hasValue() )
aRet = OComponentHelper::queryInterface( rType );
return aRet;
diff --git a/basic/source/uno/scriptcont.cxx b/basic/source/uno/scriptcont.cxx
index 9238aed3d79f..d6a22045766c 100755
--- a/basic/source/uno/scriptcont.cxx
+++ b/basic/source/uno/scriptcont.cxx
@@ -396,8 +396,6 @@ void SAL_CALL SfxScriptLibraryContainer::importFromOldStorage( const ::rtl::OUSt
SotStorageRef xStorage = new SotStorage( sal_False, aFile );
if( xStorage.Is() && xStorage->GetError() == ERRCODE_NONE )
{
- // We need a BasicManager to avoid problems
- // StarBASIC* pBas = new StarBASIC();
BasicManager* pBasicManager = new BasicManager( *(SotStorage*)xStorage, aFile );
// Set info
@@ -641,7 +639,6 @@ sal_Bool SfxScriptLibraryContainer::implStorePasswordLibrary( SfxLibrary* pLib,
SbModule* pMod = pBasicLib->FindModule( aElementName );
if( pMod )
{
- //OUString aCodeStreamName( RTL_CONSTASCII_USTRINGPARAM("code.bin") );
OUString aCodeStreamName = aElementName;
aCodeStreamName += String( RTL_CONSTASCII_USTRINGPARAM(".bin") );
@@ -676,7 +673,6 @@ sal_Bool SfxScriptLibraryContainer::implStorePasswordLibrary( SfxLibrary* pLib,
if( pLib->mbPasswordVerified || pLib->mbDoc50Password )
{
- /*Any aElement = pLib->getByName( aElementName );*/
if( !isLibraryElementValid( pLib->getByName( aElementName ) ) )
{
#if OSL_DEBUG_LEVEL > 0
@@ -710,8 +706,6 @@ sal_Bool SfxScriptLibraryContainer::implStorePasswordLibrary( SfxLibrary* pLib,
Reference< XOutputStream > xOutput = xSourceStream->getOutputStream();
Reference< XNameContainer > xLib( pLib );
writeLibraryElement( xLib, aElementName, xOutput );
- // writeLibraryElement should have the stream already closed
- // xOutput->closeOutput();
}
catch( uno::Exception& )
{
@@ -762,7 +756,6 @@ sal_Bool SfxScriptLibraryContainer::implStorePasswordLibrary( SfxLibrary* pLib,
aElementInetObj.setExtension( OUString( RTL_CONSTASCII_USTRINGPARAM("pba") ) );
String aElementPath = aElementInetObj.GetMainURL( INetURLObject::NO_DECODE );
- /*Any aElement = pLib->getByName( aElementName );*/
if( !isLibraryElementValid( pLib->getByName( aElementName ) ) )
{
#if OSL_DEBUG_LEVEL > 0
@@ -861,13 +854,10 @@ sal_Bool SfxScriptLibraryContainer::implStorePasswordLibrary( SfxLibrary* pLib,
// TODO: handle error
}
- // Storage Dtor commits too, that makes problems
- // xElementRootStorage->Commit();
}
}
catch( Exception& )
{
- //throw e;
}
}
return sal_True;
@@ -955,7 +945,6 @@ sal_Bool SfxScriptLibraryContainer::implLoadPasswordLibrary
pBasicLib->SetModified( sal_False );
}
- //OUString aCodeStreamName( RTL_CONSTASCII_USTRINGPARAM("code.bin") );
OUString aCodeStreamName= aElementName;
aCodeStreamName += String( RTL_CONSTASCII_USTRINGPARAM(".bin") );