summaryrefslogtreecommitdiff
path: root/basctl
diff options
context:
space:
mode:
Diffstat (limited to 'basctl')
-rw-r--r--basctl/inc/basidesh.hrc174
-rw-r--r--basctl/inc/helpid.hrc106
-rw-r--r--basctl/prj/d.lst27
-rw-r--r--basctl/sdi/baside.sdi434
-rw-r--r--basctl/sdi/basslots.hrc64
-rw-r--r--basctl/sdi/basslots.sdi18
-rw-r--r--basctl/sdi/makefile.mk88
-rw-r--r--basctl/source/basicide/basdoc.cxx181
-rw-r--r--basctl/source/basicide/basdoc.hxx96
-rw-r--r--basctl/source/basicide/basicbox.cxx326
-rw-r--r--basctl/source/basicide/basicbox.hxx124
-rw-r--r--basctl/source/basicide/baside2.cxx1460
-rw-r--r--basctl/source/basicide/baside2.hrc93
-rw-r--r--basctl/source/basicide/baside2.hxx503
-rw-r--r--basctl/source/basicide/baside2b.cxx1917
-rw-r--r--basctl/source/basicide/baside3.cxx609
-rw-r--r--basctl/source/basicide/baside4.cxx62
-rw-r--r--basctl/source/basicide/basides1.cxx1179
-rw-r--r--basctl/source/basicide/basides2.cxx307
-rw-r--r--basctl/source/basicide/basides3.cxx161
-rw-r--r--basctl/source/basicide/basidesh.cxx848
-rw-r--r--basctl/source/basicide/basidesh.src2646
-rw-r--r--basctl/source/basicide/basobj2.cxx201
-rw-r--r--basctl/source/basicide/basobj3.cxx531
-rw-r--r--basctl/source/basicide/bastype2.cxx355
-rw-r--r--basctl/source/basicide/bastype2.hxx181
-rw-r--r--basctl/source/basicide/bastype3.cxx502
-rw-r--r--basctl/source/basicide/bastype3.hxx120
-rw-r--r--basctl/source/basicide/bastype4.hxx103
-rw-r--r--basctl/source/basicide/bastypes.cxx967
-rw-r--r--basctl/source/basicide/brkdlg.cxx321
-rw-r--r--basctl/source/basicide/brkdlg.hrc80
-rw-r--r--basctl/source/basicide/brkdlg.hxx118
-rw-r--r--basctl/source/basicide/brkdlg.src252
-rw-r--r--basctl/source/basicide/ide_pch.cxx63
-rw-r--r--basctl/source/basicide/ide_pch.hxx181
-rw-r--r--basctl/source/basicide/iderdll.cxx273
-rw-r--r--basctl/source/basicide/iderdll2.hxx157
-rw-r--r--basctl/source/basicide/idetemp.hxx87
-rw-r--r--basctl/source/basicide/macrodlg.cxx853
-rw-r--r--basctl/source/basicide/macrodlg.hrc87
-rw-r--r--basctl/source/basicide/macrodlg.hxx163
-rw-r--r--basctl/source/basicide/macrodlg.src522
-rw-r--r--basctl/source/basicide/makefile.mk123
-rw-r--r--basctl/source/basicide/moduldl2.cxx975
-rw-r--r--basctl/source/basicide/moduldlg.cxx795
-rw-r--r--basctl/source/basicide/moduldlg.hrc106
-rw-r--r--basctl/source/basicide/moduldlg.hxx348
-rw-r--r--basctl/source/basicide/moduldlg.src839
-rw-r--r--basctl/source/basicide/moptions.hrc81
-rw-r--r--basctl/source/basicide/moptions.src262
-rw-r--r--basctl/source/basicide/objdlg.cxx420
-rw-r--r--basctl/source/basicide/objdlg.hrc75
-rw-r--r--basctl/source/basicide/objdlg.hxx128
-rw-r--r--basctl/source/basicide/objdlg.src257
-rw-r--r--basctl/source/basicide/tbxctl.cxx241
-rw-r--r--basctl/source/basicide/tbxctl.hrc64
-rw-r--r--basctl/source/basicide/tbxctl.hxx123
-rw-r--r--basctl/source/basicide/tbxctl.src619
-rw-r--r--basctl/util/hidother.hrc61
-rw-r--r--basctl/util/hidother.src71
-rw-r--r--basctl/util/makefile.pmk63
62 files changed, 23191 insertions, 0 deletions
diff --git a/basctl/inc/basidesh.hrc b/basctl/inc/basidesh.hrc
new file mode 100644
index 000000000000..6cb846926e24
--- /dev/null
+++ b/basctl/inc/basidesh.hrc
@@ -0,0 +1,174 @@
+/*************************************************************************
+ *
+ * $RCSfile: basidesh.hrc,v $
+ *
+ * $Revision: 1.1.1.1 $
+ *
+ * last change: $Author: mh $ $Date: 2000-09-29 11:02:34 $
+ *
+ * The Contents of this file are made available subject to the terms of
+ * either of the following licenses
+ *
+ * - GNU Lesser General Public License Version 2.1
+ * - Sun Industry Standards Source License Version 1.1
+ *
+ * Sun Microsystems Inc., October, 2000
+ *
+ * GNU Lesser General Public License Version 2.1
+ * =============================================
+ * Copyright 2000 by Sun Microsystems, Inc.
+ * 901 San Antonio Road, Palo Alto, CA 94303, USA
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License version 2.1, as published by the Free Software Foundation.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this library; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston,
+ * MA 02111-1307 USA
+ *
+ *
+ * Sun Industry Standards Source License Version 1.1
+ * =================================================
+ * The contents of this file are subject to the Sun Industry Standards
+ * Source License Version 1.1 (the "License"); You may not use this file
+ * except in compliance with the License. You may obtain a copy of the
+ * License at http://www.openoffice.org/license.html.
+ *
+ * Software provided under this License is provided on an "AS IS" basis,
+ * WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING,
+ * WITHOUT LIMITATION, WARRANTIES THAT THE SOFTWARE IS FREE OF DEFECTS,
+ * MERCHANTABLE, FIT FOR A PARTICULAR PURPOSE, OR NON-INFRINGING.
+ * See the License for the specific provisions governing your rights and
+ * obligations concerning the Software.
+ *
+ * The Initial Developer of the Original Code is: Sun Microsystems, Inc.
+ *
+ * Copyright: 2000 by Sun Microsystems, Inc.
+ *
+ * All Rights Reserved.
+ *
+ * Contributor(s): _______________________________________
+ *
+ *
+ ************************************************************************/
+#ifndef _BASIDESH_HRC
+#define _BASIDESH_HRC
+
+#ifndef _SFX_HRC
+#include <sfx2/sfx.hrc>
+#endif
+
+#ifndef _SVX_SVXIDS_HRC
+#include <svx/svxids.hrc>
+#endif
+
+// #define SID_BASICIDE_START ( SID_OBJ3_START )
+
+// Resource-ID's...
+#ifndef _SVX_NOIDERESIDS
+
+#define RID_BASICIDE_OBJECTBAR ( RID_BASICIDE_START + 0 )
+
+#define RID_BMP_APPICON ( RID_BASICIDE_START + 1 )
+#define RID_BMP_BRKPNT0 ( RID_BASICIDE_START + 2 )
+#define RID_BMP_BRKPNT1 ( RID_BASICIDE_START + 3 )
+
+#define RID_EDT_WATCHEDIT ( RID_BASICIDE_START + 4 )
+#define RID_ICO_MDIWINDOW ( RID_BASICIDE_START + 5 )
+#define RID_IMG_MARKER ( RID_BASICIDE_START + 6 )
+#define RID_IMGLST_OBJECTS ( RID_BASICIDE_START + 7 )
+#define RID_IMGBTN_REMOVEWATCH ( RID_BASICIDE_START + 8 )
+#define RID_IMGBTN_GOTOCALL ( RID_BASICIDE_START + 9 )
+#define RID_POPUP_BRKDLG ( RID_BASICIDE_START + 10 )
+#define RID_POPUP_BRKPROPS ( RID_BASICIDE_START + 11 )
+#define RID_POPUP_TABBAR ( RID_BASICIDE_START + 12 )
+#define RID_TD_ORGANIZE ( RID_BASICIDE_START + 36 )
+#define RID_TP_MODULS ( RID_BASICIDE_START + 37 )
+#define RID_TP_LIBS ( RID_BASICIDE_START + 38 )
+#define RID_RES_CHECKBITMAPS ( RID_BASICIDE_START + 39 )
+#define RID_DLG_LIBS ( RID_BASICIDE_START + 40 )
+#define RID_IMG_LOCKED ( RID_BASICIDE_START + 41 )
+#define RID_DLG_NEWLIB ( RID_BASICIDE_START + 42 )
+
+#define RID_STR_CANNOTCLOSE ( RID_BASICIDE_START + 13 )
+#define RID_STR_IDENAME ( RID_BASICIDE_START + 14 )
+#define RID_STR_INITIDE ( RID_BASICIDE_START + 15 )
+#define RID_STR_STACKNAME ( RID_BASICIDE_START + 16 )
+#define RID_STR_WATCHNAME ( RID_BASICIDE_START + 17 )
+#define RID_STR_REMOVEWATCH ( RID_BASICIDE_START + 18 )
+#define RID_STR_OPEN ( RID_BASICIDE_START + 20 )
+#define RID_STR_SAVE ( RID_BASICIDE_START + 21 )
+#define RID_STR_RUNTIMEERROR ( RID_BASICIDE_START + 22 )
+#define RID_STR_COMPILEERROR ( RID_BASICIDE_START + 23 )
+#define RID_STR_STDDIALOGNAME ( RID_BASICIDE_START + 24 )
+#define RID_STR_STDMACRONAME ( RID_BASICIDE_START + 25 )
+#define RID_STR_STDJAVAFUNCTIONNAME ( RID_BASICIDE_START + 26 )
+#define RID_STR_STDMODULENAME ( RID_BASICIDE_START + 27 )
+#define RID_STR_ALL ( RID_BASICIDE_START + 28 )
+#define RID_STR_CLOSE ( RID_BASICIDE_START + 29 )
+#define RID_STR_PAGE ( RID_BASICIDE_START + 30 )
+#define RID_STR_BADSBXNAME ( RID_BASICIDE_START + 31 )
+#define RID_STR_STDLIBNAME ( RID_BASICIDE_START + 32 )
+#define RID_STR_ERROROPENSTORAGE ( RID_BASICIDE_START + 33 )
+#define RID_STR_NOLIBINSTORAGE ( RID_BASICIDE_START + 34 )
+#define RID_STR_SBXNAMEALLREADYUSED ( RID_BASICIDE_START + 35 )
+#define RID_STR_REPLACESTDLIB ( RID_BASICIDE_START + 41 )
+#define RID_STR_SBXNAMEALLREADYUSED2 ( RID_BASICIDE_START + 42 )
+#define RID_STR_SEARCHNOTFOUND ( RID_BASICIDE_START + 43 )
+#define RID_STR_SEARCHREPLACES ( RID_BASICIDE_START + 44 )
+#define RID_STR_CANNOTCHANGENAMESTDLIB ( RID_BASICIDE_START + 45 )
+#define RID_STR_CANNOTCHANGENAMEREFLIB ( RID_BASICIDE_START + 46 )
+#define RID_STR_CANNOTUNLOADSTDLIB ( RID_BASICIDE_START + 47 )
+#define RID_STR_GENERATESOURCE ( RID_BASICIDE_START + 48 )
+#define RID_STR_REFNOTPOSSIBLE ( RID_BASICIDE_START + 49 )
+#define RID_STR_FILEEXISTS ( RID_BASICIDE_START + 50 )
+#define RID_STR_ERROROPENLIB ( RID_BASICIDE_START + 55 )
+#define RID_STR_STDJAVAMODULENAME ( RID_BASICIDE_START + 56 )
+#define RID_STR_NEWLIB ( RID_BASICIDE_START + 57 )
+#define RID_STR_NEWMOD ( RID_BASICIDE_START + 58 )
+#define RID_STR_NEWDLG ( RID_BASICIDE_START + 59 )
+#define RID_STR_LIBNAMETOLONG ( RID_BASICIDE_START + 60 )
+
+#define RID_IMGLST_LAYOUT ( RID_BASICIDE_START + 49 )
+
+#define RID_STR_FILENAME ( RID_BASICIDE_START + 81 )
+#define RID_STR_APPENDLIBS ( RID_BASICIDE_START + 82 )
+#define RID_STR_QUERYDELMACRO ( RID_BASICIDE_START + 83 )
+#define RID_STR_QUERYDELDIALOG ( RID_BASICIDE_START + 84 )
+#define RID_STR_QUERYDELLIB ( RID_BASICIDE_START + 85 )
+#define RID_STR_QUERYDELLIBREF ( RID_BASICIDE_START + 86 )
+#define RID_STR_QUERYDELMODULE ( RID_BASICIDE_START + 87 )
+#define RID_STR_BASIC ( RID_BASICIDE_START + 88 )
+#define RID_STR_DOC ( RID_BASICIDE_START + 89 )
+#define RID_STR_MACRONAMEREQ ( RID_BASICIDE_START + 90 )
+#define RID_STR_WILLSTOPPRG ( RID_BASICIDE_START + 91 )
+#define RID_STR_STACK ( RID_BASICIDE_START + 92 )
+#define RID_STR_OBJNOTFOUND ( RID_BASICIDE_START + 93 )
+#define RID_STR_COULDNTREAD ( RID_BASICIDE_START + 94 )
+#define RID_STR_COULDNTWRITE ( RID_BASICIDE_START + 95 )
+#define RID_STR_WRONGPASSWORD ( RID_BASICIDE_START + 96 )
+#define RID_STR_LINE ( RID_BASICIDE_START + 97 )
+#define RID_STR_COLUMN ( RID_BASICIDE_START + 98 )
+#define RID_STR_SOURCETOBIG ( RID_BASICIDE_START + 99 )
+
+#define RID_STR_SEARCHALLMODULES ( RID_BASICIDE_START + 1 )
+#define RID_STR_SEARCHFROMSTART ( RID_BASICIDE_START + 2 )
+#define RID_STR_NOMODULE ( RID_BASICIDE_START + 3 )
+#define RID_STR_FILTER_ALLFILES ( RID_BASICIDE_START + 4 )
+
+// MacroDlg: ( RID_BASICIDE_START + 50 )
+// MacroOptionsDlg: ( RID_BASICIDE_START + 55 )
+// TbxControls: ( RID_BASICIDE_START + 65 )
+// ObjectDlg: ( RID_BASICIDE_START + 70 )
+// BreakPointDlg: ( RID_BASICIDE_START + 80 )
+
+#endif // _SVX_NOIDERESIDS
+
+#endif // _BASIDESH_HRC
diff --git a/basctl/inc/helpid.hrc b/basctl/inc/helpid.hrc
new file mode 100644
index 000000000000..b689975dfad7
--- /dev/null
+++ b/basctl/inc/helpid.hrc
@@ -0,0 +1,106 @@
+/*************************************************************************
+ *
+ * $RCSfile: helpid.hrc,v $
+ *
+ * $Revision: 1.1.1.1 $
+ *
+ * last change: $Author: mh $ $Date: 2000-09-29 11:02:34 $
+ *
+ * The Contents of this file are made available subject to the terms of
+ * either of the following licenses
+ *
+ * - GNU Lesser General Public License Version 2.1
+ * - Sun Industry Standards Source License Version 1.1
+ *
+ * Sun Microsystems Inc., October, 2000
+ *
+ * GNU Lesser General Public License Version 2.1
+ * =============================================
+ * Copyright 2000 by Sun Microsystems, Inc.
+ * 901 San Antonio Road, Palo Alto, CA 94303, USA
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License version 2.1, as published by the Free Software Foundation.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this library; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston,
+ * MA 02111-1307 USA
+ *
+ *
+ * Sun Industry Standards Source License Version 1.1
+ * =================================================
+ * The contents of this file are subject to the Sun Industry Standards
+ * Source License Version 1.1 (the "License"); You may not use this file
+ * except in compliance with the License. You may obtain a copy of the
+ * License at http://www.openoffice.org/license.html.
+ *
+ * Software provided under this License is provided on an "AS IS" basis,
+ * WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING,
+ * WITHOUT LIMITATION, WARRANTIES THAT THE SOFTWARE IS FREE OF DEFECTS,
+ * MERCHANTABLE, FIT FOR A PARTICULAR PURPOSE, OR NON-INFRINGING.
+ * See the License for the specific provisions governing your rights and
+ * obligations concerning the Software.
+ *
+ * The Initial Developer of the Original Code is: Sun Microsystems, Inc.
+ *
+ * Copyright: 2000 by Sun Microsystems, Inc.
+ *
+ * All Rights Reserved.
+ *
+ * Contributor(s): _______________________________________
+ *
+ *
+ ************************************************************************/
+#ifndef _BASCTL_HELPID_HRC
+#define _BASCTL_HELPID_HRC
+
+// include ---------------------------------------------------------------
+
+#include <svtools/solar.hrc>
+
+// Help-Ids --------------------------------------------------------------
+
+#define HID_BASICIDE_TOOLBOX (HID_BASICIDE_START + 0)
+#define HID_BASICIDE_OBJECTS (HID_BASICIDE_START + 1)
+#define HID_MACRO_OPTIONS (HID_BASICIDE_START + 2)
+#define HID_BASICIDE_BRKPNTS (HID_BASICIDE_START + 3)
+#define HID_BASICIDE_MODULS (HID_BASICIDE_START + 4)
+#define HID_BASICIDE_LIBS_TP (HID_BASICIDE_START + 5)
+#define HID_BASICIDE_LIBS_DLG (HID_BASICIDE_START + 6)
+#define HID_BASICIDE_CONTROLS (HID_BASICIDE_START + 7)
+#define HID_BASICIDE_MACROS (HID_BASICIDE_START + 8)
+#define HID_BASICIDE_LIBS (HID_BASICIDE_START + 9)
+#define HID_BASICIDE_ORG_TC (HID_BASICIDE_START + 10)
+
+#define HID_BASICIDE_MODULES_TREE (HID_BASICIDE_START + 11)
+#define HID_BASICIDE_LIBS_TREE (HID_BASICIDE_START + 12)
+#define HID_BASICIDE_LIBSDLG_TREE (HID_BASICIDE_START + 13)
+#define HID_BASICIDE_OBJECTCAT (HID_BASICIDE_START + 14)
+
+#define HID_BASICIDE_PROP_BROWSER (HID_BASICIDE_START + 15)
+
+#define HID_BASICIDE_PROP_BROWSER_LBOX (HID_BASICIDE_START + 16)
+
+#define HID_BASICIDE_OBJCAT_SHOW (HID_BASICIDE_START + 17)
+#define HID_BASICIDE_OBJCAT_PROPS (HID_BASICIDE_START + 18)
+#define HID_BASICIDE_OBJCAT_HELP (HID_BASICIDE_START + 19)
+
+#define HID_BASICIDE_BRKDLG (HID_BASICIDE_START + 20)
+#define HID_BASICIDE_ACTIV (HID_BASICIDE_START + 21)
+#define HID_BASICIDE_BRKPROPS (HID_BASICIDE_START + 22)
+#define HID_BASICIDE_REMOVEWATCH (HID_BASICIDE_START + 23)
+#define HID_BASICIDE_GOTOALL (HID_BASICIDE_START + 24)
+
+#define HID_BASICIDE_MODULWINDOW (HID_BASICIDE_START + 25)
+#define HID_BASICIDE_DIALOGWINDOW (HID_BASICIDE_START + 26)
+
+
+#endif
+
diff --git a/basctl/prj/d.lst b/basctl/prj/d.lst
new file mode 100644
index 000000000000..d76047571f53
--- /dev/null
+++ b/basctl/prj/d.lst
@@ -0,0 +1,27 @@
+touch: ..\inc\hid.lst %_DEST%\bin%_EXT%\hid.lst
+..\%__SRC%\inc\basslots.ilb %_DEST%\inc%_EXT%\basslots.ilb
+..\%__SRC%\inc\\*.ilb* %_DEST%\inc%_EXT%\*.ilb*
+..\%__SRC%\lib\lib*.* %_DEST%\lib%_EXT%\lib*.*
+..\%__SRC%\slb\basctl.lib %_DEST%\lib%_EXT%\xbasctl.lib
+..\%__SRC%\lib\basctl.lib %_DEST%\lib%_EXT%\basctl.lib
+..\%__SRC%\bin\basctl*.dll %_DEST%\bin%_EXT%\basctl*.dll
+..\%__SRC%\bin\basctl*.res %_DEST%\bin%_EXT%\basctl*.res
+..\%__SRC%\misc\basctl*.map %_DEST%\bin%_EXT%\basctl*.map
+..\%__SRC%\misc\basctl.csv %_DEST%\inc%_EXT%\basctl.csv
+..\%__SRC%\lib\basctl.lib %_DEST%\lib%_EXT%\basctl.lib
+
+del %_DEST%\inc%_EXT%\baside.hxx
+
+mkdir: %_DEST%\inc%_EXT%\basctl
+hedabu: ..\%__SRC%\inc\basslots.hxx %_DEST%\inc%_EXT%\basctl\basslots.hxx
+hedabu: ..\inc\basidesh.hxx %_DEST%\inc%_EXT%\basctl\basidesh.hxx
+hedabu: ..\inc\sidll.hxx %_DEST%\inc%_EXT%\basctl\sidll.hxx
+hedabu: ..\inc\vcattr.hxx %_DEST%\inc%_EXT%\basctl\vcattr.hxx
+hedabu: ..\inc\vcbrwwrp.hxx %_DEST%\inc%_EXT%\basctl\vcbrwwrp.hxx
+hedabu: ..\inc\vcsbxdef.hxx %_DEST%\inc%_EXT%\basctl\vcsbxdef.hxx
+hedabu: ..\inc\basobj.hxx %_DEST%\inc%_EXT%\basctl\basobj.hxx
+hedabu: ..\inc\basidesh.hrc %_DEST%\inc%_EXT%\basctl\basicide.hrc
+hedabu: ..\source\basicide\bastype2.hxx %_DEST%\inc%_EXT%\basctl\bastype2.hxx
+hedabu: ..\source\basicide\idetemp.hxx %_DEST%\inc%_EXT%\basctl\idetemp.hxx
+hedabu: ..\source\basicide\tbxctl.hxx %_DEST%\inc%_EXT%\basctl\btbxctl.hxx
+hedabu: ..\source\basicide\iderdll.hxx %_DEST%\inc%_EXT%\basctl\iderdll.hxx
diff --git a/basctl/sdi/baside.sdi b/basctl/sdi/baside.sdi
new file mode 100644
index 000000000000..de9e3d8c35ce
--- /dev/null
+++ b/basctl/sdi/baside.sdi
@@ -0,0 +1,434 @@
+import "svxslots.ilb"
+
+module
+"6706E0E7-FB05-101B-804c-04021c007002"
+"6806E0E7-FB05-101B-804c-04021c007002"
+BasicIDE
+[
+HelpText( "SFx --- BasicIDE" )
+SlotIdFile( "basidesh.hrc" )
+]
+{
+// item String SbxItem;
+// item String SvxSearchItem;
+// item String SvxSizeItem;
+/*
+ enum SvxChooseControlEnum
+ {
+ SVX_SNAP_PUSHBUTTON,
+ SVX_SNAP_CHECKBOX,
+ SVX_SNAP_RADIOBUTTON,
+ SVX_SNAP_SPINBUTTON,
+ SVX_SNAP_FIXEDTEXT,
+ SVX_SNAP_GROUPBOX,
+ SVX_SNAP_LISTBOX,
+ SVX_SNAP_COMBOBOX,
+ SVX_SNAP_EDIT,
+ SVX_SNAP_HSCROLLBAR,
+ SVX_SNAP_VSCROLLBAR,
+ SVX_SNAP_PREVIEW,
+ SVX_SNAP_SELECT,
+ SVX_SNAP_NOTHING
+ }
+ item SvxChooseControlEnum SvxChooseControlItem;
+*/
+ interface BasicIDEView: Object
+ [
+ uuid = "D88DF7A2-EE63-11d0-89CA-008029E4B0B1";
+ ]
+ {
+ }
+
+ shell BasicIDEShell
+ {
+ import BasicIDEView [Automation];
+
+ // ========================================================
+ // Current, je nach aktuellem Fenster:
+ // ========================================================
+ SID_BASICIDE_HIDECURPAGE
+ [
+ ExecMethod = ExecuteCurrent;
+ StateMethod = GetState;
+ ]
+
+ SID_BASICIDE_DELETECURRENT
+ [
+ ExecMethod = ExecuteCurrent;
+ StateMethod = GetState;
+ ]
+
+ SID_BASICIDE_RENAMECURRENT
+ [
+ ExecMethod = ExecuteCurrent;
+ StateMethod = GetState;
+ ]
+
+ SID_CUT
+ [
+ ExecMethod = ExecuteCurrent;
+ StateMethod = GetState;
+ ]
+
+ SID_COPY
+ [
+ ExecMethod = ExecuteCurrent;
+ StateMethod = GetState;
+ ]
+
+ SID_PASTE
+ [
+ ExecMethod = ExecuteCurrent;
+ StateMethod = GetState;
+ ]
+
+ SID_UNDO
+ [
+ ExecMethod = ExecuteCurrent;
+ StateMethod = GetState;
+ ]
+
+ SID_REDO
+ [
+ ExecMethod = ExecuteCurrent;
+ StateMethod = GetState;
+ ]
+
+ SID_DELETE
+ [
+ ExecMethod = ExecuteCurrent;
+ StateMethod = GetState;
+ ]
+
+ SID_BACKSPACE
+ [
+ ExecMethod = ExecuteCurrent;
+ StateMethod = GetState;
+ ]
+
+ SID_SEARCH_OPTIONS
+ [
+ ExecMethod = ExecuteCurrent;
+ StateMethod = GetState;
+ ]
+
+ SID_SEARCH_ITEM
+ [
+ ExecMethod = ExecuteCurrent;
+ StateMethod = GetState;
+ ]
+
+ FID_SEARCH_NOW
+ [
+ ExecMethod = ExecuteCurrent;
+ StateMethod = GetState;
+ ]
+
+ // ========================================================
+ // Gloabl: Egal, welches Fenster gerade aktiv ist:
+ // ========================================================
+ SID_BASICIDE_LIBSELECTOR
+ [
+ ExecMethod = ExecuteGlobal;
+ StateMethod = GetState;
+ ]
+
+ SID_BASICIDE_LIBSELECTED
+ [
+ ExecMethod = ExecuteGlobal;
+ StateMethod = GetState;
+ ]
+
+ SID_BASICIDE_LIBLOADED
+ [
+ ExecMethod = ExecuteGlobal;
+ StateMethod = GetState;
+ ]
+
+ SID_BASICIDE_LIBREMOVED
+ [
+ ExecMethod = ExecuteGlobal;
+ StateMethod = GetState;
+ ]
+
+ SID_BASICIDE_SBXDELETED
+ [
+ ExecMethod = ExecuteGlobal;
+ StateMethod = GetState;
+ ]
+
+ SID_BASICIDE_SBXINSERTED
+ [
+ ExecMethod = ExecuteGlobal;
+ StateMethod = GetState;
+ ]
+
+ SID_BASICIDE_SBXRENAMED
+ [
+ ExecMethod = ExecuteGlobal;
+ StateMethod = GetState;
+ ]
+
+ SID_BASICIDE_SHOWSBX
+ [
+ ExecMethod = ExecuteGlobal;
+ StateMethod = GetState;
+ ]
+
+ SID_NEWWINDOW
+ [
+ ExecMethod = ExecuteGlobal;
+ StateMethod = GetState;
+ ]
+
+ SID_DOCINFO
+ [
+ ExecMethod = ExecuteGlobal;
+ StateMethod = GetState;
+ ]
+
+ SID_SAVEDOC
+ [
+ ExecMethod = ExecuteGlobal;
+ StateMethod = GetState;
+ ]
+
+ SID_SAVEASDOC
+ [
+ ExecMethod = ExecuteGlobal;
+ StateMethod = GetState;
+ ]
+
+ // Ab hier normal...
+ SID_BASICIDE_CHOOSEMACRO
+ [
+ ExecMethod = ExecuteGlobal;
+ StateMethod = GetState;
+ ]
+
+ SID_BASICIDE_MODULEDLG
+ [
+ ExecMethod = ExecuteGlobal;
+ StateMethod = GetState;
+ ]
+
+ SID_BASICIDE_OBJCAT
+ [
+ ExecMethod = ExecuteGlobal;
+ StateMethod = GetState;
+ ]
+
+ SID_BASICIDE_CREATEMACRO
+ [
+ ExecMethod = ExecuteGlobal;
+ StateMethod = GetState;
+ ]
+
+ SID_BASICIDE_EDITMACRO
+ [
+ ExecMethod = ExecuteGlobal;
+ StateMethod = GetState;
+ ]
+
+ SID_BASICIDE_NAMECHANGEDONTAB
+ [
+ ExecMethod = ExecuteGlobal;
+ StateMethod = GetState;
+ ]
+
+ SID_BASICIDE_STOREMODULESOURCE
+ [
+ ExecMethod = ExecuteGlobal;
+ StateMethod = GetState;
+ ]
+
+ SID_BASICIDE_STOREALLMODULESOURCES
+ [
+ ExecMethod = ExecuteGlobal;
+ StateMethod = GetState;
+ ]
+
+ SID_BASICIDE_UPDATEMODULESOURCE
+ [
+ ExecMethod = ExecuteGlobal;
+ StateMethod = GetState;
+ ]
+
+ SID_BASICIDE_UPDATEALLMODULESOURCES
+ [
+ ExecMethod = ExecuteGlobal;
+ StateMethod = GetState;
+ ]
+
+ SID_BASICSTOP
+ [
+ ExecMethod = ExecuteGlobal;
+ StateMethod = GetState;
+ ]
+
+ SID_BASICIDE_NEWMODULE
+ [
+ ExecMethod = ExecuteGlobal;
+ StateMethod = GetState;
+ ]
+
+ SID_BASICIDE_NEWJAVAMODULE
+ [
+ ExecMethod = ExecuteGlobal;
+ StateMethod = GetState;
+ ]
+
+ SID_BASICIDE_NEWDIALOG
+ [
+ ExecMethod = ExecuteGlobal;
+ StateMethod = GetState;
+ ]
+
+ // ========================================================
+ // Nur, wenn BasicFenster oben
+ // ========================================================
+ SID_BASICRUN
+ [
+ ExecMethod = ExecuteBasic;
+ StateMethod = GetState;
+ ]
+
+ SID_BASICCOMPILE
+ [
+ ExecMethod = ExecuteBasic;
+ StateMethod = GetState;
+ ]
+
+ SID_BASICLOAD
+ [
+ ExecMethod = ExecuteBasic;
+ StateMethod = GetState;
+ ]
+
+ SID_BASICSAVEAS
+ [
+ ExecMethod = ExecuteBasic;
+ StateMethod = GetState;
+ ]
+
+ SID_BASICIDE_MATCHGROUP
+ [
+ ExecMethod = ExecuteBasic;
+ StateMethod = GetState;
+ ]
+
+ SID_BASICSTEPINTO
+ [
+ ExecMethod = ExecuteBasic;
+ StateMethod = GetState;
+ ]
+
+ SID_BASICSTEPOVER
+ [
+ ExecMethod = ExecuteBasic;
+ StateMethod = GetState;
+ ]
+
+ SID_BASICSTEPOUT
+ [
+ ExecMethod = ExecuteBasic;
+ StateMethod = GetState;
+ ]
+
+ SID_BASICIDE_TOGGLEBRKPNT
+ [
+ ExecMethod = ExecuteBasic;
+ StateMethod = GetState;
+ ]
+
+ SID_BASICIDE_ADDWATCH
+ [
+ ExecMethod = ExecuteBasic;
+ StateMethod = GetState;
+ ]
+
+ SID_BASICIDE_REMOVEWATCH
+ [
+ ExecMethod = ExecuteBasic;
+ StateMethod = GetState;
+ ]
+
+ SID_BASICIDE_BRKPNTSCHANGED
+ [
+ ExecMethod = ExecuteBasic;
+ StateMethod = GetState;
+ ]
+
+ // ========================================================
+ // Nur, wenn Dialogfenster oben
+ // ========================================================
+ SID_CHOOSE_CONTROLS
+ [
+ PseudoSlots = TRUE; // Enum-Slots automatisch erzeugen
+ PseudoPrefix = SID_INSERT;
+ ExecMethod = ExecuteDialog;
+ StateMethod = GetState;
+ ]
+
+ SID_DIALOG_TESTMODE
+ [
+ ExecMethod = ExecuteDialog;
+ StateMethod = GetState;
+ ]
+
+ SID_SHOW_HIDDEN
+ [
+ ExecMethod = ExecuteDialog;
+ StateMethod = GetState;
+ ]
+
+ SID_SHOW_FORMS
+ [
+ ExecMethod = ExecuteDialog;
+ StateMethod = GetState;
+ ]
+
+ SID_BASICIDE_STAT_POS
+ [
+ StateMethod = GetState;
+ ]
+
+ SID_BASICIDE_STAT_DATE
+ [
+ StateMethod = GetState;
+ ]
+
+ SID_BASICIDE_STAT_TITLE
+ [
+ StateMethod = GetState;
+ ]
+
+ SID_DOC_MODIFIED
+ [
+ StateMethod = GetState;
+ ]
+
+ SID_ATTR_INSERT
+ [
+ StateMethod = GetState;
+ ]
+
+ SID_ATTR_SIZE
+ [
+ StateMethod = GetState;
+ ]
+ }
+
+ interface BasicIDEDocument: Object
+ [
+ uuid = "D88DF7A1-EE63-11d0-89CA-008029E4B0B1";
+ ]
+ {
+ }
+
+ shell BasicDocShell
+ {
+ import BasicIDEDocument [Automation];
+ }
+}
+
diff --git a/basctl/sdi/basslots.hrc b/basctl/sdi/basslots.hrc
new file mode 100644
index 000000000000..e8f12220bf11
--- /dev/null
+++ b/basctl/sdi/basslots.hrc
@@ -0,0 +1,64 @@
+/*************************************************************************
+ *
+ * $RCSfile: basslots.hrc,v $
+ *
+ * $Revision: 1.1.1.1 $
+ *
+ * last change: $Author: mh $ $Date: 2000-09-29 11:02:35 $
+ *
+ * The Contents of this file are made available subject to the terms of
+ * either of the following licenses
+ *
+ * - GNU Lesser General Public License Version 2.1
+ * - Sun Industry Standards Source License Version 1.1
+ *
+ * Sun Microsystems Inc., October, 2000
+ *
+ * GNU Lesser General Public License Version 2.1
+ * =============================================
+ * Copyright 2000 by Sun Microsystems, Inc.
+ * 901 San Antonio Road, Palo Alto, CA 94303, USA
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License version 2.1, as published by the Free Software Foundation.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this library; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston,
+ * MA 02111-1307 USA
+ *
+ *
+ * Sun Industry Standards Source License Version 1.1
+ * =================================================
+ * The contents of this file are subject to the Sun Industry Standards
+ * Source License Version 1.1 (the "License"); You may not use this file
+ * except in compliance with the License. You may obtain a copy of the
+ * License at http://www.openoffice.org/license.html.
+ *
+ * Software provided under this License is provided on an "AS IS" basis,
+ * WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING,
+ * WITHOUT LIMITATION, WARRANTIES THAT THE SOFTWARE IS FREE OF DEFECTS,
+ * MERCHANTABLE, FIT FOR A PARTICULAR PURPOSE, OR NON-INFRINGING.
+ * See the License for the specific provisions governing your rights and
+ * obligations concerning the Software.
+ *
+ * The Initial Developer of the Original Code is: Sun Microsystems, Inc.
+ *
+ * Copyright: 2000 by Sun Microsystems, Inc.
+ *
+ * All Rights Reserved.
+ *
+ * Contributor(s): _______________________________________
+ *
+ *
+ ************************************************************************/
+#include <sfx2/sfx.hrc>
+#include <svx/svxids.hrc>
+#include <sfx2/sfxsids.hrc>
+
diff --git a/basctl/sdi/basslots.sdi b/basctl/sdi/basslots.sdi
new file mode 100644
index 000000000000..ee8adb230401
--- /dev/null
+++ b/basctl/sdi/basslots.sdi
@@ -0,0 +1,18 @@
+import "sfxslots.ilb"
+
+module
+"BD25A480-30AB-101C-A17D-000024021828"
+"C049C7E0-30AB-101C-A17D-000024021828"
+BasItems
+[
+HelpText( "Bas-Items" )
+SlotIdFile( "basslots.hrc" )
+TypeLibFile( "basslots.tlb" )
+]
+{
+ //=========================================================================
+
+// include "baside.sdi"
+
+}
+
diff --git a/basctl/sdi/makefile.mk b/basctl/sdi/makefile.mk
new file mode 100644
index 000000000000..dfd9c4f63b53
--- /dev/null
+++ b/basctl/sdi/makefile.mk
@@ -0,0 +1,88 @@
+#*************************************************************************
+#
+# $RCSfile: makefile.mk,v $
+#
+# $Revision: 1.1.1.1 $
+#
+# last change: $Author: mh $ $Date: 2000-09-29 11:02:35 $
+#
+# The Contents of this file are made available subject to the terms of
+# either of the following licenses
+#
+# - GNU Lesser General Public License Version 2.1
+# - Sun Industry Standards Source License Version 1.1
+#
+# Sun Microsystems Inc., October, 2000
+#
+# GNU Lesser General Public License Version 2.1
+# =============================================
+# Copyright 2000 by Sun Microsystems, Inc.
+# 901 San Antonio Road, Palo Alto, CA 94303, USA
+#
+# This library is free software; you can redistribute it and/or
+# modify it under the terms of the GNU Lesser General Public
+# License version 2.1, as published by the Free Software Foundation.
+#
+# This library is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+# Lesser General Public License for more details.
+#
+# You should have received a copy of the GNU Lesser General Public
+# License along with this library; if not, write to the Free Software
+# Foundation, Inc., 59 Temple Place, Suite 330, Boston,
+# MA 02111-1307 USA
+#
+#
+# Sun Industry Standards Source License Version 1.1
+# =================================================
+# The contents of this file are subject to the Sun Industry Standards
+# Source License Version 1.1 (the "License"); You may not use this file
+# except in compliance with the License. You may obtain a copy of the
+# License at http://www.openoffice.org/license.html.
+#
+# Software provided under this License is provided on an "AS IS" basis,
+# WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING,
+# WITHOUT LIMITATION, WARRANTIES THAT THE SOFTWARE IS FREE OF DEFECTS,
+# MERCHANTABLE, FIT FOR A PARTICULAR PURPOSE, OR NON-INFRINGING.
+# See the License for the specific provisions governing your rights and
+# obligations concerning the Software.
+#
+# The Initial Developer of the Original Code is: Sun Microsystems, Inc.
+#
+# Copyright: 2000 by Sun Microsystems, Inc.
+#
+# All Rights Reserved.
+#
+# Contributor(s): _______________________________________
+#
+#
+#
+#*************************************************************************
+
+
+PRJ=..
+
+PRJNAME=basctl
+TARGET=basslots
+#SDIEXPORT=svxnew
+
+# --- Settings -----------------------------------------------------
+
+.INCLUDE : svpre.mk
+.INCLUDE : settings.mk
+.INCLUDE : sv.mk
+
+SDINAME=$(TARGET)
+SDI1NAME=baside
+
+# --- Files --------------------------------------------------------
+
+#SRS1NAME=enumslot
+#SRC1FILES=enumslot.src
+
+
+# --- Targets -------------------------------------------------------
+
+.INCLUDE : target.mk
+
diff --git a/basctl/source/basicide/basdoc.cxx b/basctl/source/basicide/basdoc.cxx
new file mode 100644
index 000000000000..c65df66ffc77
--- /dev/null
+++ b/basctl/source/basicide/basdoc.cxx
@@ -0,0 +1,181 @@
+/*************************************************************************
+ *
+ * $RCSfile: basdoc.cxx,v $
+ *
+ * $Revision: 1.1.1.1 $
+ *
+ * last change: $Author: mh $ $Date: 2000-09-29 11:02:35 $
+ *
+ * The Contents of this file are made available subject to the terms of
+ * either of the following licenses
+ *
+ * - GNU Lesser General Public License Version 2.1
+ * - Sun Industry Standards Source License Version 1.1
+ *
+ * Sun Microsystems Inc., October, 2000
+ *
+ * GNU Lesser General Public License Version 2.1
+ * =============================================
+ * Copyright 2000 by Sun Microsystems, Inc.
+ * 901 San Antonio Road, Palo Alto, CA 94303, USA
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License version 2.1, as published by the Free Software Foundation.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this library; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston,
+ * MA 02111-1307 USA
+ *
+ *
+ * Sun Industry Standards Source License Version 1.1
+ * =================================================
+ * The contents of this file are subject to the Sun Industry Standards
+ * Source License Version 1.1 (the "License"); You may not use this file
+ * except in compliance with the License. You may obtain a copy of the
+ * License at http://www.openoffice.org/license.html.
+ *
+ * Software provided under this License is provided on an "AS IS" basis,
+ * WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING,
+ * WITHOUT LIMITATION, WARRANTIES THAT THE SOFTWARE IS FREE OF DEFECTS,
+ * MERCHANTABLE, FIT FOR A PARTICULAR PURPOSE, OR NON-INFRINGING.
+ * See the License for the specific provisions governing your rights and
+ * obligations concerning the Software.
+ *
+ * The Initial Developer of the Original Code is: Sun Microsystems, Inc.
+ *
+ * Copyright: 2000 by Sun Microsystems, Inc.
+ *
+ * All Rights Reserved.
+ *
+ * Contributor(s): _______________________________________
+ *
+ *
+ ************************************************************************/
+
+
+#include <ide_pch.hxx>
+
+#pragma hdrstop
+
+#define GLOBALOVERFLOW2
+
+#include <sfx2/docfac.hxx>
+
+#ifndef _SV_STATUS_HXX //autogen
+#include <vcl/status.hxx>
+#endif
+
+#include <basdoc.hxx>
+#include <basidesh.hrc>
+
+#define BasicDocShell
+#include <baside.hxx>
+
+
+SFX_IMPL_SIMPLE_OBJECTFACTORY( BasicDocShell, SFXOBJECTSHELL_STD_SPECIAL | SFXOBJECTSHELL_DONTREPLACE, side3 )
+{
+ Factory().SetExplorerImageId( IMG_SFX_EXP_MACROLIB );
+ Factory().RegisterHelpFile( String( RTL_CONSTASCII_USTRINGPARAM( "sbasic" ) ) );
+}
+
+
+SFX_IMPL_INTERFACE( BasicDocShell, SfxObjectShell, IDEResId( 0 ) )
+{
+ SFX_STATUSBAR_REGISTRATION( SID_BASICIDE_STATUSBAR );
+// SFX_CHILDWINDOW_REGISTRATION( SID_SHOW_BROWSER );
+}
+
+
+
+BasicDocShell::BasicDocShell( SfxObjectCreateMode eMode ) : SfxObjectShell( eMode )
+{
+ pPrinter = 0;
+ SetPool( &SFX_APP()->GetPool() );
+}
+
+
+
+
+__EXPORT BasicDocShell::~BasicDocShell()
+{
+ delete pPrinter;
+}
+
+
+
+
+void __EXPORT BasicDocShell::Execute( SfxRequest& rReq )
+{
+}
+
+
+
+
+void __EXPORT BasicDocShell::GetState(SfxItemSet &rSet)
+{
+}
+
+
+
+
+SfxPrinter* BasicDocShell::GetPrinter( BOOL bCreate )
+{
+ if ( !pPrinter && bCreate )
+ pPrinter = new SfxPrinter( new SfxItemSet( GetPool(), SID_PRINTER_NOTFOUND_WARN , SID_PRINTER_NOTFOUND_WARN ) );
+
+ return pPrinter;
+}
+
+
+
+
+void BasicDocShell::SetPrinter( SfxPrinter* pPr )
+{
+ if ( pPr != pPrinter )
+ {
+ delete pPrinter;
+ pPrinter = pPr;
+ }
+}
+
+
+void BasicDocShell::FillStatusBar( StatusBar& rStatusBar )
+{
+ String aTmp;
+
+ // Titel
+ aTmp.Fill( 30, 'X' );
+ rStatusBar.InsertItem( SID_BASICIDE_STAT_TITLE,
+ rStatusBar.GetTextWidth( aTmp ), SIB_AUTOSIZE | SIB_LEFT);
+
+ // Modify
+ rStatusBar.InsertItem( SID_DOC_MODIFIED,
+ rStatusBar.GetTextWidth( '*' ) );
+
+ // Position
+ aTmp.Erase();
+ aTmp.Fill( 15, 'X' );
+ rStatusBar.InsertItem( SID_BASICIDE_STAT_POS,
+ rStatusBar.GetTextWidth( aTmp ), SIB_LEFT);
+
+ // Insert/Overwrite
+ rStatusBar.InsertItem( SID_ATTR_INSERT,
+ rStatusBar.GetTextWidth( String( RTL_CONSTASCII_USTRINGPARAM( "XXXXX" /* "EINFG" */ ) ) ) );
+
+ // Uhrzeit
+ aTmp.Fill( 20, 'X' );
+ rStatusBar.InsertItem( SID_ATTR_SIZE,
+ rStatusBar.GetTextWidth( aTmp ), SIB_AUTOSIZE | SIB_LEFT | SIB_USERDRAW );
+
+// return pStatusBar;
+
+}
+
+
diff --git a/basctl/source/basicide/basdoc.hxx b/basctl/source/basicide/basdoc.hxx
new file mode 100644
index 000000000000..a03eeeb59f08
--- /dev/null
+++ b/basctl/source/basicide/basdoc.hxx
@@ -0,0 +1,96 @@
+/*************************************************************************
+ *
+ * $RCSfile: basdoc.hxx,v $
+ *
+ * $Revision: 1.1.1.1 $
+ *
+ * last change: $Author: mh $ $Date: 2000-09-29 11:02:35 $
+ *
+ * The Contents of this file are made available subject to the terms of
+ * either of the following licenses
+ *
+ * - GNU Lesser General Public License Version 2.1
+ * - Sun Industry Standards Source License Version 1.1
+ *
+ * Sun Microsystems Inc., October, 2000
+ *
+ * GNU Lesser General Public License Version 2.1
+ * =============================================
+ * Copyright 2000 by Sun Microsystems, Inc.
+ * 901 San Antonio Road, Palo Alto, CA 94303, USA
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License version 2.1, as published by the Free Software Foundation.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this library; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston,
+ * MA 02111-1307 USA
+ *
+ *
+ * Sun Industry Standards Source License Version 1.1
+ * =================================================
+ * The contents of this file are subject to the Sun Industry Standards
+ * Source License Version 1.1 (the "License"); You may not use this file
+ * except in compliance with the License. You may obtain a copy of the
+ * License at http://www.openoffice.org/license.html.
+ *
+ * Software provided under this License is provided on an "AS IS" basis,
+ * WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING,
+ * WITHOUT LIMITATION, WARRANTIES THAT THE SOFTWARE IS FREE OF DEFECTS,
+ * MERCHANTABLE, FIT FOR A PARTICULAR PURPOSE, OR NON-INFRINGING.
+ * See the License for the specific provisions governing your rights and
+ * obligations concerning the Software.
+ *
+ * The Initial Developer of the Original Code is: Sun Microsystems, Inc.
+ *
+ * Copyright: 2000 by Sun Microsystems, Inc.
+ *
+ * All Rights Reserved.
+ *
+ * Contributor(s): _______________________________________
+ *
+ *
+ ************************************************************************/
+
+#ifndef _BASDOC_HXX
+#define _BASDOC_HXX
+
+#include <svx/ifaceids.hxx>
+#include <iderid.hxx>
+
+#ifndef _SFX_OBJSH_HXX //autogen
+#include <sfx2/objsh.hxx>
+#endif
+
+
+class SfxPrinter;
+
+class BasicDocShell: public SfxObjectShell
+{
+ SfxPrinter* pPrinter;
+
+protected:
+ virtual void FillStatusBar( StatusBar& rBar);
+
+
+public:
+ SFX_DECL_SIMPLE_OBJECTFACTORY( BasicDocShell );
+ SFX_DECL_INTERFACE( SVX_INTERFACE_BASIDE_DOCSH );
+ BasicDocShell( SfxObjectCreateMode eMode = SFX_CREATE_MODE_STANDARD );
+ ~BasicDocShell();
+
+ void Execute( SfxRequest& rReq );
+ void GetState( SfxItemSet& rSet );
+
+ SfxPrinter* GetPrinter( BOOL bCreate );
+ void SetPrinter( SfxPrinter* pPrinter );
+};
+
+#endif // _BASDOC_HXX
diff --git a/basctl/source/basicide/basicbox.cxx b/basctl/source/basicide/basicbox.cxx
new file mode 100644
index 000000000000..db553aed4f77
--- /dev/null
+++ b/basctl/source/basicide/basicbox.cxx
@@ -0,0 +1,326 @@
+/*************************************************************************
+ *
+ * $RCSfile: basicbox.cxx,v $
+ *
+ * $Revision: 1.1.1.1 $
+ *
+ * last change: $Author: mh $ $Date: 2000-09-29 11:02:35 $
+ *
+ * The Contents of this file are made available subject to the terms of
+ * either of the following licenses
+ *
+ * - GNU Lesser General Public License Version 2.1
+ * - Sun Industry Standards Source License Version 1.1
+ *
+ * Sun Microsystems Inc., October, 2000
+ *
+ * GNU Lesser General Public License Version 2.1
+ * =============================================
+ * Copyright 2000 by Sun Microsystems, Inc.
+ * 901 San Antonio Road, Palo Alto, CA 94303, USA
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License version 2.1, as published by the Free Software Foundation.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this library; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston,
+ * MA 02111-1307 USA
+ *
+ *
+ * Sun Industry Standards Source License Version 1.1
+ * =================================================
+ * The contents of this file are subject to the Sun Industry Standards
+ * Source License Version 1.1 (the "License"); You may not use this file
+ * except in compliance with the License. You may obtain a copy of the
+ * License at http://www.openoffice.org/license.html.
+ *
+ * Software provided under this License is provided on an "AS IS" basis,
+ * WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING,
+ * WITHOUT LIMITATION, WARRANTIES THAT THE SOFTWARE IS FREE OF DEFECTS,
+ * MERCHANTABLE, FIT FOR A PARTICULAR PURPOSE, OR NON-INFRINGING.
+ * See the License for the specific provisions governing your rights and
+ * obligations concerning the Software.
+ *
+ * The Initial Developer of the Original Code is: Sun Microsystems, Inc.
+ *
+ * Copyright: 2000 by Sun Microsystems, Inc.
+ *
+ * All Rights Reserved.
+ *
+ * Contributor(s): _______________________________________
+ *
+ *
+ ************************************************************************/
+
+#include <ide_pch.hxx>
+
+#pragma hdrstop
+
+#include <basidesh.hrc>
+#define _SVSTDARR_STRINGS
+#include <svtools/svstdarr.hxx>
+#include <basobj.hxx>
+
+#include <basicbox.hxx>
+#include <iderid.hxx>
+#include <bastypes.hxx>
+
+SFX_IMPL_TOOLBOX_CONTROL( LibBoxControl, SfxStringItem );
+
+LibBoxControl::LibBoxControl( USHORT nId, ToolBox& rTbx, SfxBindings& rBind )
+ : SfxToolBoxControl( nId, rTbx, rBind )
+{
+}
+
+
+
+LibBoxControl::~LibBoxControl()
+{
+}
+
+
+
+void LibBoxControl::StateChanged( USHORT nSID, SfxItemState eState, const SfxPoolItem* pState )
+{
+ BasicLibBox* pBox = (BasicLibBox*) GetToolBox().GetItemWindow( GetId() );
+
+ DBG_ASSERT( pBox, "Box not found" );
+ if ( !pBox )
+ return;
+
+ if ( eState != SFX_ITEM_AVAILABLE )
+ pBox->Disable();
+ else
+ {
+ pBox->Enable();
+
+ if ( pState->ISA(SfxStringItem) )
+ pBox->Update( (const SfxStringItem*)pState );
+ else
+ pBox->Update( NULL );
+ }
+}
+
+
+
+Window* LibBoxControl::CreateItemWindow( Window *pParent )
+{
+ return new BasicLibBox( pParent );
+}
+
+
+
+
+
+BasicLibBox::BasicLibBox( Window* pParent ) :
+ ListBox( pParent, WinBits( WB_BORDER | WB_DROPDOWN ) )
+{
+ FillBox();
+ bIgnoreSelect = TRUE; // Select von 0 noch nicht weiterleiten
+ bFillBox = TRUE;
+ SelectEntryPos( 0 );
+ aCurText = GetEntry( 0 );
+ SetSizePixel( Size( 165, 200 ) );
+ bIgnoreSelect = FALSE;
+ StartListening( *SFX_APP(), TRUE /* Nur einmal anmelden */ );
+}
+
+
+
+__EXPORT BasicLibBox::~BasicLibBox()
+{
+}
+
+void __EXPORT BasicLibBox::Update( const SfxStringItem* pItem )
+{
+ // Immer auf dem laufenden sein...
+// if ( !pItem || !pItem->GetValue().Len() )
+ FillBox();
+
+ if ( pItem )
+ {
+ aCurText = pItem->GetValue();
+ if ( aCurText.Len() == 0 )
+ aCurText = String( IDEResId( RID_STR_ALL ) );
+ }
+
+ if ( GetSelectEntry() != aCurText )
+ SelectEntry( aCurText );
+}
+
+void __EXPORT BasicLibBox::ReleaseFocus()
+{
+ SfxViewShell* pCurSh = SfxViewShell::Current();
+ DBG_ASSERT( pCurSh, "Current ViewShell not found!" );
+
+ if ( pCurSh )
+ {
+ Window* pShellWin = pCurSh->GetWindow();
+ if ( !pShellWin ) // sonst werde ich ihn nicht los
+ pShellWin = Application::GetDefModalDialogParent();
+
+ pShellWin->GrabFocus();
+ }
+}
+
+
+
+void __EXPORT BasicLibBox::SFX_NOTIFY( SfxBroadcaster& rBC, const TypeId&,
+ const SfxHint& rHint, const TypeId& )
+{
+ if ( rHint.IsA( TYPE( SfxEventHint ) ) )
+ {
+ if ( ( ((SfxEventHint&)rHint).GetEventId() == SFX_EVENT_CREATEDOC ) ||
+ ( ((SfxEventHint&)rHint).GetEventId() == SFX_EVENT_OPENDOC ) )
+ {
+ FillBox(); // IDE reagiert selbst, wenn == aktuelle Lib
+ }
+ else if ( ((SfxEventHint&)rHint).GetEventId() == SFX_EVENT_SAVEASDOC )
+ {
+ // Wenn das aktuell angezeigte Doc umbenannt wird...
+ // Funktioniert nicht, da ich den alten Namen nicht bekomme
+// String aCurLib( GetLibFromMgrAndLib( aCurText ) );
+// String aCurMgr( GetMgrFromMgrAndLib( aCurText ) );
+// String aCurDoc = SfxObjectShell::Current()->GetTitle();
+// if ( aCurMgr == aCurDoc )
+// {
+// FillBox( FALSE );
+// aCurText = CreateMgrAndLibStr( aCurDoc, aCurLib );
+// bIgnoreSelect = TRUE;
+// SelectEntry( aCurText );
+// InfoBox( 0, aCurText ).Execute();
+// bIgnoreSelect = FALSE;
+// }
+// else
+ FillBox( TRUE );
+
+ }
+ else if ( ((SfxEventHint&)rHint).GetEventId() == SFX_EVENT_CLOSEDOC )
+ {
+ if ( SFX_APP()->IsInBasicCall() ) // Nicht wenn Office beendet
+ FillBox();
+ }
+ }
+}
+
+
+
+void BasicLibBox::FillBox( BOOL bSelect )
+{
+ SetUpdateMode( FALSE );
+ bIgnoreSelect = TRUE;
+
+ aCurText = GetSelectEntry();
+ USHORT nCurPos = GetSelectEntryPos();
+
+ SelectEntryPos( 0 );
+ Clear();
+
+ SvStrings* pStrings = BasicIDE::CreateBasicLibBoxEntries();
+ for ( USHORT n = 0; n < pStrings->Count(); n++ )
+ {
+ String* pStr = pStrings->GetObject( n );
+ InsertEntry( *pStr, LISTBOX_APPEND );
+ }
+ pStrings->DeleteAndDestroy( 0, pStrings->Count() );
+ delete pStrings;
+
+ SetUpdateMode( TRUE );
+
+ if ( bSelect )
+ {
+ SelectEntry( aCurText );
+ if ( !GetSelectEntryCount() )
+ {
+ SelectEntryPos( GetEntryCount() ); // gibst es nicht => leer?
+ aCurText = GetSelectEntry();
+ }
+ }
+ bIgnoreSelect = FALSE;
+}
+
+long BasicLibBox::PreNotify( NotifyEvent& rNEvt )
+{
+ long nDone = 0;
+ if( rNEvt.GetType() == EVENT_KEYINPUT )
+ {
+ KeyEvent aKeyEvt = *rNEvt.GetKeyEvent();
+ USHORT nKeyCode = aKeyEvt.GetKeyCode().GetCode();
+ switch( nKeyCode )
+ {
+ case KEY_RETURN:
+ {
+ NotifyIDE();
+ nDone = 1;
+ }
+ break;
+
+ case KEY_ESCAPE:
+ {
+ SelectEntry( aCurText );
+ ReleaseFocus();
+ nDone = 1;
+ }
+ break;
+ }
+ }
+ else if( rNEvt.GetType() == EVENT_GETFOCUS )
+ {
+ if ( bFillBox )
+ {
+ FillBox();
+ bFillBox = FALSE;
+ }
+ }
+ else if( rNEvt.GetType() == EVENT_LOSEFOCUS )
+ {
+ if ( !HasChildPathFocus( TRUE ) )
+ {
+ bIgnoreSelect = TRUE;
+ bFillBox = TRUE;
+ }
+ }
+
+ return nDone ? nDone : ListBox::PreNotify( rNEvt );
+}
+
+void __EXPORT BasicLibBox::Select()
+{
+ if ( !IsTravelSelect() )
+ {
+ if ( !bIgnoreSelect )
+ NotifyIDE();
+ else
+ SelectEntry( aCurText ); // Seit 306... (Select nach Escape)
+ }
+}
+
+
+
+void BasicLibBox::NotifyIDE()
+{
+ String aLib;
+ if ( GetSelectEntryPos() )
+ aLib = GetSelectEntry();
+
+ SfxStringItem aLibName( SID_BASICIDE_ARG_LIBNAME, aLib );
+ SfxViewFrame* pCurFrame = SfxViewFrame::Current();
+ DBG_ASSERT( pCurFrame != NULL, "No current view frame!" );
+ SfxDispatcher* pDispatcher = pCurFrame ? pCurFrame->GetDispatcher() : NULL;
+ if( pDispatcher )
+ {
+ pDispatcher->Execute( SID_BASICIDE_LIBSELECTED,
+ SFX_CALLMODE_SYNCHRON, &aLibName, 0L );
+ }
+ ReleaseFocus();
+}
+
+
+
diff --git a/basctl/source/basicide/basicbox.hxx b/basctl/source/basicide/basicbox.hxx
new file mode 100644
index 000000000000..4d9c4ad86731
--- /dev/null
+++ b/basctl/source/basicide/basicbox.hxx
@@ -0,0 +1,124 @@
+/*************************************************************************
+ *
+ * $RCSfile: basicbox.hxx,v $
+ *
+ * $Revision: 1.1.1.1 $
+ *
+ * last change: $Author: mh $ $Date: 2000-09-29 11:02:35 $
+ *
+ * The Contents of this file are made available subject to the terms of
+ * either of the following licenses
+ *
+ * - GNU Lesser General Public License Version 2.1
+ * - Sun Industry Standards Source License Version 1.1
+ *
+ * Sun Microsystems Inc., October, 2000
+ *
+ * GNU Lesser General Public License Version 2.1
+ * =============================================
+ * Copyright 2000 by Sun Microsystems, Inc.
+ * 901 San Antonio Road, Palo Alto, CA 94303, USA
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License version 2.1, as published by the Free Software Foundation.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this library; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston,
+ * MA 02111-1307 USA
+ *
+ *
+ * Sun Industry Standards Source License Version 1.1
+ * =================================================
+ * The contents of this file are subject to the Sun Industry Standards
+ * Source License Version 1.1 (the "License"); You may not use this file
+ * except in compliance with the License. You may obtain a copy of the
+ * License at http://www.openoffice.org/license.html.
+ *
+ * Software provided under this License is provided on an "AS IS" basis,
+ * WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING,
+ * WITHOUT LIMITATION, WARRANTIES THAT THE SOFTWARE IS FREE OF DEFECTS,
+ * MERCHANTABLE, FIT FOR A PARTICULAR PURPOSE, OR NON-INFRINGING.
+ * See the License for the specific provisions governing your rights and
+ * obligations concerning the Software.
+ *
+ * The Initial Developer of the Original Code is: Sun Microsystems, Inc.
+ *
+ * Copyright: 2000 by Sun Microsystems, Inc.
+ *
+ * All Rights Reserved.
+ *
+ * Contributor(s): _______________________________________
+ *
+ *
+ ************************************************************************/
+//
+#ifndef _BASICBOX_HXX
+#define _BASICBOX_HXX
+
+#ifndef _SFXSTRITEM_HXX //autogen
+#include <svtools/stritem.hxx>
+#endif
+#ifndef _SVHEADER_HXX
+#include <svheader.hxx>
+#endif
+
+#ifndef _SFXTBXCTRL_HXX //autogen
+#include <sfx2/tbxctrl.hxx>
+#endif
+
+#ifndef _SV_LSTBOX_HXX //autogen
+#include <vcl/lstbox.hxx>
+#endif
+
+
+class LibBoxControl: public SfxToolBoxControl
+{
+public:
+ SFX_DECL_TOOLBOX_CONTROL();
+
+ LibBoxControl( USHORT nId, ToolBox& rTbx, SfxBindings& rBind );
+ ~LibBoxControl();
+
+ virtual void StateChanged( USHORT nSID, SfxItemState eState,
+ const SfxPoolItem* pState );
+ virtual Window* CreateItemWindow( Window *pParent );
+};
+
+//
+
+class BasicLibBox : public ListBox, public SfxListener
+{
+private:
+ String aCurText;
+ BOOL bIgnoreSelect;
+ BOOL bFillBox;
+
+ void ReleaseFocus();
+
+protected:
+ virtual void Select();
+ virtual long PreNotify( NotifyEvent& rNEvt );
+
+ virtual void SFX_NOTIFY( SfxBroadcaster& rBC, const TypeId& rBCType,
+ const SfxHint& rHint, const TypeId& rHintType );
+
+
+public:
+ BasicLibBox( Window* pParent );
+ ~BasicLibBox();
+
+ void FillBox( BOOL bSelect = TRUE );
+ void Update( const SfxStringItem* pItem );
+ void NotifyIDE();
+};
+
+
+#endif // _BASICBOX_HXX
+
diff --git a/basctl/source/basicide/baside2.cxx b/basctl/source/basicide/baside2.cxx
new file mode 100644
index 000000000000..40d286a2e2fe
--- /dev/null
+++ b/basctl/source/basicide/baside2.cxx
@@ -0,0 +1,1460 @@
+/*************************************************************************
+ *
+ * $RCSfile: baside2.cxx,v $
+ *
+ * $Revision: 1.1.1.1 $
+ *
+ * last change: $Author: mh $ $Date: 2000-09-29 11:02:35 $
+ *
+ * The Contents of this file are made available subject to the terms of
+ * either of the following licenses
+ *
+ * - GNU Lesser General Public License Version 2.1
+ * - Sun Industry Standards Source License Version 1.1
+ *
+ * Sun Microsystems Inc., October, 2000
+ *
+ * GNU Lesser General Public License Version 2.1
+ * =============================================
+ * Copyright 2000 by Sun Microsystems, Inc.
+ * 901 San Antonio Road, Palo Alto, CA 94303, USA
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License version 2.1, as published by the Free Software Foundation.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this library; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston,
+ * MA 02111-1307 USA
+ *
+ *
+ * Sun Industry Standards Source License Version 1.1
+ * =================================================
+ * The contents of this file are subject to the Sun Industry Standards
+ * Source License Version 1.1 (the "License"); You may not use this file
+ * except in compliance with the License. You may obtain a copy of the
+ * License at http://www.openoffice.org/license.html.
+ *
+ * Software provided under this License is provided on an "AS IS" basis,
+ * WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING,
+ * WITHOUT LIMITATION, WARRANTIES THAT THE SOFTWARE IS FREE OF DEFECTS,
+ * MERCHANTABLE, FIT FOR A PARTICULAR PURPOSE, OR NON-INFRINGING.
+ * See the License for the specific provisions governing your rights and
+ * obligations concerning the Software.
+ *
+ * The Initial Developer of the Original Code is: Sun Microsystems, Inc.
+ *
+ * Copyright: 2000 by Sun Microsystems, Inc.
+ *
+ * All Rights Reserved.
+ *
+ * Contributor(s): _______________________________________
+ *
+ *
+ ************************************************************************/
+
+
+#include <ide_pch.hxx>
+
+#pragma hdrstop
+
+#include <svtools/texteng.hxx>
+#include <svtools/textview.hxx>
+#include <svtools/xtextedt.hxx>
+
+#ifndef _SBXCLASS_HXX //autogen
+#include <svtools/sbx.hxx>
+#endif
+#ifndef _IODLG_HXX //autogen
+#include <sfx2/iodlg.hxx>
+#endif
+
+#ifndef _SFXDOCFILE_HXX //autogen
+#include <sfx2/docfile.hxx>
+#endif
+#include <basic/basrdll.hxx>
+
+
+#include <baside2.hrc>
+#include <baside2.hxx>
+#include <objdlg.hxx>
+#include <iderdll.hxx>
+#include <iderdll2.hxx>
+
+#include <basobj.hxx>
+
+#include <svx/srchdlg.hxx>
+
+#include <vcl/sound.hxx>
+
+#ifndef _TXTCMP_HXX //autogen
+#include <svtools/txtcmp.hxx>
+#endif
+
+
+//#ifdef OS2
+//#define INCL_DOSPROCESS
+//#include <sysdep.hxx>
+//#endif
+
+#define SPLIT_MARGIN 5
+#define SPLIT_HEIGHT 2
+
+#define LMARGPRN 1700
+#define RMARGPRN 900
+#define TMARGPRN 2000
+#define BMARGPRN 1000
+#define BORDERPRN 300
+
+#define APPWAIT_START 100
+
+#define VALIDWINDOW 0x1234
+
+#if defined(MAC)
+#define FILTERMASK_ALL "****"
+#elif defined(OW) || defined(MTF)
+#define FILTERMASK_ALL "*"
+#elif defined(PM2)
+#define FILTERMASK_ALL ""
+#else
+#define FILTERMASK_ALL "*.*"
+#endif
+
+
+DBG_NAME( ModulWindow );
+
+TYPEINIT1( ModulWindow , IDEBaseWindow );
+
+void lcl_PrintHeader( Printer* pPrinter, USHORT nPages, USHORT nCurPage, const String& rTitle )
+{
+ short nLeftMargin = LMARGPRN;
+ Size aSz = pPrinter->GetOutputSize();
+ short nBorder = BORDERPRN;
+
+ const Color aOldLineColor( pPrinter->GetLineColor() );
+ const Color aOldFillColor( pPrinter->GetFillColor() );
+ const Font aOldFont( pPrinter->GetFont() );
+
+ pPrinter->SetLineColor( Color( COL_BLACK ) );
+ pPrinter->SetFillColor();
+
+ Font aFont( aOldFont );
+ aFont.SetWeight( WEIGHT_BOLD );
+ aFont.SetAlign( ALIGN_BOTTOM );
+ pPrinter->SetFont( aFont );
+
+ long nFontHeight = pPrinter->GetTextHeight();
+
+ // 1.Border => Strich, 2+3 Border = Freiraum.
+ long nYTop = TMARGPRN-3*nBorder-nFontHeight;
+
+ long nXLeft = nLeftMargin-nBorder;
+ long nXRight = aSz.Width()-RMARGPRN+nBorder;
+
+ pPrinter->DrawRect( Rectangle(
+ Point( nXLeft, nYTop ),
+ Size( nXRight-nXLeft, aSz.Height() - nYTop - BMARGPRN + nBorder ) ) );
+
+
+ long nY = TMARGPRN-2*nBorder;
+ Point aPos( nLeftMargin, nY );
+ pPrinter->DrawText( aPos, rTitle );
+ if ( nPages != 1 )
+ {
+ aFont.SetWeight( WEIGHT_NORMAL );
+ pPrinter->SetFont( aFont );
+ String aPageStr( RTL_CONSTASCII_USTRINGPARAM( " [" ) );
+ aPageStr += String( IDEResId( RID_STR_PAGE ) );
+ aPageStr += ' ';
+ aPageStr += String::CreateFromInt32( nCurPage );
+ aPageStr += ']';
+ aPos.X() += pPrinter->GetTextWidth( rTitle );
+ pPrinter->DrawText( aPos, aPageStr );
+ }
+
+
+ nY = TMARGPRN-nBorder;
+
+ pPrinter->DrawLine( Point( nXLeft, nY ), Point( nXRight, nY ) );
+
+ pPrinter->SetFont( aOldFont );
+ pPrinter->SetFillColor( aOldFillColor );
+ pPrinter->SetLineColor( aOldLineColor );
+}
+
+void lcl_ConvertTabsToSpaces( String& rLine )
+{
+ if ( rLine.Len() )
+ {
+ USHORT nPos = 0;
+ USHORT nMax = rLine.Len();
+ while ( nPos < nMax )
+ {
+ if ( rLine.GetChar( nPos ) == '\t' )
+ {
+ // Nicht 4 Blanks, sondern an 4er TabPos:
+ String aBlanker;
+ aBlanker.Fill( ( 4 - ( nPos % 4 ) ), ' ' );
+ rLine.Erase( nPos, 1 );
+ rLine.Insert( aBlanker, nPos );
+ nMax = rLine.Len();
+ }
+ nPos++; // Nicht optimal, falls Tab, aber auch nicht verkehrt...
+ }
+ }
+}
+
+
+ModulWindow::ModulWindow( ModulWindowLayout* pParent, StarBASIC* pBas, SbModule* pModule ) :
+ IDEBaseWindow( pParent, pBas ),
+ aXEditorWindow( this )
+{
+ DBG_CTOR( ModulWindow, 0 );
+ nValid = VALIDWINDOW;
+ pLayout = pParent;
+ aXEditorWindow.Show();
+
+ DBG_ASSERT( pModule, "Es muss ein Modul uebergeben werden!" );
+ xModule = pModule;
+ SetBackground();
+}
+
+__EXPORT ModulWindow::~ModulWindow()
+{
+ DBG_DTOR( ModulWindow, 0 );
+ nValid = 0;
+
+ StarBASIC::Stop();
+}
+
+
+void __EXPORT ModulWindow::GetFocus()
+{
+ if ( nValid != VALIDWINDOW )
+ return;
+ DBG_CHKTHIS( ModulWindow, 0 );
+ aXEditorWindow.GetEdtWindow().GrabFocus();
+ // Basisklasse nicht rufen, weil Focus jetzt woanders...
+}
+
+void ModulWindow::DoInit()
+{
+ DBG_CHKTHIS( ModulWindow, 0 );
+ // Wird beim Umschalten der Fenster gerufen...
+ if ( GetVScrollBar() )
+ GetVScrollBar()->Hide();
+ GetHScrollBar()->Show();
+// GetEditorWindow().SetScrollBarRanges();
+ GetEditorWindow().InitScrollBars();
+// GetEditorWindow().GrabFocus();
+}
+
+
+void __EXPORT ModulWindow::Paint( const Rectangle& )
+{
+ DBG_CHKTHIS( ModulWindow, 0 );
+#ifdef DEBUG
+// SetFillInBrush( Brush( Color( COL_GREEN ) ) );
+// Size aSz = GetOutputSize();
+// DrawRect( Rectangle( Point( 0, 0 ), aSz ) );
+#endif
+}
+
+void __EXPORT ModulWindow::Resize()
+{
+ aXEditorWindow.SetPosSizePixel( Point( 0, 0 ),
+ Size( GetOutputSizePixel() ) );
+}
+
+
+// "Import" von baside4.cxx
+void CreateEngineForBasic( StarBASIC* pBasic );
+
+void ModulWindow::CheckCompileBasic()
+{
+ DBG_CHKTHIS( ModulWindow, 0 );
+
+ // Zur Laufzeit wird niemals compiliert!
+ BOOL bRunning = StarBASIC::IsRunning();
+ BOOL bModified = ( !xModule->IsCompiled() ||
+ ( GetEditEngine() && GetEditEngine()->IsModified() ) );
+
+ if ( !bRunning && bModified )
+ {
+ BOOL bDone = FALSE;
+ Application::EnterWait();
+
+ if( bModified )
+ {
+ AssertValidEditEngine();
+ GetEditorWindow().SetSourceInBasic( FALSE );
+ }
+
+ BOOL bWasModified = GetBasic()->IsModified();
+
+ bDone = GetBasic()->Compile( xModule );
+ if ( !bWasModified )
+ GetBasic()->SetModified( FALSE );
+
+ if ( bDone )
+ {
+ GetBreakPoints().SetBreakPointsInBasic( xModule );
+ }
+
+ Application::LeaveWait();
+
+// BasicIDE::MarkDocShellModified( GetBasic() );
+
+ aStatus.bError = !bDone;
+ aStatus.bIsRunning = FALSE;
+ }
+}
+
+BOOL ModulWindow::BasicExecute()
+{
+ DBG_CHKTHIS( ModulWindow, 0 );
+ CheckCompileBasic();
+
+ if ( !aStatus.bError && xModule->IsCompiled() )
+ {
+ if ( GetBreakPoints().Count() )
+ aStatus.nBasicFlags = aStatus.nBasicFlags | SbDEBUG_BREAK;
+
+ if ( !aStatus.bIsRunning )
+ {
+ DBG_ASSERT( xModule.Is(), "Kein Modul!" );
+ AddStatus( BASWIN_RUNNINGBASIC );
+ USHORT nStart, nEnd, nCurMethodStart;
+ SbMethod* pMethod = 0;
+ // erstes Macro, sonst blind "Main" (ExtSearch?)
+ for ( USHORT nMacro = 0; nMacro < xModule->GetMethods()->Count(); nMacro++ )
+ {
+ SbMethod* pM = (SbMethod*)xModule->GetMethods()->Get( nMacro );
+ DBG_ASSERT( pM, "Method?" );
+ pM->GetLineRange( nStart, nEnd );
+ if ( !pMethod || ( nStart < nCurMethodStart ) )
+ {
+ pMethod = pM;
+ nCurMethodStart = nStart;
+ }
+ }
+ if ( !pMethod )
+ pMethod = (SbMethod*)xModule->Find( String( RTL_CONSTASCII_USTRINGPARAM( "Main" ) ), SbxCLASS_METHOD );
+
+ if ( pMethod )
+ {
+ pMethod->SetDebugFlags( aStatus.nBasicFlags );
+ BasicDLL::SetDebugMode( TRUE );
+ BasicIDE::RunMethod( pMethod );
+ BasicDLL::SetDebugMode( FALSE );
+ // Falls waehrend Interactive=FALSE abgebrochen
+ BasicDLL::EnableBreak( TRUE );
+ }
+ ClearStatus( BASWIN_RUNNINGBASIC );
+ }
+ else
+ aStatus.bIsRunning = FALSE; // Abbruch von Reschedule()
+ }
+
+ BOOL bDone = !aStatus.bError;
+
+ return bDone;
+}
+
+BOOL ModulWindow::CompileBasic()
+{
+ DBG_CHKTHIS( ModulWindow, 0 );
+ CheckCompileBasic();
+ return xModule->IsCompiled();
+}
+
+BOOL ModulWindow::BasicRun()
+{
+ DBG_CHKTHIS( ModulWindow, 0 );
+
+ aStatus.nBasicFlags = 0;
+ BOOL bDone = BasicExecute();
+ return bDone;
+}
+
+BOOL ModulWindow::BasicStepOver()
+{
+ DBG_CHKTHIS( ModulWindow, 0 );
+ aStatus.nBasicFlags = SbDEBUG_STEPINTO | SbDEBUG_STEPOVER;
+ BOOL bDone = BasicExecute();
+ return bDone;
+}
+
+
+BOOL ModulWindow::BasicStepInto()
+{
+ DBG_CHKTHIS( ModulWindow, 0 );
+
+ aStatus.nBasicFlags = SbDEBUG_STEPINTO;
+ BOOL bDone = BasicExecute();
+ return bDone;
+}
+
+BOOL ModulWindow::BasicStepOut()
+{
+ DBG_CHKTHIS( ModulWindow, 0 );
+
+ aStatus.nBasicFlags = SbDEBUG_STEPOUT;
+ BOOL bDone = BasicExecute();
+ return bDone;
+}
+
+
+
+void ModulWindow::BasicStop()
+{
+ DBG_CHKTHIS( ModulWindow, 0 );
+
+ GetBasic()->Stop();
+ aStatus.bIsRunning = FALSE;
+}
+
+BOOL ModulWindow::LoadBasic()
+{
+ DBG_CHKTHIS( ModulWindow, 0 );
+ BOOL bDone = FALSE;
+
+ SfxFileDialog aFileDialogBox( this, WinBits( WB_OPEN | WB_3DLOOK ) );
+ if ( aCurPath.Len() )
+ aFileDialogBox.SetPath( aCurPath );
+ aFileDialogBox.SetText( String( IDEResId( RID_STR_OPEN ) ) );
+ aFileDialogBox.AddFilter( String( RTL_CONSTASCII_USTRINGPARAM( "BASIC" ) ), String( RTL_CONSTASCII_USTRINGPARAM( "*.bas" ) ) );
+ aFileDialogBox.AddFilter( String( RTL_CONSTASCII_USTRINGPARAM( "StarScript" ) ), String( RTL_CONSTASCII_USTRINGPARAM( "*.sjs" ) ) );
+ aFileDialogBox.AddFilter( String( IDEResId( RID_STR_FILTER_ALLFILES ) ), String( RTL_CONSTASCII_USTRINGPARAM( FILTERMASK_ALL ) ) );
+ aFileDialogBox.SetCurFilter( String( RTL_CONSTASCII_USTRINGPARAM( "BASIC" ) ) );
+
+ if ( aFileDialogBox.Execute() )
+ {
+ aCurPath = aFileDialogBox.GetPath();
+ SfxMedium aMedium( aCurPath, STREAM_READ | STREAM_SHARE_DENYWRITE | STREAM_NOCREATE, TRUE );
+ SvStream* pStream = aMedium.GetInStream();
+ if ( pStream )
+ {
+ AssertValidEditEngine();
+ ULONG nLines = CalcLineCount( *pStream );
+ // nLines*4: ReadText/Formatting/Highlighting/Formatting
+ GetEditorWindow().CreateProgress( String( IDEResId( RID_STR_GENERATESOURCE ) ), nLines*4 );
+ GetEditEngine()->SetUpdateMode( FALSE );
+ GetEditView()->Read( *pStream );
+ GetEditEngine()->SetUpdateMode( TRUE );
+ GetEditorWindow().Update(); // Es wurde bei UpdateMode = TRUE nur Invalidiert
+ GetEditorWindow().ForceSyntaxTimeout();
+ GetEditorWindow().DestroyProgress();
+ ULONG nError = aMedium.GetError();
+ if ( nError )
+ ErrorHandler::HandleError( nError );
+ else
+ bDone = TRUE;
+ }
+ else
+ ErrorBox( this, WB_OK | WB_DEF_OK, String( IDEResId( RID_STR_COULDNTREAD ) ) ).Execute();
+ }
+ return bDone;
+}
+
+
+
+BOOL ModulWindow::SaveBasicSource()
+{
+ DBG_CHKTHIS( ModulWindow, 0 );
+ BOOL bDone = FALSE;
+ SfxFileDialog aFileDialogBox( this, WinBits( WB_SAVEAS | WB_3DLOOK ) );
+ if ( aCurPath.Len() )
+ aFileDialogBox.SetPath( aCurPath );
+ aFileDialogBox.SetText( String( IDEResId( RID_STR_SAVE ) ) );
+
+ aFileDialogBox.AddFilter( String( RTL_CONSTASCII_USTRINGPARAM( "BASIC" ) ), String( RTL_CONSTASCII_USTRINGPARAM( "*.bas" ) ) );
+ aFileDialogBox.AddFilter( String( RTL_CONSTASCII_USTRINGPARAM( "StarScript" ) ), String( RTL_CONSTASCII_USTRINGPARAM( "*.sjs" ) ) );
+ aFileDialogBox.AddFilter( String( IDEResId( RID_STR_FILTER_ALLFILES ) ), String( RTL_CONSTASCII_USTRINGPARAM( FILTERMASK_ALL ) ) );
+
+ aFileDialogBox.SetDefaultExt( String( RTL_CONSTASCII_USTRINGPARAM( "bas" ) ) );
+ aFileDialogBox.SetCurFilter( String( RTL_CONSTASCII_USTRINGPARAM( "BASIC" ) ) );
+
+ if ( aFileDialogBox.Execute() )
+ {
+ aCurPath = aFileDialogBox.GetPath();
+ SfxMedium aMedium( aCurPath, STREAM_WRITE | STREAM_SHARE_DENYWRITE | STREAM_TRUNC, TRUE, FALSE );
+ SvStream* pStream = aMedium.GetOutStream();
+ if ( pStream )
+ {
+ Application::EnterWait();
+ AssertValidEditEngine();
+ GetEditEngine()->Write( *pStream );
+ aMedium.Commit();
+ Application::LeaveWait();
+ ULONG nError = aMedium.GetError();
+ if ( nError )
+ ErrorHandler::HandleError( nError );
+ else
+ bDone = TRUE;
+ }
+ else
+ ErrorBox( this, WB_OK | WB_DEF_OK, String( IDEResId( RID_STR_COULDNTWRITE) ) ).Execute();
+ }
+
+ return bDone;
+}
+
+
+BOOL ModulWindow::ToggleBreakPoint( ULONG nLine )
+{
+ DBG_ASSERT( xModule.Is(), "Kein Modul!" );
+ CheckCompileBasic();
+ if ( aStatus.bError )
+ {
+ Sound::Beep();
+ return FALSE;
+ }
+
+ BOOL bNewBreakPoint = FALSE;
+ BreakPoint* pBrk = GetBreakPoints().FindBreakPoint( nLine );
+ if ( pBrk ) // entfernen
+ {
+ xModule->ClearBP( (USHORT)nLine );
+ delete GetBreakPoints().Remove( pBrk );
+ }
+ else // einen erzeugen
+ {
+ if ( xModule->SetBP( (USHORT)nLine) )
+ {
+ GetBreakPoints().InsertSorted( new BreakPoint( nLine ) );
+ bNewBreakPoint = TRUE;
+ if ( StarBASIC::IsRunning() )
+ {
+ for ( USHORT nMethod = 0; nMethod < xModule->GetMethods()->Count(); nMethod++ )
+ {
+ SbMethod* pMethod = (SbMethod*)xModule->GetMethods()->Get( nMethod );
+ DBG_ASSERT( pMethod, "Methode nicht gefunden! (NULL)" );
+ pMethod->SetDebugFlags( pMethod->GetDebugFlags() | SbDEBUG_BREAK );
+ }
+ }
+ }
+
+ if ( !bNewBreakPoint )
+ Sound::Beep();
+ }
+
+ return bNewBreakPoint;
+}
+
+void ModulWindow::UpdateBreakPoint( const BreakPoint& rBrk )
+{
+ DBG_ASSERT( xModule.Is(), "Kein Modul!" );
+
+ CheckCompileBasic();
+
+ rtl::OUString aModName;
+ if ( rBrk.bEnabled )
+ xModule->SetBP( (USHORT)rBrk.nLine );
+ else
+ xModule->ClearBP( (USHORT)rBrk.nLine );
+}
+
+
+BOOL ModulWindow::BasicToggleBreakPoint()
+{
+ DBG_CHKTHIS( ModulWindow, 0 );
+ AssertValidEditEngine();
+
+ TextSelection aSel = GetEditView()->GetSelection();
+ aSel.GetStart().GetPara()++; // Basic-Zeilen beginnen bei 1!
+ aSel.GetEnd().GetPara()++;
+
+ BOOL bNewBreakPoint = FALSE;
+
+ for ( ULONG nLine = aSel.GetStart().GetPara(); nLine <= aSel.GetEnd().GetPara(); nLine++ )
+ {
+ if ( ToggleBreakPoint( nLine ) )
+ bNewBreakPoint = TRUE;
+ }
+
+ aXEditorWindow.GetBrkWindow().Invalidate();
+ return bNewBreakPoint;
+}
+
+IMPL_LINK( ModulWindow, BasicErrorHdl, StarBASIC *, pBasic )
+{
+ DBG_CHKTHIS( ModulWindow, 0 );
+ GoOnTop();
+
+ // ReturnWert: BOOL
+ // FALSE: Abbrechen
+ // TRUE: Weiter....
+ String aErrorText( pBasic->GetErrorText() );
+ USHORT nErrorLine = pBasic->GetLine() - 1;
+ USHORT nErrCol1 = pBasic->GetCol1();
+ USHORT nErrCol2 = pBasic->GetCol2();
+ if ( nErrCol2 != 0xFFFF )
+ nErrCol2++;
+
+ AssertValidEditEngine();
+ GetEditView()->SetSelection( TextSelection( TextPaM( nErrorLine, nErrCol1 ), TextPaM( nErrorLine, nErrCol2 ) ) );
+
+ String aErrorTextPrefix;
+ if( pBasic->IsCompilerError() )
+ {
+ aErrorTextPrefix = String( IDEResId( RID_STR_COMPILEERROR ) );
+ }
+ else
+ {
+ aErrorTextPrefix = String( IDEResId( RID_STR_RUNTIMEERROR ) );
+ aErrorTextPrefix += StarBASIC::GetVBErrorCode( pBasic->GetErrorCode() );
+ aErrorTextPrefix += ' ';
+ pLayout->GetStackWindow().UpdateCalls();
+ }
+ // Wenn anderes Basic, dan sollte die IDE versuchen, da richtige
+ // Modul anzuzeigen...
+ BOOL bMarkError = ( pBasic == GetBasic() ) ? TRUE : FALSE;
+ if ( bMarkError )
+ aXEditorWindow.GetBrkWindow().SetMarkerPos( nErrorLine, TRUE );
+// ErrorBox( this, WB_OK | WB_DEF_OK, String( aErrorTextPrefix + aErrorText ) ).Execute();
+// ErrorHandler::HandleError( pBasic->GetErrorCode() );
+ BasicIDE::HandleBasicError();
+ if ( bMarkError )
+ aXEditorWindow.GetBrkWindow().SetMarkerPos( MARKER_NOMARKER );
+ return FALSE;
+}
+
+long __EXPORT ModulWindow::BasicBreakHdl( StarBASIC* pBasic )
+{
+ DBG_CHKTHIS( ModulWindow, 0 );
+ // Ein GoOnTop aktiviert da Fenster, das veraendert aber den Context fuer
+ // das Programm!
+// GoOnTop();
+
+ // ReturnWert: USHORT => siehe SB-Debug-Flags
+ USHORT nErrorLine = pBasic->GetLine();
+
+ // Gibt es hier einen BreakPoint?
+ BreakPoint* pBrk = GetBreakPoints().FindBreakPoint( nErrorLine );
+ if ( pBrk && pBrk->nStopAfter )
+ {
+ pBrk->nStopAfter--;
+ if ( pBrk->nStopAfter && GetBasic()->IsBreak() )
+ return aStatus.nBasicFlags; // weiterlaufen...
+ }
+
+ nErrorLine--; // EditEngine begint bei 0, Basic bei 1
+ // Alleine schon damit gescrollt wird...
+ AssertValidEditEngine();
+ GetEditView()->SetSelection( TextSelection( TextPaM( nErrorLine, 0 ), TextPaM( nErrorLine, 0 ) ) );
+ aXEditorWindow.GetBrkWindow().SetMarkerPos( nErrorLine );
+
+ pLayout->GetWatchWindow().UpdateWatches();
+ pLayout->GetStackWindow().UpdateCalls();
+
+ aStatus.bIsInReschedule = TRUE;
+ aStatus.bIsRunning = TRUE;
+
+ AddStatus( BASWIN_INRESCHEDULE );
+
+ if( BasicIDE::GetBasicDialogCount() )
+ {
+ Application::GetDefModalDialogParent()->EnableInput( TRUE, TRUE );
+ }
+
+ BasicIDE::InvalidateDebuggerSlots();
+
+ while( aStatus.bIsRunning )
+ Application::Yield();
+
+ if( BasicIDE::GetBasicDialogCount() )
+ {
+ Application::GetDefModalDialogParent()->EnableInput( FALSE, TRUE );
+ }
+
+ aStatus.bIsInReschedule = FALSE;
+ aXEditorWindow.GetBrkWindow().SetMarkerPos( MARKER_NOMARKER );
+
+ ClearStatus( BASWIN_INRESCHEDULE );
+
+ return aStatus.nBasicFlags;
+}
+
+void ModulWindow::BasicAddWatch()
+{
+ DBG_CHKTHIS( ModulWindow, 0 );
+ String aWatchStr;
+ BOOL bInserted = FALSE;
+ AssertValidEditEngine();
+ BOOL bAdd = TRUE;
+ if ( !GetEditView()->HasSelection() )
+ {
+// bAdd = GetEditView()->SelectCurrentWord();
+ TextPaM aWordStart;
+ String aWord = GetEditEngine()->GetWord( GetEditView()->GetSelection().GetEnd(), &aWordStart );
+ if ( aWord.Len() )
+ {
+ TextSelection aSel( aWordStart );
+ aSel.GetEnd().GetIndex() += aWord.Len();
+ GetEditView()->SetSelection( aSel );
+ bAdd = TRUE;
+ }
+ }
+ if ( bAdd )
+ {
+ TextSelection aSel = GetEditView()->GetSelection();
+ if ( aSel.GetStart().GetPara() == aSel.GetEnd().GetPara() )
+ {
+ aWatchStr = GetEditView()->GetSelected();
+ pLayout->GetWatchWindow().AddWatch( aWatchStr );
+ pLayout->GetWatchWindow().UpdateWatches();
+ bInserted = TRUE;
+ }
+ }
+
+ if ( !bInserted )
+ Sound::Beep();
+}
+
+
+
+void ModulWindow::BasicRemoveWatch()
+{
+ DBG_CHKTHIS( ModulWindow, 0 );
+ BOOL bRemoved = pLayout->GetWatchWindow().RemoveSelectedWatch();
+
+ if ( !bRemoved )
+ Sound::Beep();
+}
+
+
+void ModulWindow::EditMacro( const String& rMacroName )
+{
+ DBG_CHKTHIS( ModulWindow, 0 );
+ DBG_ASSERT( xModule.Is(), "Kein Modul!" );
+ CheckCompileBasic();
+
+ if ( !aStatus.bError )
+ {
+ USHORT nStart, nEnd;
+ SbMethod* pMethod = (SbMethod*)xModule->Find( rMacroName, SbxCLASS_METHOD );
+ if ( pMethod )
+ {
+ pMethod->GetLineRange( nStart, nEnd );
+ if ( nStart )
+ {
+ // Basic beginnt bei 1
+ nStart--;
+ nEnd--;
+ }
+ TextSelection aSel( TextPaM( nStart, 0 ), TextPaM( nStart, 0 ) );
+ AssertValidEditEngine();
+ TextView * pView = GetEditView();
+ // ggf. hinscrollen, so dass erste Zeile oben...
+ long nVisHeight = GetOutputSizePixel().Height();
+ if ( (long)pView->GetTextEngine()->GetTextHeight() > nVisHeight )
+ {
+ long nMaxY = pView->GetTextEngine()->GetTextHeight() - nVisHeight;
+ long nOldStartY = pView->GetStartDocPos().Y();
+ long nNewStartY = nStart * pView->GetTextEngine()->GetCharHeight();
+ nNewStartY = Min( nNewStartY, nMaxY );
+ pView->Scroll( 0, -(nNewStartY-nOldStartY) );
+ pView->ShowCursor( FALSE, TRUE );
+ GetEditVScrollBar().SetThumbPos( pView->GetStartDocPos().Y() );
+ }
+ pView->SetSelection( aSel );
+ pView->ShowCursor();
+ pView->GetWindow()->GrabFocus();
+ }
+ }
+}
+
+
+void __EXPORT ModulWindow::StoreData()
+{
+ DBG_CHKTHIS( ModulWindow, 0 );
+ // StoreData wird gerufen, wenn der BasicManager zerstoert oder
+ // dieses Fenster beendet wird.
+ // => Keine Unterbrechungen erwuenscht!
+ // Und bei SAVE, wenn AppBasic...
+ GetEditorWindow().SetSourceInBasic( TRUE );
+ // Nicht das Modify loeschen, sonst wird das Basic nicht gespeichert
+ // Es wird beim Speichern sowieso geloescht.
+// xModule->SetModified( FALSE );
+}
+
+BOOL __EXPORT ModulWindow::CanClose()
+{
+ DBG_CHKTHIS( ModulWindow, 0 );
+ if ( GetEditEngine() && GetEditEngine()->IsModified() )
+ {
+ ULONG nLen = GetEditEngine()->GetTextLen();
+ if ( nLen > 0xFFFb ) // Maximale String-Laenge
+ {
+ String aError( CreateQualifiedName() );
+ aError += String( RTL_CONSTASCII_USTRINGPARAM( ":\n" ) );
+ aError += String( IDEResId( RID_STR_SOURCETOBIG ) );
+ ErrorBox( this, WB_OK | WB_DEF_OK, aError ).Execute();
+ return FALSE;
+ }
+ }
+ return TRUE;
+}
+
+
+BOOL __EXPORT ModulWindow::AllowUndo()
+{
+ return GetEditorWindow().CanModify();
+}
+
+
+void __EXPORT ModulWindow::UpdateData()
+{
+ DBG_CHKTHIS( ModulWindow, 0 );
+ DBG_ASSERT( xModule.Is(), "Kein Modul!" );
+ // UpdateData wird gerufen, wenn sich der Source von aussen
+ // geaendert hat.
+ // => Keine Unterbrechungen erwuenscht!
+ if ( GetEditView() )
+ {
+ TextSelection aSel = GetEditView()->GetSelection();
+ GetEditEngine()->SetText( xModule->GetSource() );
+ GetEditView()->SetSelection( aSel );
+ GetEditEngine()->SetModified( FALSE );
+ BasicIDE::MarkDocShellModified( GetBasic() );
+ }
+}
+
+
+void __EXPORT ModulWindow::PrintData( Printer* pPrinter )
+{
+ DBG_CHKTHIS( ModulWindow, 0 );
+
+ AssertValidEditEngine();
+
+ MapMode eOldMapMode( pPrinter->GetMapMode() );
+ Font aOldFont( pPrinter->GetFont() );
+
+// Font aFont( GetEditEngine()->CreateFontFromItemSet( GetEditEngine()->GetEmptyItemSet() ) );
+ Font aFont( GetEditEngine()->GetFont() );
+ aFont.SetAlign( ALIGN_BOTTOM );
+ aFont.SetTransparent( TRUE );
+ aFont.SetSize( Size( 0, 360 ) );
+ pPrinter->SetFont( aFont );
+ pPrinter->SetMapMode( MAP_100TH_MM );
+
+ String aTitle( CreateQualifiedName() );
+
+ USHORT nLineHeight = (USHORT) pPrinter->GetTextHeight(); // etwas mehr.
+ USHORT nParaSpace = 10;
+
+ Size aPaperSz = pPrinter->GetOutputSize();
+ aPaperSz.Width() -= (LMARGPRN+RMARGPRN);
+ aPaperSz.Height() -= (TMARGPRN+BMARGPRN);
+
+ // nLinepPage stimmt nicht, wenn Zeilen umgebrochen werden muessen...
+ USHORT nLinespPage = (USHORT) (aPaperSz.Height()/nLineHeight);
+ USHORT nCharspLine = (USHORT) (aPaperSz.Width() / pPrinter->GetTextWidth( 'X' ) );
+ ULONG nParas = GetEditEngine()->GetParagraphCount();
+
+ USHORT nPages = (USHORT) (nParas/nLinespPage+1 );
+ USHORT nCurPage = 1;
+ USHORT nCurLine = 0;
+
+ pPrinter->StartJob( aTitle );
+ pPrinter->StartPage();
+ // Header drucken...
+ lcl_PrintHeader( pPrinter, nPages, nCurPage, aTitle );
+ Point aPos( LMARGPRN, TMARGPRN );
+ for ( ULONG nPara = 0; nPara < nParas; nPara++ )
+ {
+ String aLine( GetEditEngine()->GetText( nPara ) );
+ lcl_ConvertTabsToSpaces( aLine );
+ USHORT nLines = aLine.Len()/nCharspLine+1;
+ for ( USHORT nLine = 0; nLine < nLines; nLine++ )
+ {
+ String aTmpLine( aLine, nLine*nCharspLine, nCharspLine );
+ aPos.Y() += nLineHeight;
+ if ( aPos.Y() > ( aPaperSz.Height()+TMARGPRN ) )
+ {
+ nCurPage++;
+ pPrinter->EndPage();
+ pPrinter->StartPage();
+ lcl_PrintHeader( pPrinter, nPages, nCurPage, aTitle );
+ aPos = Point( LMARGPRN, TMARGPRN+nLineHeight );
+ }
+ pPrinter->DrawText( aPos, aTmpLine );
+ }
+ aPos.Y() += nParaSpace;
+ }
+ pPrinter->EndPage();
+ pPrinter->EndJob();
+
+ pPrinter->SetFont( aOldFont );
+ pPrinter->SetMapMode( eOldMapMode );
+}
+
+
+void __EXPORT ModulWindow::ExecuteCommand( SfxRequest& rReq )
+{
+ DBG_CHKTHIS( ModulWindow, 0 );
+ AssertValidEditEngine();
+ USHORT nSlot = rReq.GetSlot();
+ switch ( nSlot )
+ {
+ case SID_BASICRUN:
+ {
+ BasicRun();
+ }
+ break;
+ case SID_BASICCOMPILE:
+ {
+ CompileBasic();
+ }
+ break;
+ case SID_BASICSTEPOVER:
+ {
+ BasicStepOver();
+ }
+ break;
+ case SID_BASICSTEPINTO:
+ {
+ BasicStepInto();
+ }
+ break;
+ case SID_BASICSTEPOUT:
+ {
+ BasicStepOut();
+ }
+ break;
+ case SID_BASICLOAD:
+ {
+ LoadBasic();
+ }
+ break;
+ case SID_BASICSAVEAS:
+ {
+ SaveBasicSource();
+ }
+ break;
+ case SID_BASICIDE_MATCHGROUP:
+ {
+ if ( !GetEditView()->MatchGroup() )
+ Sound::Beep();
+ }
+ break;
+ case SID_BASICIDE_TOGGLEBRKPNT:
+ {
+ BasicToggleBreakPoint();
+ }
+ break;
+ case SID_BASICIDE_ADDWATCH:
+ {
+ BasicAddWatch();
+ }
+ break;
+ case SID_BASICIDE_REMOVEWATCH:
+ {
+ BasicRemoveWatch();
+ }
+ break;
+ case SID_CUT:
+ {
+ GetEditView()->Cut();
+ BasicIDE::GetBindings().Invalidate( SID_DOC_MODIFIED );
+ }
+ break;
+ case SID_COPY:
+ {
+ GetEditView()->Copy();
+ }
+ break;
+ case SID_PASTE:
+ {
+ GetEditView()->Paste();
+ BasicIDE::GetBindings().Invalidate( SID_DOC_MODIFIED );
+ }
+ break;
+ case SID_BASICIDE_BRKPNTSCHANGED:
+ {
+ GetBreakPointWindow().Invalidate();
+ }
+ break;
+ }
+}
+
+
+
+void __EXPORT ModulWindow::GetState( SfxItemSet &rSet )
+{
+ DBG_CHKTHIS( ModulWindow, 0 );
+ SfxWhichIter aIter(rSet);
+ for ( USHORT nWh = aIter.FirstWhich(); 0 != nWh; nWh = aIter.NextWhich() )
+ {
+ switch ( nWh )
+ {
+ // allgemeine Items:
+ case SID_CUT:
+ case SID_COPY:
+ {
+// if ( !GetEditView() || !GetEditView()->HasSelection() )
+// rSet.DisableItem( nWh );
+ }
+ break;
+ case SID_PASTE:
+ case SID_DELETE:
+ {
+ ;
+ }
+ break;
+ case SID_BASICIDE_STAT_POS:
+ {
+ TextView* pView = GetEditView();
+ if ( pView )
+ {
+ TextSelection aSel = pView->GetSelection();
+ String aPos( IDEResId( RID_STR_LINE ) );
+ aPos += ' ';
+ aPos += String::CreateFromInt32( aSel.GetEnd().GetPara()+1 );
+ aPos += String( RTL_CONSTASCII_USTRINGPARAM( ", " ) );
+ aPos += String( IDEResId( RID_STR_COLUMN ) );
+ aPos += ' ';
+ aPos += String::CreateFromInt32( aSel.GetEnd().GetIndex()+1 );
+ SfxStringItem aItem( SID_BASICIDE_STAT_POS, aPos );
+ rSet.Put( aItem );
+ }
+ }
+ break;
+ case SID_ATTR_INSERT:
+ {
+ TextView* pView = GetEditView();
+ if ( pView )
+ {
+// USHORT nId = pView->IsInsertMode() ? RID_STR_INSERTMODE : RID_STR_OVERWRITEMODE;
+// SfxStringItem aItem( SID_ATTR_INSERT, String( IDEResId( nId ) ) );
+ SfxBoolItem aItem( SID_ATTR_INSERT, pView->IsInsertMode() );
+ rSet.Put( aItem );
+ }
+ }
+ break;
+ }
+ }
+}
+
+
+void __EXPORT ModulWindow::DoScroll( ScrollBar* pCurScrollBar )
+{
+ DBG_CHKTHIS( ModulWindow, 0 );
+ if ( ( pCurScrollBar == GetHScrollBar() ) && GetEditView() )
+ {
+ // Nicht mit dem Wert Scrollen, sondern lieber die Thumb-Pos fuer die
+ // VisArea verwenden:
+ long nDiff = GetEditView()->GetStartDocPos().X() - pCurScrollBar->GetThumbPos();
+ GetEditView()->Scroll( nDiff, 0 );
+ GetEditView()->ShowCursor( FALSE, TRUE );
+ pCurScrollBar->SetThumbPos( GetEditView()->GetStartDocPos().X() );
+
+ }
+}
+
+
+
+void ModulWindow::RenameModule( const String& rNewName )
+{
+ DBG_ASSERT( xModule.Is(), "Kein Modul!" );
+ xModule->SetName( rNewName );
+}
+
+
+
+BOOL __EXPORT ModulWindow::IsModified()
+{
+ return GetEditEngine() ? GetEditEngine()->IsModified() : FALSE;
+}
+
+
+
+void __EXPORT ModulWindow::GoOnTop()
+{
+ IDE_DLL()->GetShell()->GetViewFrame()->ToTop();
+}
+
+String ModulWindow::GetModuleName()
+{
+ String aModuleName;
+ if ( xModule.Is() )
+ aModuleName = xModule->GetName();
+ return aModuleName;
+}
+
+
+
+String __EXPORT ModulWindow::GetTitle()
+{
+ return GetModuleName();
+}
+
+
+
+void ModulWindow::FrameWindowMoved()
+{
+// if ( GetEditEngine() && GetEditEngine()->IsInSelectionMode() )
+// GetEditEngine()->StopSelectionMode();
+}
+
+
+
+void ModulWindow::ShowCursor( BOOL bOn )
+{
+ if ( GetEditEngine() )
+ {
+ TextView* pView = GetEditEngine()->GetActiveView();
+ if ( pView )
+ {
+ if ( bOn )
+ pView->ShowCursor();
+ else
+ pView->HideCursor();
+ }
+ }
+}
+
+
+Window* __EXPORT ModulWindow::GetLayoutWindow()
+{
+ return pLayout;
+}
+
+void ModulWindow::AssertValidEditEngine()
+{
+ if ( !GetEditEngine() )
+ GetEditorWindow().CreateEditEngine();
+}
+
+void ModulWindow::Deactivating()
+{
+ if ( GetEditView() )
+ GetEditView()->EraseVirtualDevice();
+}
+
+USHORT ModulWindow::StartSearchAndReplace( const SvxSearchItem& rSearchItem, BOOL bFromStart )
+
+{
+ // Mann koennte fuer das blinde Alle-Ersetzen auch auf
+ // Syntaxhighlighting/Formatierung verzichten...
+ AssertValidEditEngine();
+ ExtTextView* pView = GetEditView();
+ TextSelection aSel;
+ if ( bFromStart )
+ {
+ aSel = pView->GetSelection();
+ if ( !rSearchItem.GetBackward() )
+ pView->SetSelection( TextSelection() );
+ else
+ pView->SetSelection( TextSelection( TextPaM( 0xFFFFFFFF, 0xFFFF ), TextPaM( 0xFFFFFFFF, 0xFFFF ) ) );
+ }
+
+ SearchParam aSearchParam( rSearchItem.GetSearchString(),
+ SearchParam::SRCH_NORMAL, rSearchItem.GetExact(),
+ rSearchItem.GetWordOnly(), rSearchItem.GetSelection() );
+ if ( rSearchItem.GetRegExp() )
+ aSearchParam.SetSrchType( SearchParam::SRCH_REGEXP );
+ else if ( rSearchItem.IsLevenshtein() )
+ {
+ aSearchParam.SetSrchType( SearchParam::SRCH_LEVDIST );
+ aSearchParam.SetSrchRelaxed( rSearchItem.IsLEVRelaxed() ? TRUE : FALSE );
+ aSearchParam.SetLEVOther( rSearchItem.GetLEVOther() );
+ aSearchParam.SetLEVShorter( rSearchItem.GetLEVShorter() );
+ aSearchParam.SetLEVLonger( rSearchItem.GetLEVLonger() );
+ }
+ BOOL bForward = !rSearchItem.GetBackward();
+ USHORT nFound = 0;
+ if ( ( rSearchItem.GetCommand() == SVX_SEARCHCMD_FIND ) ||
+ ( rSearchItem.GetCommand() == SVX_SEARCHCMD_FIND_ALL ) )
+ {
+ nFound = pView->Search( aSearchParam, bForward );
+ }
+ else if ( ( rSearchItem.GetCommand() == SVX_SEARCHCMD_REPLACE ) ||
+ ( rSearchItem.GetCommand() == SVX_SEARCHCMD_REPLACE_ALL ) )
+ {
+ aSearchParam.SetReplaceStr( rSearchItem.GetReplaceString() );
+ BOOL bAll = rSearchItem.GetCommand() == SVX_SEARCHCMD_REPLACE_ALL;
+ nFound = pView->Replace( aSearchParam, bAll, bForward );
+ }
+
+ if ( bFromStart && !nFound )
+ pView->SetSelection( aSel );
+
+ return nFound;
+}
+
+SfxUndoManager* __EXPORT ModulWindow::GetUndoManager()
+{
+ if ( GetEditEngine() )
+ return &GetEditEngine()->GetUndoManager();
+ return NULL;
+}
+
+USHORT __EXPORT ModulWindow::GetSearchOptions()
+{
+ return SEARCH_OPTIONS_SEARCH | SEARCH_OPTIONS_REPLACE |
+ SEARCH_OPTIONS_REPLACE_ALL | SEARCH_OPTIONS_WHOLE_WORDS |
+ SEARCH_OPTIONS_BACKWARDS | SEARCH_OPTIONS_REG_EXP |
+ SEARCH_OPTIONS_EXACT | SEARCH_OPTIONS_SELECTION | SEARCH_OPTIONS_SIMILARITY;
+}
+
+void __EXPORT ModulWindow::BasicStarted()
+{
+ aStatus.bIsRunning = TRUE;
+ if ( GetBreakPoints().Count() )
+ {
+ GetBreakPoints().SetBreakPointsInBasic( xModule );
+ for ( USHORT nMethod = 0; nMethod < xModule->GetMethods()->Count(); nMethod++ )
+ {
+ SbMethod* pMethod = (SbMethod*)xModule->GetMethods()->Get( nMethod );
+ DBG_ASSERT( pMethod, "Methode nicht gefunden! (NULL)" );
+ pMethod->SetDebugFlags( pMethod->GetDebugFlags() | SbDEBUG_BREAK );
+ }
+ }
+}
+
+void __EXPORT ModulWindow::BasicStopped()
+{
+ aStatus.bIsRunning = FALSE;
+ GetBreakPointWindow().SetMarkerPos( MARKER_NOMARKER );
+}
+
+String ModulWindow::CreateSbxDescription()
+{
+ String aDescription = IDEBaseWindow::CreateSbxDescription();
+ aDescription += ';';
+ aDescription += GetModule()->GetName();
+ return aDescription;
+}
+
+void ModulWindow::SetReadOnly( BOOL b )
+{
+ if ( GetEditView() )
+ GetEditView()->SetReadOnly( b );
+}
+
+ModulWindowLayout::ModulWindowLayout( Window* pParent ) :
+ Window( pParent, WB_CLIPCHILDREN ),
+ aWatchWindow( this ),
+ aStackWindow( this ),
+ aVSplitter( this, WinBits( WB_VSCROLL ) ),
+ aHSplitter( this, WinBits( WB_HSCROLL ) ),
+ aImages( IDEResId( RID_IMGLST_LAYOUT ) )
+{
+ pModulWindow = 0;
+ bVSplitted = FALSE;
+ bHSplitted = FALSE;
+
+ aVSplitter.SetSplitHdl( LINK( this, ModulWindowLayout, SplitHdl ) );
+ aHSplitter.SetSplitHdl( LINK( this, ModulWindowLayout, SplitHdl ) );
+ aVSplitter.Show();
+ aHSplitter.Show();
+
+ aWatchWindow.Show();
+ aStackWindow.Show();
+
+ aSyntaxColors[0] = Color( COL_BLACK ); // TT_UNKNOWN,
+ aSyntaxColors[1] = Color( COL_GREEN ); // TT_IDENTIFIER,
+ aSyntaxColors[2] = Color( COL_BLACK ); // TT_WHITESPACE,
+ aSyntaxColors[3] = Color( COL_LIGHTRED ); // TT_NUMBER,
+ aSyntaxColors[4] = Color( COL_LIGHTRED ); // TT_STRING,
+ aSyntaxColors[5] = Color( COL_BLACK ); // TT_EOL,
+ aSyntaxColors[6] = Color( COL_GRAY ); // TT_COMMENT,
+ aSyntaxColors[7] = Color( COL_RED ); // TT_ERROR,
+ aSyntaxColors[8] = Color( COL_BLUE ); // TT_OPERATOR,
+ aSyntaxColors[9] = Color( COL_BLUE ); // TT_KEYWORD
+
+ Font aFont( GetFont() );
+ Size aSz( aFont.GetSize() );
+ aSz.Height() *= 3;
+ aSz.Height() /= 2;
+ aFont.SetSize( aSz );
+ aFont.SetWeight( WEIGHT_BOLD );
+ SetFont( aFont );
+}
+
+ModulWindowLayout::~ModulWindowLayout()
+{
+}
+
+void __EXPORT ModulWindowLayout::Resize()
+{
+ // ScrollBars, etc. passiert in BasicIDEShell:Adjust...
+ ArrangeWindows();
+// Invalidate();
+}
+
+void __EXPORT ModulWindowLayout::Paint( const Rectangle& rRect )
+{
+ DrawText( Point(), String( IDEResId( RID_STR_NOMODULE ) ) );
+}
+
+
+void ModulWindowLayout::ArrangeWindows()
+{
+ Size aSz = GetOutputSizePixel();
+
+ // prueffen, ob der Splitter in einem gueltigen Bereich liegt...
+ long nMinPos = SPLIT_MARGIN;
+ long nMaxPos = aSz.Height() - SPLIT_MARGIN;
+
+ long nVSplitPos = aVSplitter.GetSplitPosPixel();
+ long nHSplitPos = aHSplitter.GetSplitPosPixel();
+ if ( !bVSplitted )
+ {
+ // Wenn noch nie gesplitted wurde, Verhaeltniss = 3 : 4
+ nVSplitPos = aSz.Height() * 3 / 4;
+ aVSplitter.SetSplitPosPixel( nVSplitPos );
+ }
+ if ( !bHSplitted )
+ {
+ // Wenn noch nie gesplitted wurde, Verhaeltniss = 2 : 3
+ nHSplitPos = aSz.Width() * 2 / 3;
+ aHSplitter.SetSplitPosPixel( nHSplitPos );
+ }
+ if ( ( nVSplitPos < nMinPos ) || ( nVSplitPos > nMaxPos ) )
+ nVSplitPos = ( nVSplitPos < nMinPos ) ? 0 : ( aSz.Height() - SPLIT_HEIGHT );
+
+ Size aXEWSz;
+ aXEWSz.Width() = aSz.Width();
+ aXEWSz.Height() = nVSplitPos + 1;
+ if ( pModulWindow )
+ {
+ DBG_CHKOBJ( pModulWindow, ModulWindow, 0 );
+ pModulWindow->SetPosSizePixel( Point( 0, 0 ), aXEWSz );
+ }
+
+ aVSplitter.SetDragRectPixel( Rectangle( Point( 0, 0 ), Size( aSz.Width(), aSz.Height() ) ) );
+ aVSplitter.SetPosPixel( Point( 0, nVSplitPos ) );
+ aVSplitter.SetSizePixel( Size( aSz.Width(), SPLIT_HEIGHT ) );
+
+ aHSplitter.SetDragRectPixel( Rectangle( Point( 0, nVSplitPos+SPLIT_HEIGHT ), Size( aSz.Width(), aSz.Height() - nVSplitPos - SPLIT_HEIGHT ) ) );
+ aHSplitter.SetPosPixel( Point( nHSplitPos, nVSplitPos ) );
+ aHSplitter.SetSizePixel( Size( SPLIT_HEIGHT, aSz.Height() - nVSplitPos ) );
+
+ Size aWWSz;
+ Point aWWPos( 0, nVSplitPos+SPLIT_HEIGHT );
+ aWWSz.Width() = nHSplitPos;
+ aWWSz.Height() = aSz.Height() - aWWPos.Y();
+ if ( !aWatchWindow.IsFloatingMode() )
+ aWatchWindow.SetPosSizePixel( aWWPos, aWWSz );
+
+ Size aSWSz;
+ Point aSWPos( nHSplitPos+SPLIT_HEIGHT, nVSplitPos+SPLIT_HEIGHT );
+ aSWSz.Width() = aSz.Width() - aSWPos.X();
+ aSWSz.Height() = aSz.Height() - aSWPos.Y();
+ if ( !aStackWindow.IsFloatingMode() )
+ aStackWindow.SetPosSizePixel( aSWPos, aSWSz );
+
+#ifndef VCL
+#ifndef UNX
+ if ( aStackWindow.IsFloatingMode() && aWatchWindow.IsFloatingMode() )
+ aHSplitter.Hide();
+ else
+ aHSplitter.Show();
+#else
+ // Irgendwas liegt im argen. Das Stacking der windows kommt manchmal
+ // durcheinander.
+ if ( aStackWindow.IsFloatingMode() && aWatchWindow.IsFloatingMode() )
+ aHSplitter.Hide();
+ else
+ {
+ aHSplitter.Show();
+ aHSplitter.ToTop();
+ }
+ aVSplitter.ToTop();
+ Invalidate();
+#endif
+#else
+ if ( aStackWindow.IsFloatingMode() && aWatchWindow.IsFloatingMode() )
+ aHSplitter.Hide();
+ else
+ aHSplitter.Show();
+#endif
+
+ long nHDoubleClickSplitPosX = aSz.Width()-aHSplitter.GetSizePixel().Width();
+ if ( aHSplitter.GetSplitPosPixel() < nHDoubleClickSplitPosX )
+ aHSplitter.SetLastSplitPosPixel( nHDoubleClickSplitPosX );
+
+
+ long nHDoubleClickSplitPosY = aSz.Height()-aVSplitter.GetSizePixel().Height();
+ if ( aVSplitter.GetSplitPosPixel() < nHDoubleClickSplitPosY )
+ aVSplitter.SetLastSplitPosPixel( nHDoubleClickSplitPosY );
+}
+
+IMPL_LINK( ModulWindowLayout, SplitHdl, Splitter *, pSplitter )
+{
+ if ( pSplitter == &aVSplitter )
+ bVSplitted = TRUE;
+ else
+ bHSplitted = TRUE;
+
+ ArrangeWindows();
+ return 0;
+}
+
+BOOL ModulWindowLayout::IsToBeDocked( DockingWindow* pDockingWindow, const Point& rPos, Rectangle& rRect )
+{
+ // prueffen, ob als Dock oder als Child:
+ // TRUE: Floating
+ // FALSE: Child
+ Point aPosInMe = ScreenToOutputPixel( rPos );
+ Size aSz = GetOutputSizePixel();
+ if ( ( aPosInMe.X() > 0 ) && ( aPosInMe.X() < aSz.Width() ) &&
+ ( aPosInMe.Y() > 0 ) && ( aPosInMe.Y() < aSz.Height() ) )
+ {
+ long nVSplitPos = aVSplitter.GetSplitPosPixel();
+ long nHSplitPos = aHSplitter.GetSplitPosPixel();
+ if ( pDockingWindow == &aWatchWindow )
+ {
+ if ( ( aPosInMe.Y() > nVSplitPos ) && ( aPosInMe.X() < nHSplitPos ) )
+ {
+ rRect.SetSize( Size( nHSplitPos, aSz.Height() - nVSplitPos ) );
+ rRect.SetPos( OutputToScreenPixel( Point( 0, nVSplitPos ) ) );
+ return TRUE;
+ }
+ }
+ if ( pDockingWindow == &aStackWindow )
+ {
+ if ( ( aPosInMe.Y() > nVSplitPos ) && ( aPosInMe.X() > nHSplitPos ) )
+ {
+ rRect.SetSize( Size( aSz.Width() - nHSplitPos, aSz.Height() - nVSplitPos ) );
+ rRect.SetPos( OutputToScreenPixel( Point( nHSplitPos, nVSplitPos ) ) );
+ return TRUE;
+ }
+ }
+ }
+ return FALSE;
+}
+
+void ModulWindowLayout::DockaWindow( DockingWindow* pDockingWindow )
+{
+ if ( pDockingWindow == &aWatchWindow )
+ {
+ // evtl. Sonderbehandlung...
+ ArrangeWindows();
+ }
+ else if ( pDockingWindow == &aStackWindow )
+ {
+ // evtl. Sonderbehandlung...
+ ArrangeWindows();
+ }
+#ifndef PRODUCT
+ else
+ DBG_ERROR( "Wer will sich denn hier andocken ?" );
+#endif
+}
+
+void ModulWindowLayout::SetModulWindow( ModulWindow* pModWin )
+{
+ pModulWindow = pModWin;
+ ArrangeWindows();
+}
+
diff --git a/basctl/source/basicide/baside2.hrc b/basctl/source/basicide/baside2.hrc
new file mode 100644
index 000000000000..eeec12d4a1a8
--- /dev/null
+++ b/basctl/source/basicide/baside2.hrc
@@ -0,0 +1,93 @@
+/*************************************************************************
+ *
+ * $RCSfile: baside2.hrc,v $
+ *
+ * $Revision: 1.1.1.1 $
+ *
+ * last change: $Author: mh $ $Date: 2000-09-29 11:02:35 $
+ *
+ * The Contents of this file are made available subject to the terms of
+ * either of the following licenses
+ *
+ * - GNU Lesser General Public License Version 2.1
+ * - Sun Industry Standards Source License Version 1.1
+ *
+ * Sun Microsystems Inc., October, 2000
+ *
+ * GNU Lesser General Public License Version 2.1
+ * =============================================
+ * Copyright 2000 by Sun Microsystems, Inc.
+ * 901 San Antonio Road, Palo Alto, CA 94303, USA
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License version 2.1, as published by the Free Software Foundation.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this library; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston,
+ * MA 02111-1307 USA
+ *
+ *
+ * Sun Industry Standards Source License Version 1.1
+ * =================================================
+ * The contents of this file are subject to the Sun Industry Standards
+ * Source License Version 1.1 (the "License"); You may not use this file
+ * except in compliance with the License. You may obtain a copy of the
+ * License at http://www.openoffice.org/license.html.
+ *
+ * Software provided under this License is provided on an "AS IS" basis,
+ * WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING,
+ * WITHOUT LIMITATION, WARRANTIES THAT THE SOFTWARE IS FREE OF DEFECTS,
+ * MERCHANTABLE, FIT FOR A PARTICULAR PURPOSE, OR NON-INFRINGING.
+ * See the License for the specific provisions governing your rights and
+ * obligations concerning the Software.
+ *
+ * The Initial Developer of the Original Code is: Sun Microsystems, Inc.
+ *
+ * Copyright: 2000 by Sun Microsystems, Inc.
+ *
+ * All Rights Reserved.
+ *
+ * Contributor(s): _______________________________________
+ *
+ *
+ ************************************************************************/
+#ifndef _BASIDE2_HRC
+#define _BASIDE2_HRC
+
+#include <basidesh.hrc>
+
+// Diese Dateien enthaelt nur die lokalen ID's.
+
+// RID_POPUP_BRKPROPS
+#define RID_BRKPROPS 1
+#define RID_ACTIV 2
+
+// RID_POPUP_BRKDLG
+#define RID_BRKDLG 1
+
+
+// BasicTreeListBox
+#define IMGID_APPICON ( SID_BASICIDE_IMAGESTART + 1 )
+#define IMGID_LIB ( SID_BASICIDE_IMAGESTART + 2 )
+#define IMGID_MODULE ( SID_BASICIDE_IMAGESTART + 3 )
+#define IMGID_MACRO ( SID_BASICIDE_IMAGESTART + 4 )
+#define IMGID_OBJECT ( SID_BASICIDE_IMAGESTART + 5 )
+#define IMGID_SUBOBJ ( SID_BASICIDE_IMAGESTART + 6 )
+#define IMGID_PROP ( SID_BASICIDE_IMAGESTART + 7 )
+#define IMGID_DOCUMENT ( SID_BASICIDE_IMAGESTART + 8 )
+#define IMGID_LIBNOTLOADED ( SID_BASICIDE_IMAGESTART + 9 )
+
+// ModulWindowLayout
+#define IMGID_BRKENABLED ( SID_BASICIDE_IMAGESTART + 20 )
+#define IMGID_BRKDISABLED ( SID_BASICIDE_IMAGESTART + 21 )
+#define IMGID_STEPMARKER ( SID_BASICIDE_IMAGESTART + 22 )
+#define IMGID_ERRORMARKER ( SID_BASICIDE_IMAGESTART + 23 )
+
+#endif // _BASIDE2_HRC
diff --git a/basctl/source/basicide/baside2.hxx b/basctl/source/basicide/baside2.hxx
new file mode 100644
index 000000000000..2192d6117c38
--- /dev/null
+++ b/basctl/source/basicide/baside2.hxx
@@ -0,0 +1,503 @@
+/*************************************************************************
+ *
+ * $RCSfile: baside2.hxx,v $
+ *
+ * $Revision: 1.1.1.1 $
+ *
+ * last change: $Author: mh $ $Date: 2000-09-29 11:02:36 $
+ *
+ * The Contents of this file are made available subject to the terms of
+ * either of the following licenses
+ *
+ * - GNU Lesser General Public License Version 2.1
+ * - Sun Industry Standards Source License Version 1.1
+ *
+ * Sun Microsystems Inc., October, 2000
+ *
+ * GNU Lesser General Public License Version 2.1
+ * =============================================
+ * Copyright 2000 by Sun Microsystems, Inc.
+ * 901 San Antonio Road, Palo Alto, CA 94303, USA
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License version 2.1, as published by the Free Software Foundation.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this library; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston,
+ * MA 02111-1307 USA
+ *
+ *
+ * Sun Industry Standards Source License Version 1.1
+ * =================================================
+ * The contents of this file are subject to the Sun Industry Standards
+ * Source License Version 1.1 (the "License"); You may not use this file
+ * except in compliance with the License. You may obtain a copy of the
+ * License at http://www.openoffice.org/license.html.
+ *
+ * Software provided under this License is provided on an "AS IS" basis,
+ * WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING,
+ * WITHOUT LIMITATION, WARRANTIES THAT THE SOFTWARE IS FREE OF DEFECTS,
+ * MERCHANTABLE, FIT FOR A PARTICULAR PURPOSE, OR NON-INFRINGING.
+ * See the License for the specific provisions governing your rights and
+ * obligations concerning the Software.
+ *
+ * The Initial Developer of the Original Code is: Sun Microsystems, Inc.
+ *
+ * Copyright: 2000 by Sun Microsystems, Inc.
+ *
+ * All Rights Reserved.
+ *
+ * Contributor(s): _______________________________________
+ *
+ *
+ ************************************************************************/
+
+#ifndef _BASIDE2_HXX
+#define _BASIDE2_HXX
+
+#ifndef _SVHEADER_HXX
+#include <svheader.hxx>
+#endif
+
+#include <bastypes.hxx>
+#include <bastype3.hxx>
+#include <basidesh.hxx>
+
+#include <basic/hilight.hxx>
+
+class ExtTextEngine;
+class ExtTextView;
+class SvxSearchItem;
+
+#ifndef _SFXSTBMGR_HXX //autogen
+#include <sfx2/stbmgr.hxx>
+#endif
+
+#ifndef _SVTREEBOX_HXX //autogen
+#include <svtools/svtreebx.hxx>
+#endif
+
+#ifndef _SV_BUTTON_HXX //autogen
+#include <vcl/button.hxx>
+#endif
+
+#ifndef _SB_SBMOD_HXX //autogen
+#include <basic/sbmod.hxx>
+#endif
+
+#ifndef _SV_SPLIT_HXX //autogen
+#include <vcl/split.hxx>
+#endif
+
+#include <sfx2/progress.hxx>
+
+
+DBG_NAMEEX( ModulWindow );
+
+#define MARKER_NOMARKER 0xFFFF
+
+
+
+class ProgressInfo : public SfxProgress
+{
+private:
+ ULONG nCurState;
+
+public:
+
+ inline ProgressInfo( SfxObjectShell* pObjSh, const String& rText, ULONG nRange );
+
+// inline void StartProgress( const String& rName, ULONG nStates );
+// inline void EndProgress();
+ inline void StepProgress();
+};
+
+inline ProgressInfo::ProgressInfo( SfxObjectShell* pObjSh, const String& rText, ULONG nRange )
+ : SfxProgress( pObjSh, rText, nRange )
+{
+ nCurState = 0;
+}
+
+// inline void ProgressInfo::StartProgress( const String& rName, ULONG nStates )
+// {
+// nCurState = 0;
+// if ( pStbMgr )
+// pStbMgr->StartProgressMode( rName, nStates );
+// }
+
+// inline void ProgressInfo::EndProgress()
+// {
+// if ( pStbMgr )
+// pStbMgr->EndProgressMode();
+//}
+
+inline void ProgressInfo::StepProgress()
+{
+ SetState( ++nCurState );
+}
+
+class EditorWindow : public Window, public SfxListener
+{
+private:
+ ExtTextView* pEditView;
+ ExtTextEngine* pEditEngine;
+
+ long nCurTextWidth;
+
+ SyntaxHighlighter aHighlighter;
+ Timer aSyntaxIdleTimer;
+ Table aSyntaxLineTable;
+ DECL_LINK( SyntaxTimerHdl, Timer * );
+ ProgressInfo* pProgress;
+ ModulWindow* pModulWindow;
+
+ Timer aHelpAgentTimer;
+ DECL_LINK( HelpAgentTimerHdl, Timer * );
+
+
+ virtual void Notify( SfxBroadcaster& rBC, const SfxHint& rHint );
+
+ void ImpDoHighlight( ULONG nLineOff );
+ BOOL bHighlightning;
+ BOOL bDoSyntaxHighlight;
+ BOOL bDelayHighlight;
+
+protected:
+ virtual void Paint( const Rectangle& );
+ virtual void Resize();
+ virtual void KeyInput( const KeyEvent& rKeyEvt );
+ virtual void MouseMove( const MouseEvent& rMEvt );
+ virtual void MouseButtonDown( const MouseEvent& rMEvt );
+ virtual void MouseButtonUp( const MouseEvent& rMEvt );
+ virtual void Command( const CommandEvent& rCEvt );
+ virtual BOOL Drop( const DropEvent& rEvt );
+ virtual BOOL QueryDrop( DropEvent& rEvt );
+ virtual void LoseFocus();
+ virtual void RequestHelp( const HelpEvent& rHEvt );
+
+ void DoSyntaxHighlight( ULONG nPara );
+ void ToggleHighlightMode();
+ String GetWordAtCursor();
+ BOOL ImpCanModify();
+
+public:
+ EditorWindow( Window* pParent );
+ ~EditorWindow();
+
+ ExtTextEngine* GetEditEngine() const { return (ExtTextEngine*)pEditEngine; }
+ ExtTextView* GetEditView() const { return pEditView; }
+ ProgressInfo* GetProgress() const { return pProgress; }
+
+ void CreateProgress( const String& rText, ULONG nRange );
+ void DestroyProgress();
+
+ void ParagraphInsertedDeleted( ULONG nNewPara, BOOL bInserted );
+ void DoDelayedSyntaxHighlight( ULONG nPara );
+
+ void CreateEditEngine();
+ void SetScrollBarRanges();
+ void InitScrollBars();
+ void SetModulWindow( ModulWindow* pWin )
+ { pModulWindow = pWin; }
+
+ void ForceSyntaxTimeout();
+ BOOL SetSourceInBasic( BOOL bQuiet = TRUE );
+
+ BOOL CanModify() { return ImpCanModify(); }
+};
+
+
+class BreakPointWindow : public Window
+{
+private:
+ long nCurYOffset;
+ USHORT nMarkerPos;
+ BreakPointList aBreakPointList;
+ ModulWindow* pModulWindow;
+ BOOL bErrorMarker;
+
+protected:
+ virtual void Paint( const Rectangle& );
+ virtual void Resize();
+ BreakPoint* FindBreakPoint( const Point& rMousePos );
+ void ShowMarker( BOOL bShow );
+ virtual void MouseButtonDown( const MouseEvent& rMEvt );
+ virtual void Command( const CommandEvent& rCEvt );
+
+ BOOL SyncYOffset();
+
+public:
+ BreakPointWindow( Window* pParent );
+ ~BreakPointWindow();
+
+ void SetModulWindow( ModulWindow* pWin )
+ { pModulWindow = pWin; }
+
+ void SetMarkerPos( USHORT nLine, BOOL bErrorMarker = FALSE );
+
+// virtual void MouseMove( const MouseEvent& rMEvt );
+// virtual void MouseButtonUp( const MouseEvent& rMEvt );
+// virtual BOOL Drop( const DropEvent& rEvt );
+// virtual BOOL QueryDrop( const DropEvent& rEvt );
+
+ void Scroll( long nHorzScroll, long nVertScroll );
+ long& GetCurYOffset() { return nCurYOffset; }
+ BreakPointList& GetBreakPoints() { return aBreakPointList; }
+};
+
+
+class WatchTreeListBox : public SvTreeListBox
+{
+ String aEditingRes;
+
+protected:
+ virtual BOOL EditingEntry( SvLBoxEntry* pEntry, Selection& rSel );
+ virtual BOOL EditedEntry( SvLBoxEntry* pEntry, const String& rNewText );
+
+ BOOL ImplBasicEntryEdited( SvLBoxEntry* pEntry, const String& rVName, const String& rResult );
+
+// virtual DragDropMode NotifyBeginDrag( SvLBoxEntry* );
+// virtual BOOL NotifyQueryDrop( SvLBoxEntry* );
+
+// virtual BOOL NotifyMoving( SvLBoxEntry* pTarget, SvLBoxEntry* pEntry,
+// SvLBoxEntry*& rpNewParent, ULONG& rNewChildPos );
+// virtual BOOL NotifyCopying( SvLBoxEntry* pTarget, SvLBoxEntry* pEntry,
+// SvLBoxEntry*& rpNewParent, ULONG& rNewChildPos );
+// BOOL NotifyCopyingMoving( SvLBoxEntry* pTarget, SvLBoxEntry* pEntry,
+// SvLBoxEntry*& rpNewParent, ULONG& rNewChildPos, BOOL bMove );
+
+public:
+ WatchTreeListBox( Window* pParent, WinBits nWinBits );
+ ~WatchTreeListBox();
+
+ void UpdateWatches();
+};
+
+
+
+class WatchWindow : public BasicDockingWindow
+{
+private:
+ WatchTreeListBox aTreeListBox;
+
+ String aWatchStr;
+ ExtendedEdit aXEdit;
+ ImageButton aRemoveWatchButton;
+
+protected:
+ virtual void Resize();
+ virtual void Paint( const Rectangle& rRect );
+
+ DECL_LINK( ButtonHdl, ImageButton * );
+ DECL_LINK( TreeListHdl, SvTreeListBox * );
+ DECL_LINK( EditAccHdl, Accelerator * );
+
+public:
+ WatchWindow( Window* pParent );
+ ~WatchWindow();
+
+ void AddWatch( const String& rVName );
+ BOOL RemoveSelectedWatch();
+ void UpdateWatches();
+
+ WatchTreeListBox& GetWatchTreeListBox() { return aTreeListBox; }
+};
+
+
+class StackWindow : public BasicDockingWindow
+{
+private:
+ SvTreeListBox aTreeListBox;
+ ImageButton aGotoCallButton;
+ String aStackStr;
+
+protected:
+ virtual void Resize();
+ virtual void Paint( const Rectangle& rRect );
+ DECL_LINK( ButtonHdl, ImageButton * );
+
+public:
+ StackWindow( Window* pParent );
+ ~StackWindow();
+
+ void UpdateCalls();
+};
+
+
+class ComplexEditorWindow : public Window
+{
+private:
+ BreakPointWindow aBrkWindow;
+ EditorWindow aEdtWindow;
+ ScrollBar aEWVScrollBar;
+
+protected:
+ virtual void Resize();
+ virtual void Paint( const Rectangle& rRect );
+ DECL_LINK( ScrollHdl, ScrollBar * );
+
+public:
+ ComplexEditorWindow( ModulWindow* pParent );
+
+ BreakPointWindow& GetBrkWindow() { return aBrkWindow; }
+ EditorWindow& GetEdtWindow() { return aEdtWindow; }
+ ScrollBar& GetEWVScrollBar() { return aEWVScrollBar; }
+};
+
+
+#define SYNTAX_COLOR_MAX 5
+
+class ModulWindow: public IDEBaseWindow
+{
+ friend class BasicIDEShell;
+
+private:
+
+ short nValid;
+ ComplexEditorWindow aXEditorWindow;
+ BasicStatus aStatus;
+ SbModuleRef xModule;
+ ModulWindowLayout* pLayout;
+ String aCurPath;
+
+ DECL_LINK( BasicErrorHdl, StarBASIC * );
+ long BasicBreakHdl( StarBASIC* pBasic );
+
+ void CheckCompileBasic();
+ BOOL BasicExecute();
+
+ void GoOnTop();
+ void AssertValidEditEngine();
+
+protected:
+ virtual void Resize();
+ virtual void GetFocus();
+ virtual void Paint( const Rectangle& );
+ virtual void Deactivating();
+ virtual void DoInit();
+ virtual void DoScroll( ScrollBar* pCurScrollBar );
+
+public:
+ TYPEINFO();
+ ModulWindow( ModulWindowLayout* pParent, StarBASIC* pBasic, SbModule* pModule );
+ ~ModulWindow();
+
+ virtual void ExecuteCommand( SfxRequest& rReq );
+ virtual void GetState( SfxItemSet& );
+ virtual void StoreData();
+ virtual void UpdateData();
+ virtual BOOL CanClose();
+ virtual void PrintData( Printer* pPrinter );
+ virtual String GetTitle();
+ virtual String CreateSbxDescription();
+ virtual BOOL AllowUndo();
+ virtual void SetReadOnly( BOOL bReadOnly );
+
+
+ SbModule* GetModule() { return xModule; }
+ String GetModuleName();
+
+ BOOL CompileBasic();
+ BOOL BasicRun();
+ BOOL BasicStepOver();
+ BOOL BasicStepInto();
+ BOOL BasicStepOut();
+ void BasicStop();
+ BOOL BasicToggleBreakPoint();
+ void UpdateBreakPoint( const BreakPoint& rBrk );
+ void BasicAddWatch();
+ void BasicRemoveWatch();
+
+ BOOL LoadBasic();
+ BOOL SaveBasicSource();
+
+ void EditMacro( const String& rMacroName );
+
+// void InsertFromObjectCatalog( ObjectCatalog* pObjDlg );
+
+ BOOL ToggleBreakPoint( ULONG nLine );
+ void RenameModule( const String& rNewName );
+
+ BasicStatus& GetBasicStatus() { return aStatus; }
+
+ virtual BOOL IsModified();
+
+ void FrameWindowMoved();
+ void ShowCursor( BOOL bOn );
+
+ virtual USHORT GetSearchOptions();
+ USHORT StartSearchAndReplace( const SvxSearchItem& rSearchItem, BOOL bFromStart = FALSE );
+
+ virtual Window* GetLayoutWindow();
+
+ EditorWindow& GetEditorWindow() { return aXEditorWindow.GetEdtWindow(); }
+ BreakPointWindow& GetBreakPointWindow() { return aXEditorWindow.GetBrkWindow(); }
+ ScrollBar& GetEditVScrollBar() { return aXEditorWindow.GetEWVScrollBar(); }
+ ExtTextEngine* GetEditEngine() { return GetEditorWindow().GetEditEngine(); }
+ ExtTextView* GetEditView() { return GetEditorWindow().GetEditView(); }
+ BreakPointList& GetBreakPoints() { return GetBreakPointWindow().GetBreakPoints(); }
+ ModulWindowLayout* GetLayout() const { return pLayout; }
+
+ virtual void BasicStarted();
+ virtual void BasicStopped();
+
+ virtual SfxUndoManager* GetUndoManager();
+};
+
+class ModulWindowLayout: public Window
+{
+private:
+
+ Splitter aVSplitter;
+ Splitter aHSplitter;
+
+ WatchWindow aWatchWindow;
+ StackWindow aStackWindow;
+
+ DECL_LINK( SplitHdl, Splitter * );
+ BOOL bVSplitted;
+ BOOL bHSplitted;
+
+ void ArrangeWindows();
+
+ ModulWindow* pModulWindow;
+
+// BOOL bDoSyntaxHighlight;
+ Color aSyntaxColors[10];
+
+ ImageList aImages;
+
+protected:
+ virtual void Resize();
+ virtual void Paint( const Rectangle& rRect );
+
+public:
+ ModulWindowLayout( Window* pParent );
+ ~ModulWindowLayout();
+
+ void DockaWindow( DockingWindow* pDockingWin );
+ BOOL IsToBeDocked( DockingWindow* pDockingWin, const Point& rPos, Rectangle& rRect );
+
+ void SetModulWindow( ModulWindow* pModWin );
+ ModulWindow* GetModulWindow() const { return pModulWindow; }
+
+ WatchWindow& GetWatchWindow() { return aWatchWindow; }
+ StackWindow& GetStackWindow() { return aStackWindow; }
+
+ Color* GetSyntaxColors() { return aSyntaxColors; }
+
+ Image GetImage( USHORT nId ) { return aImages.GetImage( nId ); }
+
+// BOOL DoHighlight() const { return bDoSyntaxHighlight; }
+// void SetHighlightMode( BOOL bHighlight )
+// { bDoSyntaxHighlight = bHighlight; }
+};
+
+#endif // _BASIDE2_HXX
diff --git a/basctl/source/basicide/baside2b.cxx b/basctl/source/basicide/baside2b.cxx
new file mode 100644
index 000000000000..ea7395325950
--- /dev/null
+++ b/basctl/source/basicide/baside2b.cxx
@@ -0,0 +1,1917 @@
+/*************************************************************************
+ *
+ * $RCSfile: baside2b.cxx,v $
+ *
+ * $Revision: 1.1.1.1 $
+ *
+ * last change: $Author: mh $ $Date: 2000-09-29 11:02:36 $
+ *
+ * The Contents of this file are made available subject to the terms of
+ * either of the following licenses
+ *
+ * - GNU Lesser General Public License Version 2.1
+ * - Sun Industry Standards Source License Version 1.1
+ *
+ * Sun Microsystems Inc., October, 2000
+ *
+ * GNU Lesser General Public License Version 2.1
+ * =============================================
+ * Copyright 2000 by Sun Microsystems, Inc.
+ * 901 San Antonio Road, Palo Alto, CA 94303, USA
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License version 2.1, as published by the Free Software Foundation.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this library; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston,
+ * MA 02111-1307 USA
+ *
+ *
+ * Sun Industry Standards Source License Version 1.1
+ * =================================================
+ * The contents of this file are subject to the Sun Industry Standards
+ * Source License Version 1.1 (the "License"); You may not use this file
+ * except in compliance with the License. You may obtain a copy of the
+ * License at http://www.openoffice.org/license.html.
+ *
+ * Software provided under this License is provided on an "AS IS" basis,
+ * WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING,
+ * WITHOUT LIMITATION, WARRANTIES THAT THE SOFTWARE IS FREE OF DEFECTS,
+ * MERCHANTABLE, FIT FOR A PARTICULAR PURPOSE, OR NON-INFRINGING.
+ * See the License for the specific provisions governing your rights and
+ * obligations concerning the Software.
+ *
+ * The Initial Developer of the Original Code is: Sun Microsystems, Inc.
+ *
+ * Copyright: 2000 by Sun Microsystems, Inc.
+ *
+ * All Rights Reserved.
+ *
+ * Contributor(s): _______________________________________
+ *
+ *
+ ************************************************************************/
+
+
+#include <svtools/svarray.hxx>
+#define _BASIC_TEXTPORTIONS
+#include <basic/sbdef.hxx>
+#include <ide_pch.hxx>
+
+#pragma hdrstop
+
+#ifndef _SBXCLASS_HXX //autogen
+#include <svtools/sbx.hxx>
+#endif
+#include <vcl/sound.hxx>
+#include <svtools/xtextedt.hxx>
+#include <svtools/txtattr.hxx>
+
+#include <baside2.hrc>
+#include <baside2.hxx>
+#include <brkdlg.hxx>
+#include <objdlg.hxx>
+#include <basobj.hxx>
+#include <iderdll.hxx>
+#include <iderdll2.hxx>
+
+#include <vcl/system.hxx>
+
+#ifndef _SFX_HELP_HXX //autogen
+#include <sfx2/sfxhelp.hxx>
+#endif
+
+
+long nVirtToolBoxHeight; // wird im WatchWindow init., im Stackwindow verw.
+
+#define SCROLL_LINE 12
+#define SCROLL_PAGE 60
+
+#define DWBORDER 3
+
+static const char cSuffixes[] = "%&!#@$";
+
+MapUnit eEditMapUnit = MAP_100TH_MM;
+
+
+void lcl_GetValues( String& rWatchStr, SbxDimArray* pArray,
+ short* pIdx, USHORT nCurrentDim )
+{
+ USHORT nDims = pArray->GetDims();
+ short nMin, nMax;
+ pArray->GetDim( nCurrentDim, nMin, nMax );
+ for ( USHORT n = nMin; n <= nMax; n++ )
+ {
+// pIdx[nDims-nCurrentDim] = n;
+ pIdx[nCurrentDim-1] = n;
+// if ( nCurrentDim > 1 )
+ if ( nCurrentDim < nDims )
+ rWatchStr += String( RTL_CONSTASCII_USTRINGPARAM( "[ " ) );
+
+// if ( nCurrentDim > 1 )
+ if ( nCurrentDim < nDims )
+// lcl_GetValues( rWatchStr, pArray, pIdx, nCurrentDim-1 );
+ lcl_GetValues( rWatchStr, pArray, pIdx, nCurrentDim+1 );
+ else
+ {
+ SbxBase* pElem = pArray->Get( pIdx );
+ if ( pElem )
+ rWatchStr += ((SbxVariable*)pElem)->GetString();
+ if ( n < nMax )
+ rWatchStr += String( RTL_CONSTASCII_USTRINGPARAM( "; " ) );
+ }
+// if ( nCurrentDim > 1 )
+ if ( nCurrentDim < nDims )
+ rWatchStr += String( RTL_CONSTASCII_USTRINGPARAM( " ]" ) );
+ }
+}
+
+
+SbxBase* lcl_FindElement( SbxDimArray* pArray, const String& rIndex, BOOL& rbValidIndex )
+{
+ rbValidIndex = FALSE;
+ SbxBase* pElem = 0;
+
+ USHORT nTokens = rIndex.GetTokenCount( ',' );
+ USHORT nDims = pArray->GetDims();
+ if ( nDims == nTokens )
+ {
+ short* pIdx = new short[ nDims ];
+ for ( USHORT n = nDims; n; )
+ pIdx[--n] = 0;
+
+ rbValidIndex = TRUE;
+ for ( USHORT nDim = nTokens; nDim; nDim--,rbValidIndex )
+ {
+ String aTmpIndex( rIndex.GetToken( nDims-nDim, ',' ) );
+ aTmpIndex.EraseLeadingChars();
+ aTmpIndex.EraseTrailingChars();
+ short nIndex = 0x7FFF;
+
+ if ( ByteString( aTmpIndex, RTL_TEXTENCODING_UTF8 ).IsNumericAscii() )
+ nIndex = (USHORT) aTmpIndex.ToInt32();
+ else
+ {
+ SbxBase* pIndexSBX = StarBASIC::FindSBXInCurrentScope( aTmpIndex );
+ if ( pIndexSBX && pIndexSBX->ISA( SbxVariable ) && !pIndexSBX->ISA( SbxMethod ) )
+ {
+ SbxVariable* pIndexVar = (SbxVariable*)pIndexSBX;
+ SbxDataType eType = pIndexVar->GetType();
+ if ( ( (BYTE)eType != (BYTE)SbxOBJECT )
+ && !( eType & SbxARRAY ) )
+ {
+ nIndex = (USHORT) pIndexVar->GetString().ToInt32();
+ }
+ }
+ }
+
+ short nMin, nMax;
+ pArray->GetDim( nDim, nMin, nMax );
+ if ( ( nIndex >= nMin ) && ( nIndex <= nMax ) )
+ pIdx[nDims-nDim] = nIndex;
+ else
+ rbValidIndex = FALSE; // Und Abbruch...
+ }
+
+ if ( rbValidIndex )
+ pElem = pArray->Get( pIdx );
+ }
+
+ return pElem;
+}
+
+void lcl_FormatArrayString( String& rResult )
+{
+ USHORT nLastSep = 0xFFFF;
+
+ // Format eines mehrdimensionalen Arrays:
+ // Beliebig tief geschachtelt.
+ // {[ [ 1;2 ][ 3;4 ] ] [ 5;6 ][ 7;8 ] ] ]}
+
+ // Geschw. Klammern nur dann entfernen, wenn sie genau am Anfang und Ende
+ // stehen, falls es einfach nur char's in einem String sind.
+ if ( ( rResult.Len() > 1 ) && ( rResult.GetChar( 0 ) == '{' ) && ( rResult.GetChar( rResult.Len() - 1 ) == '}') )
+ {
+ rResult.Erase( 0, 1 );
+ rResult.Erase( rResult.Len()-1, 1 );
+ rResult.EraseLeadingChars();
+ rResult.EraseTrailingChars();
+ }
+
+ // Jetzt die Klammern abarbeiten:
+ // Vor einer '[' muss ein Separator gewesen sein (oder Start)
+ // String stammen.
+ // Nach einer ']' muss ein Blank oder ein ']' oder ein '[' stehen.
+ USHORT nIndex = 0;
+ USHORT nLevel = 0;
+ char cLastSep = ' ';
+ BOOL bLastWasSep = TRUE;
+ while ( nIndex < rResult.Len() )
+ {
+ switch ( rResult.GetChar( nIndex ) )
+ {
+ case '[':
+ {
+ if ( bLastWasSep )
+ {
+ rResult.Erase( nIndex, 1 );
+ while ( ( nIndex < rResult.Len() ) && ( rResult.GetChar( nIndex ) == ' ' ) )
+ rResult.Erase( nIndex, 1 );
+ nLevel++;
+ cLastSep = '[';
+ bLastWasSep = TRUE;
+ }
+ else
+ nIndex++;
+ }
+ break;
+ case ']':
+ {
+ USHORT nNext = nIndex+1;
+ if ( nLevel &&
+ ( ( nNext == rResult.Len() ) || ( rResult.GetChar( nNext ) == ' ' )
+ || ( rResult.GetChar( nNext ) == '[' ) || ( rResult.GetChar( nNext ) == ']' ) ) )
+ {
+ rResult.Erase( nIndex, 1 );
+ while ( ( nIndex < rResult.Len() ) && ( rResult.GetChar( nIndex ) == ' ' ) )
+ rResult.Erase( nIndex, 1 );
+ nLevel--;
+ // vor einer ']' steht keine ';':
+ if ( cLastSep == '[' )
+ rResult.Insert( ';', nIndex++ );
+ cLastSep = ']';
+ bLastWasSep = TRUE;
+ }
+ else
+ nIndex++;
+ }
+ break;
+ default:
+ {
+ nIndex++;
+ bLastWasSep = FALSE;
+ }
+ }
+ }
+// if ( rResult.Len() && rResult[(USHORT)(rResult.Len()-1)] == ';' )
+// rResult.Erase( rResult.Len()-1 );
+}
+
+void lcl_DrawIDEWindowFrame( DockingWindow* pWin )
+{
+ if ( !pWin->IsFloatingMode() )
+ {
+ Size aSz = pWin->GetOutputSizePixel();
+ long nY = nVirtToolBoxHeight - 1;
+ const Color aOldLineColor( pWin->GetLineColor() );
+ pWin->SetLineColor( Color( COL_WHITE ) );
+ // oben eine weisse..
+ pWin->DrawLine( Point( 0, 0 ), Point( aSz.Width(), 0 ) );
+ // unten eine schwarze...
+ pWin->SetLineColor( Color( COL_BLACK ) );
+ pWin->DrawLine( Point( 0, aSz.Height() - 1 ), Point( aSz.Width(), aSz.Height() - 1 ) );
+ pWin->SetLineColor( aOldLineColor );
+ }
+}
+
+void lcl_SeparateNameAndIndex( const String& rVName, String& rVar, String& rIndex )
+{
+ rVar = rVName;
+ rIndex.Erase();
+ USHORT nIndexStart = rVar.Search( '(' );
+ if ( nIndexStart != STRING_NOTFOUND )
+ {
+ USHORT nIndexEnd = rVar.Search( ')', nIndexStart );
+ if ( nIndexStart != STRING_NOTFOUND )
+ {
+ rIndex = rVar.Copy( nIndexStart+1, nIndexEnd-nIndexStart-1 );
+ rVar.Erase( nIndexStart );
+ rVar.EraseTrailingChars();
+ rIndex.EraseLeadingChars();
+ rIndex.EraseTrailingChars();
+ }
+ }
+
+ if ( rVar.Len() )
+ {
+ USHORT nLastChar = rVar.Len()-1;
+ if ( strchr( cSuffixes, rVar.GetChar( nLastChar ) ) )
+ rVar.Erase( nLastChar, 1 );
+ }
+ if ( rIndex.Len() )
+ {
+ USHORT nLastChar = rIndex.Len()-1;
+ if ( strchr( cSuffixes, rIndex.GetChar( nLastChar ) ) )
+ rIndex.Erase( nLastChar, 1 );
+ }
+}
+
+
+EditorWindow::EditorWindow( Window* pParent ) :
+ Window( pParent, WB_BORDER )
+{
+ bDoSyntaxHighlight = TRUE;
+ bDelayHighlight = TRUE;
+ pModulWindow = 0;
+ pEditView = 0;
+ pEditEngine = 0;
+ bHighlightning = FALSE;
+ pProgress = 0;
+ nCurTextWidth = 0;
+ SetBackground( Wallpaper( COL_WHITE ) );
+ EnableDrop();
+ SetPointer( Pointer( POINTER_TEXT ) );
+}
+
+
+
+__EXPORT EditorWindow::~EditorWindow()
+{
+ aSyntaxIdleTimer.Stop();
+ aHelpAgentTimer.Stop();
+
+ if ( pEditEngine )
+ {
+ EndListening( *pEditEngine );
+ pEditEngine->RemoveView( pEditView );
+// pEditEngine->SetViewWin( 0 );
+ delete pEditView;
+ delete pEditEngine;
+ }
+}
+
+String EditorWindow::GetWordAtCursor()
+{
+// ESelection aESel( pEditView->GetSelection() );
+ // Nicht den Selektierten Bereich, sondern an der CursorPosition,
+ // falls Teil eines Worts markiert.
+ String aWord( pEditView->GetTextEngine()->GetWord( pEditView->GetSelection().GetEnd() ) );
+ // Kann leer sein, wenn komplettes Word markiert, da Cursor dahinter.
+ if ( !aWord.Len() && pEditView->HasSelection() )
+ aWord = pEditView->GetTextEngine()->GetWord( pEditView->GetSelection().GetStart() );
+ return aWord ;
+}
+
+void __EXPORT EditorWindow::RequestHelp( const HelpEvent& rHEvt )
+{
+ // Sollte eigentlich mal aktiviert werden...
+ if ( pEditEngine )
+ {
+ if ( rHEvt.GetMode() & HELPMODE_CONTEXT )
+ {
+ String aKeyword = GetWordAtCursor();
+ SfxHelp::ShowHelp( aKeyword, TRUE );
+ }
+ else if ( rHEvt.GetMode() & HELPMODE_QUICK )
+ {
+ String aHelpText;
+ Point aTopLeft;
+ if ( StarBASIC::IsRunning() )
+ {
+ Point aWindowPos = rHEvt.GetMousePosPixel();
+ aWindowPos = ScreenToOutputPixel( aWindowPos );
+ Point aDocPos = GetEditView()->GetDocPos( aWindowPos );
+ TextPaM aCursor = GetEditView()->GetTextEngine()->GetPaM( aDocPos, FALSE );
+ TextPaM aStartOfWord;
+ String aWord = GetEditView()->GetTextEngine()->GetWord( aCursor, &aStartOfWord );
+ if ( aWord.Len() && !ByteString( aWord, RTL_TEXTENCODING_UTF8 ).IsNumericAscii() )
+ {
+ USHORT nLastChar =aWord.Len()-1;
+ if ( strchr( cSuffixes, aWord.GetChar( nLastChar ) ) )
+ aWord.Erase( nLastChar, 1 );
+ SbxBase* pSBX = StarBASIC::FindSBXInCurrentScope( aWord );
+ if ( pSBX && pSBX->ISA( SbxVariable ) && !pSBX->ISA( SbxMethod ) )
+ {
+ SbxVariable* pVar = (SbxVariable*)pSBX;
+ SbxDataType eType = pVar->GetType();
+ if ( (BYTE)eType == (BYTE)SbxOBJECT )
+ // Kann zu Absturz, z.B. bei Selections-Objekt fuehren
+ // Type == Object heisst nicht, dass pVar == Object!
+ ; // aHelpText = ((SbxObject*)pVar)->GetClassName();
+ else if ( eType & SbxARRAY )
+ ; // aHelpText = "{...}";
+ else if ( (BYTE)eType != (BYTE)SbxEMPTY )
+ {
+ aHelpText = pVar->GetName();
+ if ( !aHelpText.Len() ) // Bei Uebergabeparametern wird der Name nicht kopiert
+ aHelpText = aWord;
+ aHelpText += '=';
+ aHelpText += pVar->GetString();
+ }
+ }
+ if ( aHelpText.Len() )
+ {
+ aTopLeft = GetEditView()->GetTextEngine()->PaMtoEditCursor( aStartOfWord ).BottomLeft();
+ aTopLeft = GetEditView()->GetWindowPos( aTopLeft );
+ aTopLeft.X() += 5;
+ aTopLeft.Y() += 5;
+ aTopLeft = OutputToScreenPixel( aTopLeft );
+ }
+ }
+ }
+ Help::ShowQuickHelp( this, Rectangle( aTopLeft, Size( 1, 1 ) ), aHelpText, QUICKHELP_TOP|QUICKHELP_LEFT);
+ }
+ }
+ else
+ Window::RequestHelp( rHEvt );
+}
+
+
+void __EXPORT EditorWindow::Resize()
+{
+ // ScrollBars, etc. passiert in Adjust...
+ if ( pEditView )
+ {
+ long nVisY = pEditView->GetStartDocPos().Y();
+// pEditView->SetOutputArea( Rectangle( Point( 0, 0 ), GetOutputSize() ) );
+ pEditView->ShowCursor();
+ Size aOutSz( GetOutputSizePixel() );
+ long nMaxVisAreaStart = pEditView->GetTextEngine()->GetTextHeight() - aOutSz.Height();
+ if ( nMaxVisAreaStart < 0 )
+ nMaxVisAreaStart = 0;
+ if ( pEditView->GetStartDocPos().Y() > nMaxVisAreaStart )
+ {
+ Point aStartDocPos( pEditView->GetStartDocPos() );
+ aStartDocPos.Y() = nMaxVisAreaStart;
+ pEditView->SetStartDocPos( aStartDocPos );
+ pEditView->ShowCursor();
+ pModulWindow->GetBreakPointWindow().GetCurYOffset() = aStartDocPos.Y();
+ }
+ InitScrollBars();
+ if ( nVisY != pEditView->GetStartDocPos().Y() )
+ Invalidate();
+ }
+}
+
+
+
+void __EXPORT EditorWindow::MouseMove( const MouseEvent &rEvt )
+{
+ if ( pEditView )
+ pEditView->MouseMove( rEvt );
+}
+
+
+
+void __EXPORT EditorWindow::MouseButtonUp( const MouseEvent &rEvt )
+{
+ if ( pEditView )
+ {
+ pEditView->MouseButtonUp( rEvt );
+ BasicIDE::GetBindings().Invalidate( SID_BASICIDE_STAT_POS );
+ }
+}
+
+void __EXPORT EditorWindow::MouseButtonDown( const MouseEvent &rEvt )
+{
+ GrabFocus();
+ if ( pEditView )
+ {
+ pEditView->MouseButtonDown( rEvt );
+ if ( SFX_APP()->GetHelpPI() )
+ aHelpAgentTimer.Start();
+ }
+}
+
+void __EXPORT EditorWindow::Command( const CommandEvent& rCEvt )
+{
+ if ( pEditView )
+ {
+ pEditView->Command( rCEvt );
+ if ( ( rCEvt.GetCommand() == COMMAND_WHEEL ) ||
+ ( rCEvt.GetCommand() == COMMAND_STARTAUTOSCROLL ) ||
+ ( rCEvt.GetCommand() == COMMAND_AUTOSCROLL ) )
+ {
+ HandleScrollCommand( rCEvt, pModulWindow->GetHScrollBar(), &pModulWindow->GetEditVScrollBar() );
+ }
+ }
+}
+
+BOOL __EXPORT EditorWindow::Drop( const DropEvent& rEvt )
+{
+ BOOL bDone = FALSE;
+ if ( pEditView && ImpCanModify() )
+ {
+ bDone = pEditView->Drop( rEvt );
+ if ( bDone )
+ {
+ SfxBindings& rBindings = BasicIDE::GetBindings();
+ rBindings.Invalidate( SID_BASICIDE_STAT_POS );
+ rBindings.Invalidate( SID_SAVEDOC );
+ rBindings.Invalidate( SID_DOC_MODIFIED );
+ }
+ }
+ return bDone;
+}
+
+BOOL __EXPORT EditorWindow::QueryDrop( DropEvent& rEvt )
+{
+ if ( pEditView )
+ return pEditView->QueryDrop( rEvt );
+ return FALSE;
+}
+
+
+BOOL EditorWindow::ImpCanModify()
+{
+ BOOL bCanModify = TRUE;
+ if ( StarBASIC::IsRunning() )
+ {
+ // Wenn im Trace-Mode, entweder Trace abbrechen oder
+ // Eingabe verweigern
+ // Im Notify bei Basic::Stoped die Markierungen in den Modulen
+ // entfernen!
+ if ( QueryBox( 0, WB_OK_CANCEL, String( IDEResId( RID_STR_WILLSTOPPRG ) ) ).Execute() == RET_OK )
+ {
+ pModulWindow->GetBasicStatus().bIsRunning = FALSE;
+ BasicIDE::StopBasic();
+ }
+ else
+ bCanModify = FALSE;
+ }
+ return bCanModify;
+}
+
+void __EXPORT EditorWindow::KeyInput( const KeyEvent& rKEvt )
+{
+ if ( !pEditView ) // Passiert unter W95 bei letzte Version, Ctrl-Tab
+ return;
+
+#ifdef DEBUG
+ Range aRange = pModulWindow->GetHScrollBar()->GetRange();
+ long nVisSz = pModulWindow->GetHScrollBar()->GetVisibleSize();
+ long nPapSz = pModulWindow->GetHScrollBar()->GetPageSize();
+ long nLinSz = pModulWindow->GetHScrollBar()->GetLineSize();
+ long nThumb = pModulWindow->GetHScrollBar()->GetThumbPos();
+#endif
+ BOOL bDone = FALSE;
+ BOOL bWasModified = pEditEngine->IsModified();
+ if ( !TextEngine::DoesKeyChangeText( rKEvt ) || ImpCanModify() )
+ {
+ if ( ( rKEvt.GetKeyCode().GetCode() == KEY_A) && rKEvt.GetKeyCode().IsMod1() )
+ pEditView->SetSelection( TextSelection( TextPaM( 0, 0 ), TextPaM( 0xFFFFFFFF, 0xFFFF ) ) );
+ else if ( ( rKEvt.GetKeyCode().GetCode() == KEY_Y ) && rKEvt.GetKeyCode().IsMod1() )
+ bDone = TRUE; // CTRL-Y schlucken, damit kein Vorlagenkatalog
+ else
+ {
+ if ( ( rKEvt.GetKeyCode().GetCode() == KEY_TAB ) && !rKEvt.GetKeyCode().IsMod1() && !rKEvt.GetKeyCode().IsMod2() )
+ {
+ TextSelection aSel( pEditView->GetSelection() );
+ if ( aSel.GetStart().GetPara() != aSel.GetEnd().GetPara() )
+ {
+ bDelayHighlight = FALSE;
+ if ( !rKEvt.GetKeyCode().IsShift() )
+ pEditView->IndentBlock();
+ else
+ pEditView->UnindentBlock();
+ bDelayHighlight = TRUE;
+ bDone = TRUE;
+ }
+ }
+ if ( !bDone )
+ bDone = pEditView->KeyInput( rKEvt );
+ }
+ }
+#ifndef PRODUCT
+ if( !bDone )
+ {
+ if ( ( rKEvt.GetKeyCode().GetCode() == KEY_H ) &&
+ rKEvt.GetKeyCode().IsMod1() && rKEvt.GetKeyCode().IsMod2() )
+ {
+ ToggleHighlightMode();
+ }
+ }
+#endif
+ if ( !bDone )
+ {
+ if ( !SfxViewShell::Current()->KeyInput( rKEvt ) )
+ Window::KeyInput( rKEvt );
+ }
+ else
+ {
+ SfxBindings& rBindings = BasicIDE::GetBindings();
+ rBindings.Invalidate( SID_BASICIDE_STAT_POS );
+ if ( rKEvt.GetKeyCode().GetGroup() == KEYGROUP_CURSOR )
+ rBindings.Update( SID_BASICIDE_STAT_POS );
+ if ( !bWasModified && pEditEngine->IsModified() )
+ {
+ rBindings.Invalidate( SID_SAVEDOC );
+ rBindings.Invalidate( SID_DOC_MODIFIED );
+ }
+ if( rKEvt.GetKeyCode().GetCode() == KEY_INSERT )
+ rBindings.Invalidate( SID_ATTR_INSERT );
+ if ( SFX_APP()->GetHelpPI() )
+ aHelpAgentTimer.Start();
+ }
+}
+
+void __EXPORT EditorWindow::Paint( const Rectangle& rRect )
+{
+ if ( !pEditEngine ) // spaetestens jetzt brauche ich sie...
+ CreateEditEngine();
+
+ pEditView->Paint( rRect );
+}
+
+void __EXPORT EditorWindow::LoseFocus()
+{
+ SetSourceInBasic();
+ Window::LoseFocus();
+}
+
+BOOL EditorWindow::SetSourceInBasic( BOOL bQuiet )
+{
+ BOOL bChanged = FALSE;
+ if ( pEditEngine && pEditEngine->IsModified() )
+ {
+ ULONG nLen = pEditEngine->GetTextLen();
+ if ( nLen > 0xFFFb ) // Maximale String-Laenge
+ {
+ if ( !bQuiet )
+ {
+ String aError( pModulWindow->CreateQualifiedName() );
+ aError += String( RTL_CONSTASCII_USTRINGPARAM( ":\n" ) );
+ aError += String( IDEResId( RID_STR_SOURCETOBIG ) );
+ ErrorBox( this, WB_OK | WB_DEF_OK, aError ).Execute();
+ }
+ }
+ else if ( !StarBASIC::IsRunning() ) // Nicht zur Laufzeit!
+ {
+ String aSource( pEditEngine->GetText() );
+ DBG_ASSERT( pModulWindow->GetModule(), "Kein Modul?!" );
+ pModulWindow->GetModule()->SetSource( aSource );
+ pEditEngine->SetModified( FALSE );
+ BasicIDE::MarkDocShellModified( pModulWindow->GetBasic() );
+ bChanged = TRUE;
+ }
+ }
+ return bChanged;
+}
+
+
+void EditorWindow::CreateEditEngine()
+{
+ if ( pEditEngine )
+ return;
+
+#ifdef DEBUG
+ BOOL bModified = pModulWindow->GetModule()->IsModified();
+#endif
+
+ pEditEngine = new ExtTextEngine;
+ pEditView = new ExtTextView( pEditEngine, this );
+ pEditView->SetAutoIndentMode( TRUE );
+ pEditEngine->SetUpdateMode( FALSE );
+ pEditEngine->InsertView( pEditView );
+
+ Font aFont( System::GetStandardFont( STDFONT_FIXED ) );
+ aFont.SetTransparent( FALSE );
+ Size aFontSize( 0, 10 ); // Points
+
+ aFont.SetSize( aFontSize );
+ SetPointFont( aFont );
+ aFont = GetFont();
+
+ pModulWindow->GetBreakPointWindow().SetFont( aFont );
+ pEditEngine->SetFont( aFont );
+
+ aSyntaxIdleTimer.SetTimeout( 200 );
+ aSyntaxIdleTimer.SetTimeoutHdl( LINK( this, EditorWindow, SyntaxTimerHdl ) );
+
+ aHelpAgentTimer.SetTimeout( 2000 );
+ aHelpAgentTimer.SetTimeoutHdl( LINK( this, EditorWindow, HelpAgentTimerHdl ) );
+
+ aHighlighter.initialize( HIGHLIGHT_BASIC );
+
+ bDoSyntaxHighlight = FALSE; // Bei grossen Texten zu langsam...
+ String aSource( pModulWindow->GetModule()->GetSource() );
+ aSource.ConvertLineEnd( LINEEND_LF );
+ USHORT nLines = aSource.GetTokenCount( LINE_SEP );
+
+ // nLines*4: SetText+Formatting+DoHighlight+Formatting
+ // 1 Formatting koennte eingespart werden, aber dann wartet man
+ // bei einem langen Sourcecode noch laenger auf den Text...
+ pProgress = new ProgressInfo( IDE_DLL()->GetShell()->GetViewFrame()->GetObjectShell(), String( IDEResId( RID_STR_GENERATESOURCE ) ), nLines*4 );
+ pEditEngine->SetText( aSource );
+
+ pEditView->SetStartDocPos( Point( 0, 0 ) );
+ pEditView->SetSelection( TextSelection() );
+ pModulWindow->GetBreakPointWindow().GetCurYOffset() = 0;
+ pEditEngine->SetUpdateMode( TRUE );
+ Update(); // Es wurde bei UpdateMode = TRUE nur Invalidiert
+
+ // Die anderen Fenster auch, damit keine halben Sachen auf dem Bildschirm!
+ pModulWindow->GetLayout()->GetWatchWindow().Update();
+ pModulWindow->GetLayout()->GetStackWindow().Update();
+ pModulWindow->GetBreakPointWindow().Update();
+
+ pEditView->ShowCursor( TRUE, TRUE );
+
+ StartListening( *pEditEngine );
+
+ // Das Syntax-Highlightning legt ein rel. groesse VDev an.
+ aSyntaxIdleTimer.Stop();
+ bDoSyntaxHighlight = TRUE;
+
+
+ for ( USHORT nLine = 0; nLine < nLines; nLine++ )
+ aSyntaxLineTable.Insert( nLine, (void*)(USHORT)1 );
+ ForceSyntaxTimeout();
+
+ DELETEZ( pProgress );
+
+ pEditView->EraseVirtualDevice();
+ pEditEngine->SetModified( FALSE );
+ pEditEngine->EnableUndo( TRUE );
+
+ InitScrollBars();
+
+ BasicIDE::GetBindings().Invalidate( SID_BASICIDE_STAT_POS );
+
+ DBG_ASSERT( pModulWindow->GetBreakPointWindow().GetCurYOffset() == 0, "CreateEditEngine: Brechpunkte verschoben?" );
+
+ BasicManager* pBasMgr = BasicIDE::FindBasicManager( pModulWindow->GetBasic() );
+ SfxObjectShell* pShell = BasicIDE::FindDocShell( pBasMgr );
+ if ( pShell && pShell->IsReadOnly() )
+ pEditView->SetReadOnly( TRUE );
+}
+
+void EditorWindow::Notify( SfxBroadcaster& rBC, const SfxHint& rHint )
+{
+ if ( rHint.ISA( TextHint ) )
+ {
+ const TextHint& rTextHint = (const TextHint&)rHint;
+ if( rTextHint.GetId() == TEXT_HINT_VIEWSCROLLED )
+ {
+ if ( pModulWindow->GetHScrollBar() )
+ pModulWindow->GetHScrollBar()->SetThumbPos( pEditView->GetStartDocPos().X() );
+ pModulWindow->GetEditVScrollBar().SetThumbPos( pEditView->GetStartDocPos().Y() );
+ pModulWindow->GetBreakPointWindow().Scroll( 0, pModulWindow->GetBreakPointWindow().GetCurYOffset() - pEditView->GetStartDocPos().Y() );
+ }
+ else if( rTextHint.GetId() == TEXT_HINT_TEXTHEIGHTCHANGED )
+ {
+ if ( pEditView->GetStartDocPos().Y() )
+ {
+ long nOutHeight = GetOutputSizePixel().Height();
+ long nTextHeight = pEditEngine->GetTextHeight();
+ if ( nTextHeight < nOutHeight )
+ pEditView->Scroll( 0, pEditView->GetStartDocPos().Y() );
+ }
+
+ SetScrollBarRanges();
+ }
+ else if( rTextHint.GetId() == TEXT_HINT_TEXTFORMATTED )
+ {
+ if ( pModulWindow->GetHScrollBar() )
+ {
+ ULONG nWidth = pEditEngine->CalcTextWidth();
+ if ( (long)nWidth != nCurTextWidth )
+ {
+ nCurTextWidth = nWidth;
+ pModulWindow->GetHScrollBar()->SetRange( Range( 0, (long)nCurTextWidth) );
+ pModulWindow->GetHScrollBar()->SetThumbPos( pEditView->GetStartDocPos().X() );
+ }
+ }
+ }
+ else if( rTextHint.GetId() == TEXT_HINT_PARAINSERTED )
+ {
+ ParagraphInsertedDeleted( rTextHint.GetValue(), TRUE );
+ }
+ else if( rTextHint.GetId() == TEXT_HINT_PARAREMOVED )
+ {
+ ParagraphInsertedDeleted( rTextHint.GetValue(), FALSE );
+ }
+ else if( rTextHint.GetId() == TEXT_HINT_FORMATPARA )
+ {
+ DoDelayedSyntaxHighlight( rTextHint.GetValue() );
+ }
+ }
+}
+
+
+void EditorWindow::SetScrollBarRanges()
+{
+ // Extra-Methode, nicht InitScrollBars, da auch fuer EditEngine-Events.
+ if ( !pEditEngine )
+ return;
+
+ if ( pModulWindow->GetHScrollBar() )
+ pModulWindow->GetHScrollBar()->SetRange( Range( 0, nCurTextWidth ) );
+
+ pModulWindow->GetEditVScrollBar().SetRange( Range( 0, pEditEngine->GetTextHeight() ) );
+}
+
+void EditorWindow::InitScrollBars()
+{
+ if ( !pEditEngine )
+ return;
+
+ SetScrollBarRanges();
+ Size aOutSz( GetOutputSizePixel() );
+ pModulWindow->GetEditVScrollBar().SetVisibleSize( aOutSz.Height() );
+ pModulWindow->GetEditVScrollBar().SetPageSize( aOutSz.Height() * 8 / 10 );
+ pModulWindow->GetEditVScrollBar().SetLineSize( GetTextHeight() );
+ pModulWindow->GetEditVScrollBar().SetThumbPos( pEditView->GetStartDocPos().Y() );
+ pModulWindow->GetEditVScrollBar().Show();
+
+ if ( pModulWindow->GetHScrollBar() )
+ {
+ pModulWindow->GetHScrollBar()->SetVisibleSize( aOutSz.Width() );
+ pModulWindow->GetHScrollBar()->SetPageSize( aOutSz.Width() * 8 / 10 );
+ pModulWindow->GetHScrollBar()->SetLineSize( GetTextWidth( 'x' ) );
+ pModulWindow->GetHScrollBar()->SetThumbPos( pEditView->GetStartDocPos().X() );
+ pModulWindow->GetHScrollBar()->Show();
+ }
+}
+
+void EditorWindow::ImpDoHighlight( ULONG nLine )
+{
+ String aLine( pEditEngine->GetText( nLine ) );
+ Range aChanges = aHighlighter.notifyChange( nLine, 0, &aLine, 1 );
+ if ( aChanges.Len() )
+ {
+ for ( long n = aChanges.Min() + 1; n <= aChanges.Max(); n++ )
+ aSyntaxLineTable.Insert( n, (void*)(ULONG)1 );
+ aSyntaxIdleTimer.Start();
+ }
+
+ BOOL bWasModified = pEditEngine->IsModified();
+
+ HighlightPortions aPortions;
+ aHighlighter.getHighlightPortions( nLine, aLine, aPortions );
+ USHORT nCount = aPortions.Count();
+ for ( USHORT i = 0; i < nCount; i++ )
+ {
+ HighlightPortion& r = aPortions[i];
+ USHORT nCol = r.tokenType;
+ const Color& rColor = ((ModulWindowLayout*)pModulWindow->GetLayoutWindow())->GetSyntaxColors()[nCol];
+ pEditEngine->SetAttrib( TextAttribFontColor( rColor ), nLine, r.nBegin, r.nEnd );
+ }
+
+ // Das Highlighten soll kein Modify setzen
+ pEditEngine->SetModified( bWasModified );
+}
+
+void EditorWindow::DoSyntaxHighlight( ULONG nPara )
+{
+ // Durch das DelayedSyntaxHighlight kann es passieren,
+ // dass die Zeile nicht mehr existiert!
+ if ( nPara < pEditEngine->GetParagraphCount() )
+ {
+ // leider weis ich nicht, ob genau diese Zeile Modified() ...
+ if ( pProgress )
+ pProgress->StepProgress();
+ pEditEngine->RemoveAttribs( nPara );
+ ImpDoHighlight( nPara );
+ }
+}
+
+void EditorWindow::DoDelayedSyntaxHighlight( ULONG nPara )
+{
+ // Zeile wird nur in 'Liste' aufgenommen, im TimerHdl abgearbeitet.
+ // => Nicht Absaetze manipulieren, waehrend EditEngine formatiert.
+ if ( pProgress )
+ pProgress->StepProgress();
+
+ if ( !bHighlightning && bDoSyntaxHighlight )
+ {
+ if ( bDelayHighlight )
+ {
+ aSyntaxLineTable.Insert( nPara, (void*)(ULONG)1 );
+ aSyntaxIdleTimer.Start();
+ }
+ else
+ DoSyntaxHighlight( nPara );
+ }
+}
+
+IMPL_LINK( EditorWindow, HelpAgentTimerHdl, Timer *, EMPTYARG )
+{
+ SfxHelpPI* pHelpAgent = SFX_APP()->GetHelpPI();
+ if ( pHelpAgent)
+ {
+ pHelpAgent->LoadTopic( GetWordAtCursor() );
+ }
+ return 0;
+}
+
+IMPL_LINK( EditorWindow, SyntaxTimerHdl, Timer *, EMPTYARG )
+{
+ DBG_ASSERT( pEditView, "Noch keine View, aber Syntax-Highlight ?!" );
+
+ BOOL bWasModified = pEditEngine->IsModified();
+ pEditEngine->SetUpdateMode( FALSE );
+
+ bHighlightning = TRUE;
+ USHORT nLine;
+ void* p = aSyntaxLineTable.First();
+ while ( p )
+ {
+ nLine = (USHORT)aSyntaxLineTable.GetCurKey();
+ DoSyntaxHighlight( nLine );
+ p = aSyntaxLineTable.Next();
+ }
+ if ( aSyntaxLineTable.Count() > 3 ) // Ohne VDev
+ {
+ pEditEngine->SetUpdateMode( TRUE );
+ pEditView->ShowCursor( TRUE, TRUE );
+ }
+ else
+ pEditEngine->SetUpdateMode( TRUE ); // ! Mit VDev
+// pEditView->ForceUpdate();
+
+ pEditEngine->SetModified( bWasModified );
+
+ aSyntaxLineTable.Clear();
+ // SyntaxTimerHdl wird gerufen, wenn Text-Aenderung
+ // => gute Gelegenheit, Textbreite zu ermitteln!
+ long nPrevTextWidth = nCurTextWidth;
+ nCurTextWidth = pEditEngine->CalcTextWidth();
+ if ( nCurTextWidth != nPrevTextWidth )
+ SetScrollBarRanges();
+ bHighlightning = FALSE;
+
+
+ return 0;
+}
+
+void EditorWindow::ParagraphInsertedDeleted( ULONG nPara, BOOL bInserted )
+{
+ if ( pProgress )
+ pProgress->StepProgress();
+
+ if ( !bInserted && ( nPara == TEXT_PARA_ALL ) )
+ {
+ pModulWindow->GetBreakPoints().Reset();
+ pModulWindow->GetBreakPointWindow().Invalidate();
+ aHighlighter.initialize( HIGHLIGHT_BASIC );
+ }
+ else
+ {
+ // Brechpunkte Aktualisieren...
+ // keine Sonderbehandlung fuer EditEngine-CTOR ( Erste-Zeile-Problem ),
+ // da in diesem Moment noch keine BreakPoints.
+ // +1: Basic-Zeilen beginnen bei 1!
+ pModulWindow->GetBreakPoints().AdjustBreakPoints( (USHORT)nPara+1, bInserted );
+
+ // Im BreakPointWindow invalidieren...
+ long nLineHeight = GetTextHeight();
+ Size aSz = pModulWindow->GetBreakPointWindow().GetOutputSize();
+ Rectangle aInvRec( Point( 0, 0 ), aSz );
+ long nY = nPara*nLineHeight - pModulWindow->GetBreakPointWindow().GetCurYOffset();
+ aInvRec.Top() = nY;
+ pModulWindow->GetBreakPointWindow().Invalidate( aInvRec );
+
+ String aDummy;
+ aHighlighter.notifyChange( nPara, bInserted ? 1 : (-1), &aDummy, 1 );
+ }
+}
+
+void EditorWindow::ToggleHighlightMode()
+{
+ bDoSyntaxHighlight = !bDoSyntaxHighlight;
+ if ( !pEditEngine )
+ return;
+
+
+ if ( bDoSyntaxHighlight )
+ {
+ for ( ULONG i = 0; i < pEditEngine->GetParagraphCount(); i++ )
+ DoDelayedSyntaxHighlight( i );
+ }
+ else
+ {
+ aSyntaxIdleTimer.Stop();
+ pEditEngine->SetUpdateMode( FALSE );
+ for ( ULONG i = 0; i < pEditEngine->GetParagraphCount(); i++ )
+ pEditEngine->RemoveAttribs( i );
+
+// pEditEngine->QuickFormatDoc();
+ pEditEngine->SetUpdateMode( TRUE );
+ pEditView->ShowCursor(TRUE, TRUE );
+ }
+}
+
+
+void EditorWindow::CreateProgress( const String& rText, ULONG nRange )
+{
+ DBG_ASSERT( !pProgress, "ProgressInfo existiert schon" );
+ pProgress = new ProgressInfo( ProgressInfo( IDE_DLL()->GetShell()->GetViewFrame()->GetObjectShell(), rText, nRange ) );
+}
+
+void EditorWindow::DestroyProgress()
+{
+ DELETEZ( pProgress );
+}
+
+void EditorWindow::ForceSyntaxTimeout()
+{
+ aSyntaxIdleTimer.Stop();
+ ((Link&)aSyntaxIdleTimer.GetTimeoutHdl()).Call( &aSyntaxIdleTimer );
+}
+
+
+
+BreakPointWindow::BreakPointWindow( Window* pParent ) :
+ Window( pParent, WB_BORDER )
+{
+ pModulWindow = 0;
+ nCurYOffset = 0;
+ SetLineColor( Color( COL_BLACK ) );
+ SetBackground( Wallpaper( COL_WHITE ) );
+ nMarkerPos = MARKER_NOMARKER;
+
+ // nCurYOffset merken und nicht von EditEngine holen.
+ // Falls in EditEngine autom. gescrollt wurde, wuesste ich sonst nicht,
+ // wo ich gerade stehe.
+}
+
+
+
+__EXPORT BreakPointWindow::~BreakPointWindow()
+{
+ aBreakPointList.Reset();
+}
+
+
+
+void __EXPORT BreakPointWindow::Resize()
+{
+/// Invalidate();
+}
+
+
+
+void __EXPORT BreakPointWindow::Paint( const Rectangle& )
+{
+ if ( SyncYOffset() )
+ return;
+
+ Size aOutSz( GetOutputSize() );
+ long nLineHeight = GetTextHeight();
+
+ Image aBrk1( ((ModulWindowLayout*)pModulWindow->GetLayoutWindow())->GetImage( IMGID_BRKENABLED ) );
+ Image aBrk0( ((ModulWindowLayout*)pModulWindow->GetLayoutWindow())->GetImage( IMGID_BRKDISABLED ) );
+ Size aBmpSz( aBrk1.GetSizePixel() );
+ aBmpSz = PixelToLogic( aBmpSz );
+ Point aBmpOff( 0, 0 );
+ aBmpOff.X() = ( aOutSz.Width() - aBmpSz.Width() ) / 2;
+ aBmpOff.Y() = ( nLineHeight - aBmpSz.Height() ) / 2;
+
+ BreakPoint* pBrk = GetBreakPoints().First();
+ while ( pBrk )
+ {
+ ULONG nLine = pBrk->nLine-1;
+ ULONG nY = nLine*nLineHeight - nCurYOffset;
+ DrawImage( Point( 0, nY ) + aBmpOff, pBrk->bEnabled ? aBrk1 : aBrk0 );
+ pBrk = GetBreakPoints().Next();
+ }
+ ShowMarker( TRUE );
+}
+
+
+
+void BreakPointWindow::Scroll( long nHorzScroll, long nVertScroll )
+{
+ nCurYOffset -= nVertScroll;
+ Window::Scroll( nHorzScroll, nVertScroll );
+}
+
+
+
+void BreakPointWindow::SetMarkerPos( USHORT nLine, BOOL bError )
+{
+ if ( SyncYOffset() )
+ Update();
+
+ ShowMarker( FALSE ); // Alten wegzeichen...
+ nMarkerPos = nLine;
+ bErrorMarker = bError;
+ ShowMarker( TRUE ); // Neuen zeichnen...
+}
+
+void BreakPointWindow::ShowMarker( BOOL bShow )
+{
+ if ( nMarkerPos == MARKER_NOMARKER )
+ return;
+
+ Size aOutSz( GetOutputSize() );
+ long nLineHeight = GetTextHeight();
+
+ Image aMarker;
+ if ( bErrorMarker )
+ aMarker = ((ModulWindowLayout*)pModulWindow->GetLayoutWindow())->GetImage( IMGID_ERRORMARKER );
+ else
+ aMarker = ((ModulWindowLayout*)pModulWindow->GetLayoutWindow())->GetImage( IMGID_STEPMARKER );
+
+ Size aMarkerSz( aMarker.GetSizePixel() );
+ aMarkerSz = PixelToLogic( aMarkerSz );
+ Point aMarkerOff( 0, 0 );
+ aMarkerOff.X() = ( aOutSz.Width() - aMarkerSz.Width() ) / 2;
+ aMarkerOff.Y() = ( nLineHeight - aMarkerSz.Height() ) / 2;
+
+ ULONG nY = nMarkerPos*nLineHeight - nCurYOffset;
+ Point aPos( 0, nY );
+ aPos += aMarkerOff;
+ if ( bShow )
+ DrawImage( aPos, aMarker );
+ else
+ Invalidate( Rectangle( aPos, aMarkerSz ) );
+}
+
+
+
+
+BreakPoint* BreakPointWindow::FindBreakPoint( const Point& rMousePos )
+{
+ long nLineHeight = GetTextHeight();
+ long nYPos = rMousePos.Y() + nCurYOffset;
+// Image aBrk( ((ModulWindowLayout*)pModulWindow->GetLayoutWindow())->GetImage( IMGID_BRKENABLED ) );
+// Size aBmpSz( aBrk.GetSizePixel() );
+// aBmpSz = PixelToLogic( aBmpSz );
+
+ BreakPoint* pBrk = GetBreakPoints().First();
+ while ( pBrk )
+ {
+ ULONG nLine = pBrk->nLine-1;
+ long nY = nLine*nLineHeight;
+ if ( ( nYPos > nY ) && ( nYPos < ( nY + nLineHeight ) ) )
+ return pBrk;
+ pBrk = GetBreakPoints().Next();
+ }
+ return 0;
+}
+
+void __EXPORT BreakPointWindow::MouseButtonDown( const MouseEvent& rMEvt )
+{
+ if ( rMEvt.GetClicks() == 2 )
+ {
+ Point aMousePos( PixelToLogic( rMEvt.GetPosPixel() ) );
+ long nLineHeight = GetTextHeight();
+ long nYPos = aMousePos.Y() + nCurYOffset;
+ long nLine = nYPos / nLineHeight + 1;
+ pModulWindow->ToggleBreakPoint( (ULONG)nLine );
+ // vielleicht mal etwas genauer...
+ Invalidate();
+ }
+}
+
+
+
+void __EXPORT BreakPointWindow::Command( const CommandEvent& rCEvt )
+{
+ if ( rCEvt.GetCommand() == COMMAND_CONTEXTMENU )
+ {
+ Point aPos( rCEvt.IsMouseEvent() ? rCEvt.GetMousePosPixel() : Point(1,1) );
+ Point aEventPos( PixelToLogic( aPos ) );
+ BreakPoint* pBrk = rCEvt.IsMouseEvent() ? FindBreakPoint( aEventPos ) : 0;
+ if ( pBrk )
+ {
+ // prueffen, ob Brechpunkt enabled....
+ PopupMenu aBrkPropMenu( IDEResId( RID_POPUP_BRKPROPS ) );
+ aBrkPropMenu.CheckItem( RID_ACTIV, pBrk->bEnabled );
+ switch ( aBrkPropMenu.Execute( this, aPos ) )
+ {
+ case RID_ACTIV:
+ {
+ pBrk->bEnabled = pBrk->bEnabled ? FALSE : TRUE;
+ pModulWindow->UpdateBreakPoint( *pBrk );
+ Invalidate();
+ }
+ break;
+ case RID_BRKPROPS:
+ {
+ BreakPointDialog aBrkDlg( this, GetBreakPoints() );
+ aBrkDlg.SetCurrentBreakPoint( *pBrk );
+ aBrkDlg.Execute();
+ Invalidate();
+ }
+ break;
+ }
+ }
+ else
+ {
+ PopupMenu aBrkListMenu( IDEResId( RID_POPUP_BRKDLG ) );
+ switch ( aBrkListMenu.Execute( this, aPos ) )
+ {
+ case RID_BRKDLG:
+ {
+ BreakPointDialog aBrkDlg( this, GetBreakPoints() );
+ aBrkDlg.Execute();
+ Invalidate();
+ }
+ break;
+ }
+ }
+ }
+}
+
+BOOL BreakPointWindow::SyncYOffset()
+{
+ TextView* pView = pModulWindow->GetEditView();
+ if ( pView )
+ {
+ long nViewYOffset = pView->GetStartDocPos().Y();
+ if ( nCurYOffset != nViewYOffset )
+ {
+ nCurYOffset = nViewYOffset;
+ Invalidate();
+ return TRUE;
+ }
+ }
+ return FALSE;
+}
+
+
+/*
+
+
+void __EXPORT BreakPointWindow::MouseMove( const MouseEvent &rEvt )
+{
+}
+
+
+
+void __EXPORT BreakPointWindow::MouseButtonUp( const MouseEvent &rEvt )
+{
+}
+
+
+
+
+BOOL __EXPORT BreakPointWindow::Drop( const DropEvent& rEvt )
+{
+}
+
+
+
+BOOL __EXPORT BreakPointWindow::QueryDrop( const DropEvent& rEvt )
+{
+}
+*/
+
+
+
+WatchWindow::WatchWindow( Window* pParent ) :
+ BasicDockingWindow( pParent ),
+ aTreeListBox( this, WB_BORDER | WB_3DLOOK | WB_HASBUTTONS | WB_HASLINES | WB_HSCROLL ),
+ aXEdit( this, IDEResId( RID_EDT_WATCHEDIT ) ),
+ aWatchStr( IDEResId( RID_STR_REMOVEWATCH ) ),
+ aRemoveWatchButton( this, IDEResId( RID_IMGBTN_REMOVEWATCH ) )
+{
+ nVirtToolBoxHeight = aXEdit.GetSizePixel().Height() + 7;
+
+ aTreeListBox.EnableInplaceEditing( TRUE );
+ aTreeListBox.SetSelectHdl( LINK( this, WatchWindow, TreeListHdl ) );
+ aTreeListBox.SetPosPixel( Point( DWBORDER, nVirtToolBoxHeight ) );
+ aTreeListBox.SetHighlightRange();
+
+ aRemoveWatchButton.Disable();
+
+ aTreeListBox.Show();
+
+ long nTextLen = GetTextWidth( aWatchStr ) + DWBORDER;
+ aXEdit.SetPosPixel( Point( nTextLen, 3 ) );
+ aXEdit.SetAccHdl( LINK( this, WatchWindow, EditAccHdl ) );
+ aXEdit.GetAccelerator().InsertItem( 1, KeyCode( KEY_RETURN ) );
+ aXEdit.GetAccelerator().InsertItem( 2, KeyCode( KEY_ESCAPE ) );
+ aXEdit.Show();
+
+ aRemoveWatchButton.SetClickHdl( LINK( this, WatchWindow, ButtonHdl ) );
+ aRemoveWatchButton.SetPosPixel( Point( nTextLen + aXEdit.GetSizePixel().Width() + 4, 2 ) );
+ Size aSz( aRemoveWatchButton.GetImage().GetSizePixel() );
+ aSz.Width() += 6;
+ aSz.Height() += 6;
+ aRemoveWatchButton.SetSizePixel( aSz );
+ aRemoveWatchButton.Show();
+
+ SetText( String( IDEResId( RID_STR_WATCHNAME ) ) );
+#ifndef VCL
+#ifdef UNX
+ aFont=GetFont();
+ aFont.SetTransparent(TRUE);
+ SetFont(aFont);
+#endif
+#endif
+}
+
+
+
+__EXPORT WatchWindow::~WatchWindow()
+{
+}
+
+
+
+void __EXPORT WatchWindow::Paint( const Rectangle& )
+{
+ DrawText( Point( DWBORDER, 7 ), aWatchStr );
+ lcl_DrawIDEWindowFrame( this );
+}
+
+
+
+void __EXPORT WatchWindow::Resize()
+{
+ Size aSz = GetOutputSizePixel();
+ Size aBoxSz( aSz.Width() - 2*DWBORDER, aSz.Height() - nVirtToolBoxHeight - DWBORDER );
+
+ if ( aBoxSz.Width() < 4 ) // < 4, weil noch Border...
+ aBoxSz.Width() = 0;
+ if ( aBoxSz.Height() < 4 )
+ aBoxSz.Height() = 0;
+
+ aTreeListBox.SetSizePixel( aBoxSz );
+
+ Invalidate(); //Wegen DrawLine im Paint...
+}
+
+
+
+void WatchWindow::AddWatch( const String& rVName )
+{
+ // TRUE/FALSE: ChildsOnDemand => Fuer properties
+ SvLBoxEntry* pNewEntry = aTreeListBox.InsertEntry( rVName, 0, FALSE, LIST_APPEND );
+ // Den Variablen-Namen ranhaengen, da der Text des Entries
+ // immer um den Wert der Wariablen ergaenzt wird.
+ pNewEntry->SetUserData( new String( rVName ) );
+ aTreeListBox.Select( pNewEntry, TRUE );
+ aTreeListBox.MakeVisible( pNewEntry );
+ aRemoveWatchButton.Enable();
+}
+
+
+
+BOOL WatchWindow::RemoveSelectedWatch()
+{
+ SvLBoxEntry* pEntry = aTreeListBox.GetCurEntry();
+ if ( pEntry )
+ {
+ aTreeListBox.GetModel()->Remove( pEntry );
+ pEntry = aTreeListBox.GetCurEntry();
+ if ( pEntry )
+ aXEdit.SetText( *((String*)pEntry->GetUserData()) );
+ else
+ aXEdit.SetText( String() );
+ if ( !aTreeListBox.GetEntryCount() )
+ aRemoveWatchButton.Disable();
+ return TRUE;
+ }
+ else
+ return FALSE;
+}
+
+
+IMPL_LINK_INLINE_START( WatchWindow, ButtonHdl, ImageButton *, pButton )
+{
+ if ( pButton == &aRemoveWatchButton )
+ {
+ SfxViewFrame* pCurFrame = SfxViewFrame::Current();
+ DBG_ASSERT( pCurFrame != NULL, "No current view frame!" );
+ SfxDispatcher* pDispatcher = pCurFrame ? pCurFrame->GetDispatcher() : NULL;
+ if( pDispatcher )
+ {
+ pDispatcher->Execute( SID_BASICIDE_REMOVEWATCH );
+ }
+ }
+ return 0;
+}
+IMPL_LINK_INLINE_END( WatchWindow, ButtonHdl, ImageButton *, pButton )
+
+
+
+IMPL_LINK_INLINE_START( WatchWindow, TreeListHdl, SvTreeListBox *, EMPTYARG )
+{
+ SvLBoxEntry* pCurEntry = aTreeListBox.GetCurEntry();
+ if ( pCurEntry && pCurEntry->GetUserData() )
+ aXEdit.SetText( *((String*)pCurEntry->GetUserData()) );
+
+ return 0;
+}
+IMPL_LINK_INLINE_END( WatchWindow, TreeListHdl, SvTreeListBox *, EMPTYARG )
+
+
+
+IMPL_LINK( WatchWindow, EditAccHdl, Accelerator *, pAcc )
+{
+ switch ( pAcc->GetCurKeyCode().GetCode() )
+ {
+ case KEY_RETURN:
+ {
+ String aCurText( aXEdit.GetText() );
+ if ( aCurText.Len() )
+ {
+ AddWatch( aCurText );
+ aXEdit.SetSelection( Selection( 0, 0xFFFF ) );
+ UpdateWatches();
+ }
+ else
+ Sound::Beep();
+ }
+ break;
+ case KEY_ESCAPE:
+ {
+ aXEdit.SetText( String() );
+ }
+ break;
+ }
+
+ return 0;
+}
+
+void WatchWindow::UpdateWatches()
+{
+ aTreeListBox.UpdateWatches();
+}
+
+
+StackWindow::StackWindow( Window* pParent ) :
+ BasicDockingWindow( pParent ),
+ aGotoCallButton( this, IDEResId( RID_IMGBTN_GOTOCALL ) ),
+ aTreeListBox( this, WB_BORDER | WB_3DLOOK | WB_HSCROLL ),
+ aStackStr( IDEResId( RID_STR_STACK ) )
+{
+
+ aTreeListBox.SetPosPixel( Point( DWBORDER, nVirtToolBoxHeight ) );
+ aTreeListBox.SetHighlightRange();
+ aTreeListBox.Show();
+
+ SetText( String( IDEResId( RID_STR_STACKNAME ) ) );
+
+ aGotoCallButton.SetClickHdl( LINK( this, StackWindow, ButtonHdl ) );
+ aGotoCallButton.SetPosPixel( Point( DWBORDER, 2 ) );
+ Size aSz( aGotoCallButton.GetImage().GetSizePixel() );
+ aSz.Width() += 6;
+ aSz.Height() += 6;
+ aGotoCallButton.SetSizePixel( aSz );
+// aGotoCallButton.Show(); // wird vom Basic noch nicht unterstuetzt!
+ aGotoCallButton.Hide();
+#ifndef VCL
+#ifdef UNX
+ aFont=GetFont();
+ aFont.SetTransparent(TRUE);
+ SetFont(aFont);
+#endif
+#endif
+}
+
+
+
+__EXPORT StackWindow::~StackWindow()
+{
+}
+
+
+
+void __EXPORT StackWindow::Paint( const Rectangle& )
+{
+ DrawText( Point( DWBORDER, 7 ), aStackStr );
+ lcl_DrawIDEWindowFrame( this );
+}
+
+
+
+void __EXPORT StackWindow::Resize()
+{
+ Size aSz = GetOutputSizePixel();
+ Size aBoxSz( aSz.Width() - 2*DWBORDER, aSz.Height() - nVirtToolBoxHeight - DWBORDER );
+
+ if ( aBoxSz.Width() < 4 ) // < 4, weil noch Border...
+ aBoxSz.Width() = 0;
+ if ( aBoxSz.Height() < 4 )
+ aBoxSz.Height() = 0;
+
+ aTreeListBox.SetSizePixel( aBoxSz );
+
+ Invalidate(); //Wegen DrawLine im Paint...
+}
+
+
+
+IMPL_LINK_INLINE_START( StackWindow, ButtonHdl, ImageButton *, pButton )
+{
+ if ( pButton == &aGotoCallButton )
+ {
+ SfxViewFrame* pCurFrame = SfxViewFrame::Current();
+ DBG_ASSERT( pCurFrame != NULL, "No current view frame!" );
+ SfxDispatcher* pDispatcher = pCurFrame ? pCurFrame->GetDispatcher() : NULL;
+ if( pDispatcher )
+ {
+ pDispatcher->Execute( SID_BASICIDE_GOTOCALL );
+ }
+ }
+ return 0;
+}
+IMPL_LINK_INLINE_END( StackWindow, ButtonHdl, ImageButton *, pButton )
+
+
+
+void __EXPORT StackWindow::UpdateCalls()
+{
+ aTreeListBox.SetUpdateMode( FALSE );
+ aTreeListBox.Clear();
+ USHORT nScope = 0;
+ String aCaller;
+
+ SbxError eOld = SbxBase::GetError();
+
+ SbMethod* pMethod = StarBASIC::GetActiveMethod( nScope );
+ while ( pMethod )
+ {
+ String aEntry( String::CreateFromInt32(nScope ));
+ if ( aEntry.Len() < 2 )
+ aEntry.Insert( ' ', 0 );
+ aEntry += String( RTL_CONSTASCII_USTRINGPARAM( ": " ) );
+ aEntry += pMethod->GetName();
+ SbxArray* pParams = pMethod->GetParameters();
+ SbxInfo* pInfo = pMethod->GetInfo();
+ if ( pParams )
+ {
+ aEntry += '(';
+ // 0 ist der Name der Sub...
+ for ( USHORT nParam = 1; nParam < pParams->Count(); nParam++ )
+ {
+ SbxVariable* pVar = pParams->Get( nParam );
+ DBG_ASSERT( pVar, "Parameter?!" );
+ if ( pVar->GetName().Len() )
+ aEntry += pVar->GetName();
+ else if ( pInfo )
+ {
+ const SbxParamInfo* pParam = pInfo->GetParam( nParam );
+ if ( pParam )
+ aEntry += pParam->aName;
+ }
+ aEntry += '=';
+ if( pVar->GetType() & SbxARRAY )
+ aEntry += String( RTL_CONSTASCII_USTRINGPARAM( "..." ) );
+ else
+ aEntry += pVar->GetString();
+ if ( nParam < ( pParams->Count() - 1 ) )
+ aEntry += String( RTL_CONSTASCII_USTRINGPARAM( ", " ) );
+ }
+ aEntry += ')';
+ }
+ aTreeListBox.InsertEntry( aEntry, 0, FALSE, LIST_APPEND );
+ nScope++;
+ pMethod = StarBASIC::GetActiveMethod( nScope );
+ }
+
+ SbxBase::ResetError();
+ if( eOld != SbxERR_OK )
+ SbxBase::SetError( eOld );
+
+ aTreeListBox.SetUpdateMode( TRUE );
+}
+
+
+
+
+ComplexEditorWindow::ComplexEditorWindow( ModulWindow* pParent ) :
+ Window( pParent, WB_3DLOOK | WB_CLIPCHILDREN ),
+ aEWVScrollBar( this, WB_VSCROLL | WB_DRAG ),
+ aBrkWindow( this ),
+ aEdtWindow( this )
+{
+ aEdtWindow.SetModulWindow( pParent );
+ aBrkWindow.SetModulWindow( pParent );
+ aEdtWindow.Show();
+ aBrkWindow.Show();
+
+ aEWVScrollBar.SetLineSize( SCROLL_LINE );
+ aEWVScrollBar.SetPageSize( SCROLL_PAGE );
+ aEWVScrollBar.SetScrollHdl( LINK( this, ComplexEditorWindow, ScrollHdl ) );
+ aEWVScrollBar.Show();
+}
+
+
+
+void __EXPORT ComplexEditorWindow::Resize()
+{
+ Size aOutSz = GetOutputSizePixel();
+ Size aSz( aOutSz );
+ aSz.Width() -= 2*DWBORDER;
+ aSz.Height() -= 2*DWBORDER;
+ long nBrkWidth = 20;
+ long nSBWidth = aEWVScrollBar.GetSizePixel().Width();
+
+ Size aBrkSz( Size( nBrkWidth, aSz.Height() ) );
+ aBrkWindow.SetPosSizePixel( Point( DWBORDER, DWBORDER ), aBrkSz );
+
+#ifndef VCL
+#ifdef UNX
+ Size aEWSz( Size( aSz.Width() - nBrkWidth - nSBWidth, aSz.Height() ) );
+ aEdtWindow.SetPosSizePixel( Point( DWBORDER+aBrkSz.Width(), DWBORDER ), aEWSz );
+#else
+ Size aEWSz( Size( aSz.Width() - nBrkWidth - nSBWidth + 2, aSz.Height() ) );
+ aEdtWindow.SetPosSizePixel( Point( DWBORDER+aBrkSz.Width()-1, DWBORDER ), aEWSz );
+#endif
+#else
+ Size aEWSz( Size( aSz.Width() - nBrkWidth - nSBWidth + 2, aSz.Height() ) );
+ aEdtWindow.SetPosSizePixel( Point( DWBORDER+aBrkSz.Width()-1, DWBORDER ), aEWSz );
+#endif
+
+ aEWVScrollBar.SetPosSizePixel( Point( aOutSz.Width()-DWBORDER-nSBWidth, DWBORDER ), Size( nSBWidth, aSz.Height() ) );
+
+ // Macht das EditorWindow, ausserdem hier falsch, da Pixel
+// aEWVScrollBar.SetPageSize( aEWSz.Height() * 8 / 10 );
+// aEWVScrollBar.SetVisibleSize( aSz.Height() );
+// Invalidate();
+}
+
+
+
+void __EXPORT ComplexEditorWindow::Paint( const Rectangle& rRect )
+{
+#ifdef WIN
+ Point aPos( aEWVScrollBar.GetPosPixel() );
+ Size aSz( aEWVScrollBar.GetSizePixel() );
+ const Color aOldLineColor( GetLineColor() );
+ SetLineColor( Color( COL_GRAY ) );
+ DrawLine( Point( aPos.X(), aPos.Y() - 1 ), Point( aPos.X() + aSz.Width(), aPos.Y() - 1 ) );
+ SetLineColor( Color( COL_WHITE ) );
+ DrawLine( Point( aPos.X() + aSz.Width(), aPos.Y() - 1 ), Point( aPos.X() + aSz.Width(), aPos.Y() + aSz.Height() ) );
+ DrawLine( Point( aPos.X(), aPos.Y() + aSz.Height() ), Point( aPos.X() + aSz.Width(), aPos.Y() + aSz.Height() ) );
+ SetLineColor( aOldLineColor );
+#endif
+}
+
+
+IMPL_LINK( ComplexEditorWindow, ScrollHdl, ScrollBar *, pCurScrollBar )
+{
+ if ( aEdtWindow.GetEditView() )
+ {
+ DBG_ASSERT( pCurScrollBar == &aEWVScrollBar, "Wer scrollt hier ?" );
+ long nDiff = aEdtWindow.GetEditView()->GetStartDocPos().Y() - pCurScrollBar->GetThumbPos();
+ aEdtWindow.GetEditView()->Scroll( 0, nDiff );
+ aBrkWindow.Scroll( 0, nDiff );
+ aEdtWindow.GetEditView()->ShowCursor( FALSE, TRUE );
+ pCurScrollBar->SetThumbPos( aEdtWindow.GetEditView()->GetStartDocPos().Y() );
+ }
+
+ return 0;
+}
+
+
+
+WatchTreeListBox::WatchTreeListBox( Window* pParent, WinBits nWinBits )
+ : SvTreeListBox( pParent, nWinBits )
+{
+}
+
+WatchTreeListBox::~WatchTreeListBox()
+{
+ // User-Daten zerstoeren...
+ SvLBoxEntry* pEntry = First();
+ while ( pEntry )
+ {
+ delete (String*)pEntry->GetUserData();
+ pEntry = Next( pEntry );
+ }
+}
+
+BOOL __EXPORT WatchTreeListBox::EditingEntry( SvLBoxEntry* pEntry, Selection& rSel )
+{
+ BOOL bEdit = FALSE;
+ if ( StarBASIC::IsRunning() && StarBASIC::GetActiveMethod() && !SbxBase::IsError() )
+ {
+ String aEntryText( GetEntryText( pEntry ) );
+ USHORT nPos = aEntryText.Search( '=' );
+ if ( nPos != STRING_NOTFOUND )
+ aEditingRes = aEntryText.Copy( nPos+1);
+ else
+ aEditingRes.Erase();
+ aEditingRes.EraseLeadingChars();
+ aEditingRes.EraseTrailingChars();
+
+ bEdit = TRUE;
+ }
+
+ if ( !bEdit )
+ Sound::Beep();
+
+ return bEdit;
+}
+
+BOOL __EXPORT WatchTreeListBox::EditedEntry( SvLBoxEntry* pEntry, const String& rNewText )
+{
+ USHORT nPos = rNewText.Search( '=' );
+ String aVName, aResult;
+ aVName = rNewText.Copy( 0, nPos );
+ if ( nPos != STRING_NOTFOUND )
+ aResult = rNewText.Copy( nPos+1);
+ aVName.EraseLeadingChars();
+ aVName.EraseTrailingChars();
+ aResult.EraseLeadingChars();
+ aResult.EraseTrailingChars();
+
+ BOOL bVarModified = ( aVName != *((String*)pEntry->GetUserData()) ) ? TRUE : FALSE;
+ BOOL bResModified = ( aResult != aEditingRes ) ? TRUE : FALSE;
+
+ BOOL bError = FALSE;
+
+ if ( !aVName.Len() )
+ bError = TRUE;
+
+ if ( bVarModified && !bError )
+ {
+ delete (String*)pEntry->GetUserData();
+ pEntry->SetUserData( new String( aVName ) );
+ }
+
+ if ( aVName.Len() && strchr( cSuffixes, aVName.GetChar( aVName.Len() - 1 ) ) )
+ {
+ aVName.Erase( aVName.Len()-1, 1 );
+ if ( !aVName.Len() )
+ bError = TRUE;
+ }
+
+ BOOL bRet = FALSE;
+
+ if ( bError )
+ Sound::Beep();
+ else if ( bResModified )
+ {
+ bRet = ImplBasicEntryEdited( pEntry, aVName, aResult );
+ }
+
+ return bRet;
+}
+
+BOOL WatchTreeListBox::ImplBasicEntryEdited( SvLBoxEntry* pEntry, const String& rVName, const String& rResult )
+{
+ BOOL bError = FALSE;
+ String aResult( rResult );
+ String aVar, aIndex;
+ lcl_SeparateNameAndIndex( rVName, aVar, aIndex );
+ SbxBase* pToBeChanged = 0;
+ SbxBase* pSBX = StarBASIC::FindSBXInCurrentScope( aVar );
+ if ( pSBX && pSBX->ISA( SbxVariable ) && !pSBX->ISA( SbxMethod ) )
+ {
+ SbxVariable* pVar = (SbxVariable*)pSBX;
+ SbxDataType eType = pVar->GetType();
+ if ( (BYTE)eType == (BYTE)SbxOBJECT )
+ bError = TRUE;
+ else if ( eType & SbxARRAY )
+ {
+ SbxBase* pBase = pVar->GetObject();
+ if ( pBase && pBase->ISA( SbxDimArray ) )
+ {
+ SbxDimArray* pArray = (SbxDimArray*)pBase;
+ if ( !aIndex.Len() )
+ {
+ // Das Array auf das Format XX;XX;XX formatieren lassen,
+ // wenn TokenCount == Array-Groesse, Werte reinplaetten.
+ lcl_FormatArrayString( aResult );
+ USHORT nVars = pArray->Count();
+ if ( aResult.GetTokenCount() == (nVars+1) )
+ {
+ for ( USHORT nVar = 0; nVar < nVars; nVar++,bError )
+ {
+ SbxBase* pElem = pArray->SbxArray::Get( nVar );
+ if ( pElem && pElem->ISA( SbxVariable ) )
+ {
+ String aVar = aResult.GetToken( nVar, ';' );
+ // Falls die Variablen als String geputtet werden
+ // addieren sich sonst die Zwischenraeume...
+ aVar.EraseLeadingChars();
+ aVar.EraseTrailingChars();
+ ((SbxVariable*)pElem)->PutStringExt( aVar );
+ }
+ else
+ bError = TRUE;
+ }
+ }
+ else
+ bError = TRUE;
+ }
+ else
+ {
+ BOOL bValidIndex;
+ pToBeChanged = lcl_FindElement( pArray, aIndex, bValidIndex );
+ if ( pToBeChanged )
+ lcl_FormatArrayString( aResult );
+ else
+ bError = TRUE;
+ }
+ }
+ else
+ bError = TRUE;
+ }
+ else
+ pToBeChanged = pSBX;
+ }
+
+ if ( pToBeChanged )
+ {
+ if ( pToBeChanged->ISA( SbxVariable ) )
+ {
+ // Wenn der Typ variabel ist, macht die Konvertierung des SBX nichts,
+ // bei festem Typ wird der String konvertiert.
+ ((SbxVariable*)pToBeChanged)->PutStringExt( aResult );
+ }
+ else
+ bError = TRUE;
+ }
+
+ // Wenn jemand z.B. einen zu grossen Wert fuer ein Int eingegeben hat,
+ // folgt beim naechsten Step() ein Runtime-Error.
+ if ( SbxBase::IsError() )
+ {
+ bError = TRUE;
+ SbxBase::ResetError();
+ }
+
+ if ( bError )
+ Sound::Beep();
+
+ UpdateWatches();
+
+ // Der Text soll niemals 1-zu-1 uebernommen werden, weil dann das
+ // UpdateWatches verlorengeht.
+ return FALSE;
+}
+
+
+void WatchTreeListBox::UpdateWatches()
+{
+ SbMethod* pCurMethod = StarBASIC::GetActiveMethod();
+ SbModule* pModule = pCurMethod ? pCurMethod->GetModule() : 0;
+
+ SbxError eOld = SbxBase::GetError();
+
+ SvLBoxEntry* pEntry = First();
+ while ( pEntry )
+ {
+ String aVName( *( (String*)pEntry->GetUserData() ) );
+ DBG_ASSERT( aVName.Len(), "Var? - Darf nicht leer sein!" );
+ String aWatchStr( aVName );
+ aWatchStr += String( RTL_CONSTASCII_USTRINGPARAM( " = " ) );
+ if ( pCurMethod )
+ {
+ String aVar, aIndex;
+ lcl_SeparateNameAndIndex( aVName, aVar, aIndex );
+ SbxBase* pSBX = StarBASIC::FindSBXInCurrentScope( aVar );
+ if ( pSBX && pSBX->ISA( SbxVariable ) && !pSBX->ISA( SbxMethod ) )
+ {
+ SbxVariable* pVar = (SbxVariable*)pSBX;
+ // Sonderbehandlung fuer Arrays:
+ SbxDataType eType = pVar->GetType();
+ if ( (BYTE)eType == (BYTE)SbxOBJECT )
+ aWatchStr += String( RTL_CONSTASCII_USTRINGPARAM( "<?>" ) );
+ else if ( eType & SbxARRAY )
+ {
+ // Mehrdimensionale Arrays beruecksichtigen!
+ SbxBase* pBase = pVar->GetObject();
+ if ( pBase && pBase->ISA( SbxDimArray ) )
+ {
+ SbxDimArray* pArray = (SbxDimArray*)pBase;
+ aWatchStr += '{';
+ USHORT nDims = pArray->GetDims();
+ if ( !aIndex.Len() )
+ {
+ short* pIdx = new short[ nDims ];
+ for ( USHORT n = nDims; n; )
+ pIdx[--n] = 0;
+ // hoechste Dimension festhalen.
+// lcl_GetValues( aWatchStr, pArray, pIdx, nDims );
+ lcl_GetValues( aWatchStr, pArray, pIdx, 1 );
+ delete pIdx;
+ }
+ else
+ {
+ BOOL bValidIndex;
+ SbxBase* pElem = lcl_FindElement( pArray, aIndex, bValidIndex );
+ if ( pElem )
+ aWatchStr += ((SbxVariable*)pElem)->GetString();
+ else if ( !bValidIndex )
+ aWatchStr += String( RTL_CONSTASCII_USTRINGPARAM( "<Invalid index>" ) );
+ }
+ aWatchStr += '}';
+ }
+ else
+ aWatchStr += String( RTL_CONSTASCII_USTRINGPARAM( "<?>" ) );
+ }
+ else
+ aWatchStr += pVar->GetString();
+ }
+ else
+ aWatchStr += String( RTL_CONSTASCII_USTRINGPARAM( "<Out of Scope>" ) );
+ }
+ SetEntryText( pEntry, aWatchStr );
+
+ pEntry = Next( pEntry );
+ }
+
+ SbxBase::ResetError();
+ if( eOld != SbxERR_OK )
+ SbxBase::SetError( eOld );
+
+}
+
diff --git a/basctl/source/basicide/baside3.cxx b/basctl/source/basicide/baside3.cxx
new file mode 100644
index 000000000000..2482f23e3a1c
--- /dev/null
+++ b/basctl/source/basicide/baside3.cxx
@@ -0,0 +1,609 @@
+/*************************************************************************
+ *
+ * $RCSfile: baside3.cxx,v $
+ *
+ * $Revision: 1.1.1.1 $
+ *
+ * last change: $Author: mh $ $Date: 2000-09-29 11:02:36 $
+ *
+ * The Contents of this file are made available subject to the terms of
+ * either of the following licenses
+ *
+ * - GNU Lesser General Public License Version 2.1
+ * - Sun Industry Standards Source License Version 1.1
+ *
+ * Sun Microsystems Inc., October, 2000
+ *
+ * GNU Lesser General Public License Version 2.1
+ * =============================================
+ * Copyright 2000 by Sun Microsystems, Inc.
+ * 901 San Antonio Road, Palo Alto, CA 94303, USA
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License version 2.1, as published by the Free Software Foundation.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this library; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston,
+ * MA 02111-1307 USA
+ *
+ *
+ * Sun Industry Standards Source License Version 1.1
+ * =================================================
+ * The contents of this file are subject to the Sun Industry Standards
+ * Source License Version 1.1 (the "License"); You may not use this file
+ * except in compliance with the License. You may obtain a copy of the
+ * License at http://www.openoffice.org/license.html.
+ *
+ * Software provided under this License is provided on an "AS IS" basis,
+ * WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING,
+ * WITHOUT LIMITATION, WARRANTIES THAT THE SOFTWARE IS FREE OF DEFECTS,
+ * MERCHANTABLE, FIT FOR A PARTICULAR PURPOSE, OR NON-INFRINGING.
+ * See the License for the specific provisions governing your rights and
+ * obligations concerning the Software.
+ *
+ * The Initial Developer of the Original Code is: Sun Microsystems, Inc.
+ *
+ * Copyright: 2000 by Sun Microsystems, Inc.
+ *
+ * All Rights Reserved.
+ *
+ * Contributor(s): _______________________________________
+ *
+ *
+ ************************************************************************/
+
+//svdraw.hxx
+//#define _SVDRAW_HXX ***
+#define _SDR_NOITEMS
+#define _SDR_NOTOUCH
+#define _SDR_NOTRANSFORM
+#define _SDR_NOOBJECTS
+//#define _SDR_NOVIEWS ***
+#define _SDR_NOVIEWMARKER
+#define _SDR_NODRAGMETHODS
+//#define _SDR_NOUNDO ***
+#define _SDR_NOXOUTDEV
+
+#include <ide_pch.hxx>
+
+#pragma hdrstop
+
+#include <basidesh.hrc>
+#include <baside3.hxx>
+#include <vced.hxx>
+#include <vcbrw.hxx>
+#include <basobj.hxx>
+#include <iderdll.hxx>
+#include <basidesh.hxx>
+#include <idetemp.hxx>
+#include <helpid.hrc>
+
+TYPEINIT1( DialogWindow, IDEBaseWindow );
+
+DialogWindow::DialogWindow( Window* pParent, VCSbxDialogRef aDialog,
+ StarBASIC* pBas ) :
+ IDEBaseWindow( pParent, pBas ),
+ pUndoMgr(NULL)
+{
+ // Bitte kein Show() !
+ if( aDialog.Is() )
+ pDialog = aDialog;
+ else
+ {
+ pDialog = new VCSbxDialog;
+ pDialog->SetName( String( RTL_CONSTASCII_USTRINGPARAM( "Dialog" ) ) );
+ GetBasic()->Insert( pDialog );
+ }
+
+ InitSettings( TRUE, TRUE, TRUE );
+ pEditor = new VCDlgEditor( GetBasic() );
+ pEditor->SetWindow( this );
+ pEditor->SetVCSbxForm( pDialog );
+
+ // Undo einrichten
+ pUndoMgr = new SfxUndoManager;
+
+ Link aDummyLink;
+ aOldNotifyUndoActionHdl = pEditor->GetModel()->GetNotifyUndoActionHdl();
+ pEditor->GetModel()->SetNotifyUndoActionHdl(
+ LINK(this, DialogWindow, NotifyUndoActionHdl));
+
+ SetHelpId( HID_BASICIDE_DIALOGWINDOW );
+}
+
+DialogWindow::DialogWindow( DialogWindow* pOrgWin ) :
+ IDEBaseWindow( pOrgWin->GetParent(), pOrgWin->GetBasic() )
+{
+ DBG_ERROR( "Dieser CTOR ist nicht erlaubt!" );
+}
+
+
+
+DialogWindow::~DialogWindow()
+{
+ delete pEditor;
+ delete pUndoMgr;
+}
+
+void DialogWindow::LoseFocus()
+{
+ if( pEditor->IsModified() )
+ {
+ BasicIDE::MarkDocShellModified( pEditor->GetBasic() );
+ pEditor->ClearModifyFlag();
+ pDialog->SetModified( TRUE );
+ }
+ Window::LoseFocus();
+}
+
+
+
+void DialogWindow::Paint( const Rectangle& rRect )
+{
+ pEditor->Paint( rRect );
+}
+
+
+
+void DialogWindow::Resize()
+{
+ pEditor->SetScrollBars( GetHScrollBar(), GetVScrollBar() );
+}
+
+
+
+void DialogWindow::MouseButtonDown( const MouseEvent& rMEvt )
+{
+ pEditor->MouseButtonDown( rMEvt );
+}
+
+
+
+void DialogWindow::MouseButtonUp( const MouseEvent& rMEvt )
+{
+ pEditor->MouseButtonUp( rMEvt );
+ SfxBindings& rBindings = BasicIDE::GetBindings();
+ if( (pEditor->GetMode() == VCDLGED_INSERT) && !pEditor->IsCreateOK() )
+ {
+ pEditor->SetMode( VCDLGED_SELECT );
+ rBindings.Invalidate( SID_CHOOSE_CONTROLS );
+ }
+ rBindings.Invalidate( SID_DOC_MODIFIED );
+ rBindings.Invalidate( SID_SAVEDOC );
+}
+
+
+
+void DialogWindow::MouseMove( const MouseEvent& rMEvt )
+{
+ pEditor->MouseMove( rMEvt );
+}
+
+
+
+void DialogWindow::KeyInput( const KeyEvent& rKEvt )
+{
+ if( rKEvt.GetKeyCode() == KEY_BACKSPACE )
+ {
+ SfxViewFrame* pCurFrame = SfxViewFrame::Current();
+ DBG_ASSERT( pCurFrame != NULL, "No current view frame!" );
+ SfxDispatcher* pDispatcher = pCurFrame ? pCurFrame->GetDispatcher() : NULL;
+ if( pDispatcher )
+ {
+ pDispatcher->Execute( SID_BACKSPACE );
+ }
+ }
+ else
+ {
+ if( !pEditor->KeyInput( rKEvt ) )
+ {
+ if( !SfxViewShell::Current()->KeyInput( rKEvt ) )
+ Window::KeyInput( rKEvt );
+ }
+ }
+}
+
+void DialogWindow::Command( const CommandEvent& rCEvt )
+{
+ if ( ( rCEvt.GetCommand() == COMMAND_WHEEL ) ||
+ ( rCEvt.GetCommand() == COMMAND_STARTAUTOSCROLL ) ||
+ ( rCEvt.GetCommand() == COMMAND_AUTOSCROLL ) )
+ {
+ HandleScrollCommand( rCEvt, GetHScrollBar(), GetVScrollBar() );
+ }
+ else
+ IDEBaseWindow::Command( rCEvt );
+}
+
+
+
+
+IMPL_LINK( DialogWindow, NotifyUndoActionHdl, SfxUndoAction *, pUndoAction )
+{
+ if (pUndoAction)
+ {
+ pUndoMgr->AddUndoAction( pUndoAction );
+ BasicIDE::GetBindings().Invalidate( SID_UNDO );
+ }
+
+ return 0;
+}
+
+
+
+void __EXPORT DialogWindow::DoInit()
+{
+ GetHScrollBar()->Show();
+ GetVScrollBar()->Show();
+ pEditor->SetScrollBars( GetHScrollBar(), GetVScrollBar() );
+}
+
+
+
+void __EXPORT DialogWindow::DoScroll( ScrollBar* pCurScrollBar )
+{
+ pEditor->DoScroll( pCurScrollBar );
+}
+
+
+
+
+void DialogWindow::SetDialogName( const String& rName )
+{
+ pDialog->SetName( rName );
+}
+
+
+
+String DialogWindow::GetDialogName()
+{
+ return pDialog->GetName();
+}
+
+
+
+void __EXPORT DialogWindow::GetState( SfxItemSet& rSet )
+{
+ SfxWhichIter aIter(rSet);
+ for ( USHORT nWh = aIter.FirstWhich(); 0 != nWh; nWh = aIter.NextWhich() )
+ {
+ switch ( nWh )
+ {
+ case SID_PASTE:
+ break;
+ case SID_CUT:
+ case SID_COPY:
+ case SID_DELETE:
+ case SID_BACKSPACE:
+ {
+ // Object selektiert?
+ }
+ break;
+ case SID_REDO:
+ {
+ if ( !pUndoMgr->GetUndoActionCount() )
+ rSet.DisableItem( nWh );
+ }
+ break;
+
+ // Nur Dialogfenster:
+ case SID_DIALOG_TESTMODE:
+ {
+ // ist die IDE noch aktiv?
+ if( IDE_DLL()->GetShell()->GetFrame() )
+ {
+ rSet.Put( SfxBoolItem( SID_DIALOG_TESTMODE,
+ (pEditor->GetMode() == VCDLGED_TEST) ? TRUE : FALSE) );
+ }
+ else
+ rSet.Put( SfxBoolItem( SID_DIALOG_TESTMODE,FALSE ));
+ }
+ break;
+
+ case SID_CHOOSE_CONTROLS:
+ {
+ SfxAllEnumItem aItem( SID_CHOOSE_CONTROLS );
+ if( GetEditor()->GetMode() == VCDLGED_SELECT )
+ aItem.SetValue( SVX_SNAP_SELECT );
+ else
+ {
+ USHORT nObj;
+ switch( pEditor->GetInsertObj() )
+ {
+ case OBJ_DLG_CHECKBOX: nObj = SVX_SNAP_CHECKBOX; break;
+ case OBJ_DLG_RADIOBUTTON: nObj = SVX_SNAP_RADIOBUTTON; break;
+ case OBJ_DLG_PUSHBUTTON: nObj = SVX_SNAP_PUSHBUTTON; break;
+ case OBJ_DLG_SPINBUTTON: nObj = SVX_SNAP_SPINBUTTON; break;
+ case OBJ_DLG_FIXEDTEXT: nObj = SVX_SNAP_FIXEDTEXT; break;
+ case OBJ_DLG_GROUPBOX: nObj = SVX_SNAP_GROUPBOX; break;
+ case OBJ_DLG_EDIT: nObj = SVX_SNAP_EDIT; break;
+ case OBJ_DLG_LISTBOX: nObj = SVX_SNAP_LISTBOX; break;
+ case OBJ_DLG_COMBOBOX: nObj = SVX_SNAP_COMBOBOX; break;
+ case OBJ_DLG_HSCROLLBAR: nObj = SVX_SNAP_HSCROLLBAR; break;
+ case OBJ_DLG_VSCROLLBAR: nObj = SVX_SNAP_VSCROLLBAR; break;
+ case OBJ_DLG_PREVIEW: nObj = SVX_SNAP_PREVIEW; break;
+ case OBJ_DLG_URLBUTTON: nObj = SVX_SNAP_URLBUTTON; break;
+ default: nObj = 0;
+ }
+#ifdef DBG_UTIL
+ if( !nObj )
+ {
+ DBG_WARNING( "SID_CHOOSE_CONTROLS: Unbekannt!" );
+ }
+#endif
+ aItem.SetValue( nObj );
+ }
+
+ rSet.Put( aItem );
+ }
+ break;
+ }
+ }
+}
+
+
+
+void __EXPORT DialogWindow::ExecuteCommand( SfxRequest& rReq )
+{
+ switch ( rReq.GetSlot() )
+ {
+ case SID_CUT:
+ GetEditor()->Cut();
+ BasicIDE::GetBindings().Invalidate( SID_DOC_MODIFIED );
+ break;
+ case SID_DELETE:
+#ifdef MAC
+ case SID_BACKSPACE:
+#endif
+ GetEditor()->Delete();
+ BasicIDE::GetBindings().Invalidate( SID_DOC_MODIFIED );
+ break;
+ case SID_COPY:
+ GetEditor()->Copy();
+ break;
+ case SID_PASTE:
+ GetEditor()->Paste();
+ BasicIDE::GetBindings().Invalidate( SID_DOC_MODIFIED );
+ break;
+ case SID_CHOOSE_CONTROLS:
+ {
+ const SfxItemSet* pArgs = rReq.GetArgs();
+ DBG_ASSERT( pArgs, "Nix Args" );
+
+ const SfxAllEnumItem& rItem = (SfxAllEnumItem&)pArgs->Get( SID_CHOOSE_CONTROLS );
+ switch( rItem.GetValue() )
+ {
+ case SVX_SNAP_PUSHBUTTON:
+ {
+ GetEditor()->SetMode( VCDLGED_INSERT );
+ GetEditor()->SetInsertObj( OBJ_DLG_PUSHBUTTON );
+ }
+ break;
+ case SVX_SNAP_RADIOBUTTON:
+ {
+ GetEditor()->SetMode( VCDLGED_INSERT );
+ GetEditor()->SetInsertObj( OBJ_DLG_RADIOBUTTON );
+ }
+ break;
+ case SVX_SNAP_CHECKBOX:
+ {
+ GetEditor()->SetMode( VCDLGED_INSERT );
+ GetEditor()->SetInsertObj( OBJ_DLG_CHECKBOX);
+ }
+ break;
+ case SVX_SNAP_SPINBUTTON:
+ {
+ GetEditor()->SetMode( VCDLGED_INSERT );
+ GetEditor()->SetInsertObj( OBJ_DLG_SPINBUTTON );
+ }
+ break;
+ case SVX_SNAP_FIXEDTEXT:
+ {
+ GetEditor()->SetMode( VCDLGED_INSERT );
+ GetEditor()->SetInsertObj( OBJ_DLG_FIXEDTEXT );
+ }
+ break;
+ case SVX_SNAP_GROUPBOX:
+ {
+ GetEditor()->SetMode( VCDLGED_INSERT );
+ GetEditor()->SetInsertObj( OBJ_DLG_GROUPBOX );
+ }
+ break;
+ case SVX_SNAP_LISTBOX:
+ {
+ GetEditor()->SetMode( VCDLGED_INSERT );
+ GetEditor()->SetInsertObj( OBJ_DLG_LISTBOX );
+ }
+ break;
+ case SVX_SNAP_COMBOBOX:
+ {
+ GetEditor()->SetMode( VCDLGED_INSERT );
+ GetEditor()->SetInsertObj( OBJ_DLG_COMBOBOX );
+ }
+ break;
+ case SVX_SNAP_EDIT:
+ {
+ GetEditor()->SetMode( VCDLGED_INSERT );
+ GetEditor()->SetInsertObj( OBJ_DLG_EDIT );
+ }
+ break;
+ case SVX_SNAP_HSCROLLBAR:
+ {
+ GetEditor()->SetMode( VCDLGED_INSERT );
+ GetEditor()->SetInsertObj( OBJ_DLG_HSCROLLBAR );
+ }
+ break;
+ case SVX_SNAP_VSCROLLBAR:
+ {
+ GetEditor()->SetMode( VCDLGED_INSERT );
+ GetEditor()->SetInsertObj( OBJ_DLG_VSCROLLBAR );
+ }
+ break;
+ case SVX_SNAP_PREVIEW:
+ {
+ GetEditor()->SetMode( VCDLGED_INSERT );
+ GetEditor()->SetInsertObj( OBJ_DLG_PREVIEW );
+ }
+ break;
+ case SVX_SNAP_URLBUTTON:
+ {
+ GetEditor()->SetMode( VCDLGED_INSERT );
+ GetEditor()->SetInsertObj( OBJ_DLG_URLBUTTON );
+ }
+ break;
+ case SVX_SNAP_SELECT:
+ {
+ GetEditor()->SetMode( VCDLGED_SELECT );
+ }
+ break;
+ }
+ BasicIDE::GetBindings().Invalidate( SID_DOC_MODIFIED );
+ #ifdef DEBUG
+ BOOL bModified = IsModified();
+ #endif
+
+ }
+ break;
+
+ case SID_DIALOG_TESTMODE:
+ {
+ VCDlgMode eOldMode = GetEditor()->GetMode();
+ GetEditor()->SetMode( VCDLGED_TEST );
+ GetEditor()->SetMode( eOldMode );
+ rReq.Done();
+ BasicIDE::GetBindings().Invalidate( SID_DIALOG_TESTMODE );
+ return;
+ }
+ break;
+ }
+
+ rReq.Done();
+}
+
+
+
+void DialogWindow::RenameDialog( const String& rNewName )
+{
+ pDialog->SetName( rNewName );
+ BasicIDE::GetBindings().Invalidate( SID_DOC_MODIFIED );
+}
+
+
+
+
+void DialogWindow::DisableBrowser()
+{
+ SfxViewFrame* pCurFrame = SfxViewFrame::Current();
+ DBG_ASSERT( pCurFrame != NULL, "No current view frame!" );
+ SfxChildWindow* pChildWin = pCurFrame ? pCurFrame->GetChildWindow(SID_SHOW_BROWSER) : NULL;
+ if( pChildWin )
+ ((VCBrowser*)(pChildWin->GetWindow()))->Update( 0 );
+}
+
+
+
+
+void DialogWindow::UpdateBrowser()
+{
+ SfxViewFrame* pCurFrame = SfxViewFrame::Current();
+ DBG_ASSERT( pCurFrame != NULL, "No current view frame!" );
+ SfxChildWindow* pChildWin = pCurFrame ? pCurFrame->GetChildWindow(SID_SHOW_BROWSER) : NULL;
+ if( pChildWin )
+ ((VCBrowser*)(pChildWin->GetWindow()))->Update(GetEditor()->GetView());
+}
+
+
+
+
+SdrView* DialogWindow::GetView() const
+{
+ return GetEditor()->GetView();
+}
+
+
+
+BOOL __EXPORT DialogWindow::IsModified()
+{
+ // So auf jedenfall nicht verkehrt...
+ return pDialog->IsModified() || pEditor->IsModified();
+}
+
+
+
+SfxUndoManager* __EXPORT DialogWindow::GetUndoManager()
+{
+ return pUndoMgr;
+}
+
+String DialogWindow::GetTitle()
+{
+ return GetDialogName();
+}
+
+void DialogWindow::StoreData()
+{
+ // Die Daten befinden sich schon im Basic...
+// pDialog->SetModified( FALSE ); // dann wird das Modify vom Basic geloescht
+#if 1
+ if( pEditor->IsModified() )
+ BasicIDE::MarkDocShellModified( pEditor->GetBasic() );
+ pDialog->ResetFlag( SBX_MODIFIED );
+ pEditor->ClearModifyFlag();
+#else
+ if( pEditor->IsModified() )
+ pDialog->SetModified( TRUE );
+ else
+ pDialog->ResetFlag( SBX_MODIFIED );
+ pEditor->ClearModifyFlag();
+#endif
+
+}
+
+void DialogWindow::Deactivating()
+{
+ if( pEditor->IsModified() )
+ BasicIDE::MarkDocShellModified( pEditor->GetBasic() );
+}
+
+void DialogWindow::PrintData( Printer* pPrinter )
+{
+ pEditor->PrintData( pPrinter, CreateQualifiedName() );
+}
+
+void DialogWindow::DataChanged( const DataChangedEvent& rDCEvt )
+{
+ if( (rDCEvt.GetType()==DATACHANGED_SETTINGS) && (rDCEvt.GetFlags() & SETTINGS_STYLE) )
+ {
+ InitSettings( TRUE, TRUE, TRUE );
+ Invalidate();
+ }
+ else
+ IDEBaseWindow::DataChanged( rDCEvt );
+}
+
+void DialogWindow::InitSettings(BOOL bFont,BOOL bForeground,BOOL bBackground)
+{
+ const StyleSettings& rStyleSettings = GetSettings().GetStyleSettings();
+ if( bFont )
+ {
+ Font aFont;
+ aFont = rStyleSettings.GetFieldFont();
+ SetPointFont( aFont );
+ }
+
+ if( bForeground || bFont )
+ {
+ SetTextColor( rStyleSettings.GetFieldTextColor() );
+ SetTextFillColor();
+ }
+
+ if( bBackground )
+ SetBackground( rStyleSettings.GetFieldColor() );
+}
diff --git a/basctl/source/basicide/baside4.cxx b/basctl/source/basicide/baside4.cxx
new file mode 100644
index 000000000000..8ad446e08fe8
--- /dev/null
+++ b/basctl/source/basicide/baside4.cxx
@@ -0,0 +1,62 @@
+/*************************************************************************
+ *
+ * $RCSfile: baside4.cxx,v $
+ *
+ * $Revision: 1.1.1.1 $
+ *
+ * last change: $Author: mh $ $Date: 2000-09-29 11:02:36 $
+ *
+ * The Contents of this file are made available subject to the terms of
+ * either of the following licenses
+ *
+ * - GNU Lesser General Public License Version 2.1
+ * - Sun Industry Standards Source License Version 1.1
+ *
+ * Sun Microsystems Inc., October, 2000
+ *
+ * GNU Lesser General Public License Version 2.1
+ * =============================================
+ * Copyright 2000 by Sun Microsystems, Inc.
+ * 901 San Antonio Road, Palo Alto, CA 94303, USA
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License version 2.1, as published by the Free Software Foundation.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this library; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston,
+ * MA 02111-1307 USA
+ *
+ *
+ * Sun Industry Standards Source License Version 1.1
+ * =================================================
+ * The contents of this file are subject to the Sun Industry Standards
+ * Source License Version 1.1 (the "License"); You may not use this file
+ * except in compliance with the License. You may obtain a copy of the
+ * License at http://www.openoffice.org/license.html.
+ *
+ * Software provided under this License is provided on an "AS IS" basis,
+ * WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING,
+ * WITHOUT LIMITATION, WARRANTIES THAT THE SOFTWARE IS FREE OF DEFECTS,
+ * MERCHANTABLE, FIT FOR A PARTICULAR PURPOSE, OR NON-INFRINGING.
+ * See the License for the specific provisions governing your rights and
+ * obligations concerning the Software.
+ *
+ * The Initial Developer of the Original Code is: Sun Microsystems, Inc.
+ *
+ * Copyright: 2000 by Sun Microsystems, Inc.
+ *
+ * All Rights Reserved.
+ *
+ * Contributor(s): _______________________________________
+ *
+ *
+ ************************************************************************/
+
+
diff --git a/basctl/source/basicide/basides1.cxx b/basctl/source/basicide/basides1.cxx
new file mode 100644
index 000000000000..60887823548d
--- /dev/null
+++ b/basctl/source/basicide/basides1.cxx
@@ -0,0 +1,1179 @@
+/*************************************************************************
+ *
+ * $RCSfile: basides1.cxx,v $
+ *
+ * $Revision: 1.1.1.1 $
+ *
+ * last change: $Author: mh $ $Date: 2000-09-29 11:02:36 $
+ *
+ * The Contents of this file are made available subject to the terms of
+ * either of the following licenses
+ *
+ * - GNU Lesser General Public License Version 2.1
+ * - Sun Industry Standards Source License Version 1.1
+ *
+ * Sun Microsystems Inc., October, 2000
+ *
+ * GNU Lesser General Public License Version 2.1
+ * =============================================
+ * Copyright 2000 by Sun Microsystems, Inc.
+ * 901 San Antonio Road, Palo Alto, CA 94303, USA
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License version 2.1, as published by the Free Software Foundation.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this library; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston,
+ * MA 02111-1307 USA
+ *
+ *
+ * Sun Industry Standards Source License Version 1.1
+ * =================================================
+ * The contents of this file are subject to the Sun Industry Standards
+ * Source License Version 1.1 (the "License"); You may not use this file
+ * except in compliance with the License. You may obtain a copy of the
+ * License at http://www.openoffice.org/license.html.
+ *
+ * Software provided under this License is provided on an "AS IS" basis,
+ * WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING,
+ * WITHOUT LIMITATION, WARRANTIES THAT THE SOFTWARE IS FREE OF DEFECTS,
+ * MERCHANTABLE, FIT FOR A PARTICULAR PURPOSE, OR NON-INFRINGING.
+ * See the License for the specific provisions governing your rights and
+ * obligations concerning the Software.
+ *
+ * The Initial Developer of the Original Code is: Sun Microsystems, Inc.
+ *
+ * Copyright: 2000 by Sun Microsystems, Inc.
+ *
+ * All Rights Reserved.
+ *
+ * Contributor(s): _______________________________________
+ *
+ *
+ ************************************************************************/
+
+
+#define GLOBALOVERFLOW2
+
+#pragma hdrstop
+
+
+#ifndef _SBXCLASS_HXX //autogen
+#include <svtools/sbx.hxx>
+#endif
+#define _SVSTDARR_STRINGS
+#include <svtools/svstdarr.hxx>
+#include <ide_pch.hxx>
+#pragma hdrstop
+
+#define __PRIVATE 1
+
+// #define _SVX_NOIDERESIDS
+
+#define SI_NOCONTROL
+#define SI_NOSBXCONTROLS
+#define SI_NOITEMS
+#define SI_NODRW
+#define _VCTRLS_HXX
+
+#include <basidesh.hrc>
+#include <basidesh.hxx>
+#include <baside2.hxx>
+#include <baside3.hxx>
+#include <basobj.hxx>
+#include <iderdll.hxx>
+#include <iderdll2.hxx>
+#include <vcsbx.hxx>
+#include <sbxitem.hxx>
+#include <vcl/rcid.h>
+#include <helpid.hrc>
+
+#ifndef _SFX_MINFITEM_HXX //autogen
+#include <sfx2/minfitem.hxx>
+#endif
+
+
+class SvxSearchItem;
+
+// Egal was, einfach ans aktuelle Fenster:
+void __EXPORT BasicIDEShell::ExecuteCurrent( SfxRequest& rReq )
+{
+ if ( !pCurWin )
+ return;
+
+ switch ( rReq.GetSlot() )
+ {
+ case SID_BASICIDE_HIDECURPAGE:
+ {
+ pCurWin->StoreData();
+ RemoveWindow( pCurWin, FALSE );
+ }
+ break;
+ case SID_BASICIDE_DELETECURRENT:
+ {
+ StarBASIC* pBasic = pCurWin->GetBasic();
+ DBG_ASSERT( pBasic, "Aktuellen Fenster ohne Basic ?!" );
+ if ( pCurWin->ISA( ModulWindow ) )
+ {
+ SbModule* pModule = ((ModulWindow*)pCurWin)->GetModule();
+ DBG_ASSERT( pModule, "DELETECURRENT: Modul nicht gefunden!" );
+ if ( QueryDelModule( pModule->GetName(), pCurWin ) )
+ {
+ pBasic->GetModules()->Remove( pModule );
+ RemoveWindow( pCurWin, TRUE );
+ BasicIDE::MarkDocShellModified( pBasic );
+
+ }
+ }
+ else
+ {
+ SbxObject* pDlg = ((DialogWindow*)pCurWin)->GetDialog();
+ DBG_ASSERT( pDlg, "DELETECURRENT: Dialog nicht gefunden!" );
+ if ( QueryDelDialog( pDlg->GetName(), pCurWin ) )
+ {
+ pBasic->GetObjects()->Remove( pDlg );
+ RemoveWindow( pCurWin, TRUE );
+ BasicIDE::MarkDocShellModified( pBasic );
+ }
+ }
+ }
+ break;
+ case SID_BASICIDE_RENAMECURRENT:
+ {
+ pTabBar->StartEditMode( pTabBar->GetCurPageId() );
+ }
+ break;
+ case FID_SEARCH_NOW:
+ {
+ if ( pCurWin->ISA( ModulWindow ) )
+ {
+ DBG_ASSERT( rReq.GetArgs(), "arguments expected" );
+ const SfxItemSet* pArgs = rReq.GetArgs();
+ // Leider kenne ich die ID nicht:
+ USHORT nWhich = pArgs->GetWhichByPos( 0 );
+ DBG_ASSERT( nWhich, "Wich fuer SearchItem ?" );
+ const SfxPoolItem& rItem = pArgs->Get( nWhich );
+ DBG_ASSERT( rItem.ISA( SvxSearchItem ), "Kein Searchitem!" );
+ if ( rItem.ISA( SvxSearchItem ) )
+ {
+ // Item wegen der Einstellungen merken...
+ IDE_DLL()->GetExtraData()->SetSearchItem( (const SvxSearchItem&)rItem );
+ USHORT nFound = 0;
+ BOOL bCanceled = FALSE;
+ if ( ((const SvxSearchItem&)rItem).GetCommand() == SVX_SEARCHCMD_REPLACE_ALL )
+ {
+ USHORT nActModWindows = 0;
+ IDEBaseWindow* pWin = aIDEWindowTable.First();
+ while ( pWin )
+ {
+ if ( !pWin->IsSuspended() && pWin->IsA( TYPE( ModulWindow ) ) )
+ nActModWindows++;
+ pWin = aIDEWindowTable.Next();
+ }
+
+ if ( ( nActModWindows <= 1 ) || ( !((const SvxSearchItem&)rItem).GetSelection() && QueryBox( pCurWin, WB_YES_NO|WB_DEF_YES, String( IDEResId( RID_STR_SEARCHALLMODULES ) ) ).Execute() == RET_YES ) )
+ {
+ pWin = aIDEWindowTable.First();
+ while ( pWin )
+ {
+ if ( !pWin->IsSuspended() && pWin->IsA( TYPE( ModulWindow ) ) )
+ nFound += ((ModulWindow*)pWin)->StartSearchAndReplace( (const SvxSearchItem&)rItem );
+ pWin = aIDEWindowTable.Next();
+ }
+ }
+ else
+ nFound = ((ModulWindow*)pCurWin)->StartSearchAndReplace( (const SvxSearchItem&)rItem );
+
+ IDEResId nId( RID_STR_SEARCHREPLACES );
+ String aReplStr( nId );
+ aReplStr.SearchAndReplace( String( RTL_CONSTASCII_USTRINGPARAM( "XX" ) ), nFound );
+ InfoBox( pCurWin, aReplStr ).Execute();
+ }
+ else
+ {
+ nFound = ((ModulWindow*)pCurWin)->StartSearchAndReplace( (const SvxSearchItem&)rItem );
+ if ( !nFound && !((const SvxSearchItem&)rItem).GetSelection() )
+ {
+ // Andere Module durchsuchen...
+ BOOL bChangeCurWindow = FALSE;
+ aIDEWindowTable.Seek( pCurWin );
+ // Erstmal beim naechsten Anfangen, ggf. spaeter von vorne
+ IDEBaseWindow* pWin = aIDEWindowTable.Next();
+ BOOL bSearchedFromStart = FALSE;
+ while ( !nFound && !bCanceled && ( pWin || !bSearchedFromStart ) )
+ {
+ if ( !pWin )
+ {
+ QueryBox aQuery( pCurWin, WB_YES_NO|WB_DEF_YES, String( IDEResId( RID_STR_SEARCHFROMSTART ) ) );
+ if ( aQuery.Execute() == RET_YES )
+ {
+ pWin = aIDEWindowTable.First();
+ bSearchedFromStart = TRUE;
+ }
+ else
+ bCanceled = TRUE;
+ }
+
+ if ( pWin && !pWin->IsSuspended() && pWin->IsA( TYPE( ModulWindow ) ) )
+ {
+ if ( pWin != pCurWin )
+ {
+ // Groesse einstellen, damit die View
+ // gleich richtig justiert werden kann.
+ if ( pCurWin )
+ pWin->SetSizePixel( pCurWin->GetSizePixel() );
+ nFound = ((ModulWindow*)pWin)->StartSearchAndReplace( (const SvxSearchItem&)rItem, TRUE );
+ }
+ if ( nFound )
+ {
+ bChangeCurWindow = TRUE;
+ break;
+ }
+ }
+ if ( pWin && ( pWin != pCurWin ) )
+ pWin = aIDEWindowTable.Next();
+ else
+ pWin = 0; // Dann sind wir durch...
+ }
+ if ( !nFound && bSearchedFromStart ) // Aktuelles von vorne...
+ nFound = ((ModulWindow*)pCurWin)->StartSearchAndReplace( (const SvxSearchItem&)rItem, TRUE );
+ if ( bChangeCurWindow )
+ SetCurWindow( pWin, TRUE );
+ }
+ if ( !nFound && !bCanceled )
+ InfoBox( pCurWin, String( IDEResId( RID_STR_SEARCHNOTFOUND ) ) ).Execute();
+ }
+
+ rReq.Done();
+ }
+ }
+ }
+ break;
+ case SID_UNDO:
+ case SID_REDO:
+ {
+ if ( GetUndoManager() && pCurWin->AllowUndo() )
+ {
+ GetViewFrame()->ExecuteSlot( rReq );
+ }
+ }
+ break;
+ default:
+ {
+ pCurWin->ExecuteCommand( rReq );
+ }
+ }
+}
+
+// Egal, wer oben, Einfluss auf die Shell:
+void __EXPORT BasicIDEShell::ExecuteGlobal( SfxRequest& rReq )
+{
+ USHORT nSlot = rReq.GetSlot();
+ switch ( nSlot )
+ {
+ case SID_BASICSTOP:
+ {
+ // Evtl. nicht einfach anhalten, falls auf Brechpunkt!
+ if ( pCurWin && pCurWin->IsA( TYPE( ModulWindow ) ) )
+ ((ModulWindow*)pCurWin)->BasicStop();
+ BasicIDE::StopBasic();
+ }
+ break;
+
+ case SID_SAVEDOC:
+ {
+ if ( pCurWin )
+ {
+ // Daten ins BASIC zurueckschreiben
+ StoreAllWindowData();
+
+ // Doc-Basic?
+ SfxApplication* pSfxApp = SFX_APP();
+ BasicManager* pAppBasMgr = pSfxApp->GetBasicManager();
+ BasicManager *pBasMgr = BasicIDE::FindBasicManager( pCurWin->GetBasic() );
+ if ( pBasMgr != pAppBasMgr )
+ {
+ // Doc-Basic suchen
+ BOOL bFound = FALSE;
+ for ( SfxObjectShell *pDocSh = SfxObjectShell::GetFirst();
+ !bFound && pDocSh;
+ pDocSh = SfxObjectShell::GetNext(*pDocSh) )
+ {
+ if ( pDocSh->GetBasicManager() == pBasMgr )
+ {
+ // auch das Doc speichern
+ pDocSh->ExecuteSlot( rReq );
+ bFound = TRUE;
+ }
+ }
+ DBG_ASSERT( bFound, "unknown basic" );
+ }
+
+ SfxBindings &rBindings = BasicIDE::GetBindings();
+ rBindings.Invalidate( SID_DOC_MODIFIED );
+ rBindings.Invalidate( SID_SAVEDOC );
+ }
+ }
+ break;
+ case SID_BASICIDE_MODULEDLG:
+ {
+ BasicIDE::Organize();
+ }
+ break;
+ case SID_BASICIDE_CHOOSEMACRO:
+ {
+ BasicIDE::ChooseMacro();
+ }
+ break;
+ case SID_BASICIDE_CREATEMACRO:
+ case SID_BASICIDE_EDITMACRO:
+ {
+ DBG_ASSERT( rReq.GetArgs(), "arguments expected" );
+ const SfxMacroInfoItem& rInfo = (const SfxMacroInfoItem&)rReq.GetArgs()->Get(SID_BASICIDE_ARG_MACROINFO );
+ BasicManager* pBasMgr = (BasicManager*)rInfo.GetBasicManager();
+ DBG_ASSERT( pBasMgr, "Nichts selektiert im Basic-Baum ?" );
+ StartListening( *pBasMgr, TRUE /* Nur einmal anmelden */ );
+ StarBASIC* pBasic = pBasMgr->GetLib( rInfo.GetLib() );
+ if ( !pBasic )
+ {
+ // LoadOnDemand
+ USHORT nLib = pBasMgr->GetLibId( rInfo.GetLib() );
+ pBasMgr->LoadLib( nLib );
+ pBasic = pBasMgr->GetLib( nLib );
+ }
+ if ( !pBasic )
+ pBasic = pBasMgr->GetLib( 0 );
+ DBG_ASSERT( pBasic, "Kein Basic!" );
+ // Evtl pCurBasic umschalten:
+ if ( pCurBasic && ( pBasic != pCurBasic ) )
+ SetCurBasic( pBasic );
+ if ( rReq.GetSlot() == SID_BASICIDE_CREATEMACRO )
+ {
+ SbModule* pModule = pBasic->FindModule( rInfo.GetModule() );
+ if ( !pModule )
+ {
+ if ( rInfo.GetModule().Len() || !pBasic->GetModules()->Count() )
+ pModule = BasicIDE::CreateModule( pBasic, rInfo.GetModule() );
+ else
+ pModule = (SbModule*) pBasic->GetModules()->Get(0);
+ }
+ DBG_ASSERT( pModule, "Kein Modul!" );
+ if ( !pModule->GetMethods()->Find( rInfo.GetMethod(), SbxCLASS_METHOD ) )
+ BasicIDE::CreateMacro( pModule, rInfo.GetMethod() );
+ }
+ BasicIDE::Appear();
+ ModulWindow* pWin = FindBasWin( pBasic, rInfo.GetModule(), TRUE );
+ DBG_ASSERT( pWin, "Edit/Create Macro: Fenster wurde nicht erzeugt/gefunden!" );
+ SetCurWindow( pWin, TRUE );
+ pWin->EditMacro( rInfo.GetMethod() );
+ }
+ break;
+ case SID_BASICIDE_OBJCAT:
+ {
+ ShowObjectDialog( TRUE, TRUE );
+ }
+ break;
+ case SID_BASICIDE_LIBSELECTOR:
+ {
+ // !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
+ // ! Pruefen, ob diese Routine ueberhaupt gebraucht wird !
+ // !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
+
+ // String fuer aktuelle einstellung:
+ String aQName;
+ if ( pCurBasic )
+ {
+ BasicManager* pBasMgr = BasicIDE::FindBasicManager( pCurBasic );
+ if ( pBasMgr )
+ aQName = CreateMgrAndLibStr( BasicIDE::FindTitle( pBasMgr ), pCurBasic->GetName() );
+ }
+
+ PopupMenu aPopup;
+ SvStrings* pStrings = BasicIDE::CreateBasicLibBoxEntries();
+ for ( USHORT n = 0; n < pStrings->Count(); n++ )
+ {
+ String* pStr = pStrings->GetObject( n );
+ aPopup.InsertItem( n+1, *pStr ); // +1, damit keine 0
+ if ( *pStr == aQName )
+ aPopup.CheckItem( n+1, TRUE );
+ }
+ if ( !pCurBasic )
+ aPopup.CheckItem( 1, TRUE );
+
+ // (pb -> mt) we need a window here
+ Window& rWin = GetViewFrame()->GetWindow();
+ USHORT nId = aPopup.Execute( &rWin, rWin.GetPointerPosPixel() );
+ if ( nId )
+ {
+ USHORT i = nId-1;
+ String aLib;
+ if ( i ) // sonst 'Alle', also leer
+ aLib = *pStrings->GetObject( i );
+ SfxStringItem aLibName( SID_BASICIDE_ARG_LIBNAME, aLib );
+ SfxViewFrame* pCurFrame = SfxViewFrame::Current();
+ DBG_ASSERT( pCurFrame != NULL, "No current view frame!" );
+ SfxDispatcher* pDispatcher = pCurFrame ? pCurFrame->GetDispatcher() : NULL;
+ if( pDispatcher )
+ {
+ pDispatcher->Execute( SID_BASICIDE_LIBSELECTED,
+ SFX_CALLMODE_SYNCHRON, &aLibName, 0L );
+ }
+ }
+ pStrings->DeleteAndDestroy( 0, pStrings->Count() );
+ delete pStrings;
+ }
+ break;
+ case SID_BASICIDE_NAMECHANGEDONTAB:
+ {
+ DBG_ASSERT( rReq.GetArgs(), "arguments expected" );
+ const SfxUInt16Item &rTabId = (const SfxUInt16Item&)rReq.GetArgs()->Get(SID_BASICIDE_ARG_TABID );
+ const SfxStringItem &rModName = (const SfxStringItem&)rReq.GetArgs()->Get(SID_BASICIDE_ARG_MODULENAME );
+ IDEBaseWindow* pWin = aIDEWindowTable.Get( rTabId.GetValue() );
+ DBG_ASSERT( pWin, "Window nicht im Liste, aber in TabBar ?" );
+
+ // Focus wieder auf "Arbeitsflaeche"
+ pWin->GrabFocus();
+
+ if ( pWin->IsA( TYPE( ModulWindow ) ) )
+ {
+ ModulWindow* pEditWin = (ModulWindow*)pWin;
+ pEditWin->RenameModule( rModName.GetValue() );
+ }
+ else
+ {
+ DialogWindow* pViewWin = (DialogWindow*)pWin;
+ pViewWin->RenameDialog( rModName.GetValue() );
+ }
+ BasicIDE::MarkDocShellModified( pWin->GetBasic() );
+ }
+ break;
+ case SID_BASICIDE_STOREMODULESOURCE:
+ case SID_BASICIDE_UPDATEMODULESOURCE:
+ {
+ DBG_ASSERT( rReq.GetArgs(), "arguments expected" );
+ const SfxMacroInfoItem& rInfo = (const SfxMacroInfoItem&)rReq.GetArgs()->Get(SID_BASICIDE_ARG_MACROINFO );
+ BasicManager* pBasMgr = (BasicManager*)rInfo.GetBasicManager();
+ DBG_ASSERT( pBasMgr, "Store source: Kein BasMgr?" );
+ StarBASIC* pBasic = pBasMgr->GetLib( rInfo.GetLib() );
+ DBG_ASSERT( pBasic, "Lib im BasicManager nicht gefunden!" );
+ ModulWindow* pWin = FindBasWin( pBasic, rInfo.GetModule(), FALSE, TRUE );
+ if ( pWin )
+ {
+ if ( rReq.GetSlot() == SID_BASICIDE_STOREMODULESOURCE )
+ pWin->StoreData();
+ else
+ pWin->UpdateData();
+ }
+ }
+ break;
+ case SID_BASICIDE_STOREALLMODULESOURCES:
+ case SID_BASICIDE_UPDATEALLMODULESOURCES:
+ {
+ IDEBaseWindow* pWin = aIDEWindowTable.First();
+ while ( pWin )
+ {
+ if ( !pWin->IsSuspended() && pWin->IsA( TYPE( ModulWindow ) ) )
+ {
+ if ( rReq.GetSlot() == SID_BASICIDE_STOREALLMODULESOURCES )
+ pWin->StoreData();
+ else
+ pWin->UpdateData();
+ }
+ pWin = aIDEWindowTable.Next();
+ }
+ }
+ break;
+ case SID_BASICIDE_LIBSELECTED:
+ case SID_BASICIDE_LIBREMOVED:
+ case SID_BASICIDE_LIBLOADED:
+ {
+ DBG_ASSERT( rReq.GetArgs(), "arguments expected" );
+ const SfxStringItem &rLibName = (const SfxStringItem&)rReq.GetArgs()->Get(SID_BASICIDE_ARG_LIBNAME );
+ String aBasMgrAndLib( rLibName.GetValue() );
+
+ StarBASIC* pLib = 0;
+ BasicManager* pMgr = 0;
+ if ( aBasMgrAndLib.Len() )
+ {
+ String aBasMgr( GetMgrFromMgrAndLib( aBasMgrAndLib ) );
+ String aLib( GetLibFromMgrAndLib( aBasMgrAndLib ) );
+
+ pMgr = BasicIDE::FindBasicManager( aBasMgr );
+ if ( !pMgr ) // Doc schon weg...
+ return;
+ pLib = pMgr->GetLib( aLib );
+ if ( !pLib && ( nSlot == SID_BASICIDE_LIBSELECTED ) )
+ {
+ // LoadOnDemand
+ USHORT nLib = pMgr->GetLibId( aLib );
+ pMgr->LoadLib( nLib );
+ pLib = pMgr->GetLib( nLib );
+ if ( !pLib )
+ {
+ ErrorBox( pCurWin, WB_OK|WB_DEF_OK, String( IDEResId( RID_STR_ERROROPENLIB ) ) ).Execute();
+ // Hat leider keine Auswirkung, weil alter Wert => Kein StateChanged...
+ BasicIDE::GetBindings().Invalidate( SID_BASICIDE_LIBSELECTOR );
+ return;
+ }
+ }
+ }
+ if ( nSlot == SID_BASICIDE_LIBSELECTED )
+ {
+ // Keine Abfrage, ob pCurBasic == pLib,
+ // falls welche ausgeblendet waren.
+ BOOL bSet = TRUE;
+ if ( pLib )
+ {
+ USHORT nLib = pMgr->GetLibId( pLib );
+ if ( pMgr->HasPassword( nLib ) &&
+ !pMgr->IsPasswordVerified( nLib ) )
+ {
+ bSet = QueryPassword( pMgr, nLib );
+ }
+ }
+ if ( bSet )
+ SetCurBasic( pLib );
+ else // alten Wert einstellen...
+ BasicIDE::GetBindings().Invalidate( SID_BASICIDE_LIBSELECTOR, TRUE, FALSE );
+ }
+ else if ( nSlot == SID_BASICIDE_LIBREMOVED )
+ {
+ if ( !pCurBasic || ( pLib == pCurBasic ) )
+ {
+ RemoveWindows( pLib, TRUE );
+ if ( pCurBasic == pLib )
+ {
+ pCurBasic = 0;
+ // Kein UpdateWindows!
+ BasicIDE::GetBindings().Invalidate( SID_BASICIDE_LIBSELECTOR );
+ }
+ }
+ }
+ else // Loaded...
+ UpdateWindows();
+ }
+ break;
+ case SID_BASICIDE_NEWMODULE:
+ {
+ StarBASIC* pBasic = pCurBasic;
+ if ( !pBasic )
+ pBasic = SFX_APP()->GetBasicManager()->GetLib( 0 );
+ ModulWindow* pWin = CreateBasWin( pBasic, String() );
+ DBG_ASSERT( pWin, "New Module: Konnte Fenster nicht erzeugen!" );
+ SetCurWindow( pWin, TRUE );
+ }
+ break;
+ case SID_BASICIDE_NEWDIALOG:
+ {
+ StarBASIC* pBasic = pCurBasic;
+ if ( !pBasic )
+ pBasic = SFX_APP()->GetBasicManager()->GetLib( 0 );
+ DialogWindow* pWin = CreateDlgWin( pBasic, String() );
+ DBG_ASSERT( pWin, "New Module: Konnte Fenster nicht erzeugen!" );
+ SetCurWindow( pWin, TRUE );
+ }
+ break;
+ case SID_BASICIDE_SBXRENAMED:
+ {
+ DBG_ASSERT( rReq.GetArgs(), "arguments expected" );
+ const SbxItem& rSbxItem = (const SbxItem&)rReq.GetArgs()->Get(SID_BASICIDE_ARG_SBX );
+ SbxObject* pSbxObject = (SbxObject*)rSbxItem.GetSbx();
+ IDEBaseWindow* pWin = FindWindow( pSbxObject, FALSE );
+ if ( pWin )
+ {
+ // TabWriter updaten
+ USHORT nId = (USHORT)aIDEWindowTable.GetKey( pWin );
+ DBG_ASSERT( nId, "Kein Eintrag in der Tabbar!" );
+ if ( nId )
+ pTabBar->SetPageText( nId, pSbxObject->GetName() );
+ if( pWin->IsA( TYPE( DialogWindow ) ) )
+ ((DialogWindow*)pWin)->UpdateBrowser();
+ }
+ }
+ break;
+ case SID_BASICIDE_SBXINSERTED:
+ {
+ DBG_ASSERT( rReq.GetArgs(), "arguments expected" );
+ const SbxItem& rSbxItem = (const SbxItem&)rReq.GetArgs()->Get(SID_BASICIDE_ARG_SBX );
+ SbxObject* pSbxObject = (SbxObject*)rSbxItem.GetSbx();
+ StarBASIC* pBasic = BasicIDE::FindBasic( pSbxObject );
+ DBG_ASSERT( pBasic, "Basic fuer das Object nicht gefunden!" );
+ if ( !pCurBasic || ( pBasic == pCurBasic ) )
+ {
+ IDEBaseWindow* pWin = 0;
+ if ( pSbxObject->ISA( SbModule ) )
+ pWin = FindBasWin( pBasic, pSbxObject->GetName(), TRUE );
+ else if ( pSbxObject->GetSbxId() == SBXID_DIALOG )
+ pWin = FindDlgWin( pBasic, pSbxObject->GetName(), TRUE );
+ }
+ }
+ break;
+ case SID_BASICIDE_SBXDELETED:
+ {
+ DBG_ASSERT( rReq.GetArgs(), "arguments expected" );
+ const SbxItem& rSbxItem = (const SbxItem&)rReq.GetArgs()->Get(SID_BASICIDE_ARG_SBX );
+ SbxObject* pSbxObject = (SbxObject*)rSbxItem.GetSbx();
+ IDEBaseWindow* pWin = FindWindow( pSbxObject, TRUE );
+ if ( pWin )
+ RemoveWindow( pWin, TRUE );
+ }
+ break;
+ case SID_BASICIDE_SHOWSBX:
+ {
+ DBG_ASSERT( rReq.GetArgs(), "arguments expected" );
+ const SbxItem& rSbxItem = (const SbxItem&)rReq.GetArgs()->Get(SID_BASICIDE_ARG_SBX );
+ SbxVariable* pSbx = (SbxVariable*)rSbxItem.GetSbx();
+ StarBASIC* pBasic = BasicIDE::FindBasic( pSbx );
+ DBG_ASSERT( pBasic, "Basic nicht gefunden!" );
+ if ( pCurBasic && ( pCurBasic != pBasic ) )
+ SetCurBasic( pBasic );
+ IDEBaseWindow* pWin = 0;
+ if ( pSbx->GetSbxId() == SBXID_DIALOG )
+ pWin = FindDlgWin( pBasic, pSbx->GetName(), TRUE );
+ else if ( pSbx->ISA( SbModule ) )
+ pWin = FindBasWin( pBasic, pSbx->GetName(), TRUE );
+ else if ( pSbx->ISA( SbMethod ) )
+ {
+ pWin = FindBasWin( pBasic, pSbx->GetParent()->GetName(), TRUE );
+ ((ModulWindow*)pWin)->EditMacro( pSbx->GetName() );
+ }
+ DBG_ASSERT( pWin, "Fenster wurde nicht erzeugt!" );
+ SetCurWindow( pWin, TRUE );
+ }
+ break;
+ }
+}
+
+void __EXPORT BasicIDEShell::GetState(SfxItemSet &rSet)
+{
+ SfxWhichIter aIter(rSet);
+ for ( USHORT nWh = aIter.FirstWhich(); 0 != nWh; nWh = aIter.NextWhich() )
+ {
+ switch ( nWh )
+ {
+ case SID_DOCINFO:
+ {
+ rSet.DisableItem( nWh );
+ }
+ break;
+ case SID_SAVEDOC:
+ {
+/*
+ BasicManager* pAppBasMgr = SFX_APP()->GetBasicManager();
+ // Wenn nicht modifiert, sowieso disablen...
+ if ( pCurWin && ( pCurWin->IsModified() ) &&
+ ( BasicIDE::FindBasicManager( pCurWin->GetBasic() ) == pAppBasMgr ) )
+ {
+ break; // Also enabled
+ }
+ if ( !pAppBasMgr->IsModified() )
+ rSet.DisableItem( nWh );
+ // ansonsten disablen, wenn ein anderes Basic dargestellt wird.
+ else if ( pCurBasic && ( BasicIDE::FindBasicManager( pCurBasic ) != pAppBasMgr ) )
+ rSet.DisableItem( nWh );
+ else if ( !pCurBasic && pCurWin )
+ {
+ StarBASIC* pBasic = pCurWin->GetBasic();
+ BasicManager* pMgr = BasicIDE::FindBasicManager( pBasic );
+ if ( pMgr != pAppBasMgr )
+ rSet.DisableItem( nWh );
+ }
+*/
+
+ BasicManager* pMgr = pCurWin ? BasicIDE::FindBasicManager( pCurWin->GetBasic() ) : 0;
+ if ( !pCurWin || !pMgr ||
+ ( !pCurWin->IsModified() && !pMgr->IsModified() ) )
+ {
+ rSet.DisableItem( nWh );
+ }
+ }
+ break;
+ case SID_NEWWINDOW:
+ case SID_SAVEASDOC:
+ {
+ rSet.DisableItem( nWh );
+ }
+ break;
+ case SID_BASICIDE_MODULEDLG:
+ {
+ if ( StarBASIC::IsRunning() )
+ rSet.DisableItem( nWh );
+ }
+ break;
+ case SID_BASICIDE_CHOOSEMACRO:
+ case SID_BASICIDE_OBJCAT:
+ case SID_BASICIDE_SHOWSBX:
+ case SID_BASICIDE_CREATEMACRO:
+ case SID_BASICIDE_EDITMACRO:
+ case SID_BASICIDE_NAMECHANGEDONTAB:
+ {
+ ;
+ }
+ break;
+
+ case SID_BASICIDE_ADDWATCH:
+ case SID_BASICIDE_REMOVEWATCH:
+ case SID_BASICLOAD:
+ case SID_BASICSAVEAS:
+ case SID_BASICIDE_MATCHGROUP:
+ {
+ if ( !pCurWin || !pCurWin->IsA( TYPE( ModulWindow ) ) )
+ rSet.DisableItem( nWh );
+ else if ( ( nWh == SID_BASICLOAD ) && StarBASIC::IsRunning() )
+ rSet.DisableItem( nWh );
+ }
+ break;
+ case SID_BASICRUN:
+ case SID_BASICSTEPINTO:
+ case SID_BASICSTEPOVER:
+ case SID_BASICSTEPOUT:
+ case SID_BASICIDE_TOGGLEBRKPNT:
+ {
+ if ( !pCurWin || !pCurWin->IsA( TYPE( ModulWindow ) ) )
+ rSet.DisableItem( nWh );
+ else if ( StarBASIC::IsRunning() && !((ModulWindow*)pCurWin)->GetBasicStatus().bIsInReschedule )
+ rSet.DisableItem( nWh );
+ }
+ break;
+ case SID_BASICCOMPILE:
+ {
+ if ( !pCurWin || !pCurWin->IsA( TYPE( ModulWindow ) ) || StarBASIC::IsRunning() )
+ rSet.DisableItem( nWh );
+ }
+ break;
+ case SID_BASICSTOP:
+ {
+ // Stop immermoeglich, wenn irgendein Basic lauft...
+ if ( !StarBASIC::IsRunning() )
+ rSet.DisableItem( nWh );
+ }
+ break;
+ case SID_CHOOSE_CONTROLS:
+ case SID_DIALOG_TESTMODE:
+ {
+ if( !pCurWin || !pCurWin->IsA( TYPE( DialogWindow ) ) )
+ rSet.DisableItem( nWh );
+ }
+ break;
+ case SID_SHOW_FORMS:
+ case SID_SHOW_HIDDEN:
+ {
+ rSet.DisableItem( nWh );
+ }
+ break;
+ case SID_SEARCH_OPTIONS:
+ {
+ USHORT nOptions = 0;
+ if( pCurWin )
+ nOptions = pCurWin->GetSearchOptions();
+ rSet.Put( SfxUInt16Item( SID_SEARCH_OPTIONS, nOptions ) );
+ }
+ break;
+ case SID_BASICIDE_LIBSELECTOR:
+ {
+ String aQName;
+ if ( pCurBasic )
+ {
+ BasicManager* pBasMgr = BasicIDE::FindBasicManager( pCurBasic );
+ if ( pBasMgr ) // 0 bei CloseDoc!
+ aQName = CreateMgrAndLibStr( BasicIDE::FindTitle( pBasMgr ), pCurBasic->GetName() );
+ }
+ SfxStringItem aItem( SID_BASICIDE_LIBSELECTOR, aQName );
+ rSet.Put( aItem );
+ }
+ break;
+ case SID_SEARCH_ITEM:
+ {
+ String aSelected = GetSelectionText( TRUE );
+ SvxSearchItem& rItem = IDE_DLL()->GetExtraData()->GetSearchItem();
+ rItem.SetSearchString( aSelected );
+ rSet.Put( rItem );
+ }
+ break;
+ case SID_BASICIDE_STAT_DATE:
+ {
+ String aDate;
+ aDate = String( RTL_CONSTASCII_USTRINGPARAM( "Datum?!" ) );
+ SfxStringItem aItem( SID_BASICIDE_STAT_DATE, aDate );
+ rSet.Put( aItem );
+ }
+ break;
+ case SID_DOC_MODIFIED:
+ {
+ String aModifiedMarker;
+ BasicManager* pBasMgr = pCurWin ? BasicIDE::FindBasicManager( pCurWin->GetBasic() ) : 0;
+ if ( pCurWin && ( pCurWin->IsModified() || ( pBasMgr && pBasMgr->IsModified() ) ) )
+ {
+ aModifiedMarker = '*';
+ }
+ SfxStringItem aItem( SID_DOC_MODIFIED, aModifiedMarker );
+ rSet.Put( aItem );
+ }
+ break;
+ case SID_BASICIDE_STAT_TITLE:
+ {
+ if ( pCurWin )
+ {
+/*
+ String aTitle;
+ StarBASIC* pBasic = pCurWin->GetBasic();
+ BasicManager* pBasMgr = BasicIDE::FindBasicManager( pBasic );
+ DBG_ASSERT( pBasMgr, "BasMgr?!" );
+ aTitle += BasicIDE::FindTitle( pBasMgr );
+ aTitle += '.';
+ aTitle += pBasic->GetName();
+ String aExtraTitle = pCurWin->GetTitle();
+ if ( aExtraTitle.Len() )
+ {
+ aTitle += '.';
+ aTitle += aExtraTitle;
+ }
+*/
+ String aTitle = pCurWin->CreateQualifiedName();
+ SfxStringItem aItem( SID_BASICIDE_STAT_TITLE, aTitle );
+ rSet.Put( aItem );
+ }
+ }
+ break;
+ // Werden vom Controller ausgewertet:
+ case SID_ATTR_SIZE:
+ case SID_ATTR_INSERT:
+ break;
+ case SID_UNDO:
+ case SID_REDO:
+ {
+ if( GetUndoManager() ) // sonst rekursives GetState
+ GetViewFrame()->GetSlotState( nWh, NULL, &rSet );
+ }
+ break;
+ }
+ }
+ if ( pCurWin )
+ pCurWin->GetState( rSet );
+}
+
+void BasicIDEShell::SetCurWindow( IDEBaseWindow* pNewWin, BOOL bUpdateTabBar, BOOL bRememberAsCurrent )
+{
+ // Es muss ein EditWindow am Sfx gesetzt sein, sonst kommt kein
+ // Resize, also stehen die Controls auf den Wiese...
+ // Sieht dann sowieso besser aus, wenn das Modul-Layout angezeigt wird...
+ if ( !pNewWin && ( GetWindow() != pModulLayout ) )
+ {
+ pModulLayout->Show();
+ AdjustPosSizePixel( Point( 0, 0 ), GetViewFrame()->GetWindow().GetOutputSizePixel() );
+ SetWindow( pModulLayout );
+ EnableScrollbars( FALSE );
+ aVScrollBar.Hide();
+ }
+
+ if ( pNewWin != pCurWin )
+ {
+ IDEBaseWindow* pPrevCurWin = pCurWin;
+ pCurWin = pNewWin;
+ if ( pPrevCurWin )
+ {
+ pPrevCurWin->Hide();
+ pPrevCurWin->Deactivating();
+// pPrevCurWin->GetLayoutWindow()->Hide();
+ if( pPrevCurWin->IsA( TYPE( DialogWindow ) ) )
+ {
+ ((DialogWindow*)pPrevCurWin)->DisableBrowser();
+ }
+ else
+ {
+ pModulLayout->SetModulWindow( NULL );
+ }
+ }
+ if ( pCurWin )
+ {
+ AdjustPosSizePixel( Point( 0, 0 ), GetViewFrame()->GetWindow().GetOutputSizePixel() );
+ if( pCurWin->IsA( TYPE( ModulWindow ) ) )
+ {
+ GetViewFrame()->GetWindow().SetHelpId( HID_BASICIDE_MODULWINDOW );
+ pModulLayout->SetModulWindow( (ModulWindow*)pCurWin );
+ pModulLayout->Show();
+
+ if ( bRememberAsCurrent )
+ {
+ StarBASIC* pLib = ((ModulWindow*)pCurWin)->GetBasic();
+ LibInfo* pLibInf = IDE_DLL()->GetExtraData()->GetLibInfos().GetInfo( pLib, TRUE );
+ pLibInf->aCurrentModule = ((ModulWindow*)pCurWin)->GetModule()->GetName();
+ }
+ }
+ else
+ {
+ pModulLayout->Hide();
+ GetViewFrame()->GetWindow().SetHelpId( HID_BASICIDE_DIALOGWINDOW );
+ }
+ if ( GetViewFrame()->GetWindow().IsVisible() ) // sonst macht es spaeter der SFX
+ pCurWin->Show();
+
+ pCurWin->Init();
+
+ if ( !IDE_DLL()->GetExtraData()->ShellInCriticalSection() )
+ {
+ Window* pFrameWindow = &GetViewFrame()->GetWindow();
+ Window* pFocusWindow = Application::GetFocusWindow();
+ while ( pFocusWindow && ( pFocusWindow != pFrameWindow ) )
+ pFocusWindow = pFocusWindow->GetParent();
+ if ( pFocusWindow ) // Focus in BasicIDE
+ pNewWin->GrabFocus();
+ }
+ if( pCurWin->IsA( TYPE( DialogWindow ) ) )
+ ((DialogWindow*)pCurWin)->UpdateBrowser();
+ }
+ if ( bUpdateTabBar )
+ {
+ ULONG nKey = aIDEWindowTable.GetKey( pCurWin );
+ if ( pCurWin && ( pTabBar->GetPagePos( (USHORT)nKey ) == TAB_PAGE_NOTFOUND ) )
+ pTabBar->InsertPage( (USHORT)nKey, pCurWin->GetTitle() ); // wurde neu eingeblendet
+ pTabBar->SetCurPageId( (USHORT)nKey );
+ }
+ if ( pCurWin && pCurWin->IsSuspended() ) // Wenn das Fenster im Fehlerfall angezeigt wird...
+ pCurWin->SetStatus( pCurWin->GetStatus() & ~BASWIN_SUSPENDED );
+ if ( pCurWin )
+ {
+ SetWindow( pCurWin );
+ }
+ else
+ {
+ SetWindow( pModulLayout );
+ GetViewFrame()->GetWindow().SetHelpId( HID_BASICIDE_MODULWINDOW );
+ }
+ SetUndoManager( pCurWin ? pCurWin->GetUndoManager() : 0 );
+ InvalidateBasicIDESlots();
+ SetMDITitle();
+ EnableScrollbars( pCurWin ? TRUE : FALSE );
+
+ }
+}
+
+IDEBaseWindow* BasicIDEShell::FindWindow( const SbxObject* pObj, BOOL bFindSuspended )
+{
+ IDEBaseWindow* pWin = aIDEWindowTable.First();
+ while ( pWin )
+ {
+ if ( !pWin->IsSuspended() || bFindSuspended )
+ {
+ if ( !pObj ) // irgendein nicht suspendiertes
+ return pWin;
+ else if ( pWin->IsA( TYPE( ModulWindow ) ) )
+ {
+ if ( ((ModulWindow*)pWin)->GetModule() == pObj )
+ return pWin;
+ }
+ else
+ {
+ if ( ((DialogWindow*)pWin)->GetDialog() == pObj )
+ return pWin;
+ }
+ }
+ pWin = aIDEWindowTable.Next();
+ }
+ return 0;
+}
+
+long BasicIDEShell::CallBasicErrorHdl( StarBASIC* pBasic )
+{
+ long nRet = 0;
+ ModulWindow* pModWin = ShowActiveModuleWindow( pBasic );
+ if ( pModWin )
+ nRet = pModWin->BasicErrorHdl( pBasic );
+ return nRet;
+}
+
+long BasicIDEShell::CallBasicBreakHdl( StarBASIC* pBasic )
+{
+ long nRet = 0;
+ ModulWindow* pModWin = ShowActiveModuleWindow( pBasic );
+ if ( pModWin )
+ {
+ BOOL bAppWindowDisabled, bDispatcherLocked;
+ USHORT nWaitCount;
+ SfxUInt16Item *pSWActionCount, *pSWLockViewCount;
+ BasicIDE::BasicStopped( &bAppWindowDisabled, &bDispatcherLocked,
+ &nWaitCount, &pSWActionCount, &pSWLockViewCount );
+
+ nRet = pModWin->BasicBreakHdl( pBasic );
+
+ if ( StarBASIC::IsRunning() ) // Falls abgebrochen...
+ {
+ if ( bAppWindowDisabled )
+ Application::GetDefModalDialogParent()->Enable( FALSE );
+ if ( bDispatcherLocked )
+ SFX_APP()->LockDispatcher( TRUE );
+
+ for ( USHORT n = 0; n < nWaitCount; n++ )
+ Application::EnterWait();
+ }
+ }
+ return nRet;
+}
+
+ModulWindow* BasicIDEShell::ShowActiveModuleWindow( StarBASIC* pBasic )
+{
+ if ( pCurBasic && ( pBasic != pCurBasic ) )
+ SetCurBasic( 0, FALSE );
+
+ SbModule* pActiveModule = StarBASIC::GetActiveModule();
+ DBG_ASSERT( pActiveModule, "Kein aktives Modul im ErrorHdl?!" );
+ if ( pActiveModule )
+ {
+ SbxObject* pParent = pActiveModule->GetParent();
+ DBG_ASSERT( pParent && pParent->ISA( StarBASIC ), "Kein BASIC!" );
+ ModulWindow* pWin = FindBasWin( (StarBASIC*)pParent, pActiveModule->GetName(), TRUE );
+ DBG_ASSERT( pWin, "Error/Step-Hdl: Fenster wurde nicht erzeugt/gefunden!" );
+ SetCurWindow( pWin, TRUE );
+ BasicManager* pBasicMgr = BasicIDE::FindBasicManager( pBasic );
+ if ( pBasicMgr )
+ StartListening( *pBasicMgr, TRUE /* Nur einmal anmelden */ );
+ return pWin;
+ }
+ return 0;
+}
+
+void __EXPORT BasicIDEShell::AdjustPosSizePixel( const Point &rPos, const Size &rSize )
+{
+ // Nicht wenn minimiert, weil dann bei Restore der Text verschoben ist.
+ if ( GetViewFrame()->GetWindow().GetOutputSizePixel().Height() == 0 )
+ return;
+
+ Size aSz( rSize );
+// long nScrollbarWidthPixel = aVScrollBar.GetSizePixel().Width();
+ Size aScrollBarBoxSz( aScrollBarBox.GetSizePixel() );
+ aSz.Height() -= aScrollBarBoxSz.Height();
+#ifndef VCL
+#ifdef MAC
+ aSz.Height()++;
+#endif
+#endif
+ Size aOutSz( aSz );
+ aSz.Width() -= aScrollBarBoxSz.Width();
+ aScrollBarBox.SetPosPixel( Point( rSize.Width() - aScrollBarBoxSz.Width(), rSize.Height() - aScrollBarBoxSz.Height() ) );
+ aVScrollBar.SetPosSizePixel( Point( rPos.X()+aSz.Width(), rPos.Y() ), Size( aScrollBarBoxSz.Width(), aSz.Height() ) );
+ if ( bTabBarSplitted )
+ {
+ // SplitSize ist beim Resize 0 !
+ long nSplitPos = pTabBar->GetSizePixel().Width();
+ if ( nSplitPos > aSz.Width() )
+ nSplitPos = aSz.Width();
+ pTabBar->SetPosSizePixel( Point( rPos.X(), rPos.Y()+aSz.Height() ), Size( nSplitPos, aScrollBarBoxSz.Height() ) );
+ long nScrlStart = rPos.X() + nSplitPos;
+ aHScrollBar.SetPosSizePixel( Point( nScrlStart, rPos.Y()+aSz.Height() ), Size( aSz.Width() - nScrlStart + 1, aScrollBarBoxSz.Height() ) );
+ aHScrollBar.Update();
+ }
+ else
+ {
+ aHScrollBar.SetPosSizePixel( Point( rPos.X()+ aSz.Width()/2 - 1, rPos.Y()+aSz.Height() ), Size( aSz.Width()/2 + 2, aScrollBarBoxSz.Height() ) );
+ pTabBar->SetPosSizePixel( Point( rPos.X(), rPos.Y()+aSz.Height() ), Size( aSz.Width()/2, aScrollBarBoxSz.Height() ) );
+ }
+
+ Window* pEdtWin = pCurWin ? pCurWin->GetLayoutWindow() : pModulLayout;
+ if ( pEdtWin )
+ {
+ if( pCurWin && pCurWin->IsA( TYPE( DialogWindow ) ) )
+ pEdtWin->SetPosSizePixel( rPos, aSz ); // Ohne ScrollBar
+ else
+ pEdtWin->SetPosSizePixel( rPos, aOutSz );
+ }
+}
+
+void __EXPORT BasicIDEShell::Activate( BOOL bMDI )
+{
+ if ( bMDI )
+ {
+ if( pCurWin && pCurWin->IsA( TYPE( DialogWindow ) ) )
+ ((DialogWindow*)pCurWin)->UpdateBrowser();
+
+ // Accelerator hauptsaechlich aus kompatibilitaetsgruenden in
+ // ExtraData statt in ViewShell
+ Accelerator* pAccel = IDE_DLL()->GetExtraData()->GetAccelerator();
+ DBG_ASSERT( pAccel, "Accel?!" );
+ pAccel->SetSelectHdl( LINK( this, BasicIDEShell, AccelSelectHdl ) );
+ Application::InsertAccel( pAccel );
+
+ ShowObjectDialog( TRUE, FALSE );
+ }
+}
+
+void __EXPORT BasicIDEShell::Deactivate( BOOL bMDI )
+{
+ // bMDI TRUE heisst, dass ein anderes MDI aktiviert wurde, bei einem
+ // Deactivate durch eine MessageBox ist bMDI FALSE
+ if ( bMDI )
+ {
+ if( pCurWin && pCurWin->IsA( TYPE( DialogWindow ) ) )
+ {
+ DialogWindow* pXDlgWin = (DialogWindow*)pCurWin;
+ pXDlgWin->DisableBrowser();
+ if( pXDlgWin->IsModified() )
+ BasicIDE::MarkDocShellModified( pXDlgWin->GetBasic() );
+ }
+
+ // CanClose pruefen, damit auch beim deaktivieren der BasicIDE geprueft wird,
+ // ob in einem Modul der Sourcecode zu gross ist...
+ for ( ULONG nWin = 0; nWin < aIDEWindowTable.Count(); nWin++ )
+ {
+ IDEBaseWindow* pWin = aIDEWindowTable.GetObject( nWin );
+ if ( /* !pWin->IsSuspended() && */ !pWin->CanClose() )
+ {
+ if ( pCurBasic && ( pWin->GetBasic() != pCurBasic ) )
+ SetCurBasic( 0, FALSE );
+ SetCurWindow( pWin, TRUE );
+ break;
+ }
+ }
+
+ Accelerator* pAccel = IDE_DLL()->GetExtraData()->GetAccelerator();
+ DBG_ASSERT( pAccel, "Accel?!" );
+ pAccel->SetSelectHdl( Link() );
+ Application::RemoveAccel( pAccel );
+
+ ShowObjectDialog( FALSE, FALSE );
+ }
+}
+
+
+IMPL_LINK( BasicIDEShell, AccelSelectHdl, Accelerator*, pAccel )
+{
+ BOOL bDone = TRUE;
+ SfxViewFrame* pCurFrame = SfxViewFrame::Current();
+ DBG_ASSERT( pCurFrame != NULL, "No current view frame!" );
+ SfxDispatcher* pDispatcher = pCurFrame ? pCurFrame->GetDispatcher() : NULL;
+ if( !pDispatcher )
+ return FALSE;
+ switch ( pAccel->GetCurKeyCode().GetCode() )
+ {
+ case KEY_F5:
+ if ( pAccel->GetCurKeyCode().IsShift() || pAccel->GetCurKeyCode().IsMod2() )
+ pDispatcher->Execute( SID_BASICSTOP, SFX_CALLMODE_SYNCHRON );
+ if ( !pAccel->GetCurKeyCode().IsMod2() )
+ {
+ // Muss asynchron sein, damit ggf. STOP wirken kan (Reschedule).
+ pDispatcher->Execute( SID_BASICRUN, SFX_CALLMODE_ASYNCHRON );
+ }
+ break;
+ case KEY_F7:
+ pDispatcher->Execute( SID_BASICIDE_ADDWATCH, SFX_CALLMODE_SYNCHRON );
+ break;
+ case KEY_F8:
+ if ( pAccel->GetCurKeyCode().IsShift() )
+ pDispatcher->Execute( SID_BASICSTEPOVER, SFX_CALLMODE_SYNCHRON );
+ else
+ pDispatcher->Execute( SID_BASICSTEPINTO, SFX_CALLMODE_SYNCHRON );
+ break;
+ case KEY_F9:
+ pDispatcher->Execute( SID_BASICIDE_TOGGLEBRKPNT, SFX_CALLMODE_SYNCHRON );
+ break;
+ default: bDone = FALSE;
+ }
+ return bDone;
+}
+
diff --git a/basctl/source/basicide/basides2.cxx b/basctl/source/basicide/basides2.cxx
new file mode 100644
index 000000000000..57cc24f99f11
--- /dev/null
+++ b/basctl/source/basicide/basides2.cxx
@@ -0,0 +1,307 @@
+/*************************************************************************
+ *
+ * $RCSfile: basides2.cxx,v $
+ *
+ * $Revision: 1.1.1.1 $
+ *
+ * last change: $Author: mh $ $Date: 2000-09-29 11:02:36 $
+ *
+ * The Contents of this file are made available subject to the terms of
+ * either of the following licenses
+ *
+ * - GNU Lesser General Public License Version 2.1
+ * - Sun Industry Standards Source License Version 1.1
+ *
+ * Sun Microsystems Inc., October, 2000
+ *
+ * GNU Lesser General Public License Version 2.1
+ * =============================================
+ * Copyright 2000 by Sun Microsystems, Inc.
+ * 901 San Antonio Road, Palo Alto, CA 94303, USA
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License version 2.1, as published by the Free Software Foundation.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this library; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston,
+ * MA 02111-1307 USA
+ *
+ *
+ * Sun Industry Standards Source License Version 1.1
+ * =================================================
+ * The contents of this file are subject to the Sun Industry Standards
+ * Source License Version 1.1 (the "License"); You may not use this file
+ * except in compliance with the License. You may obtain a copy of the
+ * License at http://www.openoffice.org/license.html.
+ *
+ * Software provided under this License is provided on an "AS IS" basis,
+ * WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING,
+ * WITHOUT LIMITATION, WARRANTIES THAT THE SOFTWARE IS FREE OF DEFECTS,
+ * MERCHANTABLE, FIT FOR A PARTICULAR PURPOSE, OR NON-INFRINGING.
+ * See the License for the specific provisions governing your rights and
+ * obligations concerning the Software.
+ *
+ * The Initial Developer of the Original Code is: Sun Microsystems, Inc.
+ *
+ * Copyright: 2000 by Sun Microsystems, Inc.
+ *
+ * All Rights Reserved.
+ *
+ * Contributor(s): _______________________________________
+ *
+ *
+ ************************************************************************/
+
+#define SI_NOCONTROL
+#define SI_NOSBXCONTROLS
+
+#include <ide_pch.hxx>
+
+#ifndef _SBXCLASS_HXX //autogen
+#include <svtools/sbx.hxx>
+#endif
+
+#pragma hdrstop
+#define __PRIVATE 1
+
+#include <vcl/rcid.h>
+#include <vcl/sound.hxx>
+#include <basidesh.hxx>
+#include <baside2.hxx>
+#include <basdoc.hxx>
+#include <basobj.hxx>
+#include <svtools/texteng.hxx>
+#include <svtools/textview.hxx>
+#include <svtools/xtextedt.hxx>
+#include <sfx2/sfxdefs.hxx>
+
+IMPL_LINK_INLINE_START( BasicIDEShell, ObjectDialogCancelHdl, ObjectCatalog *, EMPTYARG )
+{
+ ShowObjectDialog( FALSE, TRUE );
+ return 0;
+}
+IMPL_LINK_INLINE_END( BasicIDEShell, ObjectDialogCancelHdl, ObjectCatalog *, EMPTYARG )
+
+/*
+IMPL_LINK( BasicIDEShell, ObjectDialogInsertHdl, ObjectCatalog *, pObjCat )
+{
+ if ( !pCurWin )
+ return 0;
+
+ if ( pCurWin->IsA( TYPE( ModulWindow ) ) )
+ {
+ ModulWindow* pEditWin = (ModulWindow*)pCurWin;
+ pEditWin->InsertFromObjectCatalog( pObjCat );
+ }
+ else
+ Sound::Beep();
+
+ return 0;
+}
+*/
+
+USHORT __EXPORT BasicIDEShell::Print( SfxProgress &rProgress, PrintDialog *pPrintDialog )
+{
+ if ( pCurWin )
+ {
+ SfxPrinter* pPrinter = GetPrinter( TRUE );
+ if ( pPrinter )
+ {
+ SfxViewShell::Print( rProgress, pPrintDialog );
+ pCurWin->PrintData( pPrinter );
+ }
+ }
+ return 0;
+}
+
+BOOL BasicIDEShell::HasSelection( BOOL /* bText */ ) const
+{
+ BOOL bSel = FALSE;
+ if ( pCurWin && pCurWin->ISA( ModulWindow ) )
+ {
+ TextView* pEditView = ((ModulWindow*)pCurWin)->GetEditView();
+ if ( pEditView && pEditView->HasSelection() )
+ bSel = TRUE;
+ }
+ return bSel;
+}
+
+String BasicIDEShell::GetSelectionText( BOOL bWholeWord )
+{
+ String aText;
+ if ( pCurWin && pCurWin->ISA( ModulWindow ) )
+ {
+ TextView* pEditView = ((ModulWindow*)pCurWin)->GetEditView();
+ if ( pEditView )
+ {
+ if ( bWholeWord && !pEditView->HasSelection() )
+ {
+ // String aStrCurrentDelimiters = pEngine->GetWordDelimiters();
+ // pEngine->SetWordDelimiters( " .,;\"'" );
+ aText = pEditView->GetTextEngine()->GetWord( pEditView->GetSelection().GetEnd() );
+ // pEngine->SetWordDelimiters( aStrCurrentDelimiters );
+ }
+ else
+ {
+ TextSelection aSel = pEditView->GetSelection();
+ if ( !bWholeWord || ( aSel.GetStart().GetPara() == aSel.GetEnd().GetPara() ) )
+ aText = pEditView->GetSelected();
+ }
+ }
+ }
+ return aText;
+}
+
+SfxPrinter* __EXPORT BasicIDEShell::GetPrinter( BOOL bCreate )
+{
+ if ( pCurWin ) // && pCurWin->ISA( ModulWindow ) )
+ {
+ BasicDocShell* pDocShell = (BasicDocShell*)GetViewFrame()->GetObjectShell();
+ DBG_ASSERT( pDocShell, "DocShell ?!" );
+ return pDocShell->GetPrinter( bCreate );
+ }
+ return 0;
+}
+
+USHORT __EXPORT BasicIDEShell::SetPrinter( SfxPrinter *pNewPrinter, USHORT nDiffFlags )
+{
+ BasicDocShell* pDocShell = (BasicDocShell*)GetViewFrame()->GetObjectShell();
+ DBG_ASSERT( pDocShell, "DocShell ?!" );
+ pDocShell->SetPrinter( pNewPrinter );
+ return 0;
+}
+
+void BasicIDEShell::SetMDITitle()
+{
+ String aTitle = BasicIDE::GetStdTitle();
+ if ( pCurWin )
+ {
+ StarBASIC* pLib = pCurWin->GetBasic();
+ DBG_ASSERT( pLib, "Lib?!" );
+ BasicManager* pBasMgr = BasicIDE::FindBasicManager( pLib );
+ if ( pBasMgr )
+ {
+ aTitle += String( RTL_CONSTASCII_USTRINGPARAM( " - " ) );
+ aTitle += BasicIDE::FindTitle( pBasMgr, SFX_TITLE_FILENAME );
+ aTitle += '.';
+ aTitle += pLib->GetName();
+ }
+ }
+ // Wenn DocShell::SetTitle, erfolgt beim Schliessen Abfrage, ob Speichern!
+ GetViewFrame()->GetObjectShell()->SetTitle( aTitle );
+ GetViewFrame()->GetObjectShell()->SetModified( FALSE );
+}
+
+void BasicIDEShell::DestroyModulWindowLayout()
+{
+ delete pModulLayout;
+ pModulLayout = 0;
+}
+
+
+void BasicIDEShell::UpdateModulWindowLayout()
+{
+ if ( pModulLayout )
+ {
+ pModulLayout->GetStackWindow().UpdateCalls();
+ pModulLayout->GetWatchWindow().UpdateWatches();
+ }
+}
+
+void BasicIDEShell::CreateModulWindowLayout()
+{
+ pModulLayout = new ModulWindowLayout( &GetViewFrame()->GetWindow() );
+}
+
+ModulWindow* BasicIDEShell::CreateBasWin( StarBASIC* pBasic, String aModName )
+{
+ bCreatingWindow = TRUE;
+ ULONG nKey = 0;
+ ModulWindow* pWin = 0;
+
+ SbModule* pModule = pBasic->FindModule( aModName );
+ if ( !pModule )
+ pModule = BasicIDE::CreateModule( pBasic, aModName, TRUE );
+ else // Vielleicht gibt es ein suspendiertes?
+ pWin = FindBasWin( pBasic, aModName, FALSE, TRUE );
+
+ if ( !pWin )
+ {
+ pWin = new ModulWindow( pModulLayout, pBasic, pModule );
+ nKey = InsertWindowInTable( pWin );
+ }
+ else
+ {
+ pWin->SetStatus( pWin->GetStatus() & ~BASWIN_SUSPENDED );
+ IDEBaseWindow* pTmp = aIDEWindowTable.First();
+ while ( pTmp && !nKey )
+ {
+ if ( pTmp == pWin )
+ nKey = aIDEWindowTable.GetCurKey();
+ pTmp = aIDEWindowTable.Next();
+ }
+ DBG_ASSERT( nKey, "CreateBasWin: Kein Key- Fenster nicht gefunden!" );
+ }
+ pTabBar->InsertPage( (USHORT)nKey, pModule->GetName() );
+ pWin->GrabScrollBars( &aHScrollBar, &aVScrollBar );
+ if ( !pCurWin )
+ SetCurWindow( pWin, FALSE, FALSE );
+
+ bCreatingWindow = FALSE;
+ return pWin;
+}
+
+ModulWindow* BasicIDEShell::FindBasWin( StarBASIC* pBasic, const String& rModName, BOOL bCreateIfNotExist, BOOL bFindSuspended )
+{
+ ModulWindow* pModWin = 0;
+ IDEBaseWindow* pWin = aIDEWindowTable.First();
+ while ( pWin && !pModWin )
+ {
+ if ( ( !pWin->IsSuspended() || bFindSuspended ) && pWin->IsA( TYPE( ModulWindow ) ) )
+ {
+ String aMod( ((ModulWindow*)pWin)->GetModuleName() );
+ if ( !pBasic ) // nur irgendeins finden...
+ pModWin = (ModulWindow*)pWin;
+ else if ( ( pWin->GetBasic() == pBasic ) &&
+ ( ( rModName.Len() == 0 ) || ( aMod == rModName ) ) )
+ {
+ pModWin = (ModulWindow*)pWin;
+ }
+ }
+ pWin = aIDEWindowTable.Next();
+ }
+ if ( !pModWin && bCreateIfNotExist )
+ pModWin = CreateBasWin( pBasic, rModName );
+
+ return pModWin;
+}
+
+void __EXPORT BasicIDEShell::Move()
+{
+ if ( pCurWin && pCurWin->ISA( ModulWindow ) )
+ ((ModulWindow*)pCurWin)->FrameWindowMoved();
+}
+
+void __EXPORT BasicIDEShell::ShowCursor( FASTBOOL bOn )
+{
+ if ( pCurWin && pCurWin->ISA( ModulWindow ) )
+ ((ModulWindow*)pCurWin)->ShowCursor( (BOOL)bOn );
+}
+
+// Nur wenn Basicfenster oben:
+void __EXPORT BasicIDEShell::ExecuteBasic( SfxRequest& rReq )
+{
+ if ( !pCurWin || !pCurWin->IsA( TYPE( ModulWindow ) ) )
+ return;
+
+ pCurWin->ExecuteCommand( rReq );
+ CheckWindows();
+}
+
diff --git a/basctl/source/basicide/basides3.cxx b/basctl/source/basicide/basides3.cxx
new file mode 100644
index 000000000000..4512ed85feee
--- /dev/null
+++ b/basctl/source/basicide/basides3.cxx
@@ -0,0 +1,161 @@
+/*************************************************************************
+ *
+ * $RCSfile: basides3.cxx,v $
+ *
+ * $Revision: 1.1.1.1 $
+ *
+ * last change: $Author: mh $ $Date: 2000-09-29 11:02:36 $
+ *
+ * The Contents of this file are made available subject to the terms of
+ * either of the following licenses
+ *
+ * - GNU Lesser General Public License Version 2.1
+ * - Sun Industry Standards Source License Version 1.1
+ *
+ * Sun Microsystems Inc., October, 2000
+ *
+ * GNU Lesser General Public License Version 2.1
+ * =============================================
+ * Copyright 2000 by Sun Microsystems, Inc.
+ * 901 San Antonio Road, Palo Alto, CA 94303, USA
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License version 2.1, as published by the Free Software Foundation.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this library; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston,
+ * MA 02111-1307 USA
+ *
+ *
+ * Sun Industry Standards Source License Version 1.1
+ * =================================================
+ * The contents of this file are subject to the Sun Industry Standards
+ * Source License Version 1.1 (the "License"); You may not use this file
+ * except in compliance with the License. You may obtain a copy of the
+ * License at http://www.openoffice.org/license.html.
+ *
+ * Software provided under this License is provided on an "AS IS" basis,
+ * WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING,
+ * WITHOUT LIMITATION, WARRANTIES THAT THE SOFTWARE IS FREE OF DEFECTS,
+ * MERCHANTABLE, FIT FOR A PARTICULAR PURPOSE, OR NON-INFRINGING.
+ * See the License for the specific provisions governing your rights and
+ * obligations concerning the Software.
+ *
+ * The Initial Developer of the Original Code is: Sun Microsystems, Inc.
+ *
+ * Copyright: 2000 by Sun Microsystems, Inc.
+ *
+ * All Rights Reserved.
+ *
+ * Contributor(s): _______________________________________
+ *
+ *
+ ************************************************************************/
+
+#define SI_NOCONTROL
+#define SI_NOSBXCONTROLS
+
+#include <basidesh.hrc>
+#include <ide_pch.hxx>
+
+#pragma hdrstop
+
+#define __PRIVATE 1
+
+#include <basidesh.hxx>
+#include <baside3.hxx>
+#include <basobj.hxx>
+
+DialogWindow* BasicIDEShell::CreateDlgWin( StarBASIC* pBasic, String aDlgName, SbxObject* pDlg )
+{
+ bCreatingWindow = TRUE;
+
+ ULONG nKey = 0;
+ DialogWindow* pWin = 0;
+ if ( !pDlg )
+ {
+ pDlg = BasicIDE::FindDialog( pBasic, aDlgName );
+ if ( !pDlg )
+ pDlg = BasicIDE::CreateDialog( pBasic, aDlgName );
+ DBG_ASSERT( pDlg, "Es wurde kein Dialog erzeugt!" );
+ }
+ else // Vielleicht gibt es ein suspendiertes?
+ pWin = FindDlgWin( pBasic, aDlgName, FALSE, TRUE );
+
+
+ VCSbxDialogRef xNewDlg = (VCSbxDialog*)pDlg;
+
+ if ( !pWin )
+ {
+ pWin = new DialogWindow( &GetViewFrame()->GetWindow(), xNewDlg, pBasic );
+ nKey = InsertWindowInTable( pWin );
+ }
+ else
+ {
+ pWin->SetStatus( pWin->GetStatus() & ~BASWIN_SUSPENDED );
+ IDEBaseWindow* pTmp = aIDEWindowTable.First();
+ while ( pTmp && !nKey )
+ {
+ if ( pTmp == pWin )
+ nKey = aIDEWindowTable.GetCurKey();
+ pTmp = aIDEWindowTable.Next();
+ }
+ DBG_ASSERT( nKey, "CreateDlgWin: Kein Key - Fenster nicht gefunden!" );
+ }
+ pWin->GrabScrollBars( &aHScrollBar, &aVScrollBar );
+ pTabBar->InsertPage( (USHORT)nKey, xNewDlg->GetName() );
+ if ( !pCurWin )
+ SetCurWindow( pWin, FALSE, FALSE );
+
+ bCreatingWindow = FALSE;
+ return pWin;
+}
+
+DialogWindow* BasicIDEShell::FindDlgWin( StarBASIC* pBasic, const String& rDlgName, BOOL bCreateIfNotExist, BOOL bFindSuspended )
+{
+ DialogWindow* pDlgWin = 0;
+ IDEBaseWindow* pWin = aIDEWindowTable.First();
+ while ( pWin && !pDlgWin )
+ {
+ if ( ( !pWin->IsSuspended() || bFindSuspended ) && pWin->IsA( TYPE( DialogWindow ) ) )
+ {
+ String aDlgStr( ((DialogWindow*)pWin)->GetDialogName() );
+ if ( !pBasic ) // nur irgendeins finden...
+ pDlgWin = (DialogWindow*)pWin;
+ else if ( ( pWin->GetBasic() == pBasic ) &&
+ ( ( rDlgName.Len() == 0 ) || ( aDlgStr == rDlgName ) ) )
+ pDlgWin = (DialogWindow*)pWin;
+ }
+ pWin = aIDEWindowTable.Next();
+ }
+ if ( !pDlgWin && bCreateIfNotExist )
+ pDlgWin = CreateDlgWin( pBasic, rDlgName );
+
+ return pDlgWin;
+}
+
+SdrView* BasicIDEShell::GetCurDlgView()
+{
+ if ( !pCurWin || !pCurWin->IsA( TYPE( DialogWindow ) ) )
+ return NULL;
+
+ DialogWindow* pWin = (DialogWindow*)pCurWin;
+ return pWin->GetView();
+}
+
+// Nur wenn Dialogfenster oben:
+void __EXPORT BasicIDEShell::ExecuteDialog( SfxRequest& rReq )
+{
+ if ( !pCurWin || !pCurWin->IsA( TYPE( DialogWindow ) ) )
+ return;
+
+ pCurWin->ExecuteCommand( rReq );
+}
+
diff --git a/basctl/source/basicide/basidesh.cxx b/basctl/source/basicide/basidesh.cxx
new file mode 100644
index 000000000000..c02fec385742
--- /dev/null
+++ b/basctl/source/basicide/basidesh.cxx
@@ -0,0 +1,848 @@
+/*************************************************************************
+ *
+ * $RCSfile: basidesh.cxx,v $
+ *
+ * $Revision: 1.1.1.1 $
+ *
+ * last change: $Author: mh $ $Date: 2000-09-29 11:02:36 $
+ *
+ * The Contents of this file are made available subject to the terms of
+ * either of the following licenses
+ *
+ * - GNU Lesser General Public License Version 2.1
+ * - Sun Industry Standards Source License Version 1.1
+ *
+ * Sun Microsystems Inc., October, 2000
+ *
+ * GNU Lesser General Public License Version 2.1
+ * =============================================
+ * Copyright 2000 by Sun Microsystems, Inc.
+ * 901 San Antonio Road, Palo Alto, CA 94303, USA
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License version 2.1, as published by the Free Software Foundation.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this library; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston,
+ * MA 02111-1307 USA
+ *
+ *
+ * Sun Industry Standards Source License Version 1.1
+ * =================================================
+ * The contents of this file are subject to the Sun Industry Standards
+ * Source License Version 1.1 (the "License"); You may not use this file
+ * except in compliance with the License. You may obtain a copy of the
+ * License at http://www.openoffice.org/license.html.
+ *
+ * Software provided under this License is provided on an "AS IS" basis,
+ * WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING,
+ * WITHOUT LIMITATION, WARRANTIES THAT THE SOFTWARE IS FREE OF DEFECTS,
+ * MERCHANTABLE, FIT FOR A PARTICULAR PURPOSE, OR NON-INFRINGING.
+ * See the License for the specific provisions governing your rights and
+ * obligations concerning the Software.
+ *
+ * The Initial Developer of the Original Code is: Sun Microsystems, Inc.
+ *
+ * Copyright: 2000 by Sun Microsystems, Inc.
+ *
+ * All Rights Reserved.
+ *
+ * Contributor(s): _______________________________________
+ *
+ *
+ ************************************************************************/
+
+// CLOOKS:
+//#define _MENUBTN_HXX
+#define _SPIN_HXX
+#define _PRVWIN_HXX
+//#define _FIELD_HXX ***
+//#define _TAB_HXX ***
+#define _DIALOGS_HXX
+#define _SVRTF_HXX
+#define _ISETBRW_HXX
+#define _VCTRLS_HXX
+#define SI_NOCONTROL
+#define SI_NOSBXCONTROLS
+
+#define ITEMID_SIZE 0
+
+// Falls ohne PCH's:
+#include <ide_pch.hxx>
+
+#pragma hdrstop
+
+#define __PRIVATE 1
+
+#ifndef _SBXCLASS_HXX //autogen
+#include <svtools/sbx.hxx>
+#endif
+#ifndef _SFXHINT_HXX //autogen
+#include <svtools/hint.hxx>
+#endif
+#include <basidesh.hrc>
+#include <basidesh.hxx>
+#include <basdoc.hxx>
+#include <basobj.hxx>
+#include <bastypes.hxx>
+#include <basicbox.hxx>
+#include <objdlg.hxx>
+#include <sbxitem.hxx>
+#include <tbxctl.hxx>
+#include <iderdll2.hxx>
+
+#define BasicIDEShell
+#define SFX_TYPEMAP
+#include <idetemp.hxx>
+#include <baside.hxx>
+#include <iderdll.hxx>
+#include <svx/pszctrl.hxx>
+#include <svx/insctrl.hxx>
+
+TYPEINIT1( BasicIDEShell, SfxViewShell );
+
+SFX_IMPL_VIEWFACTORY( BasicIDEShell, SVX_INTERFACE_BASIDE_VIEWSH )
+{
+ SFX_VIEW_REGISTRATION( BasicDocShell );
+}
+
+
+// SFX_IMPL_INTERFACE( BasicIDEShell, SfxViewShell, IDEResId( RID_STR_IDENAME ) )
+// {
+// }
+
+// MI: Prinzipiel IDL, aber ich lieber doch nicht?
+// SFX_IMPL_ /*IDL_*/ INTERFACE( BasicIDEShell, SfxViewShell, IDEResId( RID_STR_IDENAME ) )
+SFX_IMPL_INTERFACE( BasicIDEShell, SfxViewShell, IDEResId( RID_STR_IDENAME ) )
+{
+ SFX_OBJECTBAR_REGISTRATION( SFX_OBJECTBAR_MACRO | SFX_VISIBILITY_STANDARD
+ | SFX_VISIBILITY_FULLSCREEN | SFX_VISIBILITY_CLIENT, IDEResId( RID_BASICIDE_OBJECTBAR ) );
+ SFX_CHILDWINDOW_REGISTRATION( SID_SEARCH_DLG );
+ SFX_CHILDWINDOW_REGISTRATION( SID_SHOW_BROWSER );
+}
+
+
+
+#define IDE_VIEWSHELL_FLAGS SFX_VIEW_MAXIMIZE_FIRST|SFX_VIEW_CAN_PRINT|SFX_VIEW_NO_NEWWINDOW
+
+BasicIDEShell::BasicIDEShell( SfxViewFrame *pFrame, Window * ):
+ SfxViewShell( pFrame, IDE_VIEWSHELL_FLAGS ),
+ aHScrollBar( &GetViewFrame()->GetWindow(), WinBits( WB_HSCROLL | WB_DRAG ) ),
+ aVScrollBar( &GetViewFrame()->GetWindow(), WinBits( WB_VSCROLL | WB_DRAG ) ),
+ aScrollBarBox( &GetViewFrame()->GetWindow(), WinBits( WB_SIZEABLE ) )
+{
+ Init();
+}
+
+
+BasicIDEShell::BasicIDEShell( SfxViewFrame *pFrame, const BasicIDEShell & rView):
+ SfxViewShell( pFrame, IDE_VIEWSHELL_FLAGS ),
+ aHScrollBar( &GetViewFrame()->GetWindow(), WinBits( WB_HSCROLL | WB_DRAG ) ),
+ aVScrollBar( &GetViewFrame()->GetWindow(), WinBits( WB_VSCROLL | WB_DRAG ) ),
+ aScrollBarBox( &GetViewFrame()->GetWindow(), WinBits( WB_SIZEABLE ) )
+{
+ DBG_ERROR( "Zweite Ansicht auf Debugger nicht moeglich!" );
+}
+
+
+
+BasicIDEShell::BasicIDEShell( SfxViewFrame* pFrame, SfxViewShell* /* pOldShell */ ) :
+ SfxViewShell( pFrame, IDE_VIEWSHELL_FLAGS ),
+ aHScrollBar( &GetViewFrame()->GetWindow(), WinBits( WB_HSCROLL | WB_DRAG ) ),
+ aVScrollBar( &GetViewFrame()->GetWindow(), WinBits( WB_VSCROLL | WB_DRAG ) ),
+ aScrollBarBox( &GetViewFrame()->GetWindow(), WinBits( WB_SIZEABLE ) )
+{
+ Init();
+}
+
+
+
+void BasicIDEShell::Init()
+{
+ //TbxControls::RegisterControl( SID_CHOOSE_CONTROLS );
+ SvxPosSizeStatusBarControl::RegisterControl();
+ SvxInsertStatusBarControl::RegisterControl();
+
+ IDE_DLL()->GetExtraData()->ShellInCriticalSection() = TRUE;
+
+ SetName( String( RTL_CONSTASCII_USTRINGPARAM( "BasicIDE" ) ) );
+ SetHelpId( SVX_INTERFACE_BASIDE_VIEWSH );
+
+ SFX_APP()->EnterBasicCall();
+
+ LibBoxControl::RegisterControl( SID_BASICIDE_LIBSELECTOR );
+
+ CreateModulWindowLayout();
+
+ StartListening( *SFX_APP(), TRUE /* Nur einmal anmelden */ );
+
+ GetViewFrame()->GetWindow().SetBackground();
+
+ pCurWin = 0;
+ pCurBasic = 0;
+ pObjectCatalog = 0;
+ bCreatingWindow = FALSE;
+
+ // MT 08/00: BasicToolBar not longer in other ViewShells.
+// SFX_APP()->GetAppDispatcher().Push(*this);
+
+ pTabBar = new BasicIDETabBar( &GetViewFrame()->GetWindow() );
+ pTabBar->SetSplitHdl( LINK( this, BasicIDEShell, TabBarSplitHdl ) );
+ bTabBarSplitted = FALSE;
+
+ IDEBaseWindow* pTmpWin = 0;
+ nCurKey = 100;
+ InitScrollBars();
+ InitTabBar();
+
+ // Nicht 0, wird sonst beim naechsten Request nicht auf das entspr. Basic gesetzt.
+ SetCurBasic( SFX_APP()->GetBasicManager()->GetStdLib(), FALSE );
+ UpdateWindows();
+
+ IDE_DLL()->pShell = this;
+ IDE_DLL()->GetExtraData()->ShellInCriticalSection() = FALSE;
+}
+
+__EXPORT BasicIDEShell::~BasicIDEShell()
+{
+ IDE_DLL()->pShell = NULL;
+
+ // Damit bei einem Basic-Fehler beim Speichern die Shell nicht sofort
+ // wieder hoch kommt:
+ IDE_DLL()->GetExtraData()->ShellInCriticalSection() = TRUE;
+
+ SetWindow( 0 );
+ SetCurWindow( 0 );
+
+ // Alle Fenster zerstoeren:
+ IDEBaseWindow* pWin = aIDEWindowTable.First();
+ while ( pWin )
+ {
+ // Kein Store, passiert bereits, wenn die BasicManager zerstoert werden.
+ delete pWin;
+ pWin = aIDEWindowTable.Next();
+ }
+
+ aIDEWindowTable.Clear();
+ delete pTabBar;
+ delete pObjectCatalog;
+ DestroyModulWindowLayout();
+ // MI: Das gab einen GPF im SDT beim Schliessen da dann der ViewFrame die
+ // ObjSh loslaesst. Es wusste auch keiner mehr wozu das gut war.
+ // GetViewFrame()->GetObjectShell()->Broadcast( SfxSimpleHint( SFX_HINT_DYING ) );
+
+ SFX_APP()->LeaveBasicCall();
+ IDE_DLL()->GetExtraData()->ShellInCriticalSection() = FALSE;
+}
+
+sal_Bool BasicIDEShell::HasBasic() const
+{
+ return FALSE;
+}
+
+void BasicIDEShell::StoreAllWindowData( BOOL bPersistent )
+{
+ for ( ULONG nWin = 0; nWin < aIDEWindowTable.Count(); nWin++ )
+ {
+ IDEBaseWindow* pWin = aIDEWindowTable.GetObject( nWin );
+ DBG_ASSERT( pWin, "PrepareClose: NULL-Pointer in Table?" );
+ if ( !pWin->IsSuspended() )
+ pWin->StoreData();
+ }
+
+ if ( bPersistent && SFX_APP()->GetBasicManager()->IsModified() )
+ {
+ SFX_APP()->SaveBasicManager();
+
+ SfxBindings& rBindings = BasicIDE::GetBindings();
+ rBindings.Invalidate( SID_SAVEDOC );
+ rBindings.Update( SID_SAVEDOC );
+ }
+}
+
+
+USHORT __EXPORT BasicIDEShell::PrepareClose( BOOL bUI, BOOL bForBrowsing )
+{
+ // da es nach Drucken etc. (DocInfo) modifiziert ist, hier resetten
+ GetViewFrame()->GetObjectShell()->SetModified(FALSE);
+
+ if ( StarBASIC::IsRunning() )
+ {
+ String aErrorStr( IDEResId( RID_STR_CANNOTCLOSE ) );
+ Window *pParent = &GetViewFrame()->GetWindow();
+ InfoBox( pParent, aErrorStr ).Execute();
+ return FALSE;
+ }
+ else
+ {
+ // Hier unguenstig, wird zweimal gerufen...
+// StoreAllWindowData();
+
+ BOOL bCanClose = TRUE;
+ for ( ULONG nWin = 0; bCanClose && ( nWin < aIDEWindowTable.Count() ); nWin++ )
+ {
+ IDEBaseWindow* pWin = aIDEWindowTable.GetObject( nWin );
+ if ( /* !pWin->IsSuspended() && */ !pWin->CanClose() )
+ {
+ if ( pCurBasic && ( pWin->GetBasic() != pCurBasic ) )
+ SetCurBasic( 0, FALSE );
+ SetCurWindow( pWin, TRUE );
+ bCanClose = FALSE;
+ }
+ }
+
+ if ( bCanClose )
+ StoreAllWindowData( FALSE ); // Nicht auf Platte schreiben, das passiert am Ende automatisch
+
+ return bCanClose;
+ }
+}
+
+void BasicIDEShell::InitScrollBars()
+{
+ aVScrollBar.SetLineSize( 300 );
+ aVScrollBar.SetPageSize( 2000 );
+ aHScrollBar.SetLineSize( 300 );
+ aHScrollBar.SetPageSize( 2000 );
+ aHScrollBar.Enable();
+ aVScrollBar.Enable();
+ aVScrollBar.Show();
+ aHScrollBar.Show();
+ aScrollBarBox.Show();
+}
+
+
+
+void BasicIDEShell::InitTabBar()
+{
+ pTabBar->Enable();
+ pTabBar->Show();
+ pTabBar->SetSelectHdl( LINK( this, BasicIDEShell, TabBarHdl ) );
+}
+
+
+Size __EXPORT BasicIDEShell::GetOptimalSizePixel() const
+{
+ return Size( 400, 300 );
+}
+
+
+
+void __EXPORT BasicIDEShell::OuterResizePixel( const Point &rPos, const Size &rSize )
+{
+ // Adjust fliegt irgendwann raus...
+ AdjustPosSizePixel( rPos, rSize );
+}
+
+
+IMPL_LINK_INLINE_START( BasicIDEShell, TabBarSplitHdl, TabBar *, pTBar )
+{
+ bTabBarSplitted = TRUE;
+ ArrangeTabBar();
+
+ return 0;
+}
+IMPL_LINK_INLINE_END( BasicIDEShell, TabBarSplitHdl, TabBar *, pTBar )
+
+
+
+IMPL_LINK( BasicIDEShell, TabBarHdl, TabBar *, pCurTabBar )
+{
+ USHORT nCurId = pCurTabBar->GetCurPageId();
+ IDEBaseWindow* pWin = aIDEWindowTable.Get( nCurId );
+ DBG_ASSERT( pWin, "Eintrag in TabBar passt zu keinem Fenster!" );
+ SetCurWindow( pWin );
+
+ return 0;
+}
+
+
+
+void BasicIDEShell::ArrangeTabBar()
+{
+ Size aSz( GetViewFrame()->GetWindow().GetOutputSizePixel() );
+ long nBoxPos = aScrollBarBox.GetPosPixel().X() - 1;
+ long nPos = pTabBar->GetSplitSize();
+ if ( nPos <= nBoxPos )
+ {
+ Point aPnt( pTabBar->GetPosPixel() );
+ long nH = aHScrollBar.GetSizePixel().Height();
+ pTabBar->SetPosSizePixel( aPnt, Size( nPos, nH ) );
+ long nScrlStart = aPnt.X() + nPos;
+ aHScrollBar.SetPosSizePixel( Point( nScrlStart, aPnt.Y() ), Size( nBoxPos - nScrlStart + 2, nH ) );
+ aHScrollBar.Update();
+ }
+}
+
+
+
+SfxUndoManager* BasicIDEShell::GetUndoManager()
+{
+ SfxUndoManager* pMgr = NULL;
+ if( pCurWin )
+ pMgr = pCurWin->GetUndoManager();
+
+ return pMgr;
+}
+
+
+
+void BasicIDEShell::ShowObjectDialog( BOOL bShow, BOOL bCreateOrDestroy )
+{
+ if ( bShow )
+ {
+ if ( !pObjectCatalog && bCreateOrDestroy )
+ {
+ pObjectCatalog = new ObjectCatalog( &GetViewFrame()->GetWindow() );
+ // Position wird in BasicIDEData gemerkt und vom Dlg eingestellt
+ pObjectCatalog->SetCancelHdl( LINK( this, BasicIDEShell, ObjectDialogCancelHdl ) );
+ }
+
+ // Die allerletzten Aenderungen...
+ if ( pCurWin )
+ pCurWin->StoreData();
+
+ if ( pObjectCatalog )
+ {
+ pObjectCatalog->UpdateEntries();
+ pObjectCatalog->Show();
+ }
+ }
+ else if ( pObjectCatalog )
+ {
+ pObjectCatalog->Hide();
+ if ( bCreateOrDestroy )
+ {
+ // Wegen OS/2-Focus-Problem pObjectCatalog vorm delete auf NULL
+ ObjectCatalog* pTemp = pObjectCatalog;
+ pObjectCatalog = 0;
+ delete pTemp;
+ }
+ }
+}
+
+
+
+void __EXPORT BasicIDEShell::SFX_NOTIFY( SfxBroadcaster& rBC, const TypeId&,
+ const SfxHint& rHint, const TypeId& )
+{
+ if ( rHint.IsA( TYPE( SfxEventHint ) ) )
+ {
+ if ( ( ((SfxEventHint&)rHint).GetEventId() == SFX_EVENT_CREATEDOC ) ||
+ ( ((SfxEventHint&)rHint).GetEventId() == SFX_EVENT_OPENDOC ) )
+ {
+ UpdateWindows();
+ }
+ }
+ if ( rHint.IsA( TYPE( SfxSimpleHint ) ) )
+ {
+ if ( ((SfxSimpleHint&)rHint).GetId() == SFX_HINT_DOCCHANGED )
+ {
+ // Wird z.Z. nur gerufen bei "Letzte Version"
+ // Doc bleibt erhalten, BasicManager wird zerstoert.
+ // Die Fenster wurden durch das BasicManager-Dying zerstoert,
+ // muessen evtl. wieder angezeigt werden.
+ UpdateWindows();
+ }
+ else if ( ((SfxSimpleHint&)rHint).GetId() == SFX_HINT_MODECHANGED )
+ {
+ // ReadOnly toggled...
+ if ( rBC.IsA( TYPE( SfxObjectShell ) ) )
+ {
+ SfxObjectShell* pShell = (SfxObjectShell*)&rBC;
+ BasicManager* pBasMgr = pShell->GetBasicManager();
+ for ( ULONG nWin = aIDEWindowTable.Count(); nWin; )
+ {
+ IDEBaseWindow* pWin = aIDEWindowTable.GetObject( --nWin );
+ BasicManager* pM = BasicIDE::FindBasicManager( pWin->GetBasic() );
+ if ( pM == pBasMgr )
+ pWin->SetReadOnly( pShell->IsReadOnly() );
+ }
+ }
+
+ }
+ else if ( ((SfxSimpleHint&)rHint).GetId() == SFX_HINT_TITLECHANGED )
+ {
+ BasicIDE::GetBindings().Invalidate( SID_BASICIDE_LIBSELECTOR, TRUE, FALSE );
+ SetMDITitle();
+ }
+ else if ( ((SfxSimpleHint&)rHint).GetId() == SFX_HINT_DYING )
+ {
+ // Alle Fenster suchen, die auf einem Basic des Managers arbeiten,
+ // Daten sichern, Fenster zerstoeren
+ if ( rBC.IsA( TYPE( BasicManager ) ) )
+ {
+ BOOL bSetCurWindow = FALSE;
+ BOOL bSetCurBasic = FALSE;
+ BasicManager* pBasMgr = (BasicManager* )&rBC;
+ USHORT nLibs = pBasMgr->GetLibCount();
+ // Alle Fenster, die ein Object dieser Lib anzeigen, schliessen
+ for ( USHORT nLib = 0; nLib < nLibs; nLib++ )
+ {
+ StarBASIC* pLib = pBasMgr->GetLib( nLib );
+ if ( !pLib )
+ continue;
+
+ // Damit wird leider das ganze Basic angehalten, wenn
+ // ein vom Basic unbeteiligtes Doc geschlossen wird.
+ // Da das laufende Basic hoffentlich Referenzen auf die
+ // benoetigten Libs haelt, sollte es auch nicht noetig sein
+// if ( pLib->IsRunning() )
+// pLib->Stop();
+ for ( ULONG nWin = aIDEWindowTable.Count(); nWin; )
+ {
+ IDEBaseWindow* pWin = aIDEWindowTable.GetObject( --nWin );
+ if ( pWin->GetBasic() == pLib )
+ {
+ if ( pWin->GetStatus() & (BASWIN_RUNNINGBASIC|BASWIN_INRESCHEDULE) )
+ {
+ pWin->AddStatus( BASWIN_TOBEKILLED );
+ pWin->Hide();
+ StarBASIC::Stop();
+ // Es kommt kein Notify...
+ pWin->BasicStopped();
+ }
+ else
+ {
+ pWin->StoreData();
+ if ( pWin == pCurWin )
+ bSetCurWindow = TRUE;
+ RemoveWindow( pWin, TRUE, FALSE );
+ }
+ }
+ }
+ if ( pLib == pCurBasic )
+ bSetCurBasic = TRUE;
+ }
+ if ( bSetCurBasic )
+ SetCurBasic( SFX_APP()->GetBasic(), TRUE );
+ else if ( bSetCurWindow )
+ {
+ IDEBaseWindow* pWin = FindWindow( 0 );
+ SetCurWindow( pWin, TRUE );
+ }
+ }
+ else if ( rBC.IsA( TYPE( StarBASIC ) ) )
+ {
+ StarBASIC* pLib = (StarBASIC* )&rBC;
+ IDE_DLL()->GetExtraData()->GetLibInfos().DestroyInfo( pLib );
+ }
+ EndListening( rBC, TRUE /* Alle abmelden */ );
+ }
+ if ( rHint.IsA( TYPE( SbxHint ) ) )
+ {
+ SbxHint& rSbxHint = (SbxHint&)rHint;
+ ULONG nHintId = rSbxHint.GetId();
+ if ( ( nHintId == SBX_HINT_BASICSTART ) ||
+ ( nHintId == SBX_HINT_BASICSTOP ) )
+ {
+ SfxBindings& rBindings = BasicIDE::GetBindings();
+ rBindings.Invalidate( SID_BASICRUN );
+ rBindings.Update( SID_BASICRUN );
+ rBindings.Invalidate( SID_BASICCOMPILE );
+ rBindings.Update( SID_BASICCOMPILE );
+ rBindings.Invalidate( SID_BASICSTEPOVER );
+ rBindings.Update( SID_BASICSTEPOVER );
+ rBindings.Invalidate( SID_BASICSTEPINTO );
+ rBindings.Update( SID_BASICSTEPINTO );
+ rBindings.Invalidate( SID_BASICSTEPOUT );
+ rBindings.Update( SID_BASICSTEPOUT );
+ rBindings.Invalidate( SID_BASICSTOP );
+ rBindings.Update( SID_BASICSTOP );
+ rBindings.Invalidate( SID_BASICIDE_TOGGLEBRKPNT );
+ rBindings.Update( SID_BASICIDE_TOGGLEBRKPNT );
+ rBindings.Invalidate( SID_BASICIDE_MODULEDLG );
+ rBindings.Update( SID_BASICIDE_MODULEDLG );
+ rBindings.Invalidate( SID_BASICLOAD );
+ rBindings.Update( SID_BASICLOAD );
+
+ if ( nHintId == SBX_HINT_BASICSTOP )
+ {
+ // Nicht nur bei Error/Break oder explizitem anhalten,
+ // falls durch einen Programmierfehler das Update abgeschaltet ist.
+ BasicIDE::BasicStopped();
+ UpdateModulWindowLayout(); // Leer machen...
+ }
+
+ IDEBaseWindow* pWin = aIDEWindowTable.First();
+ while ( pWin )
+ {
+ if ( nHintId == SBX_HINT_BASICSTART )
+ pWin->BasicStarted();
+ else
+ pWin->BasicStopped();
+ pWin = aIDEWindowTable.Next();
+ }
+ }
+ }
+ }
+}
+
+
+
+void BasicIDEShell::CheckWindows()
+{
+ BOOL bSetCurWindow = FALSE;
+ for ( ULONG nWin = 0; nWin < aIDEWindowTable.Count(); nWin++ )
+ {
+ IDEBaseWindow* pWin = aIDEWindowTable.GetObject( nWin );
+ if ( pWin->GetStatus() & BASWIN_TOBEKILLED )
+ {
+ pWin->StoreData();
+ if ( pWin == pCurWin )
+ bSetCurWindow = TRUE;
+ RemoveWindow( pWin, TRUE, FALSE );
+ nWin--;
+ }
+ }
+ if ( bSetCurWindow )
+ SetCurWindow( FindWindow( 0 ), TRUE );
+}
+
+
+
+void BasicIDEShell::RemoveWindows( StarBASIC* pBasic, BOOL bDestroy )
+{
+ BOOL bChangeCurWindow = pCurWin ? FALSE : TRUE;
+ for ( ULONG nWin = 0; nWin < aIDEWindowTable.Count(); nWin++ )
+ {
+ IDEBaseWindow* pWin = aIDEWindowTable.GetObject( nWin );
+ if ( pWin->GetBasic() == pBasic )
+ {
+ if ( pWin == pCurWin )
+ bChangeCurWindow = TRUE;
+ pWin->StoreData();
+ RemoveWindow( pWin, bDestroy, FALSE );
+ nWin--;
+ }
+ }
+ if ( bChangeCurWindow )
+ SetCurWindow( FindWindow( 0 ), TRUE );
+}
+
+
+
+void BasicIDEShell::UpdateWindows()
+{
+ // Alle Fenster, die nicht angezeigt werden duerfen, entfernen
+ BOOL bChangeCurWindow = pCurWin ? FALSE : TRUE;
+ if ( pCurBasic )
+ {
+ for ( ULONG nWin = 0; nWin < aIDEWindowTable.Count(); nWin++ )
+ {
+ IDEBaseWindow* pWin = aIDEWindowTable.GetObject( nWin );
+ if ( pWin->GetBasic() != pCurBasic )
+ {
+ if ( pWin == pCurWin )
+ bChangeCurWindow = TRUE;
+ pWin->StoreData();
+ // Die Abfrage auf RUNNING verhindert den Absturz, wenn in Reschedule.
+ // Fenster bleibt erstmal stehen, spaeter sowieso mal umstellen,
+ // dass Fenster nur als Hidden markiert werden und nicht
+ // geloescht.
+ if ( !(pWin->GetStatus() & ( BASWIN_TOBEKILLED | BASWIN_RUNNINGBASIC | BASWIN_SUSPENDED ) ) )
+ {
+ RemoveWindow( pWin, FALSE, FALSE );
+ nWin--;
+ }
+ }
+ }
+ }
+
+ if ( bCreatingWindow )
+ return;
+
+ SbModule* pNextActiveModule = NULL;
+
+ // Alle anzuzeigenden Fenster anzeigen
+ BasicManager* pBasicMgr = SFX_APP()->GetBasicManager();
+ SfxObjectShell* pDocShell = 0;
+ while ( pBasicMgr )
+ {
+ // Nur, wenn es ein dazugehoeriges Fenster gibt, damit nicht die
+ // Gecachten Docs, die nicht sichtbar sind ( Remot-Dokumente )
+ if ( !pDocShell || ( ( pBasicMgr != SFX_APP()->GetBasicManager() )
+ && ( SfxViewFrame::GetFirst( pDocShell ) ) ) )
+ {
+ StartListening( *pBasicMgr, TRUE /* Nur einmal anmelden */ );
+ if ( pDocShell )
+ StartListening( *pDocShell, TRUE );
+
+ USHORT nLibs = pBasicMgr->GetLibCount();
+ for ( USHORT nLib = 0; nLib < nLibs; nLib++ )
+ {
+ if ( !pBasicMgr->HasPassword( nLib ) ||
+ pBasicMgr->IsPasswordVerified( nLib ) )
+ {
+ StarBASIC* pLib = pBasicMgr->GetLib( nLib );
+ if ( pLib && ( !pCurBasic || ( pLib == pCurBasic ) ) )
+ {
+ ImplStartListening( pLib );
+
+ LibInfo* pLibInf = IDE_DLL()->GetExtraData()->GetLibInfos().GetInfo( pLib );
+
+ for ( USHORT nMod = 0; nMod < pLib->GetModules()->Count(); nMod++ )
+ {
+ SbModule* pMod = (SbModule*)pLib->GetModules()->Get( nMod );
+ if ( !FindBasWin( pLib, pMod->GetName(), FALSE ) )
+ CreateBasWin( pLib, pMod->GetName() );
+ if ( pLibInf && !pNextActiveModule &&
+ ( pMod->GetName() == pLibInf->aCurrentModule ) )
+ {
+ pNextActiveModule = pMod;
+ }
+ }
+
+ // Und ein BasigDialog-Fenster...
+ pLib->GetAll( SbxCLASS_OBJECT );
+ for ( USHORT nObj = 0; nObj < pLib->GetObjects()->Count(); nObj++ )
+ {
+ SbxVariable* pVar = pLib->GetObjects()->Get( nObj );
+ if ( pVar->ISA( SbxObject ) && ( ((SbxObject*)pVar)->GetSbxId() == GetDialogSbxId() ) )
+ {
+ SbxObject* pObj = (SbxObject*)pVar;
+ if ( !FindDlgWin( pLib, pObj->GetName(), FALSE ) )
+ CreateDlgWin( pLib, pObj->GetName(), pObj );
+ }
+ }
+ }
+ }
+ }
+ }
+
+ if ( pDocShell )
+ pDocShell = SfxObjectShell::GetNext( *pDocShell );
+ else
+ pDocShell = SfxObjectShell::GetFirst();
+
+ pBasicMgr = ( pDocShell ? pDocShell->GetBasicManager() : 0 );
+ }
+
+ if ( bChangeCurWindow )
+ SetCurWindow( FindWindow( pNextActiveModule ), TRUE );
+}
+
+void BasicIDEShell::RemoveWindow( IDEBaseWindow* pWindow, BOOL bDestroy, BOOL bAllowChangeCurWindow )
+{
+ DBG_ASSERT( pWindow, "Kann keinen NULL-Pointer loeschen!" );
+ ULONG nKey = aIDEWindowTable.GetKey( pWindow );
+ pTabBar->RemovePage( (USHORT)nKey );
+ aIDEWindowTable.Remove( nKey );
+ if ( pWindow == pCurWin )
+ {
+ if ( bAllowChangeCurWindow )
+ SetCurWindow( FindWindow( 0 ), TRUE );
+ else
+ SetCurWindow( NULL, FALSE );
+ }
+ if ( bDestroy )
+ {
+ if ( !( pWindow->GetStatus() & BASWIN_INRESCHEDULE ) )
+ {
+ delete pWindow;
+ }
+ else
+ {
+ pWindow->AddStatus( BASWIN_TOBEKILLED );
+ pWindow->Hide();
+ StarBASIC::Stop();
+ // Es kommt kein Notify...
+ pWindow->BasicStopped();
+ aIDEWindowTable.Insert( nKey, pWindow ); // wieder einhaegen
+ }
+ }
+ else
+ {
+ pWindow->Hide();
+ pWindow->AddStatus( BASWIN_SUSPENDED );
+ pWindow->Deactivating();
+ aIDEWindowTable.Insert( nKey, pWindow ); // wieder einhaegen
+ }
+
+}
+
+
+
+USHORT BasicIDEShell::InsertWindowInTable( IDEBaseWindow* pNewWin )
+{
+ // Eigentlich prueffen,
+ nCurKey++;
+ aIDEWindowTable.Insert( nCurKey, pNewWin );
+ return nCurKey;
+}
+
+
+
+void BasicIDEShell::InvalidateBasicIDESlots()
+{
+ // Nur die, die eine optische Auswirkung haben...
+ SfxBindings& rBindings = BasicIDE::GetBindings();
+ rBindings.Invalidate( SID_UNDO );
+ rBindings.Invalidate( SID_REDO );
+ rBindings.Invalidate( SID_SAVEDOC );
+ rBindings.Invalidate( SID_BASICIDE_CHOOSEMACRO );
+ rBindings.Invalidate( SID_BASICIDE_MODULEDLG );
+ rBindings.Invalidate( SID_BASICIDE_OBJCAT );
+ rBindings.Invalidate( SID_BASICSTOP );
+ rBindings.Invalidate( SID_BASICRUN );
+ rBindings.Invalidate( SID_BASICCOMPILE );
+ rBindings.Invalidate( SID_BASICLOAD );
+ rBindings.Invalidate( SID_BASICSAVEAS );
+ rBindings.Invalidate( SID_BASICIDE_MATCHGROUP );
+ rBindings.Invalidate( SID_BASICSTEPINTO );
+ rBindings.Invalidate( SID_BASICSTEPOVER );
+ rBindings.Invalidate( SID_BASICSTEPOUT );
+ rBindings.Invalidate( SID_BASICIDE_TOGGLEBRKPNT );
+ rBindings.Invalidate( SID_BASICIDE_ADDWATCH );
+ rBindings.Invalidate( SID_BASICIDE_REMOVEWATCH );
+ rBindings.Invalidate( SID_CHOOSE_CONTROLS );
+ rBindings.Invalidate( SID_PRINTDOC );
+ rBindings.Invalidate( SID_PRINTDOCDIRECT );
+ rBindings.Invalidate( SID_SETUPPRINTER );
+ rBindings.Invalidate( SID_DIALOG_TESTMODE );
+
+ rBindings.Invalidate( SID_DOC_MODIFIED );
+ rBindings.Invalidate( SID_BASICIDE_STAT_TITLE );
+ rBindings.Invalidate( SID_BASICIDE_STAT_POS );
+ rBindings.Invalidate( SID_ATTR_INSERT );
+ rBindings.Invalidate( SID_ATTR_SIZE );
+}
+
+void BasicIDEShell::EnableScrollbars( BOOL bEnable )
+{
+ if ( bEnable )
+ {
+ aHScrollBar.Enable();
+ aVScrollBar.Enable();
+ }
+ else
+ {
+ aHScrollBar.Disable();
+ aVScrollBar.Disable();
+ }
+}
+
+void BasicIDEShell::SetCurBasic( StarBASIC* pBasic, BOOL bUpdateWindows )
+{
+ pCurBasic = pBasic;
+ if ( bUpdateWindows )
+ UpdateWindows();
+
+ pTabBar->SetCurrentLib( pBasic );
+
+ BasicIDE::GetBindings().Invalidate( SID_BASICIDE_LIBSELECTOR );
+}
+
+void BasicIDEShell::ImplStartListening( StarBASIC* pBasic )
+{
+ StartListening( pBasic->GetBroadcaster(), TRUE /* Nur einmal anmelden */ );
+}
+
+
diff --git a/basctl/source/basicide/basidesh.src b/basctl/source/basicide/basidesh.src
new file mode 100644
index 000000000000..3b0b86893506
--- /dev/null
+++ b/basctl/source/basicide/basidesh.src
@@ -0,0 +1,2646 @@
+/*************************************************************************
+ *
+ * $RCSfile: basidesh.src,v $
+ *
+ * $Revision: 1.1.1.1 $
+ *
+ * last change: $Author: mh $ $Date: 2000-09-29 11:02:36 $
+ *
+ * The Contents of this file are made available subject to the terms of
+ * either of the following licenses
+ *
+ * - GNU Lesser General Public License Version 2.1
+ * - Sun Industry Standards Source License Version 1.1
+ *
+ * Sun Microsystems Inc., October, 2000
+ *
+ * GNU Lesser General Public License Version 2.1
+ * =============================================
+ * Copyright 2000 by Sun Microsystems, Inc.
+ * 901 San Antonio Road, Palo Alto, CA 94303, USA
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License version 2.1, as published by the Free Software Foundation.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this library; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston,
+ * MA 02111-1307 USA
+ *
+ *
+ * Sun Industry Standards Source License Version 1.1
+ * =================================================
+ * The contents of this file are subject to the Sun Industry Standards
+ * Source License Version 1.1 (the "License"); You may not use this file
+ * except in compliance with the License. You may obtain a copy of the
+ * License at http://www.openoffice.org/license.html.
+ *
+ * Software provided under this License is provided on an "AS IS" basis,
+ * WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING,
+ * WITHOUT LIMITATION, WARRANTIES THAT THE SOFTWARE IS FREE OF DEFECTS,
+ * MERCHANTABLE, FIT FOR A PARTICULAR PURPOSE, OR NON-INFRINGING.
+ * See the License for the specific provisions governing your rights and
+ * obligations concerning the Software.
+ *
+ * The Initial Developer of the Original Code is: Sun Microsystems, Inc.
+ *
+ * Copyright: 2000 by Sun Microsystems, Inc.
+ *
+ * All Rights Reserved.
+ *
+ * Contributor(s): _______________________________________
+ *
+ *
+ ************************************************************************/
+
+#include <baside2.hrc>
+#include <helpid.hrc>
+String RID_STR_IDENAME
+{
+ Text = "BasicIDE" ;
+};
+String RID_STR_FILTER_ALLFILES
+{
+ TEXT = "<Alle>" ;
+ TEXT [ ENGLISH ] = "<All>" ;
+ TEXT [ norwegian ] = "<Alle>" ;
+ TEXT [ italian ] = "<tutto>" ;
+ TEXT [ portuguese_brazilian ] = "<Tudo>" ;
+ TEXT [ portuguese ] = "<Todos>" ;
+ TEXT [ finnish ] = "<All>" ;
+ TEXT [ danish ] = "<Alle>" ;
+ TEXT [ french ] = "<Tous>" ;
+ TEXT [ swedish ] = "<Alla>" ;
+ TEXT [ dutch ] = "<Alles>" ;
+ TEXT [ spanish ] = "<Todos>" ;
+ TEXT [ english_us ] = "<All>" ;
+ TEXT[ chinese_simplified ] = "<È«²¿>";
+ TEXT[ russian ] = "<Âñå>";
+ TEXT[ polish ] = "<Wszystkie>";
+ TEXT[ japanese ] = "<‚·‚ׂÄ>";
+ TEXT[ chinese_traditional ] = "<¥þ³¡>";
+ TEXT[ arabic ] = "<Çáßá>";
+ TEXT[ dutch ] = "<Alles>";
+ TEXT[ chinese_simplified ] = "<È«²¿>";
+ TEXT[ greek ] = "<¼ëá>";
+ TEXT[ korean ] = "<Àüü>";
+ TEXT[ turkish ] = "<Tümü>";
+};
+String RID_STR_NOMODULE
+{
+ Text = "< Kein Modul >" ;
+ Text [ English ] = "< No module >" ;
+ Text [ english_us ] = "< No module >" ;
+ Text [ portuguese_brazilian ] = "< Kein Modul >" ;
+ Text [ swedish ] = "< Ingen Modul >" ;
+ Text [ danish ] = "< Intet modul >" ;
+ Text [ italian ] = "<nessun modulo >" ;
+ Text [ spanish ] = "< ningún módulo >" ;
+ Text [ french ] = "< Aucun module >" ;
+ Text [ dutch ] = "< Geen module >" ;
+ Text [ portuguese ] = "< Nenhum módulo >" ;
+ Text[ chinese_simplified ] = "< ÎÞÄ£¿é >";
+ Text[ russian ] = "< Áåç ìîäóëÿ >";
+ Text[ polish ] = "< Bez modu³u >";
+ Text[ japanese ] = "<Ó¼Þ­°Ù‚È‚µ>";
+ Text[ chinese_traditional ] = "< µL¼Ò¶ô >";
+ Text[ arabic ] = "< ÈÏæä æÍÏÉ äãØíÉ >";
+ Text[ dutch ] = "< Geen module >";
+ Text[ chinese_simplified ] = "< ÎÞÄ£¿é >";
+ Text[ greek ] = "< ÊáìéÜ ëåéôïõñãéêÞ ìïíÜäá >";
+ Text[ korean ] = "< ¸ðµâ ¾øÀ½ >";
+ Text[ turkish ] = "< Modül yok >";
+};
+String RID_STR_WRONGPASSWORD
+{
+ /* ### ACHTUNG: Neuer Text in Resource? Fehlerhaftes Paßwort. : Fehlerhaftes Pa˜wort. */
+ Text = "Fehlerhaftes Passwort." ;
+ Text [ English ] = "Password doesn't match." ;
+ Text [ norwegian ] = "Passord passer ikke." ;
+ Text [ italian ] = "La password non corrisponde." ;
+ Text [ portuguese_brazilian ] = "A senha não combina." ;
+ Text [ portuguese ] = "Senha incorrecta." ;
+ Text [ finnish ] = "Salasana ei kelpaa." ;
+ Text [ danish ] = "Forkert adgangskode." ;
+ Text [ french ] = "Mot de passe incorrect." ;
+ Text [ swedish ] = "Felaktigt lösenord." ;
+ Text [ dutch ] = "Wachtwoord is niet correct." ;
+ Text [ spanish ] = "Contraseña errónea." ;
+ Text [ english_us ] = "Incorrect Password." ;
+ Text[ chinese_simplified ] = "¿ÚÁîÎÞЧ¡£";
+ Text[ russian ] = "Íåïðàâèëüíûé ïàðîëü.";
+ Text[ polish ] = "Nieprawid³owe has³o.";
+ Text[ japanese ] = "³‚µ‚­‚È‚¢Ê߽ܰÄÞB";
+ Text[ chinese_traditional ] = "±K½XµL®Ä¡C";
+ Text[ arabic ] = "ßáãÉ ÇáÓÑ ÛíÑ ÕÍíÍÉ.";
+ Text[ dutch ] = "Wachtwoord is niet correct.";
+ Text[ chinese_simplified ] = "¿ÚÁîÎÞЧ¡£";
+ Text[ greek ] = "ÅóöáëìÝíïò êùäéêüò ðñüóâáóçò.";
+ Text[ korean ] = "¾ÏÈ£¸íÀÌ Æ²¸³´Ï´Ù.";
+ Text[ turkish ] = "Yanlýþ þifre";
+};
+String RID_STR_OPEN
+{
+ Text = "Laden" ;
+ Text [ ENGLISH ] = "Load" ;
+ Text [ norwegian ] = "Load" ;
+ Text [ italian ] = "Carica" ;
+ Text [ portuguese_brazilian ] = "Carregar" ;
+ Text [ portuguese ] = "Carregar" ;
+ Text [ finnish ] = "Lataa" ;
+ Text [ danish ] = "Indlæs" ;
+ Text [ french ] = "Charger" ;
+ Text [ swedish ] = "Ladda" ;
+ Text [ dutch ] = "Laden" ;
+ Text [ spanish ] = "Cargar" ;
+ Text [ english_us ] = "Load" ;
+ Text[ chinese_simplified ] = "×°ÔØ";
+ Text[ russian ] = "Çàãðóçèòü";
+ Text[ polish ] = "Za³aduj";
+ Text[ japanese ] = "“ǂݞ‚Ý";
+ Text[ chinese_traditional ] = "¸Ë¸ü";
+ Text[ arabic ] = "ÊÍãíá";
+ Text[ dutch ] = "Laden";
+ Text[ chinese_simplified ] = "×°ÔØ";
+ Text[ greek ] = "Öüñôùóç";
+ Text[ korean ] = "·Îµå";
+ Text[ turkish ] = "Yükle";
+};
+String RID_STR_SAVE
+{
+ Text = "Speichern" ;
+ Text [ ENGLISH ] = "Save" ;
+ Text [ norwegian ] = "Save" ;
+ Text [ italian ] = "Salva" ;
+ Text [ portuguese_brazilian ] = "Gravar" ;
+ Text [ portuguese ] = "Guardar" ;
+ Text [ finnish ] = "Tallennus" ;
+ Text [ danish ] = "Gem" ;
+ Text [ french ] = "Enregistrer" ;
+ Text [ swedish ] = "Spara" ;
+ Text [ dutch ] = "Opslaan" ;
+ Text [ spanish ] = "Guardar" ;
+ Text [ english_us ] = "Save" ;
+ Text[ chinese_simplified ] = "´æÅÌ";
+ Text[ russian ] = "Ñîõðàíèòü";
+ Text[ polish ] = "Zapisz";
+ Text[ japanese ] = "•Û‘¶";
+ Text[ chinese_traditional ] = "Àx¦sÀÉ®×";
+ Text[ arabic ] = "ÍÝÙ";
+ Text[ dutch ] = "Opslaan";
+ Text[ chinese_simplified ] = "´æÅÌ";
+ Text[ greek ] = "ÁðïèÞêåõóç";
+ Text[ korean ] = "ÀúÀå";
+ Text[ turkish ] = "Kaydet";
+};
+String RID_STR_SOURCETOBIG
+{
+ /* ### ACHTUNG: Neuer Text in Resource? Der Quelltext ist zu groß und kann weder gespeichert noch compiliert werden.\nLöschen Sie einige Kommentare oder übertragen Sie einige Methoden in ein anderes Modul. : Der Quelltext ist zu gro˜ und kann weder gespeichert noch compiliert werden.\nL÷schen Sie einige Kommentare oder ³bertragen Sie einige Methoden in ein anderes Modul. */
+ Text = "Der Quelltext ist zu groß und kann weder gespeichert noch compiliert werden.\nLöschen Sie einige Kommentare oder übertragen Sie einige Methoden in ein anderes Modul." ;
+ Text [ English ] = "The source is to big and cannot be compiled or stored.\nDelete some comments or move some methods to an other module" ;
+ Text [ english_us ] = "The source text is too large and can be neither compiled nor saved.\nDelete some of the comments or transfer some methods into another module." ;
+ Text [ swedish ] = "Källtexten är för stor och kan varken sparas eller kompileras.\nRadera några kommentarer eller överför några metoder till en annan modul." ;
+ Text [ danish ] = "Kildeteksten er for stor og kan hverken gemmes eller kompileres.\nSlet nogle kommentarer eller overfør nogle metoder til et andet modul." ;
+ Text [ italian ] = "Il testo sorgente è troppo grande e non può essere né compilato né salvato\nCancellare alcuni commenti o trasferire alcuni metodi in un altro modulo." ;
+ Text [ spanish ] = "El texto fuente es demasiado grande por lo que no se puede guardar o compilar.\nElimine algunos comentarios o transfiera algunos métodos a otro módulo." ;
+ Text [ french ] = "Le texte source a trop de volume et ne peut ni être sauvegardé ni être compilé.\nVeuillez supprimer quelque commentaires ou transférer quelques méthodes dans un autre module." ;
+ Text [ dutch ] = "De brontekst is te lang en kan niet opgeslagen of gecompileerd worden.\\Wis enkele commentaren of verplaats enkele methodes naar een andere module." ;
+ Text [ portuguese_brazilian ] = "Der Quelltext ist zu groß und kann weder gespeichert noch compiliert werden.\nLöschen Sie einige Kommentare oder übertragen Sie einige Methoden in ein anderes Modul." ;
+ Text [ portuguese ] = "O texto-fonte é demasiado longo e não pode ser guardado nem compilado.\nElimine alguns comentários ou transfira alguns métodos para outro módulo." ;
+ Text[ chinese_simplified ] = "Ô´Îı¾Ì«´ó£¬ÎÞ·¨´æÅ̺ͱàÒë¡£\nÇëÄúɾ³ýһЩע½â»òÕß½«¼¸¸ö·½·¨×ªÒƵ½Ò»¸öÆäËûµÄÄ£¿éÖ®ÖС£";
+ Text[ russian ] = "Èñõîäíûé òåêñò ñëèøêîì áîëüøîé è åãî íåâîçìîæíî íè ñîõðàíèòü, íè êîìïèëèðîâàòü.\nÓäàëèòå íåêîòîðûå êîììåíòàðèè èëè ïåðåíåñèòå íåêîòîðûå ìåòîäû â äðóãîé ìîäóëü.";
+ Text[ polish ] = "Tekst Ÿród³owy jest za du¿y i nie mo¿e zostaæ zapisany ani skompilowany.\nUsuñ kilka komentarzy lub przenieœ kilka metod do innego modu³u.";
+ Text[ japanese ] = "¿°½‚ª’·‚·‚¬‚é‚̂ŕۑ¶‚·‚邱‚Æ‚àºÝÊß²Ù‚·‚邱‚Æ‚à‚Å‚«‚Ü‚¹‚ñB\n‚¢‚­‚‚©‚̺ÒÝÄ휂·‚é‚©¤‚¢‚­‚‚©‚Ì•û–@‚𑼂ÌÓ¼Þ­°Ù‚É“]‘—‚µ‚ĉº‚³‚¢B";
+ Text[ chinese_traditional ] = "­ì©lÀɤӤj¡MµLªkÀx¦s½sĶ¡C\n½Ð±z§R°£¤@¨Çª`¸Ñ©ÎªÌ±N´X­Ó¤èªkÂಾ¨ì¤@­Ó¨ä¥Lªº¼Ò¶ô¤§¤¤¡C";
+ Text[ arabic ] = "äÕ ÇáãÕÏÑ ßÈíÑ áÏÑÌÉ íÊÚÐÑ ãÚåÇ ÍÝÙå¡ Ãæ ÊÑÌãÊå.\nÞã ÈÍÐÝ ÈÚÖ ÇáÊÚáíÞÇÊ¡ Ãæ ÇäÞá ÈÚÖ ÇáÃÓÇáíÈ Åáì æÍÏÉ äãØíÉ ÃÎÑì.";
+ Text[ dutch ] = "De brontekst is te lang en kan niet opgeslagen of gecompileerd worden.\\Wis enkele commentaren of verplaats enkele methodes naar een andere module.";
+ Text[ chinese_simplified ] = "Ô´Îı¾Ì«´ó£¬ÎÞ·¨´æÅ̺ͱàÒë¡£\nÇëÄúɾ³ýһЩע½â»òÕß½«¼¸¸ö·½·¨×ªÒƵ½Ò»¸öÆäËûµÄÄ£¿éÖ®ÖС£";
+ Text[ greek ] = "Äåí åßíáé äõíáôüí íá ãßíåé ìåôáãëþôôéóç Þ áðïèÞêåõóç ôïõ êåéìÝíïõ ðñïÝëåõóçò \nåðåéäÞ åßíáé õðåñâïëéêÜ ìåãÜëï. ÄéáãñÜøôå ìåñéêÜ ó÷üëéá Þ ìåôáöÝñåôå ìåñéêÝò ìåèüäïõò óå ìéá Üëëç ëåéôïõñãéêÞ ìïíÜäá.";
+ Text[ korean ] = "¼Ò½º ÅØ½ºÆ®°¡ ³Ê¹« Ä¿¼­ ÀúÀåµµ ÄÄÆÄÀϵµ ºÒ°¡´ÉÇÕ´Ï´Ù. \n¸î °¡Áö ¸Þ¸ð¸¦ »èÁ¦Çϰųª ¸î¸î ¸Þ¼­µå¸¦ ´Ù¸¥ ¸ðµâ·Î ¿Å±â½Ê½Ã¿À.";
+ Text[ turkish ] = "Kaynak metin uzunluðu nedeniyle kaydedilemiyor ve derlenemiyor.\nBazý açýklamalarý silin ya da bazý yöntemleri baþka bir modüle aktarýn.";
+};
+String RID_STR_ERROROPENSTORAGE
+{
+ /* ### ACHTUNG: Neuer Text in Resource? Fehler beim Öffnen der Datei : Fehler beim Íffnen der Datei */
+ Text = "Fehler beim Öffnen der Datei" ;
+ Text [ English ] = "Error open file" ;
+ Text [ english_us ] = "Error opening file" ;
+ Text [ italian ] = "Errore nell'apertura del file" ;
+ Text [ spanish ] = "Error al abrir el archivo" ;
+ Text [ french ] = "Erreur lors de l'ouverture du fichier" ;
+ Text [ dutch ] = "Fout bij het openen van het bestand." ;
+ Text [ swedish ] = "Fel vid öppnande av fil" ;
+ Text [ danish ] = "Fejl ved åbning af fil" ;
+ Text [ portuguese_brazilian ] = "Fehler beim Öffnen der Datei" ;
+ Text [ portuguese ] = "Erro ao abrir o ficheiro." ;
+ Text[ chinese_simplified ] = "´ò¿ªÎļþʱ·¢Éú´íÎó¡£";
+ Text[ russian ] = "Îøèáêà ïðè îòêðûòèè ôàéëà";
+ Text[ polish ] = "B³¹d przy otwieraniu pliku";
+ Text[ japanese ] = "̧²Ù‚ðŠJ‚¯‚éÛ‚É´×°‚ª”­¶‚µ‚Ü‚µ‚½B";
+ Text[ chinese_traditional ] = "¶}±ÒÀɮ׮ɵo¥Í¿ù»~¡C";
+ Text[ arabic ] = "ÎØÃ ÃËäÇÁ ÝÊÍ ÇáãáÝ";
+ Text[ dutch ] = "Fout bij het openen van het bestand.";
+ Text[ chinese_simplified ] = "´ò¿ªÎļþʱ·¢Éú´íÎó¡£";
+ Text[ greek ] = "ÓöÜëìá êáôÜ ôï Üíïéãìá ôïõ áñ÷åßïõ";
+ Text[ korean ] = "ÆÄÀÏ ¿­±â¿¡ ¿À·ù ¹ß»ý";
+ Text[ turkish ] = "Dosyayý açma sýrasýnda hata";
+};
+String RID_STR_ERROROPENLIB
+{
+ Text = "Fehler beim Laden der Bibliothek" ;
+ Text [ English ] = "Fehler beim Laden der Bibliothek" ;
+ Text [ english_us ] = "Error loading library" ;
+ Text [ portuguese_brazilian ] = "Fehler beim Laden der Bibliothek" ;
+ Text [ swedish ] = "Fel vid laddning av bibliotek" ;
+ Text [ danish ] = "Fejl under indlæsning af biblioteket" ;
+ Text [ italian ] = "Errore nel caricare la library" ;
+ Text [ spanish ] = "Error al cargar la biblioteca" ;
+ Text [ french ] = "Erreur lors du chargem. de bibliothèque." ;
+ Text [ dutch ] = "Fout bij het laden van de bibliotheek" ;
+ Text [ portuguese ] = "Erro ao carregar a biblioteca." ;
+ Text[ chinese_simplified ] = "ÔÚ×°ÔØ¿âʱ·¢Éú´íÎó¡£";
+ Text[ russian ] = "Îøèáêà ïðè çàãðóçêå áèáëèîòåêè";
+ Text[ polish ] = "B³¹d przy ³adowaniu biblioteki";
+ Text[ japanese ] = "ײÌÞר‚̓ǂݞ‚Ý’†‚É´×°‚ª”­¶‚µ‚Ü‚µ‚½B";
+ Text[ chinese_traditional ] = "¦b¸Ë¸üµ{¦¡®w®Éµo¥Í¿ù»~¡C";
+ Text[ arabic ] = "ÎØÃ ÃËäÇÁ ÊÍãíá ÇáãßÊÈÉ";
+ Text[ dutch ] = "Fout bij het laden van de bibliotheek";
+ Text[ chinese_simplified ] = "ÔÚ×°ÔØ¿âʱ·¢Éú´íÎó¡£";
+ Text[ greek ] = "ÓöÜëìá êáôÜ ôç öüñôùóç ôçò âéâëéïèÞêçò";
+ Text[ korean ] = "¶óÀ̺귯¸® ·Îµå¿¡ ¿À·ù ¹ß»ý";
+ Text[ turkish ] = "Kitaplýðý yükleme sýrasýnda hata";
+};
+String RID_STR_NOLIBINSTORAGE
+{
+ /* ### ACHTUNG: Neuer Text in Resource? Die Datei enthält keine BASIC-Bibliotheken : Die Datei enthõlt keine BASIC-Bibliotheken */
+ Text = "Die Datei enthält keine BASIC-Bibliotheken" ;
+ Text [ English ] = "The document doesn't contain any BASIC libaries" ;
+ Text [ english_us ] = "The file doesn't contain any BASIC libraries" ;
+ Text [ italian ] = "Il file non contiene biblioteche Basic" ;
+ Text [ spanish ] = "El archivo no contiene bibliotecas BASIC" ;
+ Text [ french ] = "Le fichier ne contient pas de bibliothèque BASIC" ;
+ Text [ dutch ] = "Het bestand bevat geen BASIC-bibliotheken" ;
+ Text [ swedish ] = "Filen innehåller inga BASIC-bibliotek" ;
+ Text [ danish ] = "Filen indeholder ingen BASIC-biblioteker" ;
+ Text [ portuguese_brazilian ] = "Die Datei enthält keine Basic-Bibliotheken" ;
+ Text [ portuguese ] = "O ficheiro não contém bibliotecas BASIC." ;
+ Text[ chinese_simplified ] = "Õâ¸öÎļþûÓÐ BASIC-¿â¡£";
+ Text[ russian ] = "Ýòîò ôàéë íå ñîäåðæèò áèáëèîòåêè BASIC";
+ Text[ polish ] = "Plik nie zawiera bibliotek BASIC";
+ Text[ japanese ] = "‚±‚Ì̧²Ù‚Ì’†‚ÉBASICײÌÞר‚Í‚ ‚è‚Ü‚¹‚ñB";
+ Text[ chinese_traditional ] = "³o­ÓÀɮרS¦³ BASIC-µ{¦¡®w¡C";
+ Text[ arabic ] = ".BASIC áÇ íÍÊæí ÇáãáÝ Úáì ÃíÉ ãßÊÈÇÊ";
+ Text[ dutch ] = "Het bestand bevat geen BASIC-bibliotheken";
+ Text[ chinese_simplified ] = "Õâ¸öÎļþûÓÐ BASIC-¿â¡£";
+ Text[ greek ] = "Ôï áñ÷åßï äåí ðåñéÝ÷åé âéâëéïèÞêåò BASIC";
+ Text[ korean ] = "ÆÄÀÏÀÌ ¾Æ¹« BASIC ¶óÀ̺귯¸®µµ Æ÷ÇÔÇϰí ÀÖÁö ¾Ê½À´Ï´Ù";
+ Text[ turkish ] = "Dosya BASIC kitaplýklarý içermiyor";
+};
+String RID_STR_BADSBXNAME
+{
+ /* ### ACHTUNG: Neuer Text in Resource? Ungültiger Bezeichner : Ung³ltiger Bezeichner */
+ Text = "Ungültiger Bezeichner" ;
+ Text [ English ] = "Invalid Name" ;
+ Text [ norwegian ] = "Invalid Name" ;
+ Text [ italian ] = "Nome non valido" ;
+ Text [ portuguese_brazilian ] = "Invalid Name" ;
+ Text [ portuguese ] = "Nome incorrecto" ;
+ Text [ french ] = "Nom incorrect" ;
+ Text [ dutch ] = "Ongeldige aanduiding" ;
+ Text [ spanish ] = "Nombre no válido" ;
+ Text [ danish ] = "Ugyldigt navn" ;
+ Text [ swedish ] = "Ogiltigt namn" ;
+ Text [ finnish ] = "Invalid Name" ;
+ Text [ english_us ] = "Invalid Name" ;
+ Text[ chinese_simplified ] = "ÎÞЧµÄÃû³Æ";
+ Text[ russian ] = "Íåïðàâèëüíîå îáîçíà÷åíèå";
+ Text[ polish ] = "Nieprawid³owa nazwa";
+ Text[ japanese ] = "–¼‘O‚ª•s“K؂ł·";
+ Text[ chinese_traditional ] = "¦WºÙµL®Ä";
+ Text[ arabic ] = "ÇÓã ÛíÑ ÕÇáÍ";
+ Text[ dutch ] = "Ongeldige aanduiding";
+ Text[ chinese_simplified ] = "ÎÞЧµÄÃû³Æ";
+ Text[ greek ] = "Ìç áðïäåêôü üíïìá";
+ Text[ korean ] = "À¯È¿ÇÏÁö ¾ÊÀº À̸§";
+ Text[ turkish ] = "Geçersiz ad";
+};
+String RID_STR_LIBNAMETOLONG
+{
+ Text = "Der Name einer Bibliothek darf maximal 30 Zeichen lang sein.";
+ Text [ English ] = "The name of a library can only be 30 characters long." ;
+ Text[ english_us ] = "A library name cannot be longer than 30 characters.";
+ Text[ portuguese ] = "O nome da biblioteca só pode ter o máximo de 30 caracteres.";
+ Text[ russian ] = "Èìÿ áèáëèîòåêè ìîæåò ñîñòîÿòü èç 30 çíàêîâ ìàêñèìóì.";
+ Text[ greek ] = "Ãéá ôï üíïìá ôçò âéâëéïèÞêçò åðéôñÝðïíôáé Ýùò êáé 30 ÷áñáêôÞñåò.";
+ Text[ dutch ] = "De naam van een bibliotheek mag maximaal 30 tekens lang zijn.";
+ Text[ french ] = "Le nom d'une bibliothèque peut contenir au maximum 30 caractères.";
+ Text[ spanish ] = "El nombre de la biblioteca no debe contener más de 30 caracteres.";
+ Text[ italian ] = "Il nome della libreria può avere una lunghezza massima di 30 caratteri.";
+ Text[ danish ] = "Et biblioteks navn må højst indeholde 30 tegn.";
+ Text[ swedish ] = "Namnet på ett bibliotek får maximalt innehålla 30 tecken.";
+ Text[ polish ] = "Nazwa biblioteki mo¿e siê sk³adaæ z maksymalnie 30 znaków.";
+ Text[ portuguese_brazilian ] = "The name of a library can only be 30 characters long.";
+ Text[ japanese ] = "ײÌÞר–¼‚ÍÅ‚30•¶Žš‚܂łł·B";
+ Text[ korean ] = "¶óÀ̺귯¸® À̸§ÀÇ ±æÀÌ´Â 30ÀÚ¸¦ ÃʰúÇÒ ¼ö ¾ø½À´Ï´Ù.";
+ Text[ chinese_simplified ] = "¿âÃû³Æ×î¶àÖ»ÔÊÐíÓÉ30¸ö×Ö·û×é³É¡£";
+ Text[ chinese_traditional ] = "µ{¦¡®w¦WºÙ³Ìªø¤£±o¶W¹L30­Ó¦r¤¸¡C";
+ Text[ arabic ] = "íÌÈ ÃáÇ íÒíÏ ÇÓã ÇáãßÊÈÉ Úä 30 ÍÑÝÇð.";
+ Text[ turkish ] = "Kitaplýk adý en fazla 30 karakter uzunluðunda olmalý.";
+};
+String RID_STR_SBXNAMEALLREADYUSED
+{
+ Text = "Name bereits vergeben" ;
+ Text [ English ] = "Name allready used" ;
+ Text [ norwegian ] = "Name allready used" ;
+ Text [ italian ] = "Nome già in uso" ;
+ Text [ portuguese_brazilian ] = "Name allready used" ;
+ Text [ portuguese ] = "Nome já existe." ;
+ Text [ french ] = "Ce nom existe déjà" ;
+ Text [ dutch ] = "Naam bestaat reeds" ;
+ Text [ spanish ] = "El nombre ya existe" ;
+ Text [ danish ] = "Dette navn findes allerede" ;
+ Text [ swedish ] = "Namnet finns redan" ;
+ Text [ finnish ] = "Name allready used" ;
+ Text [ english_us ] = "Name already exists" ;
+ Text[ chinese_simplified ] = "Ãû³ÆÒѾ­±»·ÖÅÉÁË¡£";
+ Text[ russian ] = "Èìÿ óæå ïðèñâîåíî";
+ Text[ polish ] = "Nazwa ju¿ istnieje";
+ Text[ japanese ] = "‚±‚Ì–¼‘O‚Í‚·‚łɎg‚í‚ê‚Ä‚¢‚Ü‚·B";
+ Text[ chinese_traditional ] = "¦WºÙ¤w¸g³Q¤À¬£¤F¡C";
+ Text[ arabic ] = "ÇáÇÓã ãæÌæÏ ãÓÈÞÇð";
+ Text[ dutch ] = "Naam bestaat reeds";
+ Text[ chinese_simplified ] = "Ãû³ÆÒѾ­±»·ÖÅÉÁË¡£";
+ Text[ greek ] = "Ôï üíïìá áõôü õðÜñ÷åé Þäç";
+ Text[ korean ] = "À̸§ÀÌ ÀÌ¹Ì ÀÖÀ½";
+ Text[ turkish ] = "Bu ad mevcut durumda";
+};
+String RID_STR_SBXNAMEALLREADYUSED2
+{
+ Text = "Objekt mit dem Namen existiert schon" ;
+ Text [ English ] = "Object with same name allready exists" ;
+ Text [ norwegian ] = "Object with same name allready exist" ;
+ Text [ italian ] = "Esiste già un oggetto con lo stesso nome" ;
+ Text [ portuguese_brazilian ] = "Object with same name allready exist" ;
+ Text [ portuguese ] = "Já existe objecto com o mesmo nome." ;
+ Text [ french ] = "Un objet ayant le même nom existe déjà" ;
+ Text [ dutch ] = "Er bestaat reeds een object met deze naam." ;
+ Text [ spanish ] = "Ya existe un objeto con el mismo nombre" ;
+ Text [ danish ] = "Der findes allerede et objekt med dette navn" ;
+ Text [ swedish ] = "Objekt med detta namn existerar redan" ;
+ Text [ finnish ] = "Object with same name allready exist" ;
+ Text [ english_us ] = "Object with same name already exists" ;
+ Text[ chinese_simplified ] = "¶ÔÏóÒѾ­´æÔÚ¡£";
+ Text[ russian ] = "Îáúåêò ñ òàêèì èìåíåì óæå ñóùåñòâóåò";
+ Text[ polish ] = "Obiekt z t¹ nazw¹ ju¿ istnieje";
+ Text[ japanese ] = "“¯–¼‚̵ÌÞ¼Þª¸Ä‚ª‚·‚łɂ ‚è‚Ü‚·B";
+ Text[ chinese_traditional ] = "ª«¥ó¤w¸g¦s¦b¡C";
+ Text[ arabic ] = "íæÌÏ ãÓÈÞÇð ßÇÆä áå äÝÓ ÇáÇÓã";
+ Text[ dutch ] = "Er bestaat reeds een object met deze naam.";
+ Text[ chinese_simplified ] = "¶ÔÏóÒѾ­´æÔÚ¡£";
+ Text[ greek ] = "ÕðÜñ÷åé Þäç áíôéêåßìåíï ìå ôï ßäéï üíïìá";
+ Text[ korean ] = "°°Àº À̸§À» °¡Áø °³Ã¼°¡ ÀÌ¹Ì ÀÖÀ½";
+ Text[ turkish ] = "Bu adý taþýyan bir nesne mevcut";
+};
+String RID_STR_FILEEXISTS
+{
+ /* ### ACHTUNG: Neuer Text in Resource? Die Datei 'XX' existiert schon : Die Datei ''XX'' existiert schon */
+ Text = "Die Datei 'XX' existiert schon" ;
+ Text [ English ] = "The file 'XX' allready exists" ;
+ Text [ english_us ] = "The file 'XX' already exists" ;
+ Text [ portuguese_brazilian ] = "Die Datei ''XX'' existiert schon" ;
+ Text [ swedish ] = "Filen 'XX' existerar redan" ;
+ Text [ danish ] = "Filen ''XX'' eksisterer allerede" ;
+ Text [ italian ] = "Il file 'XX' esiste già" ;
+ Text [ spanish ] = "El archivo 'XX' ya existe" ;
+ Text [ french ] = "Le fichier 'XX' existe déjà." ;
+ Text [ dutch ] = "Bestand ''XX' bestaat reeds" ;
+ Text [ portuguese ] = "O ficheiro ''XX'' já existe." ;
+ Text[ chinese_simplified ] = "Îļþ 'XX' ÒѾ­´æÔÚ¡£";
+ Text[ russian ] = "Ôàéë 'XX' óæå ñóùåñòâóåò";
+ Text[ polish ] = "Plik 'XX' ju¿ istnieje";
+ Text[ japanese ] = "̧²Ù'XX'‚Í‚·‚łɑ¶Ý‚µ‚Ä‚¢‚Ü‚·B";
+ Text[ chinese_traditional ] = "ÀÉ®× 'XX' ¤w¸g¦s¦b¡C";
+ Text[ arabic ] = "ãæÌæÏ ãÓÈÞÇð 'XX' ÇáãáÝ";
+ Text[ dutch ] = "Bestand ''XX' bestaat reeds";
+ Text[ chinese_simplified ] = "Îļþ 'XX' ÒѾ­´æÔÚ¡£";
+ Text[ greek ] = "Ôï áñ÷åßï 'XX' õðÜñ÷åé Þäç";
+ Text[ korean ] = "ÆÄÀÏ'XX' Àº ÀÌ¹Ì Á¸ÀçÇÕ´Ï´Ù";
+ Text[ turkish ] = "Dosya 'XX' mevcut durumda";
+};
+String RID_STR_COMPILEERROR
+{
+ /* ### ACHTUNG: Neuer Text in Resource? Übersetzungs-Fehler: : šbersetzungs-Fehler: */
+ Text = "Übersetzungs-Fehler: " ;
+ Text [ ENGLISH ] = "Compile-Error: " ;
+ Text [ norwegian ] = "Compile-Error: " ;
+ Text [ italian ] = "Errore di compilazione: " ;
+ Text [ portuguese_brazilian ] = "Erro-Compilação: " ;
+ Text [ portuguese ] = "Erro de compilação: " ;
+ Text [ finnish ] = "Käännösaikanen virhe: " ;
+ Text [ danish ] = "Kompileringsfejl:" ;
+ Text [ french ] = "Erreur de compilation : " ;
+ Text [ swedish ] = "Kompileringsfel: " ;
+ Text [ dutch ] = "Vertaalfout: " ;
+ Text [ spanish ] = "Error de compilación: " ;
+ Text [ english_us ] = "Compile Error: " ;
+ Text[ chinese_simplified ] = "±àÒë´íÎó£º";
+ Text[ russian ] = "Îøèáêà êîìïèëÿöèè: ";
+ Text[ polish ] = "B³¹d kompilacji: ";
+ Text[ japanese ] = "ºÝÊß²Ù´×°: ";
+ Text[ chinese_traditional ] = "½sĶ¿ù»~:";
+ Text[ arabic ] = ":ÎØÃ Ýí ÇáÊÑÌãÉ";
+ Text[ dutch ] = "Vertaalfout: ";
+ Text[ chinese_simplified ] = "±àÒë´íÎó£º";
+ Text[ greek ] = "ÓöÜëìá ìåôáãëþôôéóçò: ";
+ Text[ korean ] = "¹ø¿ª ¿À·ù: ";
+ Text[ turkish ] = "Derleme hatasý ";
+};
+String RID_STR_RUNTIMEERROR
+{
+ Text = "Laufzeit-Fehler: #" ;
+ Text [ ENGLISH ] = "Runtime-Error: #" ;
+ Text [ norwegian ] = "Runtime-Error: #" ;
+ Text [ italian ] = "Errore di Runtime: #" ;
+ Text [ portuguese_brazilian ] = "Erro-Execução: #" ;
+ Text [ portuguese ] = "Erro de execução: #" ;
+ Text [ finnish ] = "Ajonaikainen virhe: #" ;
+ Text [ danish ] = "Runtimefejl: #" ;
+ Text [ french ] = "Runtime error : #" ;
+ Text [ swedish ] = "Runtime error: #" ;
+ Text [ dutch ] = "Uitvoeringsfout: #" ;
+ Text [ spanish ] = "Error en tiempo de ejecución: #" ;
+ Text [ english_us ] = "Runtime Error: #" ;
+ Text[ chinese_simplified ] = "ÔËÐÐʱ¼ä-´íÎó: #";
+ Text[ russian ] = "Îøèáêà ïðè âûïîëíåíèè: #";
+ Text[ polish ] = "B³¹d czasu przebiegu: #";
+ Text[ japanese ] = "×ÝÀ²Ñ ´×°: #";
+ Text[ chinese_traditional ] = "¹BÂà®É¶¡-¿ù»~: #";
+ Text[ arabic ] = "# :ÎØÃ Ýí æÞÊ ÇáÊÔÛíá";
+ Text[ dutch ] = "Uitvoeringsfout: #";
+ Text[ chinese_simplified ] = "ÔËÐÐʱ¼ä-´íÎó: #";
+ Text[ greek ] = "ÓöÜëìá ÷ñüíïõ åêôÝëåóçò: #";
+ Text[ korean ] = "½ÇÇà½Ã°£ ¿À·ù. #";
+ Text[ turkish ] = "Yürütüm süresi hatasý: #";
+};
+String RID_STR_SEARCHNOTFOUND
+{
+ Text = "Suchbegriff nicht gefunden" ;
+ Text [ ENGLISH ] = "Search pattern not found" ;
+ Text [ norwegian ] = "Search pattern not found" ;
+ Text [ italian ] = "Termine non trovato" ;
+ Text [ portuguese_brazilian ] = "Search pattern not found" ;
+ Text [ portuguese ] = "Impossível encontrar expressão procurada." ;
+ Text [ finnish ] = "Hakumallia ei löydy" ;
+ Text [ danish ] = "Søgningen gav intet resultat" ;
+ Text [ french ] = "Élément recherché introuvable" ;
+ Text [ swedish ] = "Sökord hittades inte" ;
+ Text [ dutch ] = "Het gezochte item is niet gevonden" ;
+ Text [ spanish ] = "No se encontró la expresión buscada" ;
+ Text [ english_us ] = "Search key not found" ;
+ Text[ chinese_simplified ] = "ûÓÐÕÒµ½ÒªËÑѰÄÚÈÝ";
+ Text[ russian ] = "Èñêîìîå ïîíÿòèå íå íàéäåíî";
+ Text[ polish ] = "Szukane has³o nie zosta³o znalezione";
+ Text[ japanese ] = "ŒŸõ€–Ú‚ªŒ©‚‚©‚è‚Ü‚¹‚ñ";
+ Text[ chinese_traditional ] = "¨S¦³§ä¨ì­n´M§äªº¤º®e";
+ Text[ arabic ] = "ÊÚÐÑ ÇáÚ辄 Úáì ÇáÈíÇäÇÊ ÇáÊí ÊÈÍË ÚäåÇ.";
+ Text[ dutch ] = "Het gezochte item is niet gevonden";
+ Text[ chinese_simplified ] = "ûÓÐÕÒµ½ÒªËÑѰÄÚÈÝ";
+ Text[ greek ] = "Äåí âñÝèçêå ç æçôïýìåíç Ýêöñáóç";
+ Text[ korean ] = "°Ë»ö´ë»óÀ» ãÁö ¸øÇßÀ½";
+ Text[ turkish ] = "Aranan terim bulunamadý";
+};
+String RID_STR_SEARCHFROMSTART
+{
+ /* ### ACHTUNG: Neuer Text in Resource? Es wurde bis zum letzten Modul gesucht. Möchten Sie die Suche beim ersten Modul fortsetzen? : Es wurde bis zum letzten Modul gesucht. M÷chten Sie die Suche beim ersten Modul fortsetzen? */
+ Text = "Es wurde bis zum letzten Modul gesucht. Möchten Sie die Suche beim ersten Modul fortsetzen?" ;
+ Text [ ENGLISH ] = "Es wurde bis zum letzten Modul gesucht. Möchten Sie die Suche beim ersten Modul fortsetzen?" ;
+ Text [ english_us ] = "Search to last module complete. Continue at first module?" ;
+ Text [ italian ] = "La ricerca è giunta alla fine dell'ultimo modulo. Continuare con il primo modulo?" ;
+ Text [ spanish ] = "Se buscó hasta el último módulo. ¿Desea continuar la búsqueda en el primer módulo?" ;
+ Text [ french ] = "La recherche a été poursuivie jusqu'au dernier module. Désirez-vous continuer la recherche avec le premier module ?" ;
+ Text [ dutch ] = "Er werd tot aan de laatste module gezocht. Wilt u doorgaan?" ;
+ Text [ swedish ] = "Sökning genomförd till sista modulen. Skall sökningen fortsätta i första modulen?" ;
+ Text [ danish ] = "Der blev søgt til sidste modul. Vil du fortsætte søgningen ved første modul?" ;
+ Text [ portuguese_brazilian ] = "Es wurde bis zum letzten Modul gesucht. Möchten Sie die Suche beim ersten Modul fortsetzen?" ;
+ Text [ portuguese ] = "Procura até ao último módulo. Deseja continuar a procura a partir do primeiro módulo?" ;
+ Text[ chinese_simplified ] = "ÒѾ­ËÑѰÖÁ×îºóÒ»¸öÄ£¿é¡£ÄúÒª´ÓµÚÒ»¸öÄ£¿é¿ªÊ¼ËÑѰÂð£¿";
+ Text[ russian ] = "Ïîèñê áûë îñóùåñòâëåí äî ïîñëåäíåãî ìîäóëÿ. Âû õîòèòå ïðîäîëæèòü ïîèñê ñ ïåðâîãî ìîäóëÿ?";
+ Text[ polish ] = "Przeszukane do ostatniego modu³u. Czy chcesz kontynuowaæ wyszukiwanie przy pierwszym module?";
+ Text[ japanese ] = "ÅŒã‚ÌÓ¼Þ­°Ù‚܂ŌŸõ‚µ‚Ü‚µ‚½B‰‚ß‚ÌÓ¼Þ­°Ù‚É–ß‚Á‚ÄŒŸõ‚𑱂¯‚Ü‚·‚©B";
+ Text[ chinese_traditional ] = "¤w¸g´M§ä¦Ü³Ì«á¤@­Ó¼Ò¶ô¡C±z­n±q²Ä¤@­Ó¼Ò¶ô¶}©l´M§ä¡S";
+ Text[ arabic ] = "Êã ÇáÈÍË ÍÊì ÇáæÍÏÉ ÇáäãØíÉ ÇáÃÎíÑÉ. åá ÊÑíÏ ãæÇÕáÉ ÇáÈÍË ÚäÏ ÇáæÍÏÉ ÇáäãØíÉ ÇáÃæáì.";
+ Text[ dutch ] = "Er werd tot aan de laatste module gezocht. Wilt u doorgaan?";
+ Text[ chinese_simplified ] = "ÒѾ­ËÑѰÖÁ×îºóÒ»¸öÄ£¿é¡£ÄúÒª´ÓµÚÒ»¸öÄ£¿é¿ªÊ¼ËÑѰÂð£¿";
+ Text[ greek ] = "¸÷åé ãßíåé ç áíáæÞôçóç Ýùò ôç ôåëåõôáßá ëåéôïõñãéêÞ ìïíÜäá. ÈÝëåôå íá óõíå÷éóôåß ç áíáæÞôçóç áðü ôç ðñþôç ëåéôïõñãéêÞ ìïíÜäá;";
+ Text[ korean ] = "¸¶Áö¸· ¸ðµâ±îÁö ã¾Ò½À´Ï´Ù. óÀ½ ¸ðµâ¿¡¼­ ã±â¸¦ °è¼ÓÇϽðڽÀ´Ï±î?";
+ Text[ turkish ] = "Son modüle kadar arama tamamlandý? Aramaya ilk modülden devam etmek istiyor musunuz?";
+};
+String RID_STR_SEARCHREPLACES
+{
+ Text = "Suchbegriff XXmal ersetzt" ;
+ Text [ ENGLISH ] = "Search pattern replaced XX times" ;
+ Text [ norwegian ] = "Search pattern replaced XX times" ;
+ Text [ italian ] = "Termine sostituito XX volte" ;
+ Text [ portuguese_brazilian ] = "Search pattern replaced XX times" ;
+ Text [ portuguese ] = "Expressão procurada substituída XX vezes" ;
+ Text [ finnish ] = "Hakumalli on korvattu XX kertaa" ;
+ Text [ danish ] = "Søgeord erstattet XX gange" ;
+ Text [ french ] = "L'élément recherché a été remplacé XX fois" ;
+ Text [ swedish ] = "Sökord ersatt XX gånger" ;
+ Text [ dutch ] = "Het gezochte item is XX keer vervangen" ;
+ Text [ spanish ] = "Expresión buscada reemplazada XX veces" ;
+ Text [ english_us ] = "Search key replaced XX times" ;
+ Text[ chinese_simplified ] = "¸üÌæËÑѰÄÚÈÝ XX ´Î";
+ Text[ russian ] = "Èñêîìîå ïîíÿòèå çàìåíåíî XXðàç";
+ Text[ polish ] = "Szukane has³o zast¹piono XXrazy";
+ Text[ japanese ] = "ŒŸõ€–Ú‚ðXX“x’u‚«Š·‚¦‚Ü‚µ‚½";
+ Text[ chinese_traditional ] = "¥N´À´M§ä¤º®e XX ¦¸";
+ Text[ arabic ] = "Êã ÇÓÊÈÏÇá ÈíÇäÇÊ ÇáÈÍË ××× ãÑÉ";
+ Text[ dutch ] = "Het gezochte item is XX keer vervangen";
+ Text[ chinese_simplified ] = "¸üÌæËÑѰÄÚÈÝ XX ´Î";
+ Text[ greek ] = "¸ãéíå XX öïñÝò áíôéêáôÜóôáóç ôçò æçôïýìåíçò Ýêöñáóçò";
+ Text[ korean ] = "°Ë»ö´ë»óÀ» XX¹ø ¹Ù²Þ";
+ Text[ turkish ] = "Aranan terim XX kez deðiþtirildi";
+};
+String RID_STR_COULDNTREAD
+{
+ Text = "Die Datei konnte nicht gelesen werden" ;
+ Text [ ENGLISH ] = "The document cannot be red" ;
+ Text [ dutch ] = "Het bestand kon niet worden gelezen." ;
+ Text [ english_us ] = "The file could not be read" ;
+ Text [ italian ] = "Non è stato possibile leggere il file" ;
+ Text [ spanish ] = "No se pudo leer el archivo" ;
+ Text [ french ] = "Impossible de lire le fichier" ;
+ Text [ swedish ] = "Filen kunde inte läsas" ;
+ Text [ danish ] = "Det var ikke muligt at læse filen" ;
+ Text [ portuguese_brazilian ] = "Die Datei konnte nicht gelesen werden" ;
+ Text [ portuguese ] = "Foi impossível ler o ficheiro." ;
+ Text[ chinese_simplified ] = "ÎÞ·¨¶ÁÈ¡Îļþ¡£";
+ Text[ russian ] = "Ïðî÷èòàòü ôàéë íå óäàåòñÿ";
+ Text[ polish ] = "Pliku nie mo¿na by³o odczytaæ";
+ Text[ japanese ] = "̧²Ù‚ª“ǂݎæ‚ê‚Ü‚¹‚ñB";
+ Text[ chinese_traditional ] = "µLªkŪ¨úÀɮסC";
+ Text[ arabic ] = "ÊÚÐÑ ÞÑÇÁÉ ÇáãáÝ";
+ Text[ dutch ] = "Het bestand kon niet worden gelezen.";
+ Text[ chinese_simplified ] = "ÎÞ·¨¶ÁÈ¡Îļþ¡£";
+ Text[ greek ] = "Äåí Þôáí äõíáôüí íá ãßíåé áíÜãíùóç ôïõ áñ÷åßïõ";
+ Text[ korean ] = "ÆÄÀÏÀ» ÀÐÁö ¸øÇß½À´Ï´Ù";
+ Text[ turkish ] = "Dosya okunamadý";
+};
+String RID_STR_COULDNTWRITE
+{
+ Text = "Die Datei konnte nicht gespeichert werden" ;
+ Text [ ENGLISH ] = "The document cannot be written" ;
+ Text [ english_us ] = "The file could not be saved" ;
+ Text [ italian ] = "Non è stato possibile salvare il file" ;
+ Text [ spanish ] = "No se pudo guardar el archivo" ;
+ Text [ french ] = "Impossible de sauvegarder le fichier" ;
+ Text [ dutch ] = "Het bestand kon niet worden opgeslagen." ;
+ Text [ swedish ] = "Filen kunde inte sparas" ;
+ Text [ danish ] = "Det var ikke muligt at gemme filen" ;
+ Text [ portuguese_brazilian ] = "Die Datei konnte nicht gespeichert werden" ;
+ Text [ portuguese ] = "Foi impossível guardar o ficheiro." ;
+ Text[ chinese_simplified ] = "ÎÞ·¨´æÅÌÎļþ¡£";
+ Text[ russian ] = "Ñîõðàíèòü ôàéë íå óäàåòñÿ";
+ Text[ polish ] = "Pliku nie mo¿na by³o zapisaæ";
+ Text[ japanese ] = "̧²Ù‚ª•Û‘¶‚Å‚«‚Ü‚¹‚ñB";
+ Text[ chinese_traditional ] = "µLªkÀx¦sÀɮסC";
+ Text[ arabic ] = "ÊÚÐÑ ÍÝÙ ÇáãáÝ";
+ Text[ dutch ] = "Het bestand kon niet worden opgeslagen.";
+ Text[ chinese_simplified ] = "ÎÞ·¨´æÅÌÎļþ¡£";
+ Text[ greek ] = "Äåí Þôáí äõíáôÞ ç áðïèÞêåõóç ôïõ áñ÷åßïõ";
+ Text[ korean ] = "ÆÄÀÏÀ» ÀúÀåÇÏÁö ¸øÇß½À´Ï´Ù";
+ Text[ turkish ] = "Dosya kaydedilemedi";
+};
+String RID_STR_CANNOTCHANGENAMESTDLIB
+{
+ /* ### ACHTUNG: Neuer Text in Resource? Der Name der Standard-Bibliothek kann nicht geändert werden : Der Name der Standard-Bibliothek kann nicht geõndert werden */
+ Text = "Der Name der Standard-Bibliothek kann nicht geändert werden" ;
+ Text [ ENGLISH ] = "Cannot change name from standard libary" ;
+ Text [ dutch ] = "De naam van de standaardbibliotheek kan niet veranderd worden." ;
+ Text [ english_us ] = "The name of a standard library cannot be changed." ;
+ Text [ italian ] = "Il nome della library standard non può essere modificato" ;
+ Text [ spanish ] = "No se puede modificar el nombre de la biblioteca estándar" ;
+ Text [ french ] = "Impossible de modifier le nom de la bibliothèque par défaut." ;
+ Text [ swedish ] = "Standardbibliotekets namn kan inte ändras" ;
+ Text [ danish ] = "Standardmappens navn kan ikke ændres" ;
+ Text [ portuguese_brazilian ] = "Der Name der Standard-Bibliothek kann nicht geändert werden" ;
+ Text [ portuguese ] = "O nome da biblioteca-padrão não pode ser alterado." ;
+ Text[ chinese_simplified ] = "ÎÞ·¨¸ü¸Ä±ê×¼-¿âµÄÃû³Æ¡£";
+ Text[ russian ] = "Èçìåíèòü èìÿ ñòàíäàðòíîé áèáëèîòåêè íåâîçìîæíî";
+ Text[ polish ] = "Nazwa biblioteki standardowej nie mo¿e zostaæ zmieniona";
+ Text[ japanese ] = "•W€×²ÌÞר–¼‚Í•ÏXo—ˆ‚Ü‚¹‚ñB";
+ Text[ chinese_traditional ] = "µLªkÅܧó¼Ð·Çµ{¦¡®wªº¦WºÙ¡C";
+ Text[ arabic ] = "áÇ íãßä ÊÛííÑ ÇÓã ÇáãßÊÈÉ ÇáÇÝÊÑÇÖíÉ";
+ Text[ dutch ] = "De naam van de standaardbibliotheek kan niet veranderd worden.";
+ Text[ chinese_simplified ] = "ÎÞ·¨¸ü¸Ä±ê×¼-¿âµÄÃû³Æ¡£";
+ Text[ greek ] = "Äåí åßíáé äõíáôüí íá ãßíåé áëëáãÞ ôïõ ïíüìáôïò ôçò âáóéêÞò âéâëéïèÞêçò.";
+ Text[ korean ] = "±âº» ¶óÀ̺귯¸®ÀÇ À̸§Àº ¹Ù²Ü ¼ö ¾ø½À´Ï´Ù.";
+ Text[ turkish ] = "Standart kitaplýðýn adý deðiþtirilemez.";
+};
+String RID_STR_CANNOTCHANGENAMEREFLIB
+{
+ /* ### ACHTUNG: Neuer Text in Resource? Der Name einer referenzierten Bibliothek kann nicht geändert werden : Der Name einer referenzierten Bibliothek kann nicht geõndert werden */
+ Text = "Der Name einer referenzierten Bibliothek kann nicht geändert werden" ;
+ Text [ ENGLISH ] = "Cannot change name from referenced libary" ;
+ Text [ dutch ] = "De naam van een bibliotheek met een verwijzing kan niet worden veranderd." ;
+ Text [ english_us ] = "The name of a referenced library cannot be changed." ;
+ Text [ italian ] = "Il nome di una library alla quale si fa riferimento non può essere cambiato" ;
+ Text [ spanish ] = "No se puede modificar el nombre de una biblioteca referenciada" ;
+ Text [ french ] = "Impossible de modifier le nom d'une bibliothèque de référence" ;
+ Text [ swedish ] = "Namnet på ett referensbibliotek kan ändras" ;
+ Text [ danish ] = "Et referencebiblioteks navn kan ikke ændres" ;
+ Text [ portuguese_brazilian ] = "Der Name einer referenzierten Bibliothek kann nicht geändert werden" ;
+ Text [ portuguese ] = "Não se pode alterar o nome de uma biblioteca de referência." ;
+ Text[ chinese_simplified ] = "ÎÞ·¨¸ü¸ÄÒýÓÿâµÄÃû³Æ¡£";
+ Text[ russian ] = "Èìÿ ññûëàåìîé áèáëèîòåêè èçìåíèòü íåâîçìîæíî.";
+ Text[ polish ] = "Nazwa biblioteki, do której siê odwo³ano, nie istnieje.";
+ Text[ japanese ] = "ŽQÆæ‚ÌײÌÞר–¼‚Í•ÏXo—ˆ‚Ü‚¹‚ñB";
+ Text[ chinese_traditional ] = "µLªkÅܧó°Ñ·Óµ{¦¡®wªº¦WºÙ¡C";
+ Text[ arabic ] = ".áÇ íãßä ÊÛííÑ ÇÓã ãßÊÈÉ ãÑÌÚíÉ";
+ Text[ dutch ] = "De naam van een bibliotheek met een verwijzing kan niet worden veranderd.";
+ Text[ chinese_simplified ] = "ÎÞ·¨¸ü¸ÄÒýÓÿâµÄÃû³Æ¡£";
+ Text[ greek ] = "Äåí åßíáé äõíáôüí íá áëëá÷èåß ôï üíïìá ìéáò âéâëéïèÞêçò ç ïðïßá åßíáé ðñïïñéóìüò êÜðïéáò áíáöïñÜò";
+ Text[ korean ] = "ÂüÁ¶µÈ ¶óÀ̺귯¸®ÀÇ À̸§Àº ¹Ù²Ü ¼ö ¾ø½À´Ï´Ù.";
+ Text[ turkish ] = "Referans alýnan bir kitaplýðýn adý deðiþtirilemez.";
+};
+String RID_STR_CANNOTUNLOADSTDLIB
+{
+ Text = "Die Standard-Bibliothek kann nicht deaktiviert werden" ;
+ Text [ ENGLISH ] = "The standard libary cannot be deactivated" ;
+ Text [ english_us ] = "The standard library cannot be deactivated" ;
+ Text [ italian ] = "La library standard non può essere disattivata" ;
+ Text [ spanish ] = "No se puede desactivar la biblioteca estándar" ;
+ Text [ french ] = "Impossible de désactiver la bibliothèque par défaut." ;
+ Text [ dutch ] = "De standaardbibliotheek kan niet worden gedeactiveerd." ;
+ Text [ swedish ] = "Standardbiblioteket kan inte deaktiveras" ;
+ Text [ danish ] = "Standardmappen kan ikke deaktiveres" ;
+ Text [ portuguese_brazilian ] = "Die Standard-Bibliothek kann nicht deaktiviert werden" ;
+ Text [ portuguese ] = "A biblioteca-padrão não pode ser desactivada." ;
+ Text[ chinese_simplified ] = "ÎÞ·¨Ê§»î±ê×¼¿â";
+ Text[ russian ] = "Äåàêòèâèðîâàòü ñòàíäàðòíóþ áèáëèîòåêó íåâîçìîæíî";
+ Text[ polish ] = "Standardowej biblioteki nie mo¿na by³o zdeaktywowaæ.";
+ Text[ japanese ] = "•W€×²ÌÞר‚ð”ñ±¸Ã¨ÌÞ‚Éo—ˆ‚Ü‚¹‚ñ";
+ Text[ chinese_traditional ] = "µLªk¥¢¬¡¼Ð·Çµ{¦¡®w";
+ Text[ arabic ] = "áÇ íãßä ÅáÛÇÁ ÊäÔíØ ÇáãßÊÈÉ ÇáÇÝÊÑÇÖíÉ";
+ Text[ dutch ] = "De standaardbibliotheek kan niet worden gedeactiveerd.";
+ Text[ chinese_simplified ] = "ÎÞ·¨Ê§»î±ê×¼¿â";
+ Text[ greek ] = "Äåí åßíáé äõíáôüí íá ãßíåé áðåíåñãïðïßçóç ôçò âáóéêÞò âéâëéïèÞêçò";
+ Text[ korean ] = "±âº» ¶óÀ̺귯¸®´Â ½ÇÇàÀ» ÁߴܽÃų ¼ö ¾ø½À´Ï´Ù.";
+ Text[ turkish ] = "Standart kitaplýðýn etkinliði kaldýrýlýmaz.";
+};
+String RID_STR_GENERATESOURCE
+{
+ Text = "Erzeuge Quelltext" ;
+ Text [ ENGLISH ] = "Generating source" ;
+ Text [ english_us ] = "Generating source" ;
+ Text [ italian ] = "Creazione del testo sorgente" ;
+ Text [ spanish ] = "Creando un texto fuente" ;
+ Text [ french ] = "Crée texte source" ;
+ Text [ dutch ] = "Brontekst maken" ;
+ Text [ swedish ] = "Skapa källtext" ;
+ Text [ danish ] = "Opret kildetekst" ;
+ Text [ portuguese_brazilian ] = "Erzeuge Quelltext" ;
+ Text [ portuguese ] = "A criar texto-fonte" ;
+ Text[ chinese_simplified ] = "Éú³ÉÔ´Îı¾";
+ Text[ russian ] = "Ñîçäàòü èñõîäíûé òåêñò";
+ Text[ polish ] = "Utwórz tekst Ÿród³owy";
+ Text[ japanese ] = "¿°½‚Ìì¬";
+ Text[ chinese_traditional ] = "¥Í¦¨­ì©lÀÉ";
+ Text[ arabic ] = "ÅäÔÇÁ äÕ ãÕÏÑ";
+ Text[ dutch ] = "Brontekst maken";
+ Text[ chinese_simplified ] = "Éú³ÉÔ´Îı¾";
+ Text[ greek ] = "Äçìéïõñãßá êåéìÝíïõ ðñïÝëåõóçò";
+ Text[ korean ] = "¼Ò½º »ý¼º Áß";
+ Text[ turkish ] = "Kaynak kod oluþturuluyor";
+};
+String RID_STR_FILENAME
+{
+ Text = "Dateiname: " ;
+ Text [ ENGLISH ] = "File name: " ;
+ Text [ dutch ] = "Bestandsnaam: " ;
+ Text [ english_us ] = "File name:" ;
+ Text [ italian ] = "Nome file: " ;
+ Text [ spanish ] = "Nom. del archivo: " ;
+ Text [ french ] = "Nom de fichier : " ;
+ Text [ swedish ] = "Filnamn: " ;
+ Text [ danish ] = "Filnavn:" ;
+ Text [ portuguese_brazilian ] = "Dateiname: " ;
+ Text [ portuguese ] = "Nome do ficheiro: " ;
+ Text[ chinese_simplified ] = "ÎļþÃû£º";
+ Text[ russian ] = "Èìÿ ôàéëà: ";
+ Text[ polish ] = "Nazwa pliku: ";
+ Text[ japanese ] = "̧²Ù–¼:";
+ Text[ chinese_traditional ] = "ÀɮצW:";
+ Text[ arabic ] = ":ÇÓã ÇáãáÝ";
+ Text[ dutch ] = "Bestandsnaam: ";
+ Text[ chinese_simplified ] = "ÎļþÃû£º";
+ Text[ greek ] = "¼íïìá áñ÷åßïõ: ";
+ Text[ korean ] = "ÆÄÀϸí: ";
+ Text[ turkish ] = "Dosya adý: ";
+};
+String RID_STR_APPENDLIBS
+{
+ /* ### ACHTUNG: Neuer Text in Resource? Bibliotheken hinzufügen : Bibliotheken hinzuf³gen */
+ Text = "Bibliotheken hinzufügen" ;
+ Text [ ENGLISH ] = "Append libaries" ;
+ Text [ english_us ] = "Append Libraries" ;
+ Text [ italian ] = "Aggiungi biblioteche" ;
+ Text [ spanish ] = "Añadir bibliotecas" ;
+ Text [ french ] = "Ajouter des bibliothèques" ;
+ Text [ dutch ] = "Bibliotheken toevoegen" ;
+ Text [ swedish ] = "Lägg till bibliotek" ;
+ Text [ danish ] = "Tilføj biblioteker" ;
+ Text [ portuguese_brazilian ] = "Bibliotheken hinzufügen" ;
+ Text [ portuguese ] = "Inserir bibliotecas" ;
+ Text[ chinese_simplified ] = "ÐÂÔö¿â";
+ Text[ russian ] = "Äîáàâèòü áèáëèîòåêè";
+ Text[ polish ] = "Dodaj biblioteki";
+ Text[ japanese ] = "ײÌÞר‚̒ljÁ";
+ Text[ chinese_traditional ] = "·s¼Wµ{¦¡®w";
+ Text[ arabic ] = "ÅáÍÇÞ ãßÊÈÇÊ";
+ Text[ dutch ] = "Bibliotheken toevoegen";
+ Text[ chinese_simplified ] = "ÐÂÔö¿â";
+ Text[ greek ] = "Ðñïóêüëëçóç âéâëéïèçêþí";
+ Text[ korean ] = "¶óÀ̺귯¸® Ãß°¡";
+ Text[ turkish ] = "Kitaplýk ekle";
+};
+String RID_STR_QUERYDELMACRO
+{
+ /* ### ACHTUNG: Neuer Text in Resource? Möchten Sie das Makro XX löschen ? : M÷chten Sie das Makro XX l÷schen ? */
+ Text = "Möchten Sie das Makro XX löschen ?" ;
+ Text [ ENGLISH ] = "Do you want to delete the macro XX ?" ;
+ Text [ english_us ] = "Do you want to delete the macro XX ?" ;
+ Text [ italian ] = "Eliminare la macro XX ?" ;
+ Text [ spanish ] = "¿Desea eliminar la macro XX?" ;
+ Text [ french ] = "Voulez-vous supprimer la macro XX ?" ;
+ Text [ dutch ] = "Wilt u de macro XX wissen?" ;
+ Text [ swedish ] = "Vill Du radera makro XX ?" ;
+ Text [ danish ] = "Vil du slette makroen XX ?" ;
+ Text [ portuguese_brazilian ] = "Möchten Sie das Makro XX löschen ?" ;
+ Text [ portuguese ] = "Deseja eliminar a macro XX ?" ;
+ Text[ chinese_simplified ] = "ÄúҪɾ³ýºê XX £¿";
+ Text[ russian ] = "Âû õîòèòå óäàëèòü ìàêðîñ XX ?";
+ Text[ polish ] = "Chcesz usun¹æ makro XX?";
+ Text[ japanese ] = "ϸÛXX‚ð휂µ‚Ü‚·‚©?";
+ Text[ chinese_traditional ] = "±z­n§R°£¥¨¶° XX ¡S";
+ Text[ arabic ] = "¿ XX åá ÊÑíÏ ÍÐÝ ÇáãÇßÑæ";
+ Text[ dutch ] = "Wilt u de macro XX wissen?";
+ Text[ chinese_simplified ] = "ÄúҪɾ³ýºê XX £¿";
+ Text[ greek ] = "ÈÝëåôå íá äéáãñáöåß ç ìáêñïåíôïëÞ ×× ;";
+ Text[ korean ] = "¸ÅÅ©·ÎXX¸¦ »èÁ¦ÇϽðڽÀ´Ï±î?";
+ Text[ turkish ] = "XX makrosunu silmek istiyor musunuz?";
+};
+String RID_STR_QUERYDELDIALOG
+{
+ /* ### ACHTUNG: Neuer Text in Resource? Möchten Sie den Dialog XX löschen ? : M÷chten Sie den Dialog XX l÷schen ? */
+ Text = "Möchten Sie den Dialog XX löschen ?" ;
+ Text [ ENGLISH ] = "Do you want to delete the dialog XX ?" ;
+ Text [ dutch ] = "Wilt u de dialoog XX wissen?" ;
+ Text [ english_us ] = "Do you want to delete the dialog XX ?" ;
+ Text [ italian ] = "Cancellare il dialogo XX" ;
+ Text [ spanish ] = "¿Desea eliminar el diálogo XX?" ;
+ Text [ french ] = "Supprimer la boîte de dialogue XX ?" ;
+ Text [ swedish ] = "Vill Du radera dialogen XX?" ;
+ Text [ danish ] = "Vil du slette dialogen XX ?" ;
+ Text [ portuguese_brazilian ] = "Möchten Sie den Dialog XX löschen ?" ;
+ Text [ portuguese ] = "Deseja eliminar o diálogo XX ?" ;
+ Text[ chinese_simplified ] = "ÄúҪɾ³ý¶Ô»° XX £¿";
+ Text[ russian ] = "Âû õîòèòå óäàëèòü äèàëîã XX ?";
+ Text[ polish ] = "Chcesz usun¹æ dialog XX?";
+ Text[ japanese ] = "ÀÞ²±Û¸ÞXX‚ð휂µ‚Ü‚·‚©?";
+ Text[ chinese_traditional ] = "±z­n§R°£¹ï¸Ü XX ¡S";
+ Text[ arabic ] = "¿ XX åá ÊÑíÏ ÍÐÝ ãÑÈÚ ÇáÍæÇÑ";
+ Text[ dutch ] = "Wilt u de dialoog XX wissen?";
+ Text[ chinese_simplified ] = "ÄúҪɾ³ý¶Ô»° XX £¿";
+ Text[ greek ] = "ÈÝëåôå íá äéáãñáöåß ï äéÜëïãïò ××;";
+ Text[ korean ] = "´ëÈ­»óÀÚXX¸¦ »èÁ¦ÇϽðڽÀ´Ï±î?";
+ Text[ turkish ] = "XX diyaloðunu silmek istiyor musunuz?";
+};
+String RID_STR_QUERYDELLIB
+{
+ /* ### ACHTUNG: Neuer Text in Resource? Möchten Sie die Bibliothek XX löschen ? : M÷chten Sie die Bibliothek XX l÷schen ? */
+ Text = "Möchten Sie die Bibliothek XX löschen ?" ;
+ Text [ ENGLISH ] = "Do you want to delete the libary XX" ;
+ Text [ english_us ] = "Do you want to delete the library XX ?" ;
+ Text [ italian ] = "Eliminare la library XX ?" ;
+ Text [ spanish ] = "¿Desea eliminar la biblioteca XX?" ;
+ Text [ french ] = "Voulez-vous supprimer la bibliothèque XX ?" ;
+ Text [ dutch ] = "Wilt u de bibliotheek XX wissen?" ;
+ Text [ swedish ] = "Vill Du radera biblioteket XX ?" ;
+ Text [ danish ] = "Vil du slette biblioteket XX ?" ;
+ Text [ portuguese_brazilian ] = "Möchten Sie die Bibliothek XX löschen ?" ;
+ Text [ portuguese ] = "Deseja eliminar a biblioteca XX ?" ;
+ Text[ chinese_simplified ] = "ÄúҪɾ³ý¿â XX £¿";
+ Text[ russian ] = "Âû õîòèòå óäàëèòü äèàëîã XX ?";
+ Text[ polish ] = "Chcesz usun¹æ bibliotekê XX?";
+ Text[ japanese ] = "ײÌÞרXX‚ð휂µ‚Ü‚·‚©?";
+ Text[ chinese_traditional ] = "±z­n§R°£µ{¦¡®w XX ¡S";
+ Text[ arabic ] = "¿ XX åá ÊÑíÏ ÍÐÝ ÇáãßÊÈÉ";
+ Text[ dutch ] = "Wilt u de bibliotheek XX wissen?";
+ Text[ chinese_simplified ] = "ÄúҪɾ³ý¿â XX £¿";
+ Text[ greek ] = "ÈÝëåôå íá äéáãñáöåß ç âéâëéïèÞêç ××;";
+ Text[ korean ] = "¶óÀ̺귯¸®XX¸¦ »èÁ¦ÇϽðڽÀ´Ï±î ?";
+ Text[ turkish ] = "XX kitaplýðýný silmek istiyor musunuz?";
+};
+String RID_STR_QUERYDELLIBREF
+{
+ /* ### ACHTUNG: Neuer Text in Resource? Möchten Sie die Referenz auf die Bibliothek XX löschen ? : M÷chten Sie die Referenz auf die Bibliothek XX l÷schen ? */
+ Text = "Möchten Sie die Referenz auf die Bibliothek XX löschen ?" ;
+ Text [ ENGLISH ] = "Do you want to delete the reference to the libary XX ?" ;
+ Text [ english_us ] = "Do you want to delete the reference to the library XX ?" ;
+ Text [ italian ] = "Cancellare il riferimento alla library XX ?" ;
+ Text [ spanish ] = "¿Desea eliminar la referencia a la biblioteca XX?" ;
+ Text [ french ] = "Voulez-vous supprimer la référence à la bibliothèque XX ?" ;
+ Text [ dutch ] = "Wilt u de verwijzing naar de bibliotheek XX wissen?" ;
+ Text [ swedish ] = "Vill Du radera referensen till biblioteket XX ?" ;
+ Text [ danish ] = "Vil du slette referencen til biblioteket XX ?" ;
+ Text [ portuguese_brazilian ] = "Möchten Sie die Referenz auf die Bibliothek XX löschen ?" ;
+ Text [ portuguese ] = "Deseja eliminar a referência à biblioteca XX ?" ;
+ Text[ chinese_simplified ] = "ÄúҪɾ³ý¿â XX µÄÒýÓã¿";
+ Text[ russian ] = "Âû õîòèòå óäàëèòü ññûëêè íà áèáëèîòåêó XX ?";
+ Text[ polish ] = "Czy chcesz usun¹æ odwo³anie do bibliotekiXX?";
+ Text[ japanese ] = "ײÌÞרXX‚ÌŽQÆæ‚ð휂µ‚Ü‚·‚©?";
+ Text[ chinese_traditional ] = "±z­n§R°£µ{¦¡®w XX ªº°Ñ·Ó¡S";
+ Text[ arabic ] = "¿ XX åá ÊÑíÏ ÍÐÝ ÇáãÑÌÚ Åáì ÇáãßÊÈÉ";
+ Text[ dutch ] = "Wilt u de verwijzing naar de bibliotheek XX wissen?";
+ Text[ chinese_simplified ] = "ÄúҪɾ³ý¿â XX µÄÒýÓã¿";
+ Text[ greek ] = "ÈÝëåôå íá äéáãñáöåß ç áíáöïñÜ ðïõ ãßíåôáé ðñïò ôç âéâëéïèÞêç ×× ;";
+ Text[ korean ] = "¶óÀ̺귯¸®XX¿¡ ÀÖ´Â ÂüÁ¶¸¦ »èÁ¦ÇϽðڽÀ´Ï±î?";
+ Text[ turkish ] = "XX kitaplýðýna iliþkin referansý silmek istiyor musunuz?";
+};
+String RID_STR_QUERYDELMODULE
+{
+ /* ### ACHTUNG: Neuer Text in Resource? Möchten Sie das Modul XX löschen ? : M÷chten Sie das Modul XX l÷schen ? */
+ Text = "Möchten Sie das Modul XX löschen ?" ;
+ Text [ ENGLISH ] = "Do you want to delete the module XX ?" ;
+ Text [ english_us ] = "Do you want to delete the module XX ?" ;
+ Text [ italian ] = "Cancellare il modulo XX ?" ;
+ Text [ spanish ] = "¿Desea eliminar el módulo XX?" ;
+ Text [ french ] = "Voulez-vous supprimer le module XX ?" ;
+ Text [ dutch ] = "Wilt u de module XX wissen?" ;
+ Text [ swedish ] = "Vill Du radera modulen XX ?" ;
+ Text [ danish ] = "Vil du slette modulet XX ?" ;
+ Text [ portuguese_brazilian ] = "Möchten Sie das Modul XX löschen ?" ;
+ Text [ portuguese ] = "Deseja eliminar o módulo XX ?" ;
+ Text[ chinese_simplified ] = "ÄúҪɾ³ýÄ£¿é XX £¿";
+ Text[ russian ] = "Âû õîòèòå óäàëèòü ìîäóëü XX ?";
+ Text[ polish ] = "Chcesz usun¹æ modu³ XX?";
+ Text[ japanese ] = "Ó¼Þ­°ÙXX‚ð휂µ‚Ü‚·‚©?";
+ Text[ chinese_traditional ] = "±z­n§R°£¼Ò¶ô XX ¡S";
+ Text[ arabic ] = "¿ XX åá ÊÑíÏ ÍÐÝ ÇáæÍÏÉ ÇáäãØíÉ";
+ Text[ dutch ] = "Wilt u de module XX wissen?";
+ Text[ chinese_simplified ] = "ÄúҪɾ³ýÄ£¿é XX £¿";
+ Text[ greek ] = "ÈÝëåôå íá äéáãñáöåß ç ëåéôïõñãéêÞ ìïíÜäá XX ;";
+ Text[ korean ] = "¸ðµâXXÀ» »èÁ¦ÇϽðڽÀ´Ï±î ?";
+ Text[ turkish ] = "XX modülünü silmek istiyor musunuz?";
+};
+String RID_STR_OBJNOTFOUND
+{
+ Text = "Objekt oder Methode nicht gefunden" ;
+ Text [ ENGLISH ] = "Object or method not found" ;
+ Text [ dutch ] = "Object of methode niet gevonden." ;
+ Text [ english_us ] = "Object or method not found" ;
+ Text [ italian ] = "Oggetto o metodo non trovato" ;
+ Text [ spanish ] = "No se ha encontrado el objeto o método" ;
+ Text [ french ] = "Objet ou méthode introuvables" ;
+ Text [ swedish ] = "Objekt eller metod hittades inte" ;
+ Text [ danish ] = "Objekt eller metode blev ikke fundet" ;
+ Text [ portuguese_brazilian ] = "Objekt oder Methode nicht gefunden" ;
+ Text [ portuguese ] = "Impossível encontrar objecto ou método." ;
+ Text[ chinese_simplified ] = "ûÓÐÕÒµ½¶ÔÏó»ò·½·¨¡£";
+ Text[ russian ] = "Îáúåêò èëè ìåòîä íå íàéäåí";
+ Text[ polish ] = "Obiektu lub metody nie znaleziono";
+ Text[ japanese ] = "µÌÞ¼Þª¸Ä‚Ü‚½‚Í•û–@‚ªŒ©‚‚©‚è‚Ü‚¹‚ñB";
+ Text[ chinese_traditional ] = "¨S¦³§ä¨ìª«¥ó©Î¤èªk¡C";
+ Text[ arabic ] = "ÊÚÐÑ ÇáÚ辄 Úáì ÇáßÇÆä Ãæ ÇáÃÓáæÈ";
+ Text[ dutch ] = "Object of methode niet gevonden.";
+ Text[ chinese_simplified ] = "ûÓÐÕÒµ½¶ÔÏó»ò·½·¨¡£";
+ Text[ greek ] = "Äåí âñÝèçêå ôï áíôéêåßìåíï Þ ç ìÝèïäïò";
+ Text[ korean ] = "°³Ã¼³ª ¸Å¼­µå¸¦ ãÁö ¸øÇßÀ½";
+ Text[ turkish ] = "Nesne ya da yöntem bulunamadý";
+};
+String RID_STR_BASIC
+{
+ Text = "BASIC" ;
+ Text [ ENGLISH ] = "BASIC" ;
+ Text [ dutch ] = "BASIC" ;
+ Text [ english_us ] = "BASIC" ;
+ Text [ italian ] = "BASIC" ;
+ Text [ spanish ] = "BASIC" ;
+ Text [ french ] = "BASIC" ;
+ Text [ swedish ] = "BASIC" ;
+ Text [ danish ] = "BASIC" ;
+ Text [ portuguese_brazilian ] = "BASIC" ;
+ Text [ portuguese ] = "BASIC" ;
+ Text[ chinese_simplified ] = "BASIC";
+ Text[ russian ] = "BASIC";
+ Text[ polish ] = "BASIC";
+ Text[ japanese ] = "BASIC";
+ Text[ chinese_traditional ] = "BASIC";
+ Text[ arabic ] = "BASIC";
+ Text[ dutch ] = "BASIC";
+ Text[ chinese_simplified ] = "BASIC";
+ Text[ greek ] = "BASIC";
+ Text[ korean ] = "BASIC";
+ Text[ turkish ] = "BASIC";
+};
+String RID_STR_LINE
+{
+ // Abkuerzung fuer 'Zeile'
+ Text = "Zl" ;
+ Text [ ENGLISH ] = "Ln" ;
+ Text [ english_us ] = "Ln" ;
+ Text [ italian ] = "Ln" ;
+ Text [ spanish ] = "Li" ;
+ Text [ french ] = "Li" ;
+ Text [ dutch ] = "Rg" ;
+ Text [ swedish ] = "Ln" ;
+ Text [ danish ] = "Rk" ;
+ Text [ portuguese_brazilian ] = "Zl" ;
+ Text [ portuguese ] = "Li" ;
+ Text[ chinese_simplified ] = "ÐÐ";
+ Text[ russian ] = "Ñò";
+ Text[ polish ] = "Wiersz";
+ Text[ japanese ] = "ü";
+ Text[ chinese_traditional ] = "¦æ";
+ Text[ arabic ] = "ÕÝ";
+ Text[ dutch ] = "Rg";
+ Text[ chinese_simplified ] = "ÐÐ";
+ Text[ greek ] = "Ãñì";
+ Text[ korean ] = "ÁÙ";
+ Text[ turkish ] = "Sa.";
+};
+String RID_STR_COLUMN
+{
+ // Abkuerzung fuer 'Spalte'
+ Text = "Sp" ;
+ Text [ ENGLISH ] = "Col" ;
+ Text [ dutch ] = "Kolom" ;
+ Text [ english_us ] = "Col" ;
+ Text [ italian ] = "Col" ;
+ Text [ spanish ] = "Col" ;
+ Text [ french ] = "Col" ;
+ Text [ swedish ] = "Kol" ;
+ Text [ danish ] = "Kol" ;
+ Text [ portuguese_brazilian ] = "Sp" ;
+ Text [ portuguese ] = "Col" ;
+ Text[ chinese_simplified ] = "ÁÐ";
+ Text[ russian ] = "Êîë";
+ Text[ polish ] = "Kol";
+ Text[ japanese ] = "—ñ";
+ Text[ chinese_traditional ] = "Äæ";
+ Text[ arabic ] = "ÚãæÏ";
+ Text[ dutch ] = "Kolom";
+ Text[ chinese_simplified ] = "ÁÐ";
+ Text[ greek ] = "Óôë";
+ Text[ korean ] = "¿­";
+ Text[ turkish ] = "Sü.";
+};
+String RID_STR_DOC
+{
+ Text = "Dokument" ;
+ Text [ ENGLISH ] = "Document" ;
+ Text [ english_us ] = "Document" ;
+ Text [ italian ] = "Documento" ;
+ Text [ spanish ] = "Documento" ;
+ Text [ french ] = "Document" ;
+ Text [ dutch ] = "Document" ;
+ Text [ swedish ] = "Dokument" ;
+ Text [ danish ] = "Dokument" ;
+ Text [ portuguese_brazilian ] = "Dokument" ;
+ Text [ portuguese ] = "Documento" ;
+ Text[ chinese_simplified ] = "Îĵµ";
+ Text[ russian ] = "Äîêóìåíò";
+ Text[ polish ] = "Dokument";
+ Text[ japanese ] = "ÄÞ·­ÒÝÄ";
+ Text[ chinese_traditional ] = "¤å¥ó";
+ Text[ arabic ] = "ÇáãÓÊäÏ";
+ Text[ dutch ] = "Document";
+ Text[ chinese_simplified ] = "Îĵµ";
+ Text[ greek ] = "¸ããñáöï";
+ Text[ korean ] = "¹®¼­";
+ Text[ turkish ] = "Belge";
+};
+Bitmap RID_BMP_BRKPNT0
+{
+ FILE = "basbrk0.bmp" ;
+};
+Bitmap RID_BMP_BRKPNT1
+{
+ FILE = "basbrk.bmp" ;
+};
+String RID_BASICIDE_OBJECTBAR
+{
+ Text = "Makro-Leiste" ;
+ Text [ ENGLISH ] = "Macro-Bar" ;
+ Text [ norwegian ] = "Macro-Bar" ;
+ Text [ italian ] = "Barra delle macro" ;
+ Text [ portuguese_brazilian ] = "Barra-Macro" ;
+ Text [ portuguese ] = "Barra de macros" ;
+ Text [ finnish ] = "Makrorivi" ;
+ Text [ danish ] = "Makrolinje" ;
+ Text [ french ] = "Barre de macros" ;
+ Text [ swedish ] = "Makrolist" ;
+ Text [ dutch ] = "Macrobalk" ;
+ Text [ spanish ] = "Barra de macro" ;
+ Text [ english_us ] = "Macro Bar" ;
+ Text[ chinese_simplified ] = "ºê-À¸";
+ Text[ russian ] = "Ïàíåëü Makroñà";
+ Text[ polish ] = "Pasek makro";
+ Text[ japanese ] = "Ï¸Û ÊÞ°";
+ Text[ chinese_traditional ] = "¥¨¶°¦C";
+ Text[ arabic ] = "ÔÑíØ ãÇßÑæ";
+ Text[ dutch ] = "Macrobalk";
+ Text[ chinese_simplified ] = "ºê-À¸";
+ Text[ greek ] = "ÃñáììÞ ìáêñïåíôïëÞò";
+ Text[ korean ] = "¸ÅÅ©·Î ¸ðÀ½";
+ Text[ turkish ] = "Makro çubuðu";
+};
+String RID_STR_CANNOTCLOSE
+{
+ /* ### ACHTUNG: Neuer Text in Resource? Das Fenster kann nicht geschlossen werden,\nwährend das BASIC-Programm läuft. : Das Fenster kann nicht geschlossen werden,\nwõhrend das BASIC-Programm lõuft. */
+ Text = "Das Fenster kann nicht geschlossen werden,\nwährend das BASIC-Programm läuft." ;
+ Text [ ENGLISH ] = "The window can't be closed while BASIC is running" ;
+ Text [ norwegian ] = "The window can't be closed while BASIC is running" ;
+ Text [ italian ] = "La finestra non può essere chiusa mentre\n il programma BASIC è in esecuzione." ;
+ Text [ portuguese_brazilian ] = "A janela não pode ser fechada enquanto o BASIC estiver rodando" ;
+ Text [ portuguese ] = "A janela não pode ser fechada enquanto o \nBASIC estiver a ser executado." ;
+ Text [ finnish ] = "Ikkunaa ei voi sulkea, kun BASIC on käynnissä" ;
+ Text [ danish ] = "Vinduet kan ikke lukkes \nmens du kører BASIC." ;
+ Text [ french ] = "Impossible de fermer la fenêtre lorsque BASIC est en cours d'exécution." ;
+ Text [ swedish ] = "Fönstret kan inte stängas\nnär BASIC-programmet körs." ;
+ Text [ dutch ] = "Het venster kan niet worden gesloten \ntijdens het uitvoeren van het BASIC-programma." ;
+ Text [ spanish ] = "No se puede cerrar la ventana\nmientras se ejecuta el programa BASIC." ;
+ Text [ english_us ] = "The window can't be closed while BASIC is running." ;
+ Text[ chinese_simplified ] = "ÔÚ BASIC ³ÌÐòÔËÐÐʱ\nÎÞ·¨¹Ø±ÕÊÓ´°¡£";
+ Text[ russian ] = "Çàêðûòü îêíî íåâîçìîæíî,\nïîêà ïðîãðàììà BASIC íàõîäèòñÿ â äåéñòâèè.";
+ Text[ polish ] = "Okna nie mo¿na by³o zamkn¹æ,\npodczas trwania programu BASIC.";
+ Text[ japanese ] = "BASICÌßÛ¸Þ×Ñ‚Ìì“®’†‚ɳ¨ÝÄÞ³‚ð•‚¶‚邱‚Ƃ͂ł«‚Ü‚¹‚ñB";
+ Text[ chinese_traditional ] = "¦b BASIC µ{¦¡¹B¦æ®É\nµLªkÃö³¬µøµ¡¡C";
+ Text[ arabic ] = "áÇ íãßä ÅÛáÇÞ ÇáäÇÝÐÉ¡\nÈíäãÇ ÈÑäÇãÌ BASIC ÞíÏ ÇáÊÔÛíá.";
+ Text[ dutch ] = "Het venster kan niet worden gesloten \ntijdens het uitvoeren van het BASIC-programma.";
+ Text[ chinese_simplified ] = "ÔÚ BASIC ³ÌÐòÔËÐÐʱ\nÎÞ·¨¹Ø±ÕÊÓ´°¡£";
+ Text[ greek ] = "Äåí åßíáé äõíáôüí íá êëåßóåôå ôï ðáñÜèõñï \nêáôÜ ôç äéÜñêåéá åêôÝëåóçò ôïõ BASIC.";
+ Text[ korean ] = "BASIC ÇÁ·Î±×·¥ÀÌ ÁøÇàµÇ´Â µ¿¾ÈÀº âÀ» ´ÝÀ» ¼ö ¾ø½À´Ï´Ù.";
+ Text[ turkish ] = "BASIC programý çalýþýrken\npencere kapatýlamaz.";
+};
+String RID_STR_REPLACESTDLIB
+{
+ Text = "Die Standard-Bibliothek kann nicht ersetzt werden." ;
+ Text [ ENGLISH ] = "The standard libary can't be replaced." ;
+ Text [ english_us ] = "The standard library cannot be replaced." ;
+ Text [ italian ] = "Non è possibile sostituire la library standard." ;
+ Text [ spanish ] = "No se puede substituir la biblioteca estándar." ;
+ Text [ french ] = "Impossible de remplacer la bibliothèque par défaut." ;
+ Text [ dutch ] = "De standaardbibliotheek kan niet worden vervangen." ;
+ Text [ swedish ] = "Standardbiblioteket kan inte ersättas." ;
+ Text [ danish ] = "Standardmappen kan ikke erstattes." ;
+ Text [ portuguese_brazilian ] = "Die Standard-Bibliothek kann nicht ersetzt werden." ;
+ Text [ portuguese ] = "A biblioteca-padrão não pode ser substituída." ;
+ Text[ chinese_simplified ] = "ÎÞ·¨¸üÌæ±ê×¼-¿â¡£";
+ Text[ russian ] = "Çàìåíèòü ñòàíäàðòíóþ áèáëèîòåêó íåâîçìîæíî.";
+ Text[ polish ] = "Standardowej biblioteki nie mo¿na by³o zast¹piæ.";
+ Text[ japanese ] = "•W€×²ÌÞר‚Í’uŠ·‚Å‚«‚Ü‚¹‚ñB";
+ Text[ chinese_traditional ] = "µLªk¥N´À¼Ð·Çµ{¦¡®w¡C";
+ Text[ arabic ] = ".áÇ íãßä ÇÓÊÈÏÇá ÇáãßÊÈÉ ÇáÇÝÊÑÇÖíÉ";
+ Text[ dutch ] = "De standaardbibliotheek kan niet worden vervangen.";
+ Text[ chinese_simplified ] = "ÎÞ·¨¸üÌæ±ê×¼-¿â¡£";
+ Text[ greek ] = "Äåí åßíáé äõíáôüí íá ãßíåé áíôéêáôÜóôáóç ôçò âáóéêÞò âéâëéïèÞêçò";
+ Text[ korean ] = "±âº» ¶óÀ̺귯¸®¸¦ ¹Ù²Ü ¼ö ¾ø½À´Ï´Ù.";
+ Text[ turkish ] = "Standart kitaplýk deðiþtirilemez.";
+};
+String RID_STR_REFNOTPOSSIBLE
+{
+ /* ### ACHTUNG: Neuer Text in Resource? Referenz auf 'XX' nicht möglich. : Referenz auf ''XX'' nicht möglich. */
+ /* ### ACHTUNG: Neuer Text in Resource? Referenz auf 'XX' nicht möglich. : Referenz auf 'XX' nicht m÷glich. */
+ Text = "Referenz auf 'XX' nicht möglich." ;
+ Text [ ENGLISH ] = "Reference to 'XX' not possible." ;
+ Text [ dutch ] = "Verwijzing naar ' XX' niet mogelijk." ;
+ Text [ english_us ] = "Reference to 'XX' not possible." ;
+ Text [ italian ] = "Riferimento a 'XX' non possibile." ;
+ Text [ spanish ] = "No es posible la referencia a 'XX' ." ;
+ Text [ french ] = "Référence à 'XX' impossible." ;
+ Text [ swedish ] = "Referens till 'XX' inte möjlig." ;
+ Text [ danish ] = "Reference til 'XX' er ikke mulig." ;
+ Text [ portuguese_brazilian ] = "Referenz auf 'XX' nicht möglich." ;
+ Text [ portuguese ] = "A referência a 'XX' é impossível." ;
+ Text[ chinese_simplified ] = "ÎÞ·¨ÒýÓÃ 'XX' ¡£";
+ Text[ russian ] = "Ññûëêà íà 'XX' íåâîçìîæíà.";
+ Text[ polish ] = "Odwo³anie do 'XX' jest niemo¿liwe.";
+ Text[ japanese ] = "'XX'‚ÌŽQƂ͂ł«‚Ü‚¹‚ñB";
+ Text[ chinese_traditional ] = "µLªk°Ñ·Ó 'XX' ¡C";
+ Text[ arabic ] = ".ÛíÑ ããßä 'XX' ÇáãÑÌÚ Åáì";
+ Text[ dutch ] = "Verwijzing naar ' XX' niet mogelijk.";
+ Text[ chinese_simplified ] = "ÎÞ·¨ÒýÓÃ 'XX' ¡£";
+ Text[ greek ] = "Äåí åßíáé äõíáôÞ ç áíáöïñÜ óôï 'XX' .";
+ Text[ korean ] = "'XX'¿¡ ÂüÁ¶ ºÒ°¡´É";
+ Text[ turkish ] = "'XX' referans alýnamaz.";
+};
+String RID_STR_WATCHNAME
+{
+ Text = "Beobachter" ;
+ Text [ ENGLISH ] = "Watches" ;
+ Text [ norwegian ] = "Watches" ;
+ Text [ italian ] = "Controllo" ;
+ Text [ portuguese_brazilian ] = "Vis es" ;
+ Text [ portuguese ] = "Observador" ;
+ Text [ finnish ] = "Vahdit" ;
+ Text [ danish ] = "Observatør" ;
+ Text [ french ] = "Espion" ;
+ Text [ swedish ] = "Bevakning" ;
+ Text [ dutch ] = "Waarnemer" ;
+ Text [ spanish ] = "Observador" ;
+ Text [ english_us ] = "Watch" ;
+ Text[ chinese_simplified ] = "²é¿´";
+ Text[ russian ] = "Êîíòðîëüíîå çíà÷åíèå:";
+ Text[ polish ] = "Czujka";
+ Text[ japanese ] = "µÌÞ»Þ°ÊÞ°";
+ Text[ chinese_traditional ] = "À˵ø";
+ Text[ arabic ] = "ãÑÇÞÈ";
+ Text[ dutch ] = "Waarnemer";
+ Text[ chinese_simplified ] = "²é¿´";
+ Text[ greek ] = "ÐáñáôçñçôÞò";
+ Text[ korean ] = "Á¶»ç½Ä";
+ Text[ turkish ] = "Ýzleyici";
+};
+String RID_STR_STACKNAME
+{
+ Text = "Kommandostapel" ;
+ Text [ ENGLISH ] = "Stack" ;
+ Text [ norwegian ] = "Stack" ;
+ Text [ italian ] = "Stack" ;
+ Text [ portuguese_brazilian ] = "Pilha" ;
+ Text [ portuguese ] = "Empilhar" ;
+ Text [ finnish ] = "Pino" ;
+ Text [ danish ] = "Kommandostak" ;
+ Text [ french ] = "Pile" ;
+ Text [ swedish ] = "Anropsstack" ;
+ Text [ dutch ] = "Commandostapel" ;
+ Text [ spanish ] = "Pila de comandos" ;
+ Text [ english_us ] = "Call Stack" ;
+ Text[ chinese_simplified ] = "ºô½Ð¶Ñµþ";
+ Text[ russian ] = "Ñòåê âûçîâà";
+ Text[ polish ] = "Stos wywo³añ";
+ Text[ japanese ] = "½À¯¸‚̌ĂÑo‚µ";
+ Text[ chinese_traditional ] = "©I¥s°ïÅ|";
+ Text[ arabic ] = "ÇÓÊÏÚÇÁ ÇáãßÏøóÓ";
+ Text[ dutch ] = "Commandostapel";
+ Text[ chinese_simplified ] = "ºô½Ð¶Ñµþ";
+ Text[ greek ] = "Óôïßâá åíôïëþí";
+ Text[ korean ] = "ÄÝ ½ºÅÃ";
+ Text[ turkish ] = "Komut yýðýný";
+};
+String RID_STR_INITIDE
+{
+ Text = "Initialisierung BASIC" ;
+ Text [ ENGLISH ] = "Init BASIC" ;
+ Text [ norwegian ] = "Init BASIC" ;
+ Text [ italian ] = "Inizializza BASIC" ;
+ Text [ portuguese_brazilian ] = "Iniciar BASIC" ;
+ Text [ portuguese ] = "Iniciar BASIC" ;
+ Text [ finnish ] = "Alusta BASIC" ;
+ Text [ danish ] = "BASIC initialisiering" ;
+ Text [ french ] = "Initialiser BASIC" ;
+ Text [ swedish ] = "Initiering BASIC" ;
+ Text [ dutch ] = "BASIC initialiseren" ;
+ Text [ spanish ] = "Iniciar BASIC" ;
+ Text [ english_us ] = "BASIC Initialization" ;
+ Text[ chinese_simplified ] = "³õʼ»¯ BASIC";
+ Text[ russian ] = "Èíèöèàëèçàöèÿ BASIC";
+ Text[ polish ] = "Inicjalizacja BASIC";
+ Text[ japanese ] = "BASIC‚̉Šú‰»";
+ Text[ chinese_traditional ] = "ªì©l¤Æ BASIC";
+ Text[ arabic ] = "BASIC ÊåíÆÉ";
+ Text[ dutch ] = "BASIC initialiseren";
+ Text[ chinese_simplified ] = "³õʼ»¯ BASIC";
+ Text[ greek ] = "Áñ÷éêïðïßçóç BASIC";
+ Text[ korean ] = "BASIC Ãʱâ";
+ Text[ turkish ] = "BASIC baþlatýlýyor";
+};
+String RID_STR_STDMODULENAME
+{
+ Text = "Modul" ;
+ Text [ ENGLISH ] = "Module" ;
+ Text [ norwegian ] = "Module" ;
+ Text [ italian ] = "Modulo" ;
+ Text [ portuguese_brazilian ] = "Módulo" ;
+ Text [ portuguese ] = "Módulo" ;
+ Text [ finnish ] = "Moduuli" ;
+ Text [ danish ] = "Modul" ;
+ Text [ french ] = "Module" ;
+ Text [ swedish ] = "Modul" ;
+ Text [ dutch ] = "Module" ;
+ Text [ spanish ] = "Módulo" ;
+ Text [ english_us ] = "Module" ;
+ Text[ chinese_simplified ] = "Ä£¿é";
+ Text[ russian ] = "Ìîäóëü";
+ Text[ polish ] = "Modu³";
+ Text[ japanese ] = "Ó¼Þ­°Ù";
+ Text[ chinese_traditional ] = "¼Ò¶ô";
+ Text[ arabic ] = "æÍÏÉ äãØíÉ";
+ Text[ dutch ] = "Module";
+ Text[ chinese_simplified ] = "Ä£¿é";
+ Text[ greek ] = "ËåéôïõñãéêÞ ìïíÜäá";
+ Text[ korean ] = "¸ðµâ";
+ Text[ turkish ] = "Modül";
+};
+String RID_STR_STDDIALOGNAME
+{
+ Text = "Dialog" ;
+ Text [ ENGLISH ] = "Dialog" ;
+ Text [ norwegian ] = "Dialog" ;
+ Text [ italian ] = "Dialogo" ;
+ Text [ portuguese_brazilian ] = "Diálogo" ;
+ Text [ portuguese ] = "Diálogo" ;
+ Text [ finnish ] = "Valintaikkuna" ;
+ Text [ danish ] = "Dialog" ;
+ Text [ french ] = "Dialogue" ;
+ Text [ swedish ] = "Dialog" ;
+ Text [ dutch ] = "Dialoog" ;
+ Text [ spanish ] = "Diálogo" ;
+ Text [ english_us ] = "Dialog" ;
+ Text[ chinese_simplified ] = "¶Ô»°¿ò";
+ Text[ russian ] = "Äèàëîã";
+ Text[ polish ] = "Dialog";
+ Text[ japanese ] = "ÀÞ²±Û¸Þ";
+ Text[ chinese_traditional ] = "¹ï¸Ü¤è¶ô";
+ Text[ arabic ] = "ãÑÈÚ ÍæÇÑ";
+ Text[ dutch ] = "Dialoog";
+ Text[ chinese_simplified ] = "¶Ô»°¿ò";
+ Text[ greek ] = "ÄéÜëïãïò";
+ Text[ korean ] = "´ëÈ­»óÀÚ";
+ Text[ turkish ] = "Diyalog";
+};
+String RID_STR_STDLIBNAME
+{
+ Text = "Bibliothek" ;
+ Text [ ENGLISH ] = "Libary" ;
+ Text [ norwegian ] = "Libary" ;
+ Text [ italian ] = "Library" ;
+ Text [ portuguese_brazilian ] = "Library" ;
+ Text [ portuguese ] = "Biblioteca" ;
+ Text [ french ] = "Bibliothèque" ;
+ Text [ dutch ] = "Bibliotheek" ;
+ Text [ spanish ] = "Biblioteca" ;
+ Text [ danish ] = "Bibliotek" ;
+ Text [ swedish ] = "Bibliotek" ;
+ Text [ finnish ] = "Libary" ;
+ Text [ english_us ] = "Library" ;
+ Text[ chinese_simplified ] = "¿â";
+ Text[ russian ] = "Áèáëèîòåêà";
+ Text[ polish ] = "Biblioteka";
+ Text[ japanese ] = "ײÌÞר";
+ Text[ chinese_traditional ] = "µ{¦¡®w";
+ Text[ arabic ] = "ãßÊÈÉ";
+ Text[ dutch ] = "Bibliotheek";
+ Text[ chinese_simplified ] = "¿â";
+ Text[ greek ] = "ÂéâëéïèÞêç";
+ Text[ korean ] = "¶óÀ̺귯¸®";
+ Text[ turkish ] = "Kitaplýk";
+};
+String RID_STR_NEWLIB
+{
+ Text = "Neue Bibliothek" ;
+ Text [ English ] = "New libary" ;
+ Text [ portuguese ] = "Nova biblioteca" ;
+ Text [ english_us ] = "New Library" ;
+ Text [ portuguese_brazilian ] = "Neue Bibliothek" ;
+ Text [ swedish ] = "Nytt bibliotek" ;
+ Text [ danish ] = "Nyt bibliotek" ;
+ Text [ italian ] = "Nuova library" ;
+ Text [ spanish ] = "Nueva biblioteca" ;
+ Text [ french ] = "Nouvelle bibliothèque" ;
+ Text [ dutch ] = "Nieuwe bibliotheek" ;
+ Text[ chinese_simplified ] = "пâ";
+ Text[ russian ] = "Ñîçäàòü áèáëèîòåêó";
+ Text[ polish ] = "Nowa biblioteka";
+ Text[ japanese ] = "V‚µ‚¢×²ÌÞר";
+ Text[ chinese_traditional ] = "·sµ{¦¡®w";
+ Text[ arabic ] = "ãßÊÈÉ ÌÏíÏÉ";
+ Text[ dutch ] = "Nieuwe bibliotheek";
+ Text[ chinese_simplified ] = "пâ";
+ Text[ greek ] = "Äçìéïõñãßá âéâëéïèÞêçò";
+ Text[ korean ] = "»õ ¶óÀ̺귯¸®";
+ Text[ turkish ] = "Yeni kitaplýk";
+};
+String RID_STR_NEWMOD
+{
+ Text = "Neues Modul" ;
+ Text [ English ] = "New module" ;
+ Text [ english_us ] = "New Module" ;
+ Text [ portuguese_brazilian ] = "Neues Modul" ;
+ Text [ swedish ] = "Ny modul" ;
+ Text [ danish ] = "Nyt modul" ;
+ Text [ italian ] = "Nuovo modulo" ;
+ Text [ spanish ] = "Nuevo módulo" ;
+ Text [ french ] = "Nouveau module" ;
+ Text [ dutch ] = "Nieuwe module" ;
+ Text [ portuguese ] = "Novo módulo" ;
+ Text[ chinese_simplified ] = "ÐÂÄ£¿é";
+ Text[ russian ] = "Ñîçäàòü ìîäóëü";
+ Text[ polish ] = "Nowy modu³";
+ Text[ japanese ] = "V‚µ‚¢Ó¼Þ­°Ù";
+ Text[ chinese_traditional ] = "·s¼Ò¶ô";
+ Text[ arabic ] = "æÍÏÉ äãØíÉ ÌÏíÏÉ";
+ Text[ dutch ] = "Nieuwe module";
+ Text[ chinese_simplified ] = "ÐÂÄ£¿é";
+ Text[ greek ] = "ÍÝá ëåéôïõñãéêÞ ìïíÜäá";
+ Text[ korean ] = "»õ ¸ðµâ";
+ Text[ turkish ] = "Yeni modül";
+};
+String RID_STR_NEWDLG
+{
+ Text = "Neuer Dialog" ;
+ Text [ English ] = "New dialog" ;
+ Text [ english_us ] = "New Dialog" ;
+ Text [ portuguese_brazilian ] = "Neuer Dialog" ;
+ Text [ swedish ] = "Ny dialog" ;
+ Text [ danish ] = "Ny dialog" ;
+ Text [ italian ] = "Nuovo dialogo" ;
+ Text [ spanish ] = "Nuevo diálogo" ;
+ Text [ french ] = "Nouvelle boîte de dialogue" ;
+ Text [ dutch ] = "Nieuwe dialoog" ;
+ Text [ portuguese ] = "Novo diálogo" ;
+ Text[ chinese_simplified ] = "жԻ°";
+ Text[ russian ] = "Íîâûé äèàëîã";
+ Text[ polish ] = "Nowy dialog";
+ Text[ japanese ] = "V‚µ‚¢ÀÞ²±Û¸Þ";
+ Text[ chinese_traditional ] = "·s¹ï¸Ü";
+ Text[ arabic ] = "ãÑÈÚ ÍæÇÑ ÌÏíÏ";
+ Text[ dutch ] = "Nieuwe dialoog";
+ Text[ chinese_simplified ] = "жԻ°";
+ Text[ greek ] = "ÍÝïò äéÜëïãïò";
+ Text[ korean ] = "»õ ´ëÈ­»óÀÚ";
+ Text[ turkish ] = "Yeni diyalog";
+};
+String RID_STR_ALL
+{
+ Text = "Alle" ;
+ Text [ ENGLISH ] = "All" ;
+ Text [ norwegian ] = "All" ;
+ Text [ italian ] = "Tutto" ;
+ Text [ portuguese_brazilian ] = "Tudo" ;
+ Text [ portuguese ] = "Tudo" ;
+ Text [ finnish ] = "Kaikki" ;
+ Text [ danish ] = "Alle" ;
+ Text [ french ] = "Tout" ;
+ Text [ swedish ] = "Alla" ;
+ Text [ dutch ] = "Alles" ;
+ Text [ spanish ] = "Todo" ;
+ Text [ english_us ] = "All" ;
+ Text[ chinese_simplified ] = "È«²¿";
+ Text[ russian ] = "Âñå";
+ Text[ polish ] = "Wszystkie";
+ Text[ japanese ] = "‚·‚ׂÄ";
+ Text[ chinese_traditional ] = "¥þ³¡";
+ Text[ arabic ] = "ßá";
+ Text[ dutch ] = "Alles";
+ Text[ chinese_simplified ] = "È«²¿";
+ Text[ greek ] = "¼ëá";
+ Text[ korean ] = "Àüü";
+ Text[ turkish ] = "Tümü";
+};
+String RID_STR_PAGE
+{
+ Text = "Seite" ;
+ Text [ ENGLISH ] = "Page" ;
+ Text [ norwegian ] = "Page" ;
+ Text [ italian ] = "Pagina" ;
+ Text [ portuguese_brazilian ] = "Página" ;
+ Text [ portuguese ] = "Página" ;
+ Text [ english_us ] = "Page" ;
+ Text [ finnish ] = "Sivu" ;
+ Text [ danish ] = "Side" ;
+ Text [ french ] = "Page" ;
+ Text [ swedish ] = "Sida" ;
+ Text [ dutch ] = "Pagina" ;
+ Text [ spanish ] = "Página" ;
+ Text[ chinese_simplified ] = "Ò³";
+ Text[ russian ] = "Ñòðàíèöà";
+ Text[ polish ] = "Strona";
+ Text[ japanese ] = "Íß°¼Þ";
+ Text[ chinese_traditional ] = "­¶";
+ Text[ arabic ] = "ÕÝÍÉ";
+ Text[ dutch ] = "Pagina";
+ Text[ chinese_simplified ] = "Ò³";
+ Text[ greek ] = "Óåëßäá";
+ Text[ korean ] = "ÆäÀÌÁö";
+ Text[ turkish ] = "Sayfa";
+};
+String RID_STR_MACRONAMEREQ
+{
+ /* ### ACHTUNG: Neuer Text in Resource? Es muß ein Name angegeben werden. : Es mu˜ ein Name angegeben werden. */
+ Text = "Es muss ein Name angegeben werden." ;
+ Text [ ENGLISH ] = "Macro name required." ;
+ Text [ dutch ] = "Er moet een naam worden ingevuld." ;
+ Text [ english_us ] = "A name must be entered." ;
+ Text [ italian ] = "È necessario digitare un nome." ;
+ Text [ spanish ] = "Se debe introducir un nombre." ;
+ Text [ french ] = "Vous devez indiquer un nom." ;
+ Text [ swedish ] = "Ett namn måste anges." ;
+ Text [ danish ] = "Der skal angives et navn" ;
+ Text [ portuguese_brazilian ] = "Es muß ein Name angegeben werden." ;
+ Text [ portuguese ] = "É necessário especificar um nome." ;
+ Text[ chinese_simplified ] = "±ØÐë¸ø¶¨Ò»¸öÃû³Æ¡£";
+ Text[ russian ] = "Íåîáõîäèìî ïðèñâîèòü èìÿ.";
+ Text[ polish ] = "Trzeba podaæ nazwê.";
+ Text[ japanese ] = "–¼‘O‚Ì“ü—Í‚ª•K—v‚Å‚·B";
+ Text[ chinese_traditional ] = "¥²¶·¿é¤J¤@­Ó¦WºÙ¡C";
+ Text[ arabic ] = ".íÌÈ ÅÏÎÇá ÇÓã";
+ Text[ dutch ] = "Er moet een naam worden ingevuld.";
+ Text[ chinese_simplified ] = "±ØÐë¸ø¶¨Ò»¸öÃû³Æ¡£";
+ Text[ greek ] = "ÐñÝðåé íá åéóÜãåôå Ýíá üíïìá.";
+ Text[ korean ] = "À̸§À» ÀÔ·ÂÇØ¾ß ÇÕ´Ï´Ù.";
+ Text[ turkish ] = "Bir ad girilmesi gerekir.";
+};
+String RID_STR_WILLSTOPPRG
+{
+ /* ### ACHTUNG: Neuer Text in Resource? Sie müssen nach dieser Änderung Ihr Programm neu starten.\nForfahren? : Sie m³ssen nach dieser Žnderung Ihr Programm neu starten.\nForfahren? */
+ Text = "Sie müssen nach dieser Änderung Ihr Programm neu starten.\nForfahren?" ;
+ Text [ ENGLISH ] = "You'll have to restart after this edit.\nProceed anyway?" ;
+ Text [ dutch ] = "U moet uw programma na deze wijziging opnieuw opstarten.\nDoorgaan?" ;
+ Text [ english_us ] = "You will have to restart the program after this edit.\nProceed?" ;
+ Text [ italian ] = "Dopo questa modifica è necessario riavviare il programma.\nProseguire?" ;
+ Text [ spanish ] = "Tendrá que volver a iniciar el programa después de estas modificaciones.\n¿Continuar?" ;
+ Text [ french ] = "Après cette modification, vous devrez relancer le programme.\nPoursuivre ?" ;
+ Text [ swedish ] = "Du måste starta om Ditt program efter den här ändringen.\nFortsätta ändå?" ;
+ Text [ danish ] = "Det er nødvendigt at genstarte programmet efter denne ændring .\nVil du fortsætte alligevel?" ;
+ Text [ portuguese_brazilian ] = "Sie müssen nach dieser Änderung Ihr Programm neu starten.\nForfahren?" ;
+ Text [ portuguese ] = "Terá que reiniciar o programa depois desta modificação.\nContinuar?" ;
+ Text[ chinese_simplified ] = "ÔÚ³ÌÐò±»¸ü¸ÄºóÄú±ØÐëÖØÐÂÆô¶¯Õâ¸ö³ÌÐò¡£\nÄúÒª¼ÌÐøÂð£¿";
+ Text[ russian ] = "Ïîñëå ýòîãî èçìåíåíèÿ Âû äîëæíû áóäåòå ïåðåñòàðòîâàòü Âàøó ïðîãðàììó.\nÏðîäîëæèòü?";
+ Text[ polish ] = "Po tej zmianie musisz ponownie uruchomiæ program.\nKontynuowaæ?";
+ Text[ japanese ] = "‚±‚Ì•ÏX‚ÌŒã¤ÌßÛ¸Þ×Ñ‚ðÄ‹N“®‚µ‚È‚¯‚ê‚΂Ȃè‚Ü‚¹‚ñB\n‘±‚¯‚Ü‚·‚©H";
+ Text[ chinese_traditional ] = "Åܧóµ{¦¡«á±z¥²¶·­«·s±Ò°Ê³o­Óµ{¦¡¡C\n­nÄ~Äò¡S";
+ Text[ arabic ] = "ÈÚÏ åÐÇ ÇáÊÛííÑ¡ íÌÈ Úáíß ÅÚÇÏÉ ÊÔÛíá ÈÑäÇãÌß.\nåá ÊÑíÏ ÇáãÊÇÈÚÉ¿";
+ Text[ dutch ] = "U moet uw programma na deze wijziging opnieuw opstarten.\nDoorgaan?";
+ Text[ chinese_simplified ] = "ÔÚ³ÌÐò±»¸ü¸ÄºóÄú±ØÐëÖØÐÂÆô¶¯Õâ¸ö³ÌÐò¡£\nÄúÒª¼ÌÐøÂð£¿";
+ Text[ greek ] = "ÌåôÜ ôçí áëëáãÞ èá ðñÝðåé íá åêêéíÞóåôå ôï ðñüãñáììá îáíÜ.\nÓõíÝ÷åéá;";
+ Text[ korean ] = "À̰ÍÀ» º¯°æÇÑ ÈÄ¿¡ ÇÁ·Î±×·¥À» »õ·Î ½ÃÀÛÇØ¾ß ÇÕ´Ï´Ù.\n°è¼ÓÇϽðڽÀ´Ï±î?";
+ Text[ turkish ] = "Bu deðiþiklikten sonra programý yeniden baþlatmanýz gerekir.\nDevam etmek istiyor musunuz?";
+};
+String RID_STR_SEARCHALLMODULES
+{
+ Text = "Soll der Text in allen aktiven Modulen ersetzt werden?" ;
+ Text [ ENGLISH ] = "Soll der Text in allen aktiven Modulen ersetzt werden?" ;
+ Text [ english_us ] = "Do you want to replace the text in all active modules?" ;
+ Text [ italian ] = "Sostituire il testo in tutti i moduli attivi ?" ;
+ Text [ spanish ] = "¿Desea substituir el texto en todos los módulos activos?" ;
+ Text [ french ] = "Désirez-vous remplacer le texte dans tous les modules actifs ?" ;
+ Text [ dutch ] = "Wilt u de tekst in alle actieve modules vervangen?" ;
+ Text [ swedish ] = "Skall texten ersättas i alla aktiva moduler?" ;
+ Text [ danish ] = "Skal teksten erstattes i alle aktive moduler?" ;
+ Text [ portuguese_brazilian ] = "Soll der Text in allen aktiven Modulen ersetzt werden?" ;
+ Text [ portuguese ] = "Deseja substituir o texto em todos os módulos activos?" ;
+ Text[ chinese_simplified ] = "ÄúÒª¸üÌæÔÚËùÓ줻îµÄÄ£¿éÄÚµÄÎÄ×Ö£¿";
+ Text[ russian ] = "Çàìåíèòü òåêñò âî âñåõ àêòèâíûõ ìîäóëÿõ?";
+ Text[ polish ] = "Czy zast¹piæ ten tekst we wszystkich aktywnych modu³ach?";
+ Text[ japanese ] = "‚±‚Ì÷½Ä‚ð‚·‚×‚Ä‚Ì±¸Ã¨ÌÞ‚ÈÓ¼Þ­°Ù‚É’uŠ·‚¦‚Ü‚·‚©?";
+ Text[ chinese_traditional ] = "±z­n¥N´À¦b©Ò¦³¿E¬¡¼Ò¶ô¤¤ªº¤º¤å¡S";
+ Text[ arabic ] = "åá ÊÑíÏ ÇÓÊÈÏÇá ÇáäÕ Ýí ßá ÇáæÍÏÇÊ ÇáäãØíÉ ÇáäÔØÉ¿";
+ Text[ dutch ] = "Wilt u de tekst in alle actieve modules vervangen?";
+ Text[ chinese_simplified ] = "ÄúÒª¸üÌæÔÚËùÓ줻îµÄÄ£¿éÄÚµÄÎÄ×Ö£¿";
+ Text[ greek ] = "ÈÝëåôå íá ãßíåé áíôéêáôÜóôáóç ôïõ êåéìÝíïõ óå üëåò ôéò ôñÝ÷ïõóåò ëåéôïõñãéêÝò ìïíÜäåò;";
+ Text[ korean ] = "¸ðµç ÇöÀç ¸ðµâÀÇ ÅØ½ºÆ®¸¦ ¹Ù²Ù½Ã°Ú½À´Ï±î?";
+ Text[ turkish ] = "Bu metin tüm etkin modüllerde deðiþtirilsin mi?";
+};
+Edit RID_EDT_WATCHEDIT
+{
+ Border = TRUE ;
+ SvLook = TRUE ;
+ Size = MAP_APPFONT ( 80 , 12 ) ;
+};
+ImageButton RID_IMGBTN_REMOVEWATCH
+{
+ HelpId = HID_BASICIDE_REMOVEWATCH ;
+ SmallStyle = TRUE ;
+ ButtonImage = Image
+ {
+ ImageBitmap = Bitmap { File = "baswatr.bmp" ; };
+ MaskColor = Color { Red = 0xC000 ; Green = 0xC000 ; Blue = 0xC000 ; };
+ };
+ QuickHelpText = "Beobachter entfernen" ;
+ QuickHelpText [ ENGLISH ] = "Remove watch" ;
+ QuickHelpText [ english_us ] = "Remove Watch" ;
+ QuickHelpText [ italian ] = "Rimuovi controllo" ;
+ QuickHelpText [ spanish ] = "Elimina observador" ;
+ QuickHelpText [ french ] = "Supprimer l'espion" ;
+ QuickHelpText [ dutch ] = "Bewaker verwijderen" ;
+ QuickHelpText [ danish ] = "Fjern observatør" ;
+ QuickHelpText [ portuguese_brazilian ] = "Beobachter entfernen" ;
+ QuickHelpText [ portuguese ] = "Elimina Observador" ;
+ QuickHelpText [ swedish ] = "Ta bort bevakare" ;
+ QuickHelpText[ russian ] = "Óáðàòü êîíòðîëüíîå çíà÷åíèå";
+ QuickHelpText[ polish ] = "Usuñ czujkê";
+ QuickHelpText[ japanese ] = "µÌÞ»Þ°ÊÞ‚Ìíœ";
+ QuickHelpText[ chinese_simplified ] = "ÒþÈë²é¿´";
+ QuickHelpText[ chinese_traditional ] = "Áô¤JÀ˵ø";
+ QuickHelpText[ arabic ] = "ÅÒÇáÉ ÇáãÑÇÞÈ";
+ QuickHelpText[ dutch ] = "Bewaker verwijderen";
+ QuickHelpText[ chinese_simplified ] = "ÒþÈë²é¿´";
+ QuickHelpText[ greek ] = "ÊáôÜñãçóç ðáñáôçñçôÞ";
+ QuickHelpText[ korean ] = "Remove Watch";
+};
+ImageButton RID_IMGBTN_GOTOCALL
+{
+ HelpId = HID_BASICIDE_GOTOALL ;
+ SmallStyle = TRUE ;
+ ButtonImage = Image { ImageBitmap = Bitmap { File = "basgocl.bmp" ; }; } ;
+};
+String RID_STR_REMOVEWATCH
+{
+ Text = "Beobachter: " ;
+ Text [ ENGLISH ] = "Watch: " ;
+ Text [ norwegian ] = "Watch: " ;
+ Text [ italian ] = "Controllo: " ;
+ Text [ portuguese_brazilian ] = "Vis o: " ;
+ Text [ portuguese ] = "Observador: " ;
+ Text [ finnish ] = "Vahti: " ;
+ Text [ danish ] = "Observatør:" ;
+ Text [ french ] = "Témoin : " ;
+ Text [ swedish ] = "Bevakning: " ;
+ Text [ dutch ] = "Waarnemer: " ;
+ Text [ spanish ] = "Observador:" ;
+ Text [ english_us ] = "Watch:" ;
+ Text[ chinese_simplified ] = "²é¿´£º";
+ Text[ russian ] = "Êîíòðîëüíîå çíà÷åíèå: ";
+ Text[ polish ] = "Czujka: ";
+ Text[ japanese ] = "µÌÞ»Þ°ÊÞ:";
+ Text[ chinese_traditional ] = "À˵ø:";
+ Text[ arabic ] = "ãÑÇÞÈÉ: ";
+ Text[ dutch ] = "Waarnemer: ";
+ Text[ chinese_simplified ] = "²é¿´£º";
+ Text[ greek ] = "ÐáñáôçñçôÞò: ";
+ Text[ korean ] = "Á¶»ç½Ä: ";
+ Text[ turkish ] = "Ýzleyici: ";
+};
+String RID_STR_STACK
+{
+ Text = "Aufrufe: " ;
+ Text [ ENGLISH ] = "Calls: " ;
+ Text [ english_us ] = "Calls:" ;
+ Text [ italian ] = "Chiamate: " ;
+ Text [ spanish ] = "Llamadas:" ;
+ Text [ french ] = "Appels : " ;
+ Text [ dutch ] = "Oproepen: " ;
+ Text [ swedish ] = "Anrop: " ;
+ Text [ danish ] = "Opkald:" ;
+ Text [ portuguese_brazilian ] = "Aufrufe: " ;
+ Text [ portuguese ] = "Chamadas: " ;
+ Text[ chinese_simplified ] = "ºô½Ð£º";
+ Text[ russian ] = "Âûçîâû: ";
+ Text[ polish ] = "Wywo³ania: ";
+ Text[ japanese ] = "ŒÄ‚Ño‚µ:";
+ Text[ chinese_traditional ] = "©I¥s:";
+ Text[ arabic ] = ":ÇÓÊÏÚÇÁÇÊ";
+ Text[ dutch ] = "Oproepen: ";
+ Text[ chinese_simplified ] = "ºô½Ð£º";
+ Text[ greek ] = "ÊëÞóåéò: ";
+ Text[ korean ] = "È£Ãâ: ";
+ Text[ turkish ] = "Çaðrýlar: ";
+};
+/*
+String RID_STR_INSERTMODE
+{
+ TEXT = "EINFG" ;
+ TEXT [ English ] = "INS" ;
+ TEXT [ norwegian ] = "SETT INN" ;
+ TEXT [ italian ] = "INS" ;
+ TEXT [ portuguese_brazilian ] = "INS" ;
+ TEXT [ portuguese ] = "INS" ;
+ TEXT [ finnish ] = "LIS" ;
+ TEXT [ danish ] = "INS" ;
+ TEXT [ french ] = "INS" ;
+ TEXT [ swedish ] = "INS" ;
+ TEXT [ dutch ] = "INS" ;
+ TEXT [ spanish ] = "INS" ;
+ TEXT [ english_us ] = "INS" ;
+};
+
+String RID_STR_OVERWRITEMODE
+{
+ Text = "ÜBER" ;
+ Text [ English ] = "OVR" ;
+ Text [ norwegian ] = "+++OVR" ;
+ Text [ italian ] = "SSC" ;
+ Text [ portuguese_brazilian ] = "OVR" ;
+ Text [ portuguese ] = "OVR" ;
+ Text [ finnish ] = "KORV" ;
+ Text [ danish ] = "OVR" ;
+ Text [ french ] = "ECR" ;
+ Text [ swedish ] = "ÖVER" ;
+ Text [ dutch ] = "OVR" ;
+ Text [ spanish ] = "SOB" ;
+ Text [ english_us ] = "OVR" ;
+};
+
+*/
+ImageList RID_DEFAULTIMAGELIST_SC
+{
+ ImageBitmap = Bitmap { FILE = "sc_ide.bmp" ; };
+ MaskColor = Color { Red = 0xC000 ; Green = 0xC000 ; Blue = 0xC000 ; };
+ IdList =
+ {
+ SID_BASICLOAD ;
+ SID_BASICSAVEAS ;
+ SID_BASICCOMPILE ;
+ SID_BASICRUN ;
+ SID_BASICSTEPINTO ;
+ SID_BASICSTEPOVER ;
+ SID_BASICSTEPOUT ;
+ SID_BASICSTOP ;
+ SID_BASICIDE_TOGGLEBRKPNT ;
+ SID_BASICIDE_ADDWATCH ;
+ SID_BASICIDE_MODULEDLG ;
+ SID_BASICIDE_OBJCAT ;
+ SID_UNDO ;
+ SID_REDO ;
+ SID_CHOOSE_CONTROLS ;
+ SID_INSERT_PUSHBUTTON ;
+ SID_INSERT_CHECKBOX ;
+ SID_INSERT_RADIOBUTTON ;
+ SID_INSERT_FIXEDTEXT ;
+ SID_INSERT_EDIT ;
+ SID_INSERT_GROUPBOX ;
+ SID_INSERT_LISTBOX ;
+ SID_INSERT_COMBOBOX ;
+ SID_SHOW_BROWSER ;
+ SID_DIALOG_TESTMODE ;
+ SID_INSERT_SPINBUTTON ;
+ SID_INSERT_HSCROLLBAR ;
+ SID_INSERT_VSCROLLBAR ;
+ SID_OBJECT_SELECT ;
+ SID_BASICIDE_MATCHGROUP ;
+ SID_INSERT_PREVIEW ;
+ SID_BASICIDE_CHOOSEMACRO ;
+ SID_INSERT_URLBUTTON ;
+ SID_SHOW_HIDDEN ;
+ SID_SHOW_FORMS ;
+ };
+};
+ImageList RID_DEFAULTIMAGELIST_LC
+{
+ ImageBitmap = Bitmap { FILE = "lc_ide.bmp" ; };
+ MaskColor = Color { Red = 0xC000 ; Green = 0xC000 ; Blue = 0xC000 ; };
+ IdList =
+ {
+ SID_BASICLOAD ;
+ SID_BASICSAVEAS ;
+ SID_BASICCOMPILE ;
+ SID_BASICRUN ;
+ SID_BASICSTEPINTO ;
+ SID_BASICSTEPOVER ;
+ SID_BASICSTEPOUT ;
+ SID_BASICSTOP ;
+ SID_BASICIDE_TOGGLEBRKPNT ;
+ SID_BASICIDE_ADDWATCH ;
+ SID_BASICIDE_MODULEDLG ;
+ SID_BASICIDE_OBJCAT ;
+ SID_UNDO ;
+ SID_REDO ;
+ SID_CHOOSE_CONTROLS ;
+ SID_INSERT_PUSHBUTTON ;
+ SID_INSERT_CHECKBOX ;
+ SID_INSERT_RADIOBUTTON ;
+ SID_INSERT_FIXEDTEXT ;
+ SID_INSERT_EDIT ;
+ SID_INSERT_GROUPBOX ;
+ SID_INSERT_LISTBOX ;
+ SID_INSERT_COMBOBOX ;
+ SID_SHOW_BROWSER ;
+ SID_DIALOG_TESTMODE ;
+ SID_INSERT_SPINBUTTON ;
+ SID_INSERT_HSCROLLBAR ;
+ SID_INSERT_VSCROLLBAR ;
+ SID_OBJECT_SELECT ;
+ SID_BASICIDE_MATCHGROUP ;
+ SID_INSERT_PREVIEW ;
+ SID_BASICIDE_CHOOSEMACRO ;
+ SID_INSERT_URLBUTTON ;
+ SID_SHOW_HIDDEN ;
+ SID_SHOW_FORMS ;
+ };
+};
+ToolBox RID_BASICIDE_OBJECTBAR
+{
+ HelpId = HID_BASICIDE_TOOLBOX ;
+ LineSpacing = TRUE ;
+ Dockable = TRUE ;
+ Moveable = TRUE ;
+ Sizeable = TRUE ;
+ Zoomable = TRUE ;
+ Scroll = TRUE ;
+ HideWhenDeactivate = TRUE ;
+ Border = TRUE ;
+ SVLook = TRUE ;
+ Align = BOXALIGN_TOP ;
+ Scroll = TRUE ;
+ Customize = TRUE ;
+ Text = "BASIC" ;
+ Text [ ENGLISH ] = "BASIC" ;
+ Text [ norwegian ] = "BASIC" ;
+ Text [ italian ] = "BASIC" ;
+ Text [ portuguese_brazilian ] = "BASIC" ;
+ Text [ portuguese ] = "BASIC" ;
+ Text [ finnish ] = "BASIC" ;
+ Text [ danish ] = "BASIC" ;
+ Text [ french ] = "BASIC" ;
+ Text [ swedish ] = "BASIC" ;
+ Text [ dutch ] = "BASIC" ;
+ Text [ spanish ] = "BASIC" ;
+ Text [ english_us ] = "BASIC" ;
+ ItemList =
+ {
+ ToolBoxItem
+ {
+ Identifier = SID_BASICIDE_LIBSELECTOR ;
+ Text = "Bibliothek" ;
+ Text [ ENGLISH ] = "Libary" ;
+ Text [ norwegian ] = "Libary" ;
+ Text [ italian ] = "LIbrary" ;
+ Text [ portuguese_brazilian ] = "Library" ;
+ Text [ portuguese ] = "Biblioteca" ;
+ Text [ finnish ] = "Libary" ;
+ Text [ danish ] = "Bibliotek" ;
+ Text [ french ] = "Bibliothèque" ;
+ Text [ swedish ] = "Bibliotek" ;
+ Text [ dutch ] = "Bibliotheek" ;
+ Text [ spanish ] = "Biblioteca" ;
+ Text [ english_us ] = "Library" ;
+ Text[ chinese_simplified ] = "¿â";
+ Text[ russian ] = "Áèáëèîòåêà";
+ Text[ polish ] = "Biblioteka";
+ Text[ japanese ] = "ײÌÞר";
+ Text[ chinese_traditional ] = "µ{¦¡®w";
+ Text[ arabic ] = "ãßÊÈÉ";
+ Text[ dutch ] = "Bibliotheek";
+ Text[ chinese_simplified ] = "¿â";
+ Text[ greek ] = "ÂéâëéïèÞêç";
+ Text[ korean ] = "¶óÀ̺귯¸®";
+ Text[ turkish ] = "Kitaplýk";
+ };
+ ToolBoxItem
+ {
+ Type = TOOLBOXITEM_SEPARATOR ;
+ };
+ ToolBoxItem
+ {
+ Identifier = SID_BASICCOMPILE ;
+ /* ### ACHTUNG: Neuer Text in Resource? Übersetzen : šbersetzen */
+ Text = "Übersetzen" ;
+ Text [ ENGLISH ] = "Compile" ;
+ Text [ norwegian ] = "Compile" ;
+ Text [ italian ] = "Compila" ;
+ Text [ portuguese_brazilian ] = "Compilar" ;
+ Text [ portuguese ] = "Compilar" ;
+ Text [ finnish ] = "Käännä" ;
+ Text [ danish ] = "Kompiler" ;
+ Text [ french ] = "Compiler" ;
+ Text [ swedish ] = "Översätta" ;
+ Text [ dutch ] = "Vertalen" ;
+ Text [ spanish ] = "Compilar" ;
+ Text [ english_us ] = "Compile" ;
+ Text[ chinese_simplified ] = "±àÒë";
+ Text[ russian ] = "Êîìïèëèðîâàòü";
+ Text[ polish ] = "Kompiluj";
+ Text[ japanese ] = "ºÝÊß²Ù‚ðs‚¤";
+ Text[ chinese_traditional ] = "½sĶ";
+ Text[ arabic ] = "ÊÑÌãÉ";
+ Text[ dutch ] = "Vertalen";
+ Text[ chinese_simplified ] = "±àÒë";
+ Text[ greek ] = "Ìåôáãëþôôéóç";
+ Text[ korean ] = "ÄÄÆÄÀÏ";
+ Text[ turkish ] = "Derle";
+ };
+ ToolBoxItem
+ {
+ Identifier = SID_BASICRUN ;
+ /* ### ACHTUNG: Neuer Text in Resource? Ausführen : Ausf³hren */
+ Text = "Ausführen" ;
+ Text [ ENGLISH ] = "Run" ;
+ Text [ norwegian ] = "Run" ;
+ Text [ italian ] = "Esegui" ;
+ Text [ portuguese_brazilian ] = "Executar" ;
+ Text [ portuguese ] = "Executar" ;
+ Text [ finnish ] = "Suorita" ;
+ Text [ danish ] = "Kør" ;
+ Text [ french ] = "Exécuter" ;
+ Text [ swedish ] = "Kör" ;
+ Text [ dutch ] = "Starten" ;
+ Text [ spanish ] = "Ejecutar" ;
+ Text [ english_us ] = "Run" ;
+ Text[ chinese_simplified ] = "ÔËÐÐ";
+ Text[ russian ] = "Âûïîëíèòü";
+ Text[ polish ] = "Wykonaj";
+ Text[ japanese ] = "ŽÀs";
+ Text[ chinese_traditional ] = "°õ¦æ";
+ Text[ arabic ] = "ÊÔÛíá";
+ Text[ dutch ] = "Starten";
+ Text[ chinese_simplified ] = "ÔËÐÐ";
+ Text[ greek ] = "ÅêôÝëåóç";
+ Text[ korean ] = "½ÇÇà";
+ Text[ turkish ] = "Yürüt";
+ };
+ ToolBoxItem
+ {
+ Identifier = SID_BASICSTOP ;
+ Text = "Anhalten" ;
+ Text [ ENGLISH ] = "Stop" ;
+ Text [ norwegian ] = "Stopp" ;
+ Text [ italian ] = "Arresta" ;
+ Text [ portuguese_brazilian ] = "Parar" ;
+ Text [ portuguese ] = "Parar" ;
+ Text [ finnish ] = "Pysäytä" ;
+ Text [ danish ] = "Stop" ;
+ Text [ french ] = "Arrêter" ;
+ Text [ swedish ] = "Stoppa" ;
+ Text [ dutch ] = "Stoppen" ;
+ Text [ spanish ] = "Detener" ;
+ Text [ english_us ] = "Stop" ;
+ Text[ chinese_simplified ] = "Í£Ö¹";
+ Text[ russian ] = "Ñòîï";
+ Text[ polish ] = "Zatrzymaj";
+ Text[ japanese ] = "’†Ž~";
+ Text[ chinese_traditional ] = "°±¤î";
+ Text[ arabic ] = "ÅíÞÇÝ";
+ Text[ dutch ] = "Stoppen";
+ Text[ chinese_simplified ] = "Í£Ö¹";
+ Text[ greek ] = "ÄéáêïðÞ";
+ Text[ korean ] = "Á¤Áö";
+ Text[ turkish ] = "Durdur";
+ };
+ ToolBoxItem
+ {
+ Type = TOOLBOXITEM_SEPARATOR ;
+ };
+ ToolBoxItem
+ {
+ Identifier = SID_BASICSTEPOVER ;
+ Text = "Prozedurschritt" ;
+ Text [ ENGLISH ] = "Step over" ;
+ Text [ dutch ] = "Procedurestap" ;
+ Text [ english_us ] = "Procedure Step" ;
+ Text [ italian ] = "Passo di procedura" ;
+ Text [ spanish ] = "Paso a paso" ;
+ Text [ french ] = "Étape de procédure" ;
+ Text [ swedish ] = "Procedursteg" ;
+ Text [ danish ] = "Proceduretrin" ;
+ Text [ portuguese ] = "Procedimento passo a passo" ;
+ Text [ portuguese_brazilian ] = "Prozedurschritt" ;
+ Text[ chinese_simplified ] = "¹ý³Ìµ¥²½";
+ Text[ russian ] = "Øàã ñ îáõîäîì";
+ Text[ polish ] = "Krok w procedurze";
+ Text[ japanese ] = "ˆ—Žè‡";
+ Text[ chinese_traditional ] = "µ{§Ç³æ¨B";
+ Text[ arabic ] = "ÎØæÉ ÇáÅÌÑÇÁ";
+ Text[ dutch ] = "Procedurestap";
+ Text[ chinese_simplified ] = "¹ý³Ìµ¥²½";
+ Text[ greek ] = "ÂÞìá äéáäéêáóßáò";
+ Text[ korean ] = "ÇÁ·Î½ÃÀú ´Ü°è";
+ Text[ turkish ] = "Yordam adýmý";
+ };
+ ToolBoxItem
+ {
+ Identifier = SID_BASICSTEPINTO ;
+ Text = "Einzelschritt" ;
+ Text [ ENGLISH ] = "Step into" ;
+ Text [ dutch ] = "Stap voor stap" ;
+ Text [ english_us ] = "Single Step" ;
+ Text [ italian ] = "Passo singolo" ;
+ Text [ spanish ] = "Paso único" ;
+ Text [ french ] = "Étape par étape" ;
+ Text [ swedish ] = "Enkelsteg" ;
+ Text [ danish ] = "Enkelt trin" ;
+ Text [ portuguese ] = "Passo único" ;
+ Text [ portuguese_brazilian ] = "Einzelschritt" ;
+ Text[ chinese_simplified ] = "µ¥²½";
+ Text[ russian ] = "Øàã ñ çàõîäîì";
+ Text[ polish ] = "Pojedynczy krok";
+ Text[ japanese ] = "¼Ý¸ÞÙ ½Ã¯Ìß";
+ Text[ chinese_traditional ] = "³æ¨B";
+ Text[ arabic ] = "ÎØæÉ ãÝÑÏÉ";
+ Text[ dutch ] = "Stap voor stap";
+ Text[ chinese_simplified ] = "µ¥²½";
+ Text[ greek ] = "Ìïíü âÞìá";
+ Text[ korean ] = "´ÜÀÏ ´Ü°è";
+ Text[ turkish ] = "Tek adým";
+ };
+ ToolBoxItem
+ {
+ Identifier = SID_BASICSTEPOUT ;
+ /* ### ACHTUNG: Neuer Text in Resource? Rücksprung : R³cksprung */
+ Text = "Rücksprung" ;
+ Text [ ENGLISH ] = "Step out" ;
+ Text [ dutch ] = "Terugspringen" ;
+ Text [ english_us ] = "Step Back" ;
+ Text [ italian ] = "Salto indietro" ;
+ Text [ spanish ] = "Salto atrás" ;
+ Text [ french ] = "Saut en arrière" ;
+ Text [ swedish ] = "Hoppa tillbaka" ;
+ Text [ danish ] = "Spring tilbage" ;
+ Text [ portuguese ] = "Para trás" ;
+ Text [ portuguese_brazilian ] = "Rücksprung" ;
+ Text[ chinese_simplified ] = "·µ»ØÒ»²½";
+ Text[ russian ] = "Øàã ñ âûõîäîì";
+ Text[ polish ] = "Krok wstecz";
+ Text[ japanese ] = "½Ã¯Ìß ÊÞ¯¸";
+ Text[ chinese_traditional ] = "ªð¦^¤@¨B";
+ Text[ arabic ] = "ÎØæÉ ááÎáÝ";
+ Text[ dutch ] = "Terugspringen";
+ Text[ chinese_simplified ] = "·µ»ØÒ»²½";
+ Text[ greek ] = "ÂÞìá ðßóù";
+ Text[ korean ] = "µÚ·Î ¶Ù¾î³Ñ±â";
+ Text[ turkish ] = "Geri adým";
+ };
+ ToolBoxItem
+ {
+ Identifier = SID_BASICIDE_TOGGLEBRKPNT ;
+ Text = "Haltepunkt" ;
+ Text [ ENGLISH ] = "Breakpoint" ;
+ Text [ norwegian ] = "Breakpoint" ;
+ Text [ italian ] = "Punto di interruzione" ;
+ Text [ portuguese_brazilian ] = "Ponto de interrupção" ;
+ Text [ portuguese ] = "Ponto de ruptura" ;
+ Text [ finnish ] = "Keskeytyskohta" ;
+ Text [ danish ] = "Pausepunkt" ;
+ Text [ french ] = "Point d'arrêt" ;
+ Text [ swedish ] = "Brytpunkt" ;
+ Text [ dutch ] = "Stoppunt" ;
+ Text [ spanish ] = "Punto de ruptura" ;
+ Text [ english_us ] = "Breakpoint" ;
+ Text[ chinese_simplified ] = "Öжϵã";
+ Text[ russian ] = "Òî÷êà îñòàíîâà";
+ Text[ polish ] = "Punkt przerwania";
+ Text[ japanese ] = "ÌÞÚ°¸Îß²ÝÄ";
+ Text[ chinese_traditional ] = "¤¤Â_ÂI";
+ Text[ arabic ] = "äÞØÉ ÅíÞÇÝ";
+ Text[ dutch ] = "Stoppunt";
+ Text[ chinese_simplified ] = "Öжϵã";
+ Text[ greek ] = "Óçìåßï äéáêïðÞò";
+ Text[ korean ] = "Áß´ÜÁ¡";
+ Text[ turkish ] = "Kesme noktasý";
+ };
+ ToolBoxItem
+ {
+ Identifier = SID_BASICIDE_ADDWATCH ;
+ Text = "Beobachter anzeigen" ;
+ Text [ ENGLISH ] = "Add watch" ;
+ Text [ dutch ] = "Bewaker weergeven" ;
+ Text [ english_us ] = "Add Watch" ;
+ Text [ italian ] = "Mostra controllo" ;
+ Text [ spanish ] = "Mostrar observador" ;
+ Text [ french ] = "Afficher l'espion" ;
+ Text [ swedish ] = "Visa bevakaren" ;
+ Text [ danish ] = "Vis observatør" ;
+ Text [ portuguese ] = "Mostrar Observador" ;
+ Text [ portuguese_brazilian ] = "Beobachter anzeigen" ;
+ Text[ chinese_simplified ] = "ÏÔʾ²é¿´";
+ Text[ russian ] = "Ïîêàçàòü êîíòðîëüíîå çíà÷åíèå";
+ Text[ polish ] = "Dodaj czujkê";
+ Text[ japanese ] = "µÌÞ»Þ°ÊÞ°‚Ì•\\ަ";
+ Text[ chinese_traditional ] = "Åã¥ÜÀ˵ø";
+ Text[ arabic ] = "ÅÙåÇÑ ÇáãÑÇÞÈ";
+ Text[ dutch ] = "Bewaker weergeven";
+ Text[ chinese_simplified ] = "ÏÔʾ²é¿´";
+ Text[ greek ] = "ÅìöÜíéóç ðáñáôçñçôÞ";
+ Text[ korean ] = "Á¶»ç½Ä Ãß°¡";
+ Text[ turkish ] = "Ýzleyici ekle";
+ };
+ ToolBoxItem
+ {
+ Type = TOOLBOXITEM_SEPARATOR ;
+ };
+ ToolBoxItem
+ {
+ Identifier = SID_BASICIDE_OBJCAT ;
+ Text = "Objektkatalog" ;
+ Text [ ENGLISH ] = "Objectcatalog" ;
+ Text [ norwegian ] = "Objectcatalog" ;
+ Text [ italian ] = "Catalogo oggetti" ;
+ Text [ portuguese_brazilian ] = "Catálogo de objetos" ;
+ Text [ portuguese ] = "Catálogo de objectos" ;
+ Text [ finnish ] = "Objektiluettelo" ;
+ Text [ danish ] = "Objektkatalog" ;
+ Text [ french ] = "Catalogue d'objets" ;
+ Text [ swedish ] = "Objektkatalog" ;
+ Text [ dutch ] = "Objectcatalogus" ;
+ Text [ spanish ] = "Catálogo de objetos" ;
+ Text [ english_us ] = "Object Catalog" ;
+ Text[ chinese_simplified ] = "¶ÔÏó·ÖÀà";
+ Text[ russian ] = "Êàòàëîã îáúåêòîâ";
+ Text[ polish ] = "Katalog obiektów";
+ Text[ japanese ] = "µÌÞ¼Þª¸Ä ¶ÀÛ¸Þ";
+ Text[ chinese_traditional ] = "ª«¥ó¤ÀÃþ";
+ Text[ arabic ] = "ßÊÇáæÌ ÇáßÇÆäÇÊ";
+ Text[ dutch ] = "Objectcatalogus";
+ Text[ chinese_simplified ] = "¶ÔÏó·ÖÀà";
+ Text[ greek ] = "ÊáôÜëïãïò áíôéêåéìÝíùí";
+ Text[ korean ] = "°³Ã¼ īŻ·Î±×";
+ Text[ turkish ] = "Nesne kataloðu";
+ };
+ ToolBoxItem
+ {
+ Identifier = SID_BASICIDE_CHOOSEMACRO ;
+ Text = "Makros" ;
+ Text [ ENGLISH ] = "Macros" ;
+ Text [ norwegian ] = "Makroer" ;
+ Text [ italian ] = "Macro" ;
+ Text [ portuguese_brazilian ] = "Macros" ;
+ Text [ portuguese ] = "Macros" ;
+ Text [ finnish ] = "Makrot" ;
+ Text [ danish ] = "Makroer" ;
+ Text [ french ] = "Macros" ;
+ Text [ swedish ] = "Makron" ;
+ Text [ dutch ] = "Macro's" ;
+ Text [ spanish ] = "Macros" ;
+ Text [ english_us ] = "Macros" ;
+ Text[ chinese_simplified ] = "ºê";
+ Text[ russian ] = "Ìàêðîñû";
+ Text[ polish ] = "Makra";
+ Text[ japanese ] = "ϸÛ";
+ Text[ chinese_traditional ] = "¥¨¶°";
+ Text[ arabic ] = "æÍÏÇÊ ÇáãÇßÑæ";
+ Text[ dutch ] = "Macro's";
+ Text[ chinese_simplified ] = "ºê";
+ Text[ greek ] = "ÌáêñïåíôïëÝò";
+ Text[ korean ] = "¸ÅÅ©·Î";
+ Text[ turkish ] = "Makrolar";
+ };
+ ToolBoxItem
+ {
+ Identifier = SID_BASICIDE_MODULEDLG ;
+ Text = "Module" ;
+ Text [ ENGLISH ] = "Modules" ;
+ Text [ norwegian ] = "Moduler" ;
+ Text [ italian ] = "Moduli" ;
+ Text [ portuguese_brazilian ] = "Módulos" ;
+ Text [ portuguese ] = "Módulos" ;
+ Text [ finnish ] = "Moduulit" ;
+ Text [ danish ] = "Moduler" ;
+ Text [ french ] = "Modules" ;
+ Text [ swedish ] = "Moduler" ;
+ Text [ dutch ] = "Module" ;
+ Text [ spanish ] = "Módulos" ;
+ Text [ english_us ] = "Modules" ;
+ Text[ chinese_simplified ] = "Ä£¿é";
+ Text[ russian ] = "Ìîäóëè";
+ Text[ polish ] = "Modu³y";
+ Text[ japanese ] = "Ó¼Þ­°Ù";
+ Text[ chinese_traditional ] = "¼Ò¶ô";
+ Text[ arabic ] = "æÍÏÉ äãØíÉ";
+ Text[ dutch ] = "Module";
+ Text[ chinese_simplified ] = "Ä£¿é";
+ Text[ greek ] = "ËåéôïõñãéêÝò ìïíÜäåò";
+ Text[ korean ] = "¸ðµâ";
+ Text[ turkish ] = "Modüller";
+ };
+ ToolBoxItem
+ {
+ Type = TOOLBOXITEM_SEPARATOR ;
+ };
+ ToolBoxItem
+ {
+ Identifier = SID_BASICIDE_MATCHGROUP ;
+ Text = "Klammer suchen" ;
+ Text [ ENGLISH ] = "Match Bracket" ;
+ Text [ norwegian ] = "Match Bracket" ;
+ Text [ italian ] = "Abbina parentesi" ;
+ Text [ portuguese_brazilian ] = "Match Bracket" ;
+ Text [ portuguese ] = "Localizar parênteses" ;
+ Text [ finnish ] = "Match Bracket" ;
+ Text [ danish ] = "Søg parentes" ;
+ Text [ french ] = "Rechercher les parenthèses" ;
+ Text [ swedish ] = "Sök parentes" ;
+ Text [ dutch ] = "Haakjes zoeken" ;
+ Text [ spanish ] = "Buscar paréntesis" ;
+ Text [ english_us ] = "Find parentheses" ;
+ Text[ chinese_simplified ] = "ËÑѰÀ¨ºÅ";
+ Text[ russian ] = "Íàéòè ñêîáêó";
+ Text[ polish ] = "Szukaj nawiasów";
+ Text[ japanese ] = "‚©‚Á‚±‚ÌŒŸõ";
+ Text[ chinese_traditional ] = "´M§ä¬A¸¹";
+ Text[ arabic ] = "ÈÍË ÃÞæÇÓ";
+ Text[ dutch ] = "Haakjes zoeken";
+ Text[ chinese_simplified ] = "ËÑѰÀ¨ºÅ";
+ Text[ greek ] = "ÁíáæÞôçóç ðáñÝíèåóçò";
+ Text[ korean ] = "°ýÈ£ ã±â";
+ Text[ turkish ] = "Ayraçlarý bul";
+ };
+ ToolBoxItem
+ {
+ Identifier = SID_CHOOSE_CONTROLS ;
+ Text = "Kontrollfelder" ;
+ Text [ ENGLISH ] = "Controls" ;
+ Text [ norwegian ] = "Kontroller" ;
+ Text [ italian ] = "Campi di controllo" ;
+ Text [ portuguese_brazilian ] = "Controles" ;
+ Text [ portuguese ] = "Campos de controlo" ;
+ Text [ finnish ] = "Ohjausobjektit" ;
+ Text [ danish ] = "Kontrolelementer" ;
+ Text [ french ] = "Eléments de contrôle" ;
+ Text [ swedish ] = "Kontrollfält" ;
+ Text [ dutch ] = "Controlevelden" ;
+ Text [ spanish ] = "Campos de control" ;
+ Text [ english_us ] = "Controls" ;
+ Text[ chinese_simplified ] = "¿ØÖÆ×Ö¶Î";
+ Text[ russian ] = "Ýëåìåíòû óïðàâëåíèÿ";
+ Text[ polish ] = "Pola kontrolne";
+ Text[ japanese ] = "ºÝÄ۰٠̨°ÙÄÞ";
+ Text[ chinese_traditional ] = "±±¨î¶µ";
+ Text[ arabic ] = "ÚäÇÕÑ ÊÍßã";
+ Text[ dutch ] = "Controlevelden";
+ Text[ chinese_simplified ] = "¿ØÖÆ×Ö¶Î";
+ Text[ greek ] = "Ðåäßá åëÝã÷ïõ";
+ Text[ korean ] = "ÄÁÆ®·Ñ";
+ Text[ turkish ] = "Komut alanlarý";
+ };
+ ToolBoxItem
+ {
+ Type = TOOLBOXITEM_SEPARATOR ;
+ };
+ ToolBoxItem
+ {
+ Identifier = SID_BASICLOAD ;
+ /* ### ACHTUNG: Neuer Text in Resource? Quelltext einfügen : Quelltext einf³gen */
+ Text = "Quelltext einfügen" ;
+ Text [ ENGLISH ] = "Insert source" ;
+ Text [ dutch ] = "Brontekst invoegen" ;
+ Text [ english_us ] = "Insert Source Text" ;
+ Text [ italian ] = "Inserisci testo sorgente" ;
+ Text [ spanish ] = "Insertar texto fuente" ;
+ Text [ french ] = "Insérer le texte source" ;
+ Text [ swedish ] = "Infoga källtext" ;
+ Text [ danish ] = "Indsæt kildetekst" ;
+ Text [ portuguese ] = "Inserir texto fonte" ;
+ Text [ portuguese_brazilian ] = "Quelltext einfügen" ;
+ Text[ chinese_simplified ] = "²åÈëÔ´Îı¾";
+ Text[ russian ] = "Âñòàâèòü èñõîäíûé òåêñò";
+ Text[ polish ] = "Wstaw tekst Ÿród³owy";
+ Text[ japanese ] = "¿°½Ã·½Ä‚Ì‘}“ü";
+ Text[ chinese_traditional ] = "´¡¤J­ì©lÀÉ";
+ Text[ arabic ] = "ÅÏÑÇÌ äÕ ãÕÏÑ";
+ Text[ dutch ] = "Brontekst invoegen";
+ Text[ chinese_simplified ] = "²åÈëÔ´Îı¾";
+ Text[ greek ] = "ÐñïóèÞêç êåéìÝíïõ ðñïÝëåõóçò";
+ Text[ korean ] = "¼Ò½º ÅØ½ºÆ® »ðÀÔ";
+ Text[ turkish ] = "Kaynak metin ekle";
+ };
+ ToolBoxItem
+ {
+ Identifier = SID_BASICSAVEAS ;
+ Text = "Quelltext speichern unter..." ;
+ Text [ ENGLISH ] = "Save source as..." ;
+ Text [ norwegian ] = "Save source as..." ;
+ Text [ italian ] = "Salva origine con nome..." ;
+ Text [ portuguese_brazilian ] = "Gravar origem como..." ;
+ Text [ portuguese ] = "Guardar texto-fonte como..." ;
+ Text [ finnish ] = "Tallenna lähde nimellä..." ;
+ Text [ danish ] = "Gem kildetekst som..." ;
+ Text [ french ] = "Enregistrer le texte source sous..." ;
+ Text [ swedish ] = "Spara källtext som..." ;
+ Text [ dutch ] = "Brontekst opslaan als..." ;
+ Text [ spanish ] = "Guardar texto fuente como..." ;
+ Text [ english_us ] = "Save Source As..." ;
+ Text[ greek ] = "ÁðïèÞêåõóç êåéìÝíïõ ðñïÝëåõóçò ùò...";
+ Text[ dutch ] = "Brontekst opslaan als...";
+ Text[ russian ] = "Èñõîäíûé òåêñò ñîõðàíèòü êàê...";
+ Text[ polish ] = "Zapisz tekst Ÿród³owy jako...";
+ Text[ japanese ] = "¿°½‚É–¼‘O‚ð‚‚¯‚ĕۑ¶...";
+ Text[ korean ] = "¼Ò½º¸¦ ´Ù¸¥ À̸§À¸·Î ÀúÀå...";
+ Text[ chinese_simplified ] = "Ô´Îı¾Áí´æÎª...";
+ Text[ chinese_traditional ] = "¥t¦s­ì©lÀÉ...";
+ Text[ arabic ] = "ÍÝÙ äÕ ÇáãÕÏÑ ÈÇÓã...";
+ Text[ turkish ] = "Kaynak metni farklý kaydet...";
+ };
+ };
+ Text[ chinese_simplified ] = "BASIC";
+ Text[ russian ] = "BASIC";
+ Text[ polish ] = "BASIC";
+ Text[ japanese ] = "BASIC";
+ Text[ chinese_traditional ] = "BASIC";
+ Text[ arabic ] = "BASIC";
+ Text[ dutch ] = "BASIC";
+ Text[ chinese_simplified ] = "BASIC";
+ Text[ greek ] = "BASIC";
+ Text[ korean ] = "BASIC";
+ Text[ turkish ] = "BASIC";
+};
+
+Menu RID_POPUP_BRKPROPS
+{
+ Text = "Eigenschaften" ;
+ Text [ ENGLISH ] = "Properties" ;
+ Text [ norwegian ] = "Egenskaper" ;
+ Text [ italian ] = "Proprietà" ;
+ Text [ portuguese_brazilian ] = "Propriedades" ;
+ Text [ portuguese ] = "Propriedades" ;
+ Text [ finnish ] = "Ominaisuudet" ;
+ Text [ danish ] = "Egenskaber" ;
+ Text [ french ] = "Propriétés" ;
+ Text [ swedish ] = "Egenskaper" ;
+ Text [ dutch ] = "Eigenschappen" ;
+ Text [ spanish ] = "Propiedades" ;
+ Text [ english_us ] = "Properties" ;
+ DefaultItemId = RID_BRKPROPS ;
+ ItemList =
+ {
+ MenuItem
+ {
+ Identifier = RID_ACTIV ;
+ HelpId = HID_BASICIDE_ACTIV ;
+ Text = "Aktiv" ;
+ Text [ ENGLISH ] = "Active" ;
+ Text [ norwegian ] = "Active" ;
+ Text [ italian ] = "Attivo" ;
+ Text [ portuguese_brazilian ] = "Ativo" ;
+ Text [ portuguese ] = "Activo" ;
+ Text [ finnish ] = "Aktiivinen" ;
+ Text [ danish ] = "Aktiv" ;
+ Text [ french ] = "Actif" ;
+ Text [ swedish ] = "Aktiv" ;
+ Text [ dutch ] = "Actief" ;
+ Text [ spanish ] = "Activo" ;
+ Text [ english_us ] = "Active" ;
+ Text[ chinese_simplified ] = "¼¤»î";
+ Text[ russian ] = "Àêòèâíûé";
+ Text[ polish ] = "Aktywny";
+ Text[ japanese ] = "±¸Ã¨ÌÞ";
+ Text[ chinese_traditional ] = "¿E¬¡";
+ Text[ arabic ] = "äÔØ";
+ Text[ dutch ] = "Actief";
+ Text[ chinese_simplified ] = "¼¤»î";
+ Text[ greek ] = "ÅíåñãÜ";
+ Text[ korean ] = "Ȱ¼º";
+ Text[ turkish ] = "Etkin";
+ };
+ MenuItem
+ {
+ Separator = TRUE ;
+ };
+ MenuItem
+ {
+ Identifier = RID_BRKPROPS ;
+ HelpId = HID_BASICIDE_BRKPROPS ;
+ Text = "Eigenschaften..." ;
+ Text [ ENGLISH ] = "Properties..." ;
+ Text [ norwegian ] = "Properties..." ;
+ Text [ italian ] = "Proprietà..." ;
+ Text [ portuguese_brazilian ] = "Propriedades..." ;
+ Text [ portuguese ] = "Propriedades..." ;
+ Text [ finnish ] = "Ominaisuudet..." ;
+ Text [ danish ] = "Egenskaber..." ;
+ Text [ french ] = "Propriétés..." ;
+ Text [ swedish ] = "Egenskaper..." ;
+ Text [ dutch ] = "Eigenschappen..." ;
+ Text [ spanish ] = "Propiedades..." ;
+ Text [ english_us ] = "Propert~ies..." ;
+ /* ### ACHTUNG: Neuer Text in Resource? Einstellungen für den Haltepunkt : Einstellungen f³r den Haltepunkt */
+ Text[ chinese_simplified ] = "ÊôÐÔ(~I)...";
+ Text[ russian ] = "Ñâîéñòâà...";
+ Text[ polish ] = "W³aœciwoœci...";
+ Text[ japanese ] = "ÌßÛÊßè(~I)...";
+ Text[ chinese_traditional ] = "ÄÝ©Ê(~I)...";
+ Text[ arabic ] = "...ÎÕÇÆÕ";
+ Text[ dutch ] = "Eigenschappen...";
+ Text[ chinese_simplified ] = "ÊôÐÔ(~I)...";
+ Text[ greek ] = "Éäéüôçôåò...";
+ Text[ korean ] = "µî·ÏÁ¤º¸(~I)...";
+ Text[ turkish ] = "Özellikler...";
+ };
+ };
+ Text[ chinese_simplified ] = "ÊôÐÔ";
+ Text[ russian ] = "Ñâîéñòâà";
+ Text[ polish ] = "W³aœciwoœci";
+ Text[ japanese ] = "ÌßÛÊßè";
+ Text[ chinese_traditional ] = "ÄÝ©Ê";
+ Text[ arabic ] = "ÎÕÇÆÕ";
+ Text[ dutch ] = "Eigenschappen";
+ Text[ chinese_simplified ] = "ÊôÐÔ";
+ Text[ greek ] = "Éäéüôçôåò";
+ Text[ korean ] = "µî·ÏÁ¤º¸";
+ Text[ turkish ] = "Özellikler";
+};
+Menu RID_POPUP_BRKDLG
+{
+ Text = "Haltepunkte" ;
+ Text [ ENGLISH ] = "Breakpoints" ;
+ Text [ norwegian ] = "Breakpoints" ;
+ Text [ italian ] = "Punti di interruzione" ;
+ Text [ portuguese_brazilian ] = "Pontos de interrupção" ;
+ Text [ portuguese ] = "Pontos de interrupção" ;
+ Text [ finnish ] = "Keskeytyskohdat" ;
+ Text [ danish ] = "Pausepunkter" ;
+ Text [ french ] = "Points d'arrêt" ;
+ Text [ swedish ] = "Brytpunkter" ;
+ Text [ dutch ] = "Stoppunten" ;
+ Text [ spanish ] = "Puntos de ruptura" ;
+ Text [ english_us ] = "Breakpoints" ;
+ ItemList =
+ {
+ MenuItem
+ {
+ Identifier = RID_BRKDLG ;
+ HelpId = HID_BASICIDE_BRKDLG ;
+ Text = "Haltepunkte..." ;
+ Text [ ENGLISH ] = "Breakpoints..." ;
+ Text [ norwegian ] = "Breakpoints..." ;
+ Text [ italian ] = "Punti di interruzione..." ;
+ Text [ portuguese_brazilian ] = "Pontos de interrupção..." ;
+ Text [ portuguese ] = "Pontos de interrupção..." ;
+ Text [ finnish ] = "Keskeytyskohdat..." ;
+ Text [ danish ] = "Pausepunkter..." ;
+ Text [ french ] = "Points d'arrêt..." ;
+ Text [ swedish ] = "Brytpunkter..." ;
+ Text [ dutch ] = "Stoppunten..." ;
+ Text [ spanish ] = "Puntos de ruptura..." ;
+ Text [ english_us ] = "Breakpoints..." ;
+ /* ### ACHTUNG: Neuer Text in Resource? Dialog für die Haltepunkte : Dialog f³r die Haltepunkte */
+ Text[ chinese_simplified ] = "Öжϵã...";
+ Text[ russian ] = "Òî÷êè îñòàíîâà...";
+ Text[ polish ] = "Punkty przerwania...";
+ Text[ japanese ] = "ÌÞÚ°¸Îß²ÝÄ...";
+ Text[ chinese_traditional ] = "¤¤Â_ÂI...";
+ Text[ arabic ] = "...äÞÇØ ÇáÅíÞÇÝ";
+ Text[ dutch ] = "Stoppunten...";
+ Text[ chinese_simplified ] = "Öжϵã...";
+ Text[ greek ] = "Óçìåßá äéáêïðÞò...";
+ Text[ korean ] = "Áß´ÜÁ¡...";
+ Text[ turkish ] = "Kesme noktalarý...";
+ };
+ };
+ Text[ chinese_simplified ] = "Öжϵã";
+ Text[ russian ] = "Òî÷êà îñòàíîâà";
+ Text[ polish ] = "Punkty przerwania";
+ Text[ japanese ] = "ÌÞÚ°¸Îß²ÝÄ";
+ Text[ chinese_traditional ] = "¤¤Â_ÂI";
+ Text[ arabic ] = "äÞÇØ ÇáÅíÞÇÝ";
+ Text[ dutch ] = "Stoppunten";
+ Text[ chinese_simplified ] = "Öжϵã";
+ Text[ greek ] = "Óçìåßá äéáêïðÞò";
+ Text[ korean ] = "Áß´ÜÁ¡";
+ Text[ turkish ] = "Kesme noktalarý";
+};
+Menu RID_POPUP_TABBAR
+{
+ DefaultItemId = SID_BASICIDE_HIDECURPAGE ;
+ ItemList =
+ {
+ MenuItem
+ {
+ /* ### ACHTUNG: Neuer Text in Resource? Einfügen : Einf³gen */
+ Text = "Einfügen" ;
+ Text [ ENGLISH ] = "Insert" ;
+ Text [ norwegian ] = "Sett inn" ;
+ Text [ italian ] = "Inserisci" ;
+ Text [ portuguese_brazilian ] = "Inserir" ;
+ Text [ portuguese ] = "Inserir" ;
+ Text [ finnish ] = "Lisää" ;
+ Text [ danish ] = "Indsæt" ;
+ Text [ french ] = "Insérer" ;
+ Text [ swedish ] = "Infoga" ;
+ Text [ dutch ] = "Invoegen" ;
+ Text [ spanish ] = "Insertar" ;
+ Text [ english_us ] = "Insert" ;
+ Submenu = Menu
+ {
+ ItemList =
+ {
+ MenuItem
+ {
+ Identifier = SID_BASICIDE_NEWMODULE ;
+ HelpId = SID_BASICIDE_NEWMODULE ;
+ Text = "BASIC-Modul" ;
+ Text [ ENGLISH ] = "BASIC module" ;
+ Text [ english_us ] = "BASIC Module" ;
+ Text [ portuguese_brazilian ] = "Módulo" ;
+ Text [ swedish ] = "BASIC-modul" ;
+ Text [ danish ] = "BASIC-modul" ;
+ Text [ italian ] = "Modulo BASIC" ;
+ Text [ spanish ] = "Módulo BASIC" ;
+ Text [ french ] = "Module BASIC" ;
+ Text [ dutch ] = "BASIC-module" ;
+ Text [ portuguese ] = "Módulo BASIC" ;
+ Text[ chinese_simplified ] = "BASIC Ä£¿é";
+ Text[ russian ] = "Ìîäóëü BASIC";
+ Text[ polish ] = "Modu³ BASIC";
+ Text[ japanese ] = "BASICÓ¼Þ­°Ù";
+ Text[ chinese_traditional ] = "BASIC ¼Ò¶ô";
+ Text[ arabic ] = "äãØíÉ BASIC æÍÏÉ";
+ Text[ dutch ] = "BASIC-module";
+ Text[ chinese_simplified ] = "BASIC Ä£¿é";
+ Text[ greek ] = "ËåéôïõñãéêÞ ìïíÜäá BASIC";
+ Text[ korean ] = "BASIC ¸ðµâ";
+ Text[ turkish ] = "BASIC modülü";
+ };
+ MenuItem
+ {
+ Identifier = SID_BASICIDE_NEWDIALOG ;
+ HelpId = SID_BASICIDE_NEWDIALOG ;
+ Text = "BASIC-Dialog" ;
+ Text [ ENGLISH ] = "BASIC dialog" ;
+ Text [ english_us ] = "BASIC Dialog" ;
+ Text [ portuguese_brazilian ] = "Diálogo" ;
+ Text [ swedish ] = "BASIC-dialog" ;
+ Text [ danish ] = "BASIC-dialog" ;
+ Text [ italian ] = "Dialogo BASIC" ;
+ Text [ spanish ] = "Diálogo BASIC" ;
+ Text [ french ] = "Boîte de dialogue BASIC" ;
+ Text [ dutch ] = "BASIC-dialoog" ;
+ Text [ portuguese ] = "Diálogo BASIC" ;
+ Text[ chinese_simplified ] = "BASIC ¶Ô»°¿ò";
+ Text[ russian ] = "Äèàëîã BASIC";
+ Text[ polish ] = "Dialog BASIC";
+ Text[ japanese ] = "BASICÀÞ²±Û¸Þ";
+ Text[ chinese_traditional ] = "BASIC ¹ï¸Ü¤è¶ô";
+ Text[ arabic ] = "ãÑÈÚ ÍæÇÑBASIC ";
+ Text[ dutch ] = "BASIC-dialoog";
+ Text[ chinese_simplified ] = "BASIC ¶Ô»°¿ò";
+ Text[ greek ] = "ÄéÜëïãïò BASIC";
+ Text[ korean ] = "BASIC ´ëÈ­»óÀÚ";
+ Text[ turkish ] = "BASIC diyaloðu";
+ };
+ };
+ };
+ /* ### ACHTUNG: Neuer Text in Resource? Modul oder Dialog einfügen : Modul oder Dialog einf³gen */
+ Text[ chinese_simplified ] = "²åÈë";
+ Text[ russian ] = "Âñòàâèòü";
+ Text[ polish ] = "Wstaw";
+ Text[ japanese ] = "‘}“ü";
+ Text[ chinese_traditional ] = "´¡¤J";
+ Text[ arabic ] = "ÅÏÑÇÌ";
+ Text[ dutch ] = "Invoegen";
+ Text[ chinese_simplified ] = "²åÈë";
+ Text[ greek ] = "ÅéóáãùãÞ";
+ Text[ korean ] = "»ðÀÔ";
+ Text[ turkish ] = "Ekle";
+ };
+ MenuItem
+ {
+ Identifier = SID_BASICIDE_DELETECURRENT ;
+ HelpId = SID_BASICIDE_DELETECURRENT ;
+ /* ### ACHTUNG: Neuer Text in Resource? Löschen : L÷schen */
+ Text = "Löschen" ;
+ Text [ ENGLISH ] = "Delete" ;
+ Text [ norwegian ] = "Slett" ;
+ Text [ italian ] = "Cancella" ;
+ Text [ portuguese_brazilian ] = "Apagar" ;
+ Text [ portuguese ] = "Eliminar" ;
+ Text [ finnish ] = "Poista" ;
+ Text [ danish ] = "Slet" ;
+ Text [ french ] = "Supprimer" ;
+ Text [ swedish ] = "Radera" ;
+ Text [ dutch ] = "Wissen" ;
+ Text [ spanish ] = "Eliminar" ;
+ Text [ english_us ] = "Delete" ;
+ /* ### ACHTUNG: Neuer Text in Resource? Modul oder Dialog löschen : Modul oder Dialog l÷schen */
+ Text[ chinese_simplified ] = "ɾ³ý";
+ Text[ russian ] = "Óäàëèòü";
+ Text[ polish ] = "Usuñ";
+ Text[ japanese ] = "íœ";
+ Text[ chinese_traditional ] = "§R°£";
+ Text[ arabic ] = "ÍÐÝ";
+ Text[ dutch ] = "Wissen";
+ Text[ chinese_simplified ] = "ɾ³ý";
+ Text[ greek ] = "ÄéáãñáöÞ";
+ Text[ korean ] = "»èÁ¦";
+ Text[ turkish ] = "Sil";
+ };
+ MenuItem
+ {
+ Identifier = SID_BASICIDE_RENAMECURRENT ;
+ HelpId = SID_BASICIDE_RENAMECURRENT ;
+ Text = "Umbenennen" ;
+ Text [ ENGLISH ] = "Rename" ;
+ Text [ norwegian ] = "Gi nytt navn til" ;
+ Text [ italian ] = "Rinomina" ;
+ Text [ portuguese_brazilian ] = "Renomear" ;
+ Text [ portuguese ] = "Mudar nome" ;
+ Text [ finnish ] = "Nimeä" ;
+ Text [ danish ] = "Omdøb" ;
+ Text [ french ] = "Renommer" ;
+ Text [ swedish ] = "Byt namn" ;
+ Text [ dutch ] = "Naam wijzigen" ;
+ Text [ spanish ] = "Cambiar nombre" ;
+ Text [ english_us ] = "Rename" ;
+ Text[ chinese_simplified ] = "ÖØÃüÃû";
+ Text[ russian ] = "Ïåðåèìåíîâàòü";
+ Text[ polish ] = "Zmieñ nazwê";
+ Text[ japanese ] = "–¼‘O‚Ì•ÏX";
+ Text[ chinese_traditional ] = "­«·s©R¦W";
+ Text[ arabic ] = "ÅÚÇÏÉ ÊÓãíÉ";
+ Text[ dutch ] = "Naam wijzigen";
+ Text[ chinese_simplified ] = "ÖØÃüÃû";
+ Text[ greek ] = "Ìåôïíïìáóßá";
+ Text[ korean ] = "À̸§ º¯°æ";
+ Text[ turkish ] = "Yeniden adlandýr";
+ };
+ MenuItem
+ {
+ Identifier = SID_BASICIDE_HIDECURPAGE ;
+ HelpId = SID_BASICIDE_HIDECURPAGE ;
+ Text = "Ausblenden" ;
+ Text [ ENGLISH ] = "Hide" ;
+ Text [ norwegian ] = "Hide" ;
+ Text [ italian ] = "Nascondi" ;
+ Text [ portuguese_brazilian ] = "Ocultar" ;
+ Text [ portuguese ] = "Ocultar" ;
+ Text [ finnish ] = "Piilota" ;
+ Text [ danish ] = "Skjul" ;
+ Text [ french ] = "Masquer" ;
+ Text [ swedish ] = "Dölj" ;
+ Text [ dutch ] = "Verbergen" ;
+ Text [ spanish ] = "Ocultar" ;
+ Text [ english_us ] = "Hide" ;
+ Text[ chinese_simplified ] = "ÒþÈë";
+ Text[ russian ] = "Ñêðûòü";
+ Text[ polish ] = "Ukryj";
+ Text[ japanese ] = "”ñ•\\ަ";
+ Text[ chinese_traditional ] = "Áô¤J";
+ Text[ arabic ] = "ÅÎÝÇÁ";
+ Text[ dutch ] = "Verbergen";
+ Text[ chinese_simplified ] = "ÒþÈë";
+ Text[ greek ] = "Áðüêñõøç";
+ Text[ korean ] = "¼û±â±â";
+ Text[ turkish ] = "Gizle";
+ };
+ MenuItem
+ {
+ Separator = TRUE ;
+ };
+ MenuItem
+ {
+ Identifier = SID_BASICIDE_MODULEDLG ;
+ HelpId = SID_BASICIDE_MODULEDLG ;
+ Text = "Module..." ;
+ Text [ ENGLISH ] = "Modules..." ;
+ Text [ norwegian ] = "Modules..." ;
+ Text [ italian ] = "Moduli..." ;
+ Text [ portuguese_brazilian ] = "Módulos..." ;
+ Text [ portuguese ] = "Módulos..." ;
+ Text [ finnish ] = "Moduulit..." ;
+ Text [ danish ] = "Moduler..." ;
+ Text [ french ] = "Modules..." ;
+ Text [ swedish ] = "Moduler..." ;
+ Text [ dutch ] = "Modules..." ;
+ Text [ spanish ] = "Módulos..." ;
+ Text [ english_us ] = "Modules..." ;
+ Text[ chinese_simplified ] = "Ä£¿é...";
+ Text[ russian ] = "Ìîäóëè...";
+ Text[ polish ] = "Modu³y...";
+ Text[ japanese ] = "Ó¼Þ­°Ù...";
+ Text[ chinese_traditional ] = "¼Ò¶ô...";
+ Text[ arabic ] = "...æÍÏÇÊ äãØíÉ";
+ Text[ dutch ] = "Modules...";
+ Text[ chinese_simplified ] = "Ä£¿é...";
+ Text[ greek ] = "ËåéôïõñãéêÝò ìïíÜäåò...";
+ Text[ korean ] = "¸ðµâ...";
+ Text[ turkish ] = "Modüller...";
+ };
+ };
+};
+ImageList RID_IMGLST_OBJECTS
+{
+ ImageBitmap = Bitmap { FILE = "images.bmp" ; };
+ MaskColor = Color { Red = 0xFFFF ; Green = 0xFFFF ; Blue = 0xFFFF ; };
+ IdList =
+ {
+ IMGID_APPICON ;
+ IMGID_LIB ;
+ IMGID_MODULE ;
+ IMGID_MACRO ;
+ IMGID_OBJECT ;
+ IMGID_SUBOBJ ;
+ IMGID_PROP ;
+ IMGID_DOCUMENT ;
+ IMGID_LIBNOTLOADED ;
+ };
+};
+ImageList RID_IMGLST_LAYOUT
+{
+ ImageBitmap = Bitmap { FILE = "images2.bmp" ; };
+ MaskColor = Color { Red = 0xFFFF ; Green = 0xFFFF ; Blue = 0xFFFF ; };
+ IdList =
+ {
+ IMGID_BRKENABLED ;
+ IMGID_BRKDISABLED ;
+ IMGID_STEPMARKER ;
+ IMGID_ERRORMARKER ;
+ };
+};
+Image RID_IMG_MARKER
+{
+ ImageBitmap = Bitmap { File = "basstep.bmp" ; };
+ MaskColor = Color { Red = 0xFFFF ; Green = 0xFFFF ; Blue = 0xFFFF ; };
+};
+Image RID_IMG_LOCKED
+{
+ ImageBitmap = Bitmap { File = "locked.bmp" ; };
+ MaskColor = Color { Red = 0xFFFF ; Green = 0xFFFF ; Blue = 0xFFFF ; };
+};
diff --git a/basctl/source/basicide/basobj2.cxx b/basctl/source/basicide/basobj2.cxx
new file mode 100644
index 000000000000..6a356fc1a889
--- /dev/null
+++ b/basctl/source/basicide/basobj2.cxx
@@ -0,0 +1,201 @@
+/*************************************************************************
+ *
+ * $RCSfile: basobj2.cxx,v $
+ *
+ * $Revision: 1.1.1.1 $
+ *
+ * last change: $Author: mh $ $Date: 2000-09-29 11:02:36 $
+ *
+ * The Contents of this file are made available subject to the terms of
+ * either of the following licenses
+ *
+ * - GNU Lesser General Public License Version 2.1
+ * - Sun Industry Standards Source License Version 1.1
+ *
+ * Sun Microsystems Inc., October, 2000
+ *
+ * GNU Lesser General Public License Version 2.1
+ * =============================================
+ * Copyright 2000 by Sun Microsystems, Inc.
+ * 901 San Antonio Road, Palo Alto, CA 94303, USA
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License version 2.1, as published by the Free Software Foundation.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this library; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston,
+ * MA 02111-1307 USA
+ *
+ *
+ * Sun Industry Standards Source License Version 1.1
+ * =================================================
+ * The contents of this file are subject to the Sun Industry Standards
+ * Source License Version 1.1 (the "License"); You may not use this file
+ * except in compliance with the License. You may obtain a copy of the
+ * License at http://www.openoffice.org/license.html.
+ *
+ * Software provided under this License is provided on an "AS IS" basis,
+ * WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING,
+ * WITHOUT LIMITATION, WARRANTIES THAT THE SOFTWARE IS FREE OF DEFECTS,
+ * MERCHANTABLE, FIT FOR A PARTICULAR PURPOSE, OR NON-INFRINGING.
+ * See the License for the specific provisions governing your rights and
+ * obligations concerning the Software.
+ *
+ * The Initial Developer of the Original Code is: Sun Microsystems, Inc.
+ *
+ * Copyright: 2000 by Sun Microsystems, Inc.
+ *
+ * All Rights Reserved.
+ *
+ * Contributor(s): _______________________________________
+ *
+ *
+ ************************************************************************/
+
+
+#include <ide_pch.hxx>
+
+#pragma hdrstop
+
+#ifndef _SBXCLASS_HXX //autogen
+#include <svtools/sbx.hxx>
+#endif
+#include <basobj.hxx>
+#include <iderdll.hxx>
+#include <iderdll2.hxx>
+#include <iderid.hxx>
+#include <macrodlg.hxx>
+#include <moduldlg.hxx>
+#include <basidesh.hxx>
+
+SfxMacro* BasicIDE::CreateMacro()
+{
+ DBG_ERROR( "BasicIDE::CreateMacro() - war eigentlich nur fuer Macro-Recording!" );
+ IDE_DLL()->GetExtraData()->ChoosingMacro() = TRUE;
+ SFX_APP()->EnterBasicCall();
+ Window* pParent = Application::GetDefDialogParent();
+ SfxMacro* pMacro = 0;
+ MacroChooser* pChooser = new MacroChooser( pParent, TRUE );
+ Window* pOldModalDialogParent = Application::GetDefDialogParent();
+ Application::SetDefDialogParent( pChooser );
+// pChooser->SetMode( MACROCHOOSER_RECORDING );
+ short nRetValue = pChooser->Execute();
+
+ Application::SetDefDialogParent( pOldModalDialogParent );
+ delete pChooser;
+
+ SFX_APP()->LeaveBasicCall();
+ IDE_DLL()->GetExtraData()->ChoosingMacro() = FALSE;
+
+ return pMacro;
+}
+
+SbMethod* BasicIDE::ChooseMacro( BOOL bExecute, BOOL bChooseOnly )
+{
+ IDE_DLL()->GetExtraData()->ChoosingMacro() = TRUE;
+ SFX_APP()->EnterBasicCall();
+
+ SbMethod* pMethod = NULL;
+
+ Window* pParent = Application::GetDefDialogParent();
+
+ MacroChooser* pChooser = new MacroChooser( pParent, TRUE );
+ if ( bChooseOnly || !SFX_APP()->HasFeature( SFX_FEATURE_BASIC_IDE ) )
+ pChooser->SetMode( MACROCHOOSER_CHOOSEONLY );
+
+ short nRetValue = pChooser->Execute();
+
+ IDE_DLL()->GetExtraData()->ChoosingMacro() = FALSE;
+
+ switch ( nRetValue )
+ {
+ case MACRO_OK_RUN:
+ {
+ pMethod = pChooser->GetMacro();
+ if ( pMethod && bExecute )
+ {
+ pMethod->AddRef(); // festhalten, bis Event abgearbeitet.
+ Application::PostUserEvent( LINK( IDE_DLL()->GetExtraData(), BasicIDEData, ExecuteMacroEvent ), pMethod );
+ }
+ }
+ break;
+ }
+
+ delete pChooser;
+
+ SFX_APP()->LeaveBasicCall();
+
+ return pMethod;
+}
+
+SbMethod* BasicIDE::ChooseMacro( BOOL bExecute, BOOL bChooseOnly, const String& rPreferredMacroDesciption )
+{
+ if ( rPreferredMacroDesciption.Len() )
+ IDE_DLL()->GetExtraData()->GetLastMacro() = rPreferredMacroDesciption;
+ return BasicIDE::ChooseMacro( bExecute, bChooseOnly );
+}
+
+void BasicIDE::Organize()
+{
+ Window* pParent = Application::GetDefDialogParent();
+ OrganizeDialog* pDlg = new OrganizeDialog( pParent );
+ if ( IDE_DLL()->GetShell() )
+ {
+ IDEBaseWindow* pWin = IDE_DLL()->GetShell()->GetCurWindow();
+ if ( pWin )
+ pDlg->SetCurrentModule( pWin->CreateSbxDescription() );
+ }
+ pDlg->Execute();
+ delete pDlg;
+}
+
+
+
+BOOL BasicIDE::IsValidSbxName( const String& rName )
+{
+ for ( USHORT nChar = 0; nChar < rName.Len(); nChar++ )
+ {
+ BOOL bValid = ( ( rName.GetChar(nChar) >= 'A' && rName.GetChar(nChar) <= 'Z' ) ||
+ ( rName.GetChar(nChar) >= 'a' && rName.GetChar(nChar) <= 'z' ) ||
+ ( rName.GetChar(nChar) >= '0' && rName.GetChar(nChar) <= '9' && nChar ) ||
+ ( rName.GetChar(nChar) == '_' ) );
+ if ( !bValid )
+ return FALSE;
+ }
+ return TRUE;
+}
+
+
+
+SbMethod* BasicIDE::FindMacro( SbModule* pModule, const String& rMacroName )
+{
+ return (SbMethod*)pModule->GetMethods()->Find( rMacroName, SbxCLASS_METHOD );
+}
+
+SbModule* BasicIDE::FindModule( StarBASIC* pBasic, const String& rModName )
+{
+ return pBasic->FindModule( rModName );
+}
+
+USHORT BasicIDE::GetBasicDialogCount()
+{
+ return IDE_DLL()->GetExtraData()->GetBasicDialogCount();
+}
+
+void BasicIDE::IncBasicDialogCount()
+{
+ IDE_DLL()->GetExtraData()->IncBasicDialogCount();
+}
+
+void BasicIDE::DecBasicDialogCount()
+{
+ DBG_ASSERT( GetBasicDialogCount(), "DecBasicDialogCount() - Count allready 0!" );
+ IDE_DLL()->GetExtraData()->DecBasicDialogCount();
+}
diff --git a/basctl/source/basicide/basobj3.cxx b/basctl/source/basicide/basobj3.cxx
new file mode 100644
index 000000000000..80bb16aee1ae
--- /dev/null
+++ b/basctl/source/basicide/basobj3.cxx
@@ -0,0 +1,531 @@
+/*************************************************************************
+ *
+ * $RCSfile: basobj3.cxx,v $
+ *
+ * $Revision: 1.1.1.1 $
+ *
+ * last change: $Author: mh $ $Date: 2000-09-29 11:02:36 $
+ *
+ * The Contents of this file are made available subject to the terms of
+ * either of the following licenses
+ *
+ * - GNU Lesser General Public License Version 2.1
+ * - Sun Industry Standards Source License Version 1.1
+ *
+ * Sun Microsystems Inc., October, 2000
+ *
+ * GNU Lesser General Public License Version 2.1
+ * =============================================
+ * Copyright 2000 by Sun Microsystems, Inc.
+ * 901 San Antonio Road, Palo Alto, CA 94303, USA
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License version 2.1, as published by the Free Software Foundation.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this library; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston,
+ * MA 02111-1307 USA
+ *
+ *
+ * Sun Industry Standards Source License Version 1.1
+ * =================================================
+ * The contents of this file are subject to the Sun Industry Standards
+ * Source License Version 1.1 (the "License"); You may not use this file
+ * except in compliance with the License. You may obtain a copy of the
+ * License at http://www.openoffice.org/license.html.
+ *
+ * Software provided under this License is provided on an "AS IS" basis,
+ * WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING,
+ * WITHOUT LIMITATION, WARRANTIES THAT THE SOFTWARE IS FREE OF DEFECTS,
+ * MERCHANTABLE, FIT FOR A PARTICULAR PURPOSE, OR NON-INFRINGING.
+ * See the License for the specific provisions governing your rights and
+ * obligations concerning the Software.
+ *
+ * The Initial Developer of the Original Code is: Sun Microsystems, Inc.
+ *
+ * Copyright: 2000 by Sun Microsystems, Inc.
+ *
+ * All Rights Reserved.
+ *
+ * Contributor(s): _______________________________________
+ *
+ *
+ ************************************************************************/
+
+
+#include <ide_pch.hxx>
+
+#pragma hdrstop
+
+#ifndef _SBXCLASS_HXX //autogen
+#include <svtools/sbx.hxx>
+#endif
+#define _SVSTDARR_STRINGS
+#include <svtools/svstdarr.hxx>
+#include <iderdll.hxx>
+#include <iderid.hxx>
+#include <basobj.hxx>
+#include <basidesh.hxx>
+#include <basidesh.hrc>
+#include <objdlg.hxx>
+#include <bastypes.hxx>
+
+#include <baside2.hxx>
+
+
+// In bastype3.cxx:
+USHORT GetDialogSbxId();
+
+#define LINE_SEP 0x0A
+
+SbMethod* BasicIDE::CreateMacro( SbModule* pModule, const String& rMacroName )
+{
+ SfxViewFrame* pCurFrame = SfxViewFrame::Current();
+ DBG_ASSERT( pCurFrame != NULL, "No current view frame!" );
+ SfxDispatcher* pDispatcher = pCurFrame ? pCurFrame->GetDispatcher() : NULL;
+ if( pDispatcher )
+ {
+ pDispatcher->Execute( SID_BASICIDE_STOREALLMODULESOURCES );
+ }
+
+ if ( pModule->GetMethods()->Find( rMacroName, SbxCLASS_METHOD ) )
+ return 0;
+
+ String aMacroName( rMacroName );
+ if ( aMacroName.Len() == 0 )
+ {
+ if ( !pModule->GetMethods()->Count() )
+ aMacroName = String( RTL_CONSTASCII_USTRINGPARAM( "Main" ) );
+ else
+ {
+ BOOL bValid = FALSE;
+ String aStdMacroText( IDEResId( RID_STR_STDMACRONAME ) );
+ USHORT nMacro = 1;
+ while ( !bValid )
+ {
+ aMacroName = aStdMacroText;
+ aMacroName += String::CreateFromInt32( nMacro );
+ // Pruefen, ob vorhanden...
+ bValid = pModule->GetMethods()->Find( aMacroName, SbxCLASS_METHOD ) ? FALSE : TRUE;
+ nMacro++;
+ }
+ }
+ }
+
+ String aSource( pModule->GetSource() );
+ aSource.ConvertLineEnd( LINEEND_LF );
+
+ // Nicht zu viele Leerzeilen erzeugen...
+ if ( aSource.Len() > 2 )
+ {
+ if ( aSource.GetChar( aSource.Len() - 1 ) != LINE_SEP )
+ aSource += String( RTL_CONSTASCII_USTRINGPARAM( "\n\n" ) );
+ else if ( aSource.GetChar( aSource.Len() - 2 ) != LINE_SEP )
+ aSource += String( RTL_CONSTASCII_USTRINGPARAM( "\n" ) );
+ else if ( aSource.GetChar( aSource.Len() - 3 ) == LINE_SEP )
+ aSource.Erase( (USHORT)(aSource.Len()-1), 1 );
+ }
+
+ String aSubStr;
+ aSubStr = String( RTL_CONSTASCII_USTRINGPARAM( "Sub " ) );
+ aSubStr += aMacroName;
+ aSubStr += String( RTL_CONSTASCII_USTRINGPARAM( "\n\nEnd Sub" ) );
+
+ aSource += aSubStr;
+ pModule->SetSource( aSource );
+// SbxObject* pObject = pModule->GetParent();
+// DBG_ASSERT( pObject->ISA( StarBASIC ), "Kein Basic! (GetParent)" );
+// ((StarBASIC*)pObject)->Compile( pModule );
+ SbMethod* pMethod = (SbMethod*)pModule->GetMethods()->Find( aMacroName, SbxCLASS_METHOD );
+ if( pDispatcher )
+ {
+ pDispatcher->Execute( SID_BASICIDE_UPDATEALLMODULESOURCES );
+ }
+ SbxObject* pParent = pModule->GetParent();
+ if ( pParent && pParent->ISA( StarBASIC ) )
+ BasicIDE::MarkDocShellModified( (StarBASIC*)pParent );
+ return pMethod;
+}
+
+String BasicIDE::CreateDialogName( StarBASIC* pBasic, const String& rDlgName )
+{
+ String aDlgName( rDlgName );
+ if ( aDlgName.Len() == 0 )
+ {
+ String aDlgStdName( IDEResId( RID_STR_STDDIALOGNAME ) );
+ BOOL bValid = FALSE;
+ USHORT i = 1;
+ while ( !bValid )
+ {
+ aDlgName = aDlgStdName;
+ aDlgName += String::CreateFromInt32( i );
+ if ( !BasicIDE::FindDialog( pBasic, aDlgName ) )
+ bValid = TRUE;
+
+ i++;
+ }
+ }
+ return aDlgName;
+}
+
+SbxObject* BasicIDE::CreateDialog( StarBASIC* pBasic, const String& rDlgName )
+{
+ String aDlgName = CreateDialogName( pBasic, rDlgName );
+ SbxObject* pDlg = pBasic->MakeObject( aDlgName, String( RTL_CONSTASCII_USTRINGPARAM( "Dialog" ) ) );
+ BasicIDE::MarkDocShellModified( pBasic );
+
+ return pDlg;
+}
+
+String BasicIDE::CreateModuleName( StarBASIC* pBasic, const String& rModName )
+{
+ String aModName( rModName );
+ if ( aModName.Len() == 0 )
+ {
+ // Namen generieren...
+ String aModStdName( IDEResId( RID_STR_STDMODULENAME ) );
+ BOOL bValid = FALSE;
+ USHORT i = 1;
+ while ( !bValid )
+ {
+ aModName = aModStdName;
+ aModName += String::CreateFromInt32( i );
+ if ( !pBasic->FindModule( aModName ) )
+ bValid = TRUE;
+
+ i++;
+ }
+ }
+ return aModName;
+}
+
+SbModule* BasicIDE::CreateModule( StarBASIC* pBasic, const String& rModName, BOOL bCreateMain )
+{
+ if ( pBasic->FindModule( rModName ) )
+ return 0;
+
+ String aModName = CreateModuleName( pBasic, rModName );
+
+ String aSource( String( RTL_CONSTASCII_USTRINGPARAM( "REM ***** BASIC *****\n\n" ) ) );
+ if ( bCreateMain )
+ aSource += String( RTL_CONSTASCII_USTRINGPARAM( "Sub Main\n\nEnd Sub" ) );
+
+ SbModule* pModule;
+ pModule = pBasic->MakeModule( aModName, aSource );
+
+ DBG_ASSERT( pModule, "Modul?!" );
+ BasicIDE::MarkDocShellModified( pBasic );
+ return pModule;
+}
+
+
+
+SbxObject* BasicIDE::FindDialog( StarBASIC* pBasic, const String& rDlgName )
+{
+ pBasic->GetAll( SbxCLASS_OBJECT );
+
+ USHORT nObjs = pBasic->GetObjects()->Count();
+ for ( USHORT nObject = 0; nObject < nObjs; nObject++ )
+ {
+ SbxVariable* pVar = pBasic->GetObjects()->Get( nObject );
+ if ( ( pVar->GetSbxId() == GetDialogSbxId() ) && ( pVar->GetName() == rDlgName ) )
+ return (SbxObject*)pVar;
+ }
+
+ return 0;
+}
+
+
+
+StarBASIC* BasicIDE::FindBasic( const SbxVariable* pVar )
+{
+ const SbxVariable* pSbx = pVar;
+ while ( pSbx && !pSbx->ISA( StarBASIC ) )
+ pSbx = pSbx->GetParent();
+
+ DBG_ASSERT( !pSbx || pSbx->ISA( StarBASIC ), "Find Basic: Kein Basic!" );
+ return (StarBASIC*)pSbx;
+}
+
+
+
+BasicManager* BasicIDE::FindBasicManager( StarBASIC* pLib )
+{
+ BasicManager* pBasicMgr = SFX_APP()->GetBasicManager();
+ SfxObjectShell* pDocShell = 0;
+ while ( pBasicMgr )
+ {
+ USHORT nLibs = pBasicMgr->GetLibCount();
+ for ( USHORT nLib = 0; nLib < nLibs; nLib++ )
+ {
+ StarBASIC* pL = pBasicMgr->GetLib( nLib );
+ if ( pL == pLib )
+ return pBasicMgr;
+ }
+
+ if ( pDocShell )
+ pDocShell = SfxObjectShell::GetNext( *pDocShell );
+ else
+ pDocShell = SfxObjectShell::GetFirst();
+
+ pBasicMgr = ( pDocShell ? pDocShell->GetBasicManager() : 0 );
+ }
+ return 0;
+}
+
+BasicManager* BasicIDE::FindBasicManager( const String& aBasMgr )
+{
+ BasicManager* pBasicMgr = SFX_APP()->GetBasicManager();
+ SfxObjectShell* pDocShell = 0;
+ while ( pBasicMgr )
+ {
+ String aMgr;
+ if (pDocShell)
+ aMgr = pDocShell->GetTitle( SFX_TITLE_FILENAME );
+ else
+ aMgr = Application::GetAppName();
+
+ if ( aMgr == aBasMgr )
+ return pBasicMgr;
+
+ if ( pDocShell )
+ pDocShell = SfxObjectShell::GetNext( *pDocShell );
+ else
+ pDocShell = SfxObjectShell::GetFirst();
+
+ pBasicMgr = ( pDocShell ? pDocShell->GetBasicManager() : 0 );
+ }
+ return 0;
+}
+
+String BasicIDE::FindTitle( BasicManager* pBasicManager, USHORT nSFXTitleType )
+{
+ BasicManager* pBasicMgr = SFX_APP()->GetBasicManager();
+ SfxObjectShell* pDocShell = 0;
+ String aTitle;
+ while ( pBasicMgr )
+ {
+ if ( pBasicMgr == pBasicManager )
+ {
+ if (pDocShell)
+ aTitle = pDocShell->GetTitle( nSFXTitleType );
+ else
+ aTitle = Application::GetAppName();
+ return aTitle;
+ }
+
+ if ( pDocShell )
+ pDocShell = SfxObjectShell::GetNext( *pDocShell );
+ else
+ pDocShell = SfxObjectShell::GetFirst();
+
+ pBasicMgr = ( pDocShell ? pDocShell->GetBasicManager() : 0 );
+ }
+ return aTitle;
+}
+
+SfxObjectShell* BasicIDE::FindDocShell( BasicManager* pBasMgr )
+{
+ SfxObjectShell* pDocShell = SfxObjectShell::GetFirst();
+ while ( pDocShell )
+ {
+ if ( ( pDocShell->GetBasicManager() != SFX_APP()->GetBasicManager() ) &&
+ ( pDocShell->GetBasicManager() == pBasMgr ) )
+ {
+ return pDocShell;
+ }
+ pDocShell = SfxObjectShell::GetNext( *pDocShell );
+ }
+ return 0;
+}
+
+void BasicIDE::MarkDocShellModified( StarBASIC* pBasic )
+{
+ // BasicManager suchen, der zur Lib passt...
+ BasicManager* pBasMgr = BasicIDE::FindBasicManager( pBasic );
+ // Koennte z.B. nach CloseDoc schon weg sein...
+ if ( pBasMgr )
+ {
+ SfxObjectShell* pShell = BasicIDE::FindDocShell( pBasMgr );
+ // Muss ja nicht aus einem Document kommen...
+ if ( pShell )
+ {
+ pShell->SetModified();
+ SfxBindings& rBindings = BasicIDE::GetBindings();
+ rBindings.Invalidate( SID_SAVEDOC );
+ rBindings.Update( SID_SAVEDOC );
+
+ }
+ }
+
+ // Objectcatalog updaten...
+ BasicIDEShell* pShell = IDE_DLL()->GetShell();
+ ObjectCatalog* pObjCatalog = pShell ? pShell->GetObjectCatalog() : 0;
+ if ( pObjCatalog )
+ pObjCatalog->UpdateEntries();
+}
+
+void BasicIDE::RunMethod( SbMethod* pMethod )
+{
+ SbxValues aRes;
+ aRes.eType = SbxVOID;
+ pMethod->Get( aRes );
+}
+
+void BasicIDE::StopBasic()
+{
+ StarBASIC::Stop();
+ BasicIDEShell* pShell = IDE_DLL()->GetShell();
+ if ( pShell )
+ {
+ IDEWindowTable& rWindows = pShell->GetIDEWindowTable();
+ IDEBaseWindow* pWin = rWindows.First();
+ while ( pWin )
+ {
+ // BasicStopped von Hand rufen, da das Stop-Notify ggf. sonst nicht
+ // durchkommen kann.
+ pWin->BasicStopped();
+ pWin = rWindows.Next();
+ }
+ }
+ BasicIDE::BasicStopped();
+}
+
+void BasicIDE::BasicStopped( BOOL* pbAppWindowDisabled,
+ BOOL* pbDispatcherLocked, USHORT* pnWaitCount,
+ SfxUInt16Item** ppSWActionCount, SfxUInt16Item** ppSWLockViewCount )
+{
+ // Nach einem Error oder dem expliziten abbrechen des Basics muessen
+ // ggf. einige Locks entfernt werden...
+
+ if ( pbAppWindowDisabled )
+ *pbAppWindowDisabled = FALSE;
+ if ( pbDispatcherLocked )
+ *pbDispatcherLocked = FALSE;
+ if ( pnWaitCount )
+ *pnWaitCount = 0;
+ if ( ppSWActionCount )
+ *ppSWActionCount = 0;
+ if ( ppSWLockViewCount )
+ *ppSWLockViewCount = 0;
+
+ // AppWait ?
+ USHORT nWait = 0;
+ while ( Application::IsWait() )
+ {
+ Application::LeaveWait();
+ nWait++;
+ }
+ if ( pnWaitCount )
+ *pnWaitCount = nWait;
+
+ // Interactive = FALSE ?
+ if ( SFX_APP()->IsDispatcherLocked() )
+ {
+ SFX_APP()->LockDispatcher( FALSE );
+ if ( pbDispatcherLocked )
+ *pbDispatcherLocked = TRUE;
+ }
+ Window* pDefParent = Application::GetDefDialogParent();
+ if ( !pDefParent->IsEnabled() )
+ {
+ // Aber nicht wenn sich noch ein Dialog im Testmodus befindet!
+// if ( pDefParent == Application::GetAppWindow() )
+ {
+// Application::GetAppWindow()->Enable( TRUE );
+ pDefParent->Enable( TRUE );
+ if ( pbAppWindowDisabled )
+ *pbAppWindowDisabled = TRUE;
+ }
+ }
+
+}
+
+void BasicIDE::InvalidateDebuggerSlots()
+{
+ SfxBindings& rBindings = BasicIDE::GetBindings();
+ rBindings.Invalidate( SID_BASICSTOP );
+ rBindings.Update( SID_BASICSTOP );
+ rBindings.Invalidate( SID_BASICRUN );
+ rBindings.Update( SID_BASICRUN );
+ rBindings.Invalidate( SID_BASICCOMPILE );
+ rBindings.Update( SID_BASICCOMPILE );
+ rBindings.Invalidate( SID_BASICSTEPOVER );
+ rBindings.Update( SID_BASICSTEPOVER );
+ rBindings.Invalidate( SID_BASICSTEPINTO );
+ rBindings.Update( SID_BASICSTEPINTO );
+ rBindings.Invalidate( SID_BASICSTEPOUT );
+ rBindings.Update( SID_BASICSTEPOUT );
+ rBindings.Invalidate( SID_BASICIDE_TOGGLEBRKPNT );
+ rBindings.Update( SID_BASICIDE_TOGGLEBRKPNT );
+ rBindings.Invalidate( SID_BASICIDE_STAT_POS );
+ rBindings.Update( SID_BASICIDE_STAT_POS );
+}
+
+void BasicIDE::HandleBasicError()
+{
+ ErrorHandler::HandleError( StarBASIC::GetErrorCode() );
+}
+
+SvStrings* BasicIDE::CreateBasicLibBoxEntries()
+{
+ SvStrings* pStrings = new SvStrings;
+ pStrings->Insert( new String( IDEResId( RID_STR_ALL ) ), 0 );
+
+ BasicManager* pBasicMgr = SFX_APP()->GetBasicManager();
+ SfxObjectShell* pDocShell = 0;
+ while ( pBasicMgr )
+ {
+ // Nur, wenn es ein dazugehoeriges Fenster gibt, damit nicht die
+ // Gecachten Docs, die nicht sichtbar sind ( Remot-Dokumente )
+ if ( !pDocShell || ( ( pBasicMgr != SFX_APP()->GetBasicManager() )
+ && ( SfxViewFrame::GetFirst( pDocShell ) ) ) )
+ {
+ String aBasMgr;
+ if (pDocShell)
+ aBasMgr = pDocShell->GetTitle( SFX_TITLE_FILENAME );
+ else
+ aBasMgr = Application::GetAppName();
+
+ USHORT nLibs = pBasicMgr->GetLibCount();
+ for ( USHORT nLib = 0; nLib < nLibs; nLib++ )
+ {
+ // Auch nicht geladene Libs anbieten...
+ String aLibName = pBasicMgr->GetLibName( nLib );
+ String* pEntry = new String( CreateMgrAndLibStr( aBasMgr, aLibName ) );
+ pStrings->Insert( pEntry, pStrings->Count() );
+ }
+ }
+
+ if ( pDocShell )
+ pDocShell = SfxObjectShell::GetNext( *pDocShell );
+ else
+ pDocShell = SfxObjectShell::GetFirst();
+
+ pBasicMgr = ( pDocShell ? pDocShell->GetBasicManager() : 0 );
+ }
+ return pStrings;
+}
+
+SfxBindings& BasicIDE::GetBindings()
+{
+ BasicIDEDLL* pIDEDLL = IDE_DLL();
+ if ( pIDEDLL && pIDEDLL->GetShell() )
+ {
+ // #63960# fuer BasicIDE die Bindings der APP
+ // 07/00 Now the APP Dispatcher is 'dead', SFX changes...
+// return SFX_APP()->GetAppBindings();
+ return pIDEDLL->GetShell()->GetFrame()->GetBindings();
+ }
+ SfxViewFrame* pCurFrame = SfxViewFrame::Current();
+ DBG_ASSERT( pCurFrame != NULL, "No current view frame!" );
+ return pCurFrame->GetBindings();
+}
+
diff --git a/basctl/source/basicide/bastype2.cxx b/basctl/source/basicide/bastype2.cxx
new file mode 100644
index 000000000000..dfcab6530c5f
--- /dev/null
+++ b/basctl/source/basicide/bastype2.cxx
@@ -0,0 +1,355 @@
+/*************************************************************************
+ *
+ * $RCSfile: bastype2.cxx,v $
+ *
+ * $Revision: 1.1.1.1 $
+ *
+ * last change: $Author: mh $ $Date: 2000-09-29 11:02:36 $
+ *
+ * The Contents of this file are made available subject to the terms of
+ * either of the following licenses
+ *
+ * - GNU Lesser General Public License Version 2.1
+ * - Sun Industry Standards Source License Version 1.1
+ *
+ * Sun Microsystems Inc., October, 2000
+ *
+ * GNU Lesser General Public License Version 2.1
+ * =============================================
+ * Copyright 2000 by Sun Microsystems, Inc.
+ * 901 San Antonio Road, Palo Alto, CA 94303, USA
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License version 2.1, as published by the Free Software Foundation.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this library; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston,
+ * MA 02111-1307 USA
+ *
+ *
+ * Sun Industry Standards Source License Version 1.1
+ * =================================================
+ * The contents of this file are subject to the Sun Industry Standards
+ * Source License Version 1.1 (the "License"); You may not use this file
+ * except in compliance with the License. You may obtain a copy of the
+ * License at http://www.openoffice.org/license.html.
+ *
+ * Software provided under this License is provided on an "AS IS" basis,
+ * WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING,
+ * WITHOUT LIMITATION, WARRANTIES THAT THE SOFTWARE IS FREE OF DEFECTS,
+ * MERCHANTABLE, FIT FOR A PARTICULAR PURPOSE, OR NON-INFRINGING.
+ * See the License for the specific provisions governing your rights and
+ * obligations concerning the Software.
+ *
+ * The Initial Developer of the Original Code is: Sun Microsystems, Inc.
+ *
+ * Copyright: 2000 by Sun Microsystems, Inc.
+ *
+ * All Rights Reserved.
+ *
+ * Contributor(s): _______________________________________
+ *
+ *
+ ************************************************************************/
+
+
+#include <ide_pch.hxx>
+
+#pragma hdrstop
+
+#include <basidesh.hrc>
+#include <bastypes.hxx>
+#include <bastype2.hxx>
+#include <basobj.hxx>
+#include <baside2.hrc>
+#include <iderid.hxx>
+
+#ifndef _SBXCLASS_HXX //autogen
+#include <svtools/sbx.hxx>
+#endif
+
+
+
+BasicTreeListBox::BasicTreeListBox( Window* pParent, const ResId& rRes ) :
+ SvTreeListBox( pParent, IDEResId( rRes.GetId() ) ),
+ aImages( IDEResId( RID_IMGLST_OBJECTS ) )
+{
+ SetSelectionMode( SINGLE_SELECTION );
+ nMode = 0xFF; // Alles
+}
+
+
+
+BasicTreeListBox::~BasicTreeListBox()
+{
+ // UserDaten zerstoeren
+ SvLBoxEntry* pEntry = First();
+ while ( pEntry )
+ {
+ delete (BasicEntry*)pEntry->GetUserData();
+ pEntry = Next( pEntry );
+ }
+}
+
+void BasicTreeListBox::ScanBasic( BasicManager* pBasMgr, const String& rName )
+{
+ DBG_ASSERT( pBasMgr, "Wir scannen einen NULL-Pointer... (warum kein BasicManager?!)" );
+
+ // eigentlich prueffen, ob Basic bereits im Baum ?!
+ SetUpdateMode( FALSE );
+
+ // Erste Ebene: Welcher BasicManager ( App, Doc, ... )
+ // 30.1.96: ScanBasic kann mehrfach zum Updateten aufgerufen werden
+ // => pruefen, ob Eintrag schon vorhanden.
+ SvLBoxEntry* pBasicManagerRootEntry = FindEntry( 0, rName, OBJTYPE_BASICMANAGER );
+ if ( !pBasicManagerRootEntry )
+ {
+ Image aImage( aImages.GetImage( ( pBasMgr == SFX_APP()->GetBasicManager() ) ? IMGID_APPICON : IMGID_DOCUMENT ) );
+ pBasicManagerRootEntry = InsertEntry( rName, aImage, aImage, 0, FALSE, LIST_APPEND );
+ pBasicManagerRootEntry->SetUserData( new BasicManagerEntry( pBasMgr ) );
+ }
+
+ // Zweite Ebene: Libs ( Standard, ... )
+ USHORT nLibs = pBasMgr->GetLibCount();
+ for ( USHORT nLib = 0; nLib < nLibs; nLib++ )
+ {
+ StarBASIC* pLib = pBasMgr->GetLib( nLib );
+ String aLibName = pBasMgr->GetLibName( nLib );
+
+ // Jetzt LoadOnDemand...
+// if ( !pLib ) // Nicht geladen...
+// continue;
+
+ SvLBoxEntry* pLibRootEntry = FindEntry( pBasicManagerRootEntry, aLibName, OBJTYPE_LIB );
+ if ( !pLibRootEntry )
+ {
+ Image aImage( aImages.GetImage( pLib ? IMGID_LIB : IMGID_LIBNOTLOADED ) );
+ pLibRootEntry = InsertEntry( aLibName, aImage, aImage,
+ pBasicManagerRootEntry, pLib ? FALSE : TRUE , LIST_APPEND );
+ pLibRootEntry->SetUserData( new BasicEntry( OBJTYPE_LIB ) );
+ }
+
+ if ( pLib )
+ ImpCreateLibSubEntries( pLibRootEntry, pLib );
+ }
+
+ SetUpdateMode( TRUE );
+}
+
+void BasicTreeListBox::ImpCreateLibSubEntries( SvLBoxEntry* pLibRootEntry, StarBASIC* pLib )
+{
+ // Erst die Module...
+ if ( pLib && ( nMode & BROWSEMODE_MODULES ) )
+ {
+ for ( USHORT nMod = 0; nMod < pLib->GetModules()->Count(); nMod++ )
+ {
+ SbModule* pModule = (SbModule*)pLib->GetModules()->Get( nMod );
+ DBG_ASSERT( pModule, "Modul nicht erhalten!" );
+ String aName( pModule->GetName() );
+ SvLBoxEntry* pModuleEntry = FindEntry( pLibRootEntry, aName, OBJTYPE_MODULE );
+ if ( !pModuleEntry )
+ {
+ USHORT nImgId = IMGID_MODULE;
+ Image aImage( aImages.GetImage( nImgId ) );
+ pModuleEntry = InsertEntry( aName, aImage, aImage, pLibRootEntry, FALSE, LIST_APPEND );
+ pModuleEntry->SetUserData( new BasicEntry( OBJTYPE_MODULE ) );
+ }
+
+ if ( nMode & BROWSEMODE_SUBS )
+ {
+ Image aImage( aImages.GetImage( IMGID_MACRO ) );
+ for ( USHORT nMethod = 0; nMethod < pModule->GetMethods()->Count(); nMethod++ )
+ {
+ SbMethod* pMethod = (SbMethod*)pModule->GetMethods()->Get( nMethod );
+ DBG_ASSERT( pMethod, "Methode nicht gefunden! (NULL)" );
+ SvLBoxEntry* pEntry = FindEntry( pModuleEntry, pMethod->GetName(), OBJTYPE_METHOD );
+ if ( !pEntry )
+ {
+ pEntry = InsertEntry( pMethod->GetName(), aImage, aImage, pModuleEntry, FALSE, LIST_APPEND );
+ pEntry->SetUserData( new BasicEntry( OBJTYPE_METHOD ) );
+ }
+ }
+ }
+ }
+ }
+
+ // ...und dann die lebenden Objecte.
+ if ( pLib && ( nMode & BROWSEMODE_OBJS ) )
+ {
+ pLib->GetAll( SbxCLASS_OBJECT );
+ for ( USHORT nObject = 0; nObject < pLib->GetObjects()->Count(); nObject++ )
+ {
+ SbxVariable* pVar = pLib->GetObjects()->Get( nObject );
+#ifndef BASICDEBUG
+ if ( pVar->GetSbxId() == GetDialogSbxId() )
+#endif
+ {
+ // Dialoge erhalten ChildsOnDemand und koennen
+ // jederzeit weiter aufgeklappt werden...
+ SvLBoxEntry* pEntry = FindEntry( pLibRootEntry, pVar->GetName(), OBJTYPE_OBJECT );
+ if ( !pEntry )
+ {
+ pEntry = InsertEntry( pVar->GetName(), aImages.GetImage( IMGID_OBJECT ), aImages.GetImage( IMGID_OBJECT ), pLibRootEntry, TRUE, LIST_APPEND );
+ pEntry->SetUserData( new BasicEntry( OBJTYPE_OBJECT ) );
+ }
+ }
+ }
+ }
+
+}
+
+void BasicTreeListBox::UpdateEntries()
+{
+ String aCurEntry = CreateEntryDescription( *this, FirstSelected() );
+
+ // Erstmal die vorhandenen Eintraege auf existens pruefen:
+ SvLBoxEntry* pLastValid = 0;
+ SvLBoxEntry* pEntry = First();
+ while ( pEntry )
+ {
+ BOOL bFound = FindVariable( pEntry ) ? TRUE : FALSE;
+ if ( !bFound && !GetModel()->GetDepth( pEntry ) )
+ {
+ // Vielleicht ist es ein BasicManager?
+ bFound = BasicIDE::FindBasicManager( GetEntryText( pEntry ) ) ? TRUE : FALSE;
+ }
+
+ if ( bFound )
+ pLastValid = pEntry;
+ else
+ {
+ delete (BasicEntry*)pEntry->GetUserData();
+ GetModel()->Remove( pEntry );
+ }
+ pEntry = pLastValid ? Next( pLastValid ) : First();
+ }
+
+ // Jetzt ueber die Basics rennen und in die Zweige eintragen
+ ScanAllBasics();
+
+ SvLBoxEntry* pNewCurrent = FindMostMatchingEntry( *this, aCurEntry );
+ if ( pNewCurrent )
+ Select( pNewCurrent, TRUE );
+}
+
+void BasicTreeListBox::ScanSbxObject( SbxObject* pObj, SvLBoxEntry* pObjEntry )
+{
+ // die Methoden des Objects...
+ if ( nMode & BROWSEMODE_SUBS )
+ {
+ for ( USHORT nMethod = 0; nMethod < pObj->GetMethods()->Count(); nMethod++ )
+ {
+ SbMethod* pMethod= (SbMethod*) pObj->GetMethods()->Get( nMethod );
+ DBG_ASSERT( pMethod , "Methode nicht gefunden! (NULL)" );
+ SvLBoxEntry* pEntry = InsertEntry( pMethod->GetName(), aImages.GetImage( IMGID_MACRO ), aImages.GetImage( IMGID_MACRO ), pObjEntry, FALSE, LIST_APPEND );
+ pEntry->SetUserData( new BasicEntry( OBJTYPE_METHODINOBJ ) );
+ }
+ }
+
+ // die Properties des Objects...
+ if ( nMode & BROWSEMODE_PROPS )
+ {
+ pObj->GetAll( SbxCLASS_PROPERTY );
+ for ( USHORT nProp = 0; nProp < pObj->GetProperties()->Count(); nProp++ )
+ {
+ SbxVariable* pVar = pObj->GetProperties()->Get( nProp );
+ DBG_ASSERT( pVar, "Property nicht gefunden! (NULL)" );
+ SvLBoxEntry* pEntry = InsertEntry( pVar->GetName(), aImages.GetImage( IMGID_PROP ), aImages.GetImage( IMGID_PROP ), pObjEntry, FALSE, LIST_APPEND );
+ pEntry->SetUserData( new BasicEntry( OBJTYPE_PROPERTY ) );
+ }
+ }
+
+ // die Subobjecte
+ if ( nMode & BROWSEMODE_SUBOBJS )
+ {
+ pObj->GetAll( SbxCLASS_OBJECT );
+ for ( USHORT nObject = 0; nObject < pObj->GetObjects()->Count(); nObject++ )
+ {
+ SbxVariable* pVar = pObj->GetObjects()->Get( nObject );
+ if ( pVar->GetClass() == SbxCLASS_OBJECT )
+ {
+ // SubObjecte erhalten ChildsOnDemand und koennen
+ // jederzeit weiter aufgeklappt werden...
+ SvLBoxEntry* pEntry = InsertEntry( pVar->GetName(), aImages.GetImage( IMGID_SUBOBJ ), aImages.GetImage( IMGID_SUBOBJ ), pObjEntry, TRUE, LIST_APPEND );
+ pEntry->SetUserData( new BasicEntry( OBJTYPE_SUBOBJ ) );
+ }
+ }
+ }
+}
+
+
+SvLBoxEntry* __EXPORT BasicTreeListBox::CloneEntry( SvLBoxEntry* pSource )
+{
+ SvLBoxEntry* pNew = SvTreeListBox::CloneEntry( pSource );
+ BasicEntry* pUser = (BasicEntry*)pSource->GetUserData();
+
+ DBG_ASSERT( pUser, "User-Daten?!" );
+ DBG_ASSERT( pUser->GetType() != OBJTYPE_BASICMANAGER, "BasMgr-Daten?!" );
+
+ BasicEntry* pNewUser = new BasicEntry( *pUser );
+ pNew->SetUserData( pNewUser );
+ return pNew;
+}
+
+SvLBoxEntry* BasicTreeListBox::FindEntry( SvLBoxEntry* pParent, const String& rText, BYTE nType )
+{
+ ULONG nRootPos = 0;
+ SvLBoxEntry* pEntry = pParent ? FirstChild( pParent ) : GetEntry( nRootPos );
+ while ( pEntry )
+ {
+ BasicEntry* pBasicEntry = (BasicEntry*)pEntry->GetUserData();
+ DBG_ASSERT( pBasicEntry, "FindEntry: Kein BasicEntry ?!" );
+ if ( ( pBasicEntry->GetType() == nType ) && ( GetEntryText( pEntry ) == rText ) )
+ return pEntry;
+
+ pEntry = pParent ? NextSibling( pEntry ) : GetEntry( ++nRootPos );
+ }
+ return 0;
+}
+
+long BasicTreeListBox::ExpandingHdl()
+{
+ // Expanding oder Collaps?
+ BOOL bOK = TRUE;
+ if ( GetModel()->GetDepth( GetHdlEntry() ) == 1 )
+ {
+ String aLib, aDummy1, aDummy2;
+ BasicManager* pBasicManager = GetSelectedSbx( aLib, aDummy1, aDummy2 );
+ if ( aLib.Len() && !aDummy1.Len() && !aDummy2.Len() )
+ {
+ // Beim expandieren einer Lib pruefen, ob Passwortschutz!
+ USHORT nLib = pBasicManager->GetLibId( aLib );
+ if ( pBasicManager->HasPassword( nLib ) &&
+ !pBasicManager->IsPasswordVerified( nLib ) )
+ {
+ bOK = QueryPassword( pBasicManager, nLib );
+ }
+ }
+ }
+ return bOK;
+}
+
+BOOL BasicTreeListBox::IsEntryProtected( SvLBoxEntry* pEntry )
+{
+ BOOL bProtected = FALSE;
+ if ( pEntry && ( GetModel()->GetDepth( pEntry ) == 1 ) )
+ {
+ String aLib, aDummy1, aDummy2, aDummy3;
+ BasicManager* pBasicManager = GetSbx( pEntry, aLib, aDummy1, aDummy2, aDummy3 );
+ USHORT nLib = pBasicManager->GetLibId( aLib );
+ if ( pBasicManager->HasPassword( nLib ) &&
+ !pBasicManager->IsPasswordVerified( nLib ) )
+ {
+ bProtected = TRUE;
+ }
+ }
+ return bProtected;
+}
+
diff --git a/basctl/source/basicide/bastype2.hxx b/basctl/source/basicide/bastype2.hxx
new file mode 100644
index 000000000000..c61728f7d303
--- /dev/null
+++ b/basctl/source/basicide/bastype2.hxx
@@ -0,0 +1,181 @@
+/*************************************************************************
+ *
+ * $RCSfile: bastype2.hxx,v $
+ *
+ * $Revision: 1.1.1.1 $
+ *
+ * last change: $Author: mh $ $Date: 2000-09-29 11:02:36 $
+ *
+ * The Contents of this file are made available subject to the terms of
+ * either of the following licenses
+ *
+ * - GNU Lesser General Public License Version 2.1
+ * - Sun Industry Standards Source License Version 1.1
+ *
+ * Sun Microsystems Inc., October, 2000
+ *
+ * GNU Lesser General Public License Version 2.1
+ * =============================================
+ * Copyright 2000 by Sun Microsystems, Inc.
+ * 901 San Antonio Road, Palo Alto, CA 94303, USA
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License version 2.1, as published by the Free Software Foundation.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this library; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston,
+ * MA 02111-1307 USA
+ *
+ *
+ * Sun Industry Standards Source License Version 1.1
+ * =================================================
+ * The contents of this file are subject to the Sun Industry Standards
+ * Source License Version 1.1 (the "License"); You may not use this file
+ * except in compliance with the License. You may obtain a copy of the
+ * License at http://www.openoffice.org/license.html.
+ *
+ * Software provided under this License is provided on an "AS IS" basis,
+ * WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING,
+ * WITHOUT LIMITATION, WARRANTIES THAT THE SOFTWARE IS FREE OF DEFECTS,
+ * MERCHANTABLE, FIT FOR A PARTICULAR PURPOSE, OR NON-INFRINGING.
+ * See the License for the specific provisions governing your rights and
+ * obligations concerning the Software.
+ *
+ * The Initial Developer of the Original Code is: Sun Microsystems, Inc.
+ *
+ * Copyright: 2000 by Sun Microsystems, Inc.
+ *
+ * All Rights Reserved.
+ *
+ * Contributor(s): _______________________________________
+ *
+ *
+ ************************************************************************/
+#ifndef _BASTYPE2_HXX
+#define _BASTYPE2_HXX
+
+#define _SVICNVW_HXX
+#ifndef _SVTREEBOX_HXX //autogen
+#include <svtools/svtreebx.hxx>
+#endif
+#ifndef _SB_SBSTAR_HXX //autogen
+#include <basic/sbstar.hxx>
+#endif
+
+#define OBJTYPE_BASICMANAGER 1L
+#define OBJTYPE_LIB 2L
+#define OBJTYPE_MODULE 3L
+#define OBJTYPE_METHOD 4L
+#define OBJTYPE_METHODINOBJ 5L
+#define OBJTYPE_OBJECT 6L
+#define OBJTYPE_SUBOBJ 7L
+#define OBJTYPE_PROPERTY 8L
+
+#define BROWSEMODE_MODULES 0x01
+#define BROWSEMODE_SUBS 0x02
+#define BROWSEMODE_OBJS 0x04
+#define BROWSEMODE_PROPS 0x08
+#define BROWSEMODE_SUBOBJS 0x10
+
+class BasicManager;
+class SbMethod;
+class SbxObject;
+class SbModule;
+class SvLBoxEntry;
+class SbxVariable;
+
+USHORT GetDialogSbxId();
+
+class BasicTreeListBox : public SvTreeListBox
+{
+private:
+ USHORT nMode;
+ ImageList aImages;
+
+ void ScanSbxObject( SbxObject* pObj, SvLBoxEntry* pObjEntry );
+
+protected:
+ void ExpandTree( SvLBoxEntry* pRootEntry );
+ virtual void RequestingChilds( SvLBoxEntry* pParent );
+ virtual void ExpandedHdl();
+ virtual SvLBoxEntry* CloneEntry( SvLBoxEntry* pSource );
+ SvLBoxEntry* FindEntry( SvLBoxEntry* pParent, const String& rText, BYTE nType );
+ virtual long ExpandingHdl();
+
+ void ImpCreateLibSubEntries( SvLBoxEntry* pLibRootEntry, StarBASIC* pLib );
+
+public:
+ BasicTreeListBox( Window* pParent, const ResId& rRes );
+ ~BasicTreeListBox();
+
+ void ScanBasic( BasicManager* pBasMgr, const String& rName );
+ void ScanAllBasics();
+ void UpdateEntries();
+
+ void ExpandAllTrees();
+
+ BYTE GetSelectedType();
+ BasicManager* GetSelectedSbx( String& rLib, String& rModOrObj, String& rSubOrProp );
+ BasicManager* GetSelectedSbx( String& rLib, String& rModOrObj, String& rSubOrPropOrSObj, String& rPropOrSubInSObj );
+ BasicManager* GetSbx( SvLBoxEntry* pEntry, String& rLib, String& rModOrObj, String& rSubOrPropOrSObj, String& rPropOrSubInSObj );
+ BOOL IsEntryProtected( SvLBoxEntry* pEntry );
+
+ void SetMode( USHORT nM ) { nMode = nM; }
+ USHORT GetMode() const { return nMode; }
+
+ Image GetImage( USHORT nId ) { return aImages.GetImage( nId ); }
+
+ SbMethod* FindMethod( SvLBoxEntry* pEntry );
+ SbxObject* FindObject( SvLBoxEntry* pEntry );
+ SbModule* FindModule( SvLBoxEntry* pEntry );
+ SbxVariable* FindVariable( SvLBoxEntry* pEntry );
+ SvLBoxEntry* FindLibEntry( StarBASIC* pLib );
+};
+
+/****************************************
+ Zuordnung von Typen und Pointern in BasicEntrys:
+
+ OBJTYPE_BASICMANAGER BasicManagerEntry
+ OBJTYPE_MODULE BasicEntry
+ OBJTYPE_OBJECT BasicEntry
+ OBJTYPE_METHOD BasicEntry
+ OBJTYPE_METHODINOBJ BasicEntry
+ OBJTYPE_SUBOBJ BasicEntry
+ OBJTYPE_PROPERTY BasicEntry
+ OBJTYPE_LIB BasicEntry
+
+******************************************/
+
+class BasicEntry
+{
+private:
+ BYTE nType;
+
+public:
+ BasicEntry( BYTE nT ) { nType = nT; }
+ BasicEntry( const BasicEntry& r ) { nType = r.nType; }
+ virtual ~BasicEntry();
+
+ BYTE GetType() const { return nType; }
+};
+
+class BasicManagerEntry : public BasicEntry
+{
+private:
+ BasicManager* pBasMgr;
+
+public:
+ BasicManagerEntry( BasicManager* pMgr );
+ virtual ~BasicManagerEntry();
+
+ BasicManager* GetBasicManager() const { return pBasMgr; }
+};
+
+#endif // _BASTYPE2_HXX
diff --git a/basctl/source/basicide/bastype3.cxx b/basctl/source/basicide/bastype3.cxx
new file mode 100644
index 000000000000..46715d1a8e05
--- /dev/null
+++ b/basctl/source/basicide/bastype3.cxx
@@ -0,0 +1,502 @@
+/*************************************************************************
+ *
+ * $RCSfile: bastype3.cxx,v $
+ *
+ * $Revision: 1.1.1.1 $
+ *
+ * last change: $Author: mh $ $Date: 2000-09-29 11:02:36 $
+ *
+ * The Contents of this file are made available subject to the terms of
+ * either of the following licenses
+ *
+ * - GNU Lesser General Public License Version 2.1
+ * - Sun Industry Standards Source License Version 1.1
+ *
+ * Sun Microsystems Inc., October, 2000
+ *
+ * GNU Lesser General Public License Version 2.1
+ * =============================================
+ * Copyright 2000 by Sun Microsystems, Inc.
+ * 901 San Antonio Road, Palo Alto, CA 94303, USA
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License version 2.1, as published by the Free Software Foundation.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this library; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston,
+ * MA 02111-1307 USA
+ *
+ *
+ * Sun Industry Standards Source License Version 1.1
+ * =================================================
+ * The contents of this file are subject to the Sun Industry Standards
+ * Source License Version 1.1 (the "License"); You may not use this file
+ * except in compliance with the License. You may obtain a copy of the
+ * License at http://www.openoffice.org/license.html.
+ *
+ * Software provided under this License is provided on an "AS IS" basis,
+ * WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING,
+ * WITHOUT LIMITATION, WARRANTIES THAT THE SOFTWARE IS FREE OF DEFECTS,
+ * MERCHANTABLE, FIT FOR A PARTICULAR PURPOSE, OR NON-INFRINGING.
+ * See the License for the specific provisions governing your rights and
+ * obligations concerning the Software.
+ *
+ * The Initial Developer of the Original Code is: Sun Microsystems, Inc.
+ *
+ * Copyright: 2000 by Sun Microsystems, Inc.
+ *
+ * All Rights Reserved.
+ *
+ * Contributor(s): _______________________________________
+ *
+ *
+ ************************************************************************/
+
+
+#include <ide_pch.hxx>
+
+#pragma hdrstop
+#define _SI_NOSBXCONTROLS
+#include <vcsbx.hxx>
+#include <svtools/sbx.hxx>
+#include <sidll.hxx>
+#include <bastype2.hxx>
+#include <baside2.hrc>
+#include <iderid.hxx>
+#include <bastypes.hxx>
+
+SV_DECL_VARARR( EntryArray, SvLBoxEntry*, 4, 4 );
+
+SV_IMPL_VARARR( EntryArray, SvLBoxEntry*);
+
+USHORT GetDialogSbxId()
+{
+ // damit nicht ueberall si.hxx includet werden muss!
+ return SBXID_DIALOG;
+}
+
+
+
+void __EXPORT BasicTreeListBox::RequestingChilds( SvLBoxEntry* pEntry )
+{
+ BasicEntry* pUser = (BasicEntry*)pEntry->GetUserData();
+ if ( ( pUser->GetType() == OBJTYPE_SUBOBJ ) ||
+ ( pUser->GetType() == OBJTYPE_OBJECT ) )
+ {
+ SbxObject* pObj = FindObject( pEntry );
+ DBG_ASSERT( pObj, "RequestingChilds: Kein gueltiges Objekt");
+ if ( pObj )
+ ScanSbxObject( pObj, pEntry );
+ }
+ else if ( pUser->GetType() == OBJTYPE_LIB )
+ {
+ String aLibName = GetEntryText( pEntry );
+ SvLBoxEntry* pParent = GetParent( pEntry );
+ pUser = (BasicEntry*)pParent->GetUserData();
+ DBG_ASSERT( pUser->GetType() == OBJTYPE_BASICMANAGER, "BasicManager?" );
+ BasicManager* pBasMgr = ((BasicManagerEntry*)pUser)->GetBasicManager();
+ USHORT nLib = pBasMgr->GetLibId( aLibName );
+
+ BOOL bOK = TRUE;
+ if ( pBasMgr->HasPassword( nLib ) &&
+ !pBasMgr->IsPasswordVerified( nLib ) )
+ {
+ bOK = QueryPassword( pBasMgr, nLib );
+ }
+ if ( bOK )
+ {
+ if ( !pBasMgr->IsLibLoaded( nLib ) )
+ pBasMgr->LoadLib( nLib );
+
+ StarBASIC* pLib = pBasMgr->GetLib( nLib );
+ if ( pLib )
+ {
+ ImpCreateLibSubEntries( pEntry, pLib );
+
+ // Das Image austauschen...
+ Image aImage( aImages.GetImage( IMGID_LIB ) );
+ SetExpandedEntryBmp( pEntry, aImage );
+ SetCollapsedEntryBmp( pEntry, aImage );
+ }
+ else
+ {
+ // Lib konnte nicht geladen werden...
+ ErrorBox( this, WB_OK|WB_DEF_OK, String( IDEResId( RID_STR_ERROROPENLIB ) ) ).Execute();
+ }
+ }
+ }
+ else
+ DBG_ERROR( "RequestingChilds: Was?" );
+}
+
+
+
+void __EXPORT BasicTreeListBox::ExpandedHdl()
+{
+ SvLBoxEntry* pEntry = GetHdlEntry();
+ DBG_ASSERT( pEntry, "Was wurde zugeklappt?" );
+ // Die OnDemand erzeugten Childs loeschen,
+ // SubChilds werden automatisch geloescht.
+ if ( !IsExpanded( pEntry ) && pEntry->HasChildsOnDemand() )
+ {
+ SvLBoxEntry* pChild = FirstChild( pEntry );
+ while ( pChild )
+ {
+ GetModel()->Remove( pChild ); // Ruft auch den DTOR
+ pChild = FirstChild( pEntry );
+ }
+ }
+}
+
+
+
+void BasicTreeListBox::ScanAllBasics()
+{
+ ScanBasic( SFX_APP()->GetBasicManager(), Application::GetAppName() );
+ SfxObjectShell* pDocShell = SfxObjectShell::GetFirst();
+ while ( pDocShell )
+ {
+ // Nur, wenn es ein dazugehoeriges Fenster gibt, damit nicht die
+ // Gecachten Docs, die nicht sichtbar sind ( Remot-Dokumente )
+ BasicManager* pBasMgr = pDocShell->GetBasicManager();
+ if ( ( pBasMgr != SFX_APP()->GetBasicManager() ) && ( SfxViewFrame::GetFirst( pDocShell ) ) )
+ ScanBasic( pBasMgr, pDocShell->GetTitle( SFX_TITLE_FILENAME ) );
+ pDocShell = SfxObjectShell::GetNext( *pDocShell );
+ }
+}
+
+/*
+void BasicTreeListBox::ExpandTree( BasicManager* pBasMgr )
+{
+ ULONG nRootPos = 0;
+ SvLBoxEntry* pRootEntry = GetEntry( nRootPos );
+ // Falsch:
+ while ( pRootEntry && (((BasicEntry*)pRootEntry->GetUserData())->GetType() != OBJTYPE_BASICMANAGER ) )
+ pRootEntry = GetEntry( ++nRootPos );
+
+ if ( pRootEntry )
+ ExpandTree( pRootEntry );
+}
+*/
+
+
+
+void BasicTreeListBox::ExpandTree( SvLBoxEntry* pRootEntry )
+{
+ DBG_ASSERT( pRootEntry, "Keine Wurzel ?" );
+
+ Expand( pRootEntry );
+
+ SvLBoxEntry* pLibEntry = FirstChild( pRootEntry );
+ while ( pLibEntry )
+ {
+ // Nur die mit Childs, sonst waere ChildsOnDemand ueberfluessig
+ if ( !IsEntryProtected( pLibEntry ) && GetChildCount( pLibEntry ) )
+ {
+ Expand( pLibEntry );
+
+ // Im ObjectDlg nicht alles expandieren...
+ if ( !( nMode & BROWSEMODE_PROPS ) )
+ {
+ SvLBoxEntry* pModOrObjEntry = FirstChild( pLibEntry );
+ while ( pModOrObjEntry )
+ {
+ Expand( pModOrObjEntry );
+ pModOrObjEntry = NextSibling( pModOrObjEntry );
+ }
+ }
+ }
+ pLibEntry = NextSibling( pLibEntry );
+ }
+}
+
+
+
+void BasicTreeListBox::ExpandAllTrees()
+{
+ ULONG nRootPos = 0;
+ SvLBoxEntry* pRootEntry = GetEntry( nRootPos );
+ while ( pRootEntry )
+ {
+ ExpandTree( pRootEntry );
+ pRootEntry = GetEntry( ++nRootPos );
+ }
+}
+
+
+
+BYTE BasicTreeListBox::GetSelectedType()
+{
+ SvLBoxEntry* pEntry = GetCurEntry();
+
+ if ( !pEntry )
+ return 0;
+
+ USHORT nDepth = GetModel()->GetDepth( pEntry );
+ if ( nDepth == 0 )
+ return OBJTYPE_BASICMANAGER;
+ else if ( nDepth == 1 )
+ return OBJTYPE_LIB;
+
+ return ((BasicEntry*)pEntry->GetUserData())->GetType();
+}
+
+
+
+BasicManager* BasicTreeListBox::GetSelectedSbx( String& rLib, String& rModOrObj, String& rSubOrPropOrSObj )
+{
+ // Methode kann eigentlich weg, wenn nicht mehr in den Apps !!!
+ // Die sollten dann auch direkt mit FindMethod() arbeiten!
+ String aTmpStr;
+ return GetSelectedSbx( rLib, rModOrObj, rSubOrPropOrSObj, aTmpStr );
+}
+
+
+
+
+BasicManager* BasicTreeListBox::GetSelectedSbx( String& rLib, String& rModOrObj, String& rSubOrPropOrSObj, String& rPropOrSubInSObj )
+{
+ SvLBoxEntry* pCurEntry = GetCurEntry();
+ return GetSbx( pCurEntry, rLib, rModOrObj, rSubOrPropOrSObj, rPropOrSubInSObj );
+}
+
+
+
+BasicManager* BasicTreeListBox::GetSbx( SvLBoxEntry* pEntry, String& rLib, String& rModOrObj, String& rSubOrPropOrSObj, String& rPropOrSubInSObj )
+{
+ rLib.Erase();
+ rModOrObj.Erase();
+ rSubOrPropOrSObj.Erase();
+ rPropOrSubInSObj.Erase();
+ BasicManager* pBasMgr = 0;
+
+ while ( pEntry )
+ {
+ USHORT nDepth = GetModel()->GetDepth( pEntry );
+ switch ( nDepth )
+ {
+ case 4: rPropOrSubInSObj = GetEntryText( pEntry );
+ break;
+ case 3: rSubOrPropOrSObj = GetEntryText( pEntry );
+ break;
+ case 2: rModOrObj = GetEntryText( pEntry );
+ break;
+ case 1: rLib = GetEntryText( pEntry );
+ break;
+ case 0: pBasMgr = ((BasicManagerEntry*)pEntry->GetUserData())->GetBasicManager();
+ break;
+ }
+ pEntry = GetParent( pEntry );
+ }
+ return pBasMgr;
+}
+
+
+
+
+SbxVariable* BasicTreeListBox::FindVariable( SvLBoxEntry* pEntry )
+{
+ if ( !pEntry )
+ return 0;
+
+ String aLib, aModOrObj, aSubOrPropOrSObj, aPropOrSubInSObj;
+ BasicManager* pBasMgr = 0;
+ EntryArray aEntries;
+
+ while ( pEntry )
+ {
+ USHORT nDepth = GetModel()->GetDepth( pEntry );
+ switch ( nDepth )
+ {
+ case 4:
+ case 3:
+ case 2:
+ case 1: {
+ aEntries.C40_INSERT( SvLBoxEntry, pEntry, 0 );
+ break;
+ }
+ case 0: pBasMgr = ((BasicManagerEntry*)pEntry->GetUserData())->GetBasicManager();
+ break;
+ }
+ pEntry = GetParent( pEntry );
+ }
+
+ DBG_ASSERT( pBasMgr, "Fuer den Eintrag keinen BasicManager gefunden!" );
+ SbxVariable* pVar = 0;
+ if ( pBasMgr && aEntries.Count() )
+ {
+ for ( USHORT n = 0; n < aEntries.Count(); n++ )
+ {
+ SvLBoxEntry* pLE = aEntries[n];
+ DBG_ASSERT( pLE, "Entrie im Array nicht gefunden" );
+ BasicEntry* pBE = (BasicEntry*)pLE->GetUserData();
+ DBG_ASSERT( pBE, "Keine Daten im Eintrag gefunden!" );
+ String aName( GetEntryText( pLE ) );
+
+ switch ( pBE->GetType() )
+ {
+ case OBJTYPE_LIB:
+ {
+ pVar = pBasMgr->GetLib( aName );
+ }
+ break;
+ case OBJTYPE_MODULE:
+ {
+ DBG_ASSERT( pVar && pVar->IsA( TYPE(StarBASIC) ), "FindVariable: Ungueltiges Basic" );
+ pVar = ((StarBASIC*)pVar)->FindModule( aName );
+ }
+ break;
+ case OBJTYPE_METHOD:
+ case OBJTYPE_METHODINOBJ:
+ {
+ DBG_ASSERT( pVar && ( (pVar->IsA( TYPE(SbModule) )) || (pVar->IsA( TYPE(SbxObject) )) ), "FindVariable: Ungueltiges Modul/Objekt" );
+ pVar = ((SbxObject*)pVar)->GetMethods()->Find( aName, SbxCLASS_METHOD );
+ }
+ break;
+ case OBJTYPE_OBJECT:
+ case OBJTYPE_SUBOBJ:
+ {
+ DBG_ASSERT( pVar && pVar->IsA( TYPE(SbxObject) ), "FindVariable: Ungueltiges Objekt" );
+ pVar = ((SbxObject*)pVar)->GetObjects()->Find( aName, SbxCLASS_OBJECT );
+ }
+ break;
+ case OBJTYPE_PROPERTY:
+ {
+ DBG_ASSERT( pVar && pVar->IsA( TYPE(SbxObject) ), "FindVariable: Ungueltiges Objekt(Property)" );
+ pVar = ((SbxObject*)pVar)->GetProperties()->Find( aName, SbxCLASS_PROPERTY );
+ }
+ break;
+ default: DBG_ERROR( "FindVariable: Unbekannter Typ!" );
+ pVar = 0;
+ }
+ if ( !pVar )
+ break;
+ }
+ }
+
+ return pVar;
+}
+
+
+
+SbxObject* BasicTreeListBox::FindObject( SvLBoxEntry* pEntry )
+{
+ SbxVariable* pVar = FindVariable( pEntry );
+ if ( pVar && pVar->IsA( TYPE(SbxObject) ) )
+ return (SbxObject*)pVar;
+ return 0;
+}
+
+
+
+SbMethod* BasicTreeListBox::FindMethod( SvLBoxEntry* pEntry )
+{
+ SbxVariable* pVar = FindVariable( pEntry );
+ if ( pVar && pVar->IsA( TYPE(SbMethod) ) )
+ return (SbMethod*)pVar;
+ return 0;
+}
+
+
+
+SbModule* BasicTreeListBox::FindModule( SvLBoxEntry* pEntry )
+{
+ SbxVariable* pVar = FindVariable( pEntry );
+ if ( pVar && pVar->IsA( TYPE(SbModule ) ) )
+ return (SbModule*)pVar;
+ return 0;
+}
+
+
+
+SvLBoxEntry* BasicTreeListBox::FindLibEntry( StarBASIC* pLib )
+{
+ if ( !pLib )
+ return 0;
+
+ ULONG nRootPos = 0;
+ SvLBoxEntry* pRootEntry = GetEntry( nRootPos );
+ while ( pRootEntry )
+ {
+ BasicManager* pBasMgr = ((BasicManagerEntry*)pRootEntry->GetUserData())->GetBasicManager();
+ DBG_ASSERT( pBasMgr, "Kein BasicManager?" );
+ SvLBoxEntry* pLibEntry = FirstChild( pRootEntry );
+ while ( pLibEntry )
+ {
+ DBG_ASSERT( (((BasicEntry*)pLibEntry->GetUserData())->GetType() == OBJTYPE_LIB ), "Kein Libeintrag?" );
+ StarBASIC* pL = pBasMgr->GetLib( GetEntryText( pLibEntry ) );
+ if ( pL == pLib )
+ return pLibEntry;
+
+ pLibEntry = NextSibling( pLibEntry );
+ }
+ pRootEntry = GetEntry( ++nRootPos );
+ }
+ return 0;
+}
+
+
+
+String CreateMgrAndLibStr( const String& rMgrName, const String& rLibName )
+{
+ String aName( '[' );
+ aName += rMgrName;
+ aName += String( RTL_CONSTASCII_USTRINGPARAM( "]." ) );
+ aName += rLibName;
+ return aName;
+}
+
+
+
+String GetMgrFromMgrAndLib( const String& rMgrAndLib )
+{
+ // Format: [XXXXXX].Lib
+ DBG_ASSERT( rMgrAndLib.GetTokenCount( '.' ) >= 2, "BasMgrAndLib ungueltig! (.)" );
+ DBG_ASSERT( rMgrAndLib.GetTokenCount( ']' ) >= 2, "BasMgrAndLib ungueltig! (])" );
+ String aLib( rMgrAndLib.GetToken(
+ rMgrAndLib.GetTokenCount( '.' ) - 1, '.' ) );
+ String aBasMgrAndLib( rMgrAndLib );
+ aBasMgrAndLib.Erase( aBasMgrAndLib.Len() - ( aLib.Len() + 1 ) );
+ DBG_ASSERT( ( aBasMgrAndLib.Len() > 2 ) && ( aBasMgrAndLib.GetChar( 0 ) == '[' ) && ( aBasMgrAndLib.GetChar( aBasMgrAndLib.Len() - 1 ) == ']' ), "BasMgrAndLib ungueltig! ([...])" );
+ String aBasMgr( aBasMgrAndLib, 1, (USHORT)(aBasMgrAndLib.Len()-2) );
+ return aBasMgr;
+}
+
+
+
+String GetLibFromMgrAndLib( const String& rMgrAndLib )
+{
+ // Format: [XXXXXX].Lib
+ DBG_ASSERT( rMgrAndLib.GetTokenCount( '.' ) >= 2, "BasMgrAndLib ungueltig! (.)" );
+ DBG_ASSERT( rMgrAndLib.GetTokenCount( ']' ) >= 2, "BasMgrAndLib ungueltig! (])" );
+ String aLib( rMgrAndLib.GetToken(
+ rMgrAndLib.GetTokenCount( '.' ) - 1, '.' ) );
+ return aLib;
+}
+
+
+void EnableBasicDialogs( BOOL bEnable )
+{
+ SiDLL* pSiDLL = SI_DLL();
+ USHORT nDlgs = pSiDLL->GetSbxDlgCount();
+ for ( USHORT nDlg = 0; nDlg < nDlgs; nDlg++ )
+ {
+ VCSbxDialog* pVCDlg = pSiDLL->GetSbxDlg( nDlg );
+ Dialog* pRealDlg = pVCDlg->GetDialog();
+ if ( pRealDlg )
+ {
+ if ( bEnable )
+ pRealDlg->Enable();
+ else
+ pRealDlg->Disable();
+ }
+ }
+}
+
diff --git a/basctl/source/basicide/bastype3.hxx b/basctl/source/basicide/bastype3.hxx
new file mode 100644
index 000000000000..82e6d0655aa0
--- /dev/null
+++ b/basctl/source/basicide/bastype3.hxx
@@ -0,0 +1,120 @@
+/*************************************************************************
+ *
+ * $RCSfile: bastype3.hxx,v $
+ *
+ * $Revision: 1.1.1.1 $
+ *
+ * last change: $Author: mh $ $Date: 2000-09-29 11:02:36 $
+ *
+ * The Contents of this file are made available subject to the terms of
+ * either of the following licenses
+ *
+ * - GNU Lesser General Public License Version 2.1
+ * - Sun Industry Standards Source License Version 1.1
+ *
+ * Sun Microsystems Inc., October, 2000
+ *
+ * GNU Lesser General Public License Version 2.1
+ * =============================================
+ * Copyright 2000 by Sun Microsystems, Inc.
+ * 901 San Antonio Road, Palo Alto, CA 94303, USA
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License version 2.1, as published by the Free Software Foundation.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this library; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston,
+ * MA 02111-1307 USA
+ *
+ *
+ * Sun Industry Standards Source License Version 1.1
+ * =================================================
+ * The contents of this file are subject to the Sun Industry Standards
+ * Source License Version 1.1 (the "License"); You may not use this file
+ * except in compliance with the License. You may obtain a copy of the
+ * License at http://www.openoffice.org/license.html.
+ *
+ * Software provided under this License is provided on an "AS IS" basis,
+ * WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING,
+ * WITHOUT LIMITATION, WARRANTIES THAT THE SOFTWARE IS FREE OF DEFECTS,
+ * MERCHANTABLE, FIT FOR A PARTICULAR PURPOSE, OR NON-INFRINGING.
+ * See the License for the specific provisions governing your rights and
+ * obligations concerning the Software.
+ *
+ * The Initial Developer of the Original Code is: Sun Microsystems, Inc.
+ *
+ * Copyright: 2000 by Sun Microsystems, Inc.
+ *
+ * All Rights Reserved.
+ *
+ * Contributor(s): _______________________________________
+ *
+ *
+ ************************************************************************/
+#ifndef _BASTYPE3_HXX
+#define _BASTYPE3_HXX
+
+#ifndef _SVHEADER_HXX
+#include <svheader.hxx>
+#endif
+
+#ifdef VCL
+#include <svtools/svmedit.hxx>
+#endif
+
+#include <iderid.hxx>
+
+class EditorWindow;
+
+#ifndef NO_SPECIALEDIT
+
+class ExtendedEdit : public Edit
+{
+private:
+ Accelerator aAcc;
+ Link aAccHdl;
+ Link aGotFocusHdl;
+ Link aLoseFocusHdl;
+
+protected:
+ DECL_LINK( EditAccHdl, Accelerator * );
+ DECL_LINK( ImplGetFocusHdl, Control* );
+ DECL_LINK( ImplLoseFocusHdl, Control* );
+
+public:
+ ExtendedEdit( Window* pParent, IDEResId nRes );
+
+ void SetAccHdl( const Link& rLink ) { aAccHdl = rLink; }
+ void SetLoseFocusHdl( const Link& rLink ) { aLoseFocusHdl = rLink; }
+ void SetGotFocusHdl( const Link& rLink ) { aGotFocusHdl = rLink; }
+ Accelerator& GetAccelerator() { return aAcc; }
+};
+
+class ExtendedMultiLineEdit : public MultiLineEdit
+{
+private:
+ Accelerator aAcc;
+ Link aAccHdl;
+
+protected:
+ DECL_LINK( EditAccHdl, Accelerator * );
+ DECL_LINK( ImplGetFocusHdl, Control* );
+ DECL_LINK( ImplLoseFocusHdl, Control* );
+
+public:
+ ExtendedMultiLineEdit( Window* pParent, IDEResId nRes );
+
+ void SetAccHdl( const Link& rLink ) { aAccHdl = rLink; }
+ Accelerator& GetAccelerator() { return aAcc; }
+};
+
+#endif //NO_SPECIALEDIT
+
+#endif // _BASTYPE3_HXX
diff --git a/basctl/source/basicide/bastype4.hxx b/basctl/source/basicide/bastype4.hxx
new file mode 100644
index 000000000000..5679fbc3da9c
--- /dev/null
+++ b/basctl/source/basicide/bastype4.hxx
@@ -0,0 +1,103 @@
+/*************************************************************************
+ *
+ * $RCSfile: bastype4.hxx,v $
+ *
+ * $Revision: 1.1.1.1 $
+ *
+ * last change: $Author: mh $ $Date: 2000-09-29 11:02:36 $
+ *
+ * The Contents of this file are made available subject to the terms of
+ * either of the following licenses
+ *
+ * - GNU Lesser General Public License Version 2.1
+ * - Sun Industry Standards Source License Version 1.1
+ *
+ * Sun Microsystems Inc., October, 2000
+ *
+ * GNU Lesser General Public License Version 2.1
+ * =============================================
+ * Copyright 2000 by Sun Microsystems, Inc.
+ * 901 San Antonio Road, Palo Alto, CA 94303, USA
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License version 2.1, as published by the Free Software Foundation.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this library; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston,
+ * MA 02111-1307 USA
+ *
+ *
+ * Sun Industry Standards Source License Version 1.1
+ * =================================================
+ * The contents of this file are subject to the Sun Industry Standards
+ * Source License Version 1.1 (the "License"); You may not use this file
+ * except in compliance with the License. You may obtain a copy of the
+ * License at http://www.openoffice.org/license.html.
+ *
+ * Software provided under this License is provided on an "AS IS" basis,
+ * WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING,
+ * WITHOUT LIMITATION, WARRANTIES THAT THE SOFTWARE IS FREE OF DEFECTS,
+ * MERCHANTABLE, FIT FOR A PARTICULAR PURPOSE, OR NON-INFRINGING.
+ * See the License for the specific provisions governing your rights and
+ * obligations concerning the Software.
+ *
+ * The Initial Developer of the Original Code is: Sun Microsystems, Inc.
+ *
+ * Copyright: 2000 by Sun Microsystems, Inc.
+ *
+ * All Rights Reserved.
+ *
+ * Contributor(s): _______________________________________
+ *
+ *
+ ************************************************************************/
+#ifndef _BASTYPE4_HXX
+#define _BASTYPE4_HXX
+
+
+#ifndef _TABBAR_HXX //autogen
+#include <svtools/tabbar.hxx>
+#endif
+
+class EditEngine;
+class EditView;
+
+class ExtendedTabBar : public TabBar
+{
+ EditEngine* pEditEngine;
+ EditView* pEditView;
+ BOOL bIsInKeyInput;
+#if __PRIVATE
+ void ImpCheckEditEngine( BOOL bKeepNewText );
+#endif
+protected:
+ virtual void MouseButtonDown( const MouseEvent& rMEvt );
+ virtual void MouseButtonUp( const MouseEvent& rMEvt );
+ virtual void MouseMove( const MouseEvent& rMEvt );
+ virtual void LoseFocus();
+ virtual void KeyInput( const KeyEvent& rKEvent );
+ virtual void Paint( const Rectangle& );
+
+ virtual BOOL StartRenamingTab( USHORT nCurId );
+ virtual BOOL AllowRenamingTab( USHORT nCurId, const String& rNewName );
+ virtual void TabRenamed( USHORT nCurId, const String& rNewName );
+
+public:
+ ExtendedTabBar( Window* pParent, WinBits nStyle );
+ ~ExtendedTabBar();
+
+ void RenameSelectedTab();
+ BOOL IsInEditMode() const { return pEditEngine ? TRUE : FALSE; }
+ void StopEditMode( BOOL bKeepCurText = FALSE );
+};
+
+#endif //_BASTYPE4_HXX
+
+
diff --git a/basctl/source/basicide/bastypes.cxx b/basctl/source/basicide/bastypes.cxx
new file mode 100644
index 000000000000..bd81d64fb23d
--- /dev/null
+++ b/basctl/source/basicide/bastypes.cxx
@@ -0,0 +1,967 @@
+/*************************************************************************
+ *
+ * $RCSfile: bastypes.cxx,v $
+ *
+ * $Revision: 1.1.1.1 $
+ *
+ * last change: $Author: mh $ $Date: 2000-09-29 11:02:36 $
+ *
+ * The Contents of this file are made available subject to the terms of
+ * either of the following licenses
+ *
+ * - GNU Lesser General Public License Version 2.1
+ * - Sun Industry Standards Source License Version 1.1
+ *
+ * Sun Microsystems Inc., October, 2000
+ *
+ * GNU Lesser General Public License Version 2.1
+ * =============================================
+ * Copyright 2000 by Sun Microsystems, Inc.
+ * 901 San Antonio Road, Palo Alto, CA 94303, USA
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License version 2.1, as published by the Free Software Foundation.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this library; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston,
+ * MA 02111-1307 USA
+ *
+ *
+ * Sun Industry Standards Source License Version 1.1
+ * =================================================
+ * The contents of this file are subject to the Sun Industry Standards
+ * Source License Version 1.1 (the "License"); You may not use this file
+ * except in compliance with the License. You may obtain a copy of the
+ * License at http://www.openoffice.org/license.html.
+ *
+ * Software provided under this License is provided on an "AS IS" basis,
+ * WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING,
+ * WITHOUT LIMITATION, WARRANTIES THAT THE SOFTWARE IS FREE OF DEFECTS,
+ * MERCHANTABLE, FIT FOR A PARTICULAR PURPOSE, OR NON-INFRINGING.
+ * See the License for the specific provisions governing your rights and
+ * obligations concerning the Software.
+ *
+ * The Initial Developer of the Original Code is: Sun Microsystems, Inc.
+ *
+ * Copyright: 2000 by Sun Microsystems, Inc.
+ *
+ * All Rights Reserved.
+ *
+ * Contributor(s): _______________________________________
+ *
+ *
+ ************************************************************************/
+
+
+#include <ide_pch.hxx>
+
+#pragma hdrstop
+
+#ifndef _SBXCLASS_HXX //autogen
+#include <svtools/sbx.hxx>
+#endif
+#include <basidesh.hrc>
+#include <bastypes.hxx>
+#include <bastype2.hxx>
+#include <baside2.hxx> // Leider brauche ich teilweise pModulWindow...
+#include <baside2.hrc>
+#include <svtools/textview.hxx>
+#include <svtools/texteng.hxx>
+#include <basobj.hxx>
+#include <sbxitem.hxx>
+
+#ifndef _SV_DRAG_HXX //autogen
+#include <vcl/drag.hxx>
+#endif
+
+#ifndef _SV_CLIP_HXX //autogen
+#include <vcl/clip.hxx>
+#endif
+
+#ifndef _PASSWD_HXX //autogen
+#include <sfx2/passwd.hxx>
+#endif
+
+
+
+
+
+
+DBG_NAME( IDEBaseWindow );
+
+const char* pRegName = "BasicIDETabBar";
+
+TYPEINIT0( IDEBaseWindow )
+TYPEINIT1( SbxItem, SfxPoolItem );
+
+IDEBaseWindow::IDEBaseWindow( Window* pParent, StarBASIC* pBas ) :
+ Window( pParent, WinBits( WB_3DLOOK ) )
+{
+ DBG_CTOR( IDEBaseWindow, 0 );
+ xBasic = pBas;
+ pShellHScrollBar = 0;
+ pShellVScrollBar = 0;
+ nStatus = 0;
+}
+
+
+
+__EXPORT IDEBaseWindow::~IDEBaseWindow()
+{
+ DBG_DTOR( IDEBaseWindow, 0 );
+ if ( pShellVScrollBar )
+ pShellVScrollBar->SetScrollHdl( Link() );
+ if ( pShellHScrollBar )
+ pShellHScrollBar->SetScrollHdl( Link() );
+}
+
+
+
+void IDEBaseWindow::Init()
+{
+ DBG_CHKTHIS( IDEBaseWindow, 0 );
+ if ( pShellVScrollBar )
+ pShellVScrollBar->SetScrollHdl( LINK( this, IDEBaseWindow, ScrollHdl ) );
+ if ( pShellHScrollBar )
+ pShellHScrollBar->SetScrollHdl( LINK( this, IDEBaseWindow, ScrollHdl ) );
+ DoInit(); // virtuell...
+}
+
+
+
+void __EXPORT IDEBaseWindow::DoInit()
+{
+}
+
+
+
+void IDEBaseWindow::GrabScrollBars( ScrollBar* pHScroll, ScrollBar* pVScroll )
+{
+ DBG_CHKTHIS( IDEBaseWindow, 0 );
+ pShellHScrollBar = pHScroll;
+ pShellVScrollBar = pVScroll;
+// Init(); // macht kein Sinn, fuehrt zu flackern, fuehr zu Fehlern...
+}
+
+
+
+IMPL_LINK_INLINE_START( IDEBaseWindow, ScrollHdl, ScrollBar *, pCurScrollBar )
+{
+ DBG_CHKTHIS( IDEBaseWindow, 0 );
+ DoScroll( pCurScrollBar );
+ return 0;
+}
+IMPL_LINK_INLINE_END( IDEBaseWindow, ScrollHdl, ScrollBar *, pCurScrollBar )
+
+
+
+void __EXPORT IDEBaseWindow::ExecuteCommand( SfxRequest& rReq )
+{
+ DBG_CHKTHIS( IDEBaseWindow, 0 );
+}
+
+
+
+void __EXPORT IDEBaseWindow::GetState( SfxItemSet& )
+{
+ DBG_CHKTHIS( IDEBaseWindow, 0 );
+}
+
+
+void __EXPORT IDEBaseWindow::DoScroll( ScrollBar* pCurScrollBar )
+{
+ DBG_CHKTHIS( IDEBaseWindow, 0 );
+}
+
+
+void __EXPORT IDEBaseWindow::StoreData()
+{
+}
+
+BOOL __EXPORT IDEBaseWindow::CanClose()
+{
+ return TRUE;
+}
+
+BOOL __EXPORT IDEBaseWindow::AllowUndo()
+{
+ return TRUE;
+}
+
+
+
+void __EXPORT IDEBaseWindow::UpdateData()
+{
+}
+
+
+
+void __EXPORT IDEBaseWindow::PrintData( Printer* pPrinter )
+{
+}
+
+
+
+String __EXPORT IDEBaseWindow::GetTitle()
+{
+ return String();
+}
+
+
+
+String IDEBaseWindow::CreateQualifiedName()
+{
+ BasicManager* pBasMgr = BasicIDE::FindBasicManager( xBasic );
+ DBG_ASSERT( pBasMgr, "BasicManager nicht gefunden!" );
+ DBG_ASSERT( xBasic.Is(), "Basic nicht initialisiert!" );
+ String aName( BasicIDE::FindTitle( pBasMgr, 3 /*SFX_TITLE_APINAME*/ ) );
+ aName += '.';
+ aName += xBasic->GetName();
+ aName += '.';
+ aName += GetTitle();
+ return aName;
+}
+
+String IDEBaseWindow::CreateSbxDescription()
+{
+ BasicManager* pBasMgr = BasicIDE::FindBasicManager( xBasic );
+ DBG_ASSERT( pBasMgr, "BasicManager nicht gefunden!" );
+ DBG_ASSERT( xBasic.Is(), "Basic nicht initialisiert!" );
+ String aDescription( BasicIDE::FindTitle( pBasMgr, 3 /*SFX_TITLE_APINAME*/ ) );
+ aDescription += ';';
+ aDescription += xBasic->GetName();
+ return aDescription;
+}
+
+void IDEBaseWindow::SetReadOnly( BOOL )
+{
+}
+
+void __EXPORT IDEBaseWindow::BasicStarted()
+{
+}
+
+void __EXPORT IDEBaseWindow::BasicStopped()
+{
+}
+
+BOOL __EXPORT IDEBaseWindow::IsModified()
+{
+ return TRUE;
+}
+
+Window* __EXPORT IDEBaseWindow::GetLayoutWindow()
+{
+ return this;
+}
+
+SfxUndoManager* __EXPORT IDEBaseWindow::GetUndoManager()
+{
+ return NULL;
+}
+
+void BreakPointList::Reset()
+{
+ BreakPoint* pBrk = First();
+ while ( pBrk )
+ {
+ delete pBrk;
+ pBrk = Next();
+ }
+ Clear();
+}
+
+void BreakPointList::InsertSorted( BreakPoint* pNewBrk )
+{
+ BreakPoint* pBrk = First();
+ while ( pBrk )
+ {
+ if ( pNewBrk->nLine <= pBrk->nLine )
+ {
+ DBG_ASSERT( ( pBrk->nLine != pNewBrk->nLine ) || pNewBrk->bTemp, "BreakPoint existiert schon!" );
+ Insert( pNewBrk );
+ return;
+ }
+ pBrk = Next();
+ }
+ // Keine Einfuegeposition gefunden => LIST_APPEND
+ Insert( pNewBrk, LIST_APPEND );
+}
+
+void BreakPointList::SetBreakPointsInBasic( SbModule* pModule )
+{
+ pModule->ClearAllBP();
+
+ BreakPoint* pBrk = First();
+ while ( pBrk )
+ {
+ if ( pBrk->bEnabled )
+ pModule->SetBP( (USHORT)pBrk->nLine );
+ pBrk = Next();
+ }
+}
+
+BreakPoint* BreakPointList::FindBreakPoint( ULONG nLine )
+{
+ BreakPoint* pBrk = First();
+ while ( pBrk )
+ {
+ if ( pBrk->nLine == nLine )
+ return pBrk;
+
+ pBrk = Next();
+ }
+
+ return (BreakPoint*)0;
+}
+
+
+
+void BreakPointList::AdjustBreakPoints( ULONG nLine, BOOL bInserted )
+{
+ BreakPoint* pBrk = First();
+ while ( pBrk )
+ {
+ BOOL bDelBrk = FALSE;
+ if ( pBrk->nLine == nLine )
+ {
+ if ( bInserted )
+ pBrk->nLine++;
+ else
+ bDelBrk = TRUE;
+ }
+ else if ( pBrk->nLine > nLine )
+ {
+ if ( bInserted )
+ pBrk->nLine++;
+ else
+ pBrk->nLine--;
+ }
+
+ if ( bDelBrk )
+ {
+ ULONG n = GetCurPos();
+ delete Remove( pBrk );
+ pBrk = Seek( n );
+ }
+ else
+ {
+ pBrk = Next();
+ }
+ }
+}
+
+void IDEBaseWindow::Deactivating()
+{
+}
+
+USHORT __EXPORT IDEBaseWindow::GetSearchOptions()
+{
+ return 0;
+}
+
+
+BasicDockingWindow::BasicDockingWindow( Window* pParent ) :
+ DockingWindow( pParent, WB_BORDER | WB_3DLOOK | WB_DOCKABLE | WB_MOVEABLE |
+ WB_SIZEABLE /*| WB_HIDEWHENDEACTIVATE*/ | WB_ROLLABLE |
+ WB_DOCKABLE | WB_CLIPCHILDREN )
+{
+}
+
+
+
+BOOL __EXPORT BasicDockingWindow::Docking( const Point& rPos, Rectangle& rRect )
+{
+ ModulWindowLayout* pLayout = (ModulWindowLayout*)GetParent();
+ Rectangle aTmpRec( rRect );
+ BOOL bDock = IsDockingPrevented() ? FALSE : pLayout->IsToBeDocked( this, rPos, aTmpRec );
+ if ( bDock )
+ {
+ rRect.SetSize( aTmpRec.GetSize() );
+ }
+ else // Alte Groesse einstellen
+ {
+ if ( !aFloatingPosAndSize.IsEmpty() )
+ rRect.SetSize( aFloatingPosAndSize.GetSize() );
+ }
+ return !bDock; // bFloat
+}
+
+
+
+void __EXPORT BasicDockingWindow::EndDocking( const Rectangle& rRect, BOOL bFloatMode )
+{
+ if ( bFloatMode )
+ DockingWindow::EndDocking( rRect, bFloatMode );
+ else
+ {
+ SetFloatingMode( FALSE );
+ ModulWindowLayout* pLayout = (ModulWindowLayout*)GetParent();
+ pLayout->DockaWindow( this );
+ }
+}
+
+
+
+void __EXPORT BasicDockingWindow::ToggleFloatingMode()
+{
+ ModulWindowLayout* pLayout = (ModulWindowLayout*)GetParent();
+ if ( IsFloatingMode() )
+ {
+ if ( !aFloatingPosAndSize.IsEmpty() )
+ SetPosSizePixel( GetParent()->ScreenToOutputPixel( aFloatingPosAndSize.TopLeft() ),
+ aFloatingPosAndSize.GetSize() );
+ }
+ pLayout->DockaWindow( this );
+}
+
+
+
+BOOL __EXPORT BasicDockingWindow::PrepareToggleFloatingMode()
+{
+ if ( IsFloatingMode() )
+ {
+ // Position und Groesse auf dem Desktop merken...
+ aFloatingPosAndSize.SetPos( GetParent()->OutputToScreenPixel( GetPosPixel() ) );
+ aFloatingPosAndSize.SetSize( GetSizePixel() );
+ }
+ return TRUE;
+}
+
+
+
+void __EXPORT BasicDockingWindow::StartDocking()
+{
+ // Position und Groesse auf dem Desktop merken...
+ if ( IsFloatingMode() )
+ {
+ aFloatingPosAndSize.SetPos( GetParent()->OutputToScreenPixel( GetPosPixel() ) );
+ aFloatingPosAndSize.SetSize( GetSizePixel() );
+ }
+}
+
+
+
+
+BasicToolBox::BasicToolBox( Window* pParent, IDEResId nRes ) :
+ ToolBox( pParent, nRes )
+{
+}
+
+
+
+void __EXPORT BasicToolBox::MouseButtonDown( const MouseEvent &rEvt )
+{
+ ToolBox::MouseButtonDown( rEvt );
+ if ( !GetCurItemId() )
+ ((BasicDockingWindow*)GetParent())->MouseButtonDown( rEvt );
+}
+
+
+
+
+ExtendedEdit::ExtendedEdit( Window* pParent, IDEResId nRes ) :
+ Edit( pParent, nRes )
+{
+ aAcc.SetSelectHdl( LINK( this, ExtendedEdit, EditAccHdl ) );
+ Control::SetGetFocusHdl( LINK( this, ExtendedEdit, ImplGetFocusHdl ) );
+ Control::SetLoseFocusHdl( LINK( this, ExtendedEdit, ImplLoseFocusHdl ) );
+}
+
+IMPL_LINK( ExtendedEdit, ImplGetFocusHdl, Control*, EMPTYARG )
+{
+ Application::InsertAccel( &aAcc );
+ aLoseFocusHdl.Call( this );
+ return 0;
+}
+
+
+IMPL_LINK( ExtendedEdit, ImplLoseFocusHdl, Control*, EMPTYARG )
+{
+ Application::RemoveAccel( &aAcc );
+ return 0;
+}
+
+
+IMPL_LINK_INLINE_START( ExtendedEdit, EditAccHdl, Accelerator *, pAcc )
+{
+ aAccHdl.Call( pAcc );
+ return 0;
+}
+IMPL_LINK_INLINE_END( ExtendedEdit, EditAccHdl, Accelerator *, pAcc )
+
+
+
+ExtendedMultiLineEdit::ExtendedMultiLineEdit( Window* pParent, IDEResId nRes ) :
+ MultiLineEdit( pParent, nRes )
+{
+ aAcc.SetSelectHdl( LINK( this, ExtendedMultiLineEdit, EditAccHdl ) );
+ Control::SetGetFocusHdl( LINK( this, ExtendedMultiLineEdit, ImplGetFocusHdl ) );
+ Control::SetLoseFocusHdl( LINK( this, ExtendedMultiLineEdit, ImplLoseFocusHdl ) );
+}
+
+IMPL_LINK( ExtendedMultiLineEdit, ImplGetFocusHdl, Control*, EMPTYARG )
+{
+ Application::InsertAccel( &aAcc );
+ return 0;
+}
+
+
+IMPL_LINK( ExtendedMultiLineEdit, ImplLoseFocusHdl, Control*, EMPTYARG )
+{
+ Application::RemoveAccel( &aAcc );
+ return 0;
+}
+
+IMPL_LINK_INLINE_START( ExtendedMultiLineEdit, EditAccHdl, Accelerator *, pAcc )
+{
+ aAccHdl.Call( pAcc );
+ return 0;
+}
+IMPL_LINK_INLINE_END( ExtendedMultiLineEdit, EditAccHdl, Accelerator *, pAcc )
+
+struct TabBarDDInfo
+{
+ ULONG npTabBar;
+ USHORT nPage;
+
+ TabBarDDInfo() { npTabBar = 0; nPage, 0; }
+ TabBarDDInfo( ULONG _npTabBar, USHORT _nPage ) { npTabBar = _npTabBar; nPage = _nPage; }
+};
+
+
+BasicIDETabBar::BasicIDETabBar( Window* pParent ) :
+ TabBar( pParent, WinBits( WB_SVLOOK | WB_SCROLL | WB_BORDER | WB_SIZEABLE | WB_DRAG ) )
+{
+ pCurrentLib = NULL;
+ EnableEditMode( TRUE );
+}
+
+void __EXPORT BasicIDETabBar::MouseButtonDown( const MouseEvent& rMEvt )
+{
+ if ( rMEvt.IsLeft() && ( rMEvt.GetClicks() == 2 ) && !IsInEditMode() )
+ {
+ SfxViewFrame* pCurFrame = SfxViewFrame::Current();
+ DBG_ASSERT( pCurFrame != NULL, "No current view frame!" );
+ SfxDispatcher* pDispatcher = pCurFrame ? pCurFrame->GetDispatcher() : NULL;
+ if( pDispatcher )
+ {
+ pDispatcher->Execute( SID_BASICIDE_MODULEDLG );
+ }
+ }
+ else
+ {
+ TabBar::MouseButtonDown( rMEvt );
+ }
+}
+
+void __EXPORT BasicIDETabBar::Command( const CommandEvent& rCEvt )
+{
+ if ( ( rCEvt.GetCommand() == COMMAND_CONTEXTMENU ) && !IsInEditMode() )
+ {
+ Point aPos( rCEvt.IsMouseEvent() ? rCEvt.GetMousePosPixel() : Point(1,1) );
+ if ( rCEvt.IsMouseEvent() ) // Richtige Tab selektieren
+ {
+ Point aP = PixelToLogic( aPos );
+ MouseEvent aMouseEvent( aP, 1, MOUSE_SIMPLECLICK, MOUSE_LEFT );
+ TabBar::MouseButtonDown( aMouseEvent );
+ }
+ PopupMenu aPopup( IDEResId( RID_POPUP_TABBAR ) );
+ if ( GetPageCount() == 0 )
+ {
+ aPopup.EnableItem( SID_BASICIDE_DELETECURRENT, FALSE );
+ aPopup.EnableItem( SID_BASICIDE_RENAMECURRENT, FALSE );
+ aPopup.EnableItem( SID_BASICIDE_HIDECURPAGE, FALSE );
+ }
+ SfxViewFrame* pCurFrame = SfxViewFrame::Current();
+ DBG_ASSERT( pCurFrame != NULL, "No current view frame!" );
+ SfxDispatcher* pDispatcher = pCurFrame ? pCurFrame->GetDispatcher() : NULL;
+ if( pDispatcher )
+ {
+ pDispatcher->Execute( aPopup.Execute( this, aPos ) );
+ }
+ }
+ else if ( ( rCEvt.GetCommand() == COMMAND_STARTDRAG ) && pCurrentLib && !IsInEditMode() )
+ {
+ Region aRegion;
+ if ( StartDrag( rCEvt, aRegion ) )
+ {
+ ULONG nReg = DragServer::RegisterFormatName( String( RTL_CONSTASCII_USTRINGPARAM( pRegName ) ) );
+ TabBarDDInfo aInf( (ULONG)this, GetPagePos( GetCurPageId() ) );
+ DragServer::CopyData( &aInf, sizeof( TabBarDDInfo ), nReg );
+
+ ExecuteDrag( Pointer( POINTER_MOVEFILE ), Pointer( POINTER_COPYFILE ),
+ DRAG_MOVEABLE, &aRegion );
+
+ HideDropPos();
+
+ }
+ }
+}
+
+BOOL __EXPORT BasicIDETabBar::QueryDrop( DropEvent& rDEvt )
+{
+ // ... pruefen, ob moeglich und ob gleiches Fenster..
+
+ if ( rDEvt.IsLeaveWindow() )
+ {
+ HideDropPos();
+ EndSwitchPage();
+ return FALSE;
+ }
+
+ ULONG nReg = Clipboard::RegisterFormatName( String( RTL_CONSTASCII_USTRINGPARAM( pRegName ) ) );
+ if ( DragServer::HasFormat( 0, nReg ) )
+ {
+ ULONG nThis = (ULONG)this;
+ TabBarDDInfo aInf;
+ DragServer::PasteData( 0, &aInf, sizeof( TabBarDDInfo ), nReg );
+ if ( nThis == aInf.npTabBar )
+ {
+ if ( rDEvt.GetAction() == DROP_MOVE )
+ {
+ USHORT nDestPos = ShowDropPos( rDEvt.GetPosPixel() );
+ if ( aInf.nPage < nDestPos )
+ nDestPos--;
+ USHORT nMods = (USHORT) pCurrentLib->GetModules()->Count();
+ return ( ( nDestPos != aInf.nPage ) &&
+ ( ( ( aInf.nPage < nMods ) && ( nDestPos < nMods ) ) ||
+ ( ( aInf.nPage >= nMods ) && ( nDestPos >= nMods ) ) ) );
+ }
+ }
+ }
+ else if ( DragServer::HasFormat( 0, FORMAT_STRING ) )
+ {
+ SwitchPage( rDEvt.GetPosPixel() );
+ }
+
+ return FALSE;
+}
+
+BOOL __EXPORT BasicIDETabBar::Drop( const DropEvent& rDEvt )
+{
+ USHORT nId = GetCurPageId();
+ if ( nId )
+ {
+ ULONG nReg = Clipboard::RegisterFormatName( String( RTL_CONSTASCII_USTRINGPARAM( pRegName ) ) );
+ TabBarDDInfo aInf;
+ DragServer::PasteData( 0, &aInf, sizeof( TabBarDDInfo ), nReg );
+
+ ULONG nMods = pCurrentLib->GetModules()->Count();
+ USHORT nPos = ShowDropPos( rDEvt.GetPosPixel() );
+ USHORT nDestPos = nPos;
+ if ( aInf.nPage < nDestPos )
+ nDestPos--;
+
+ if ( aInf.nPage < nMods )
+ {
+ // Module umsortieren
+ SbModuleRef xMod = (SbModule*) pCurrentLib->GetModules()->Get( aInf.nPage );
+ pCurrentLib->GetModules()->Remove( xMod );
+ pCurrentLib->GetModules()->Insert( xMod, nDestPos );
+ }
+ else
+ {
+ // Objekte umsortieren, leider stehen in diesem Array nicht nur Dialoge...
+ USHORT nDlg = aInf.nPage - nMods;
+ nDestPos -= nMods;
+ USHORT nD = 0, nRealPos = 0, nRealDest = 0;
+ for ( USHORT nObject = 0; nObject < pCurrentLib->GetObjects()->Count(); nObject++ )
+ {
+ SbxVariable* pVar = pCurrentLib->GetObjects()->Get( nObject );
+ if ( pVar->GetSbxId() == GetDialogSbxId() )
+ {
+ if ( nD == nDlg )
+ nRealPos = nObject;
+ if ( nD == nDestPos )
+ nRealDest = nObject;
+ nD++;
+ }
+ }
+
+ SbxObjectRef xObj = (SbxObject*) pCurrentLib->GetObjects()->Get( nRealPos );
+ pCurrentLib->GetObjects()->Remove( xObj );
+ pCurrentLib->GetObjects()->Insert( xObj, nRealDest );
+ }
+
+ pCurrentLib->SetModified( TRUE );
+
+ MovePage( nId, nPos );
+ return TRUE;
+ }
+ else
+ return FALSE;
+}
+
+
+long BasicIDETabBar::AllowRenaming()
+{
+ BOOL bValid = BasicIDE::IsValidSbxName( GetEditText() );
+
+ if ( !bValid )
+ ErrorBox( this, WB_OK | WB_DEF_OK, String( IDEResId( RID_STR_BADSBXNAME ) ) ).Execute();
+
+ return bValid ? TAB_RENAMING_YES : TAB_RENAMING_NO;
+}
+
+
+void __EXPORT BasicIDETabBar::EndRenaming()
+{
+ if ( !IsEditModeCanceled() )
+ {
+ SfxUInt16Item aID( SID_BASICIDE_ARG_TABID, GetEditPageId() );
+ SfxStringItem aNewName( SID_BASICIDE_ARG_MODULENAME, GetEditText() );
+ SfxViewFrame* pCurFrame = SfxViewFrame::Current();
+ DBG_ASSERT( pCurFrame != NULL, "No current view frame!" );
+ SfxDispatcher* pDispatcher = pCurFrame ? pCurFrame->GetDispatcher() : NULL;
+ if( pDispatcher )
+ {
+ pDispatcher->Execute( SID_BASICIDE_NAMECHANGEDONTAB,
+ SFX_CALLMODE_SYNCHRON, &aID, &aNewName, 0L );
+ }
+ }
+}
+
+
+BasicEntry::~BasicEntry()
+{
+}
+
+
+
+BasicManagerEntry::BasicManagerEntry( BasicManager* pMgr ) :
+ BasicEntry( OBJTYPE_BASICMANAGER )
+{
+ pBasMgr = pMgr;
+}
+
+
+
+BasicManagerEntry::~BasicManagerEntry()
+{
+}
+
+
+
+
+void CutLines( String& rStr, USHORT nStartLine, USHORT nLines, BOOL bEraseTrailingEmptyLines )
+{
+ rStr.ConvertLineEnd( LINEEND_LF );
+
+ USHORT nStartPos = 0;
+ USHORT nEndPos = 0;
+ USHORT nLine = 0;
+ while ( nLine < nStartLine )
+ {
+ nStartPos = rStr.Search( LINE_SEP, nStartPos );
+ nStartPos++; // nicht das \n.
+ nLine++;
+ }
+
+ DBG_ASSERTWARNING( nStartPos != STRING_NOTFOUND, "CutLines: Startzeile nicht gefunden!" );
+
+ if ( nStartPos != STRING_NOTFOUND )
+ {
+ nEndPos = nStartPos;
+ for ( USHORT i = 0; i < nLines; i++ )
+ nEndPos = rStr.Search( LINE_SEP, nEndPos+1 );
+
+ if ( nEndPos != STRING_NOTFOUND ) // kann bei letzter Zeile passieren
+ nEndPos++;
+ if ( nEndPos > rStr.Len() )
+ nEndPos = rStr.Len();
+
+ rStr.Erase( nStartPos, nEndPos-nStartPos );
+ }
+ if ( bEraseTrailingEmptyLines )
+ {
+ USHORT n = nStartPos;
+ while ( ( n < rStr.Len() ) && ( rStr.GetChar( n ) == LINE_SEP ) )
+ n++;
+
+ if ( n > nStartPos )
+ rStr.Erase( nStartPos, n-nStartPos );
+ }
+}
+
+ULONG CalcLineCount( SvStream& rStream )
+{
+ ULONG nLFs = 0;
+ ULONG nCRs = 0;
+ char c;
+
+ rStream.Seek( 0 );
+ rStream >> c;
+ while ( !rStream.IsEof() )
+ {
+ if ( c == '\n' )
+ nLFs++;
+ else if ( c == '\r' )
+ nCRs++;
+ rStream >> c;
+ }
+
+ rStream.Seek( 0 );
+ if ( nLFs > nCRs )
+ return nLFs;
+ return nCRs;
+}
+
+
+
+LibInfos::~LibInfos()
+{
+ for ( ULONG n = Count(); n; )
+ delete (LibInfo*)GetObject( --n );
+}
+
+void LibInfos::InsertInfo( const LibInfo& rInf )
+{
+ Insert( (ULONG)rInf.pLib, new LibInfo( rInf ) );
+}
+
+void LibInfos::DestroyInfo( LibInfo* pInfo )
+{
+ delete Remove( (ULONG)pInfo->pLib );
+}
+
+void LibInfos::DestroyInfo( StarBASIC* pLib )
+{
+ delete Remove( (ULONG)pLib );
+}
+
+LibInfo* LibInfos::GetInfo( StarBASIC* pLib, BOOL bCreateIfNotExist )
+{
+ LibInfo* pInf = (LibInfo*)Get( (ULONG)pLib );
+ if ( !pInf && bCreateIfNotExist )
+ {
+ pInf = new LibInfo;
+ pInf->pLib = pLib;
+ Insert( (ULONG)pLib, pInf );
+ }
+ return pInf;
+}
+
+
+SbxItem::SbxItem(USHORT nWhich, const SbxBase* p ) : SfxPoolItem( nWhich )
+{
+ pSbx = p;
+}
+
+SbxItem::SbxItem(const SbxItem& rCopy) : SfxPoolItem( rCopy )
+{
+ pSbx = rCopy.pSbx;
+}
+
+int SbxItem::operator==( const SfxPoolItem& rCmp) const
+{
+ DBG_ASSERT( rCmp.ISA( SbxItem ), "==: Kein SbxItem!" );
+ return ( SfxPoolItem::operator==( rCmp ) && ( pSbx == ((const SbxItem&)rCmp).pSbx ) );
+}
+
+SfxPoolItem *SbxItem::Clone( SfxItemPool* ) const
+{
+ return new SbxItem(*this);
+}
+
+String CreateEntryDescription( const SvTreeListBox& rBox, SvLBoxEntry* pEntry )
+{
+ String aDescription;
+ while ( pEntry )
+ {
+ aDescription.Insert( rBox.GetEntryText( pEntry ), 0 );
+ pEntry = rBox.GetParent( pEntry );
+ if ( pEntry )
+ aDescription.Insert( ';', 0 );
+ }
+ return aDescription;
+}
+
+SvLBoxEntry* FindMostMatchingEntry( const SvTreeListBox& rBox, const String& rDesrc )
+{
+ SvLBoxEntry* pEntry = 0;
+ USHORT nIndex = 0;
+ while ( nIndex != STRING_NOTFOUND )
+ {
+ String aTmp( rDesrc.GetToken( 0, ';', nIndex ) );
+ SvLBoxEntry* pTmpEntry = rBox.FirstChild( pEntry );
+ while ( pTmpEntry )
+ {
+ if ( rBox.GetEntryText( pTmpEntry ) == aTmp )
+ {
+ pEntry = pTmpEntry;
+ break;
+ }
+ pTmpEntry = rBox.NextSibling( pTmpEntry );
+ }
+ if ( !pTmpEntry )
+ return pEntry;
+ }
+ return pEntry;
+}
+
+BOOL QueryDel( const String& rName, const ResId& rId, Window* pParent )
+{
+ String aQuery( rId );
+ String aName( rName );
+ aName += '\'';
+ aName.Insert( '\'', 0 );
+ aQuery.SearchAndReplace( String( RTL_CONSTASCII_USTRINGPARAM( "XX" ) ), aName );
+ QueryBox aQueryBox( pParent, WB_YES_NO | WB_DEF_YES, aQuery );
+ if ( aQueryBox.Execute() == RET_YES )
+ return TRUE;
+ return FALSE;
+}
+
+BOOL QueryDelMacro( const String& rName, Window* pParent )
+{
+ return QueryDel( rName, IDEResId( RID_STR_QUERYDELMACRO ), pParent );
+}
+
+BOOL QueryDelDialog( const String& rName, Window* pParent )
+{
+ return QueryDel( rName, IDEResId( RID_STR_QUERYDELDIALOG ), pParent );
+}
+
+BOOL QueryDelLib( const String& rName, BOOL bRef, Window* pParent )
+{
+ return QueryDel( rName, IDEResId( bRef ? RID_STR_QUERYDELLIBREF : RID_STR_QUERYDELLIB ), pParent );
+}
+
+BOOL QueryDelModule( const String& rName, Window* pParent )
+{
+ return QueryDel( rName, IDEResId( RID_STR_QUERYDELMODULE ), pParent );
+}
+
+BOOL QueryPassword( BasicManager* pBasicManager, USHORT nLib )
+{
+ BOOL bOK = FALSE;
+ SfxPasswordDialog* pDlg = new SfxPasswordDialog( Application::GetDefDialogParent() );
+ pDlg->SetMinLen( 1 );
+ if ( pDlg->Execute() )
+ {
+ String aPassword = pDlg->GetPassword();
+ if ( aPassword == pBasicManager->GetPassword( nLib ) )
+ {
+ bOK = TRUE;
+ pBasicManager->SetPasswordVerified( nLib );
+ }
+ else
+ {
+ ErrorBox aErrorBox( Application::GetDefDialogParent(), WB_OK, String( IDEResId( RID_STR_WRONGPASSWORD ) ) );
+ aErrorBox.Execute();
+ }
+ }
+ delete pDlg;
+ return bOK;
+}
+
+
+
diff --git a/basctl/source/basicide/brkdlg.cxx b/basctl/source/basicide/brkdlg.cxx
new file mode 100644
index 000000000000..bfc7bc6ff2c2
--- /dev/null
+++ b/basctl/source/basicide/brkdlg.cxx
@@ -0,0 +1,321 @@
+/*************************************************************************
+ *
+ * $RCSfile: brkdlg.cxx,v $
+ *
+ * $Revision: 1.1.1.1 $
+ *
+ * last change: $Author: mh $ $Date: 2000-09-29 11:02:36 $
+ *
+ * The Contents of this file are made available subject to the terms of
+ * either of the following licenses
+ *
+ * - GNU Lesser General Public License Version 2.1
+ * - Sun Industry Standards Source License Version 1.1
+ *
+ * Sun Microsystems Inc., October, 2000
+ *
+ * GNU Lesser General Public License Version 2.1
+ * =============================================
+ * Copyright 2000 by Sun Microsystems, Inc.
+ * 901 San Antonio Road, Palo Alto, CA 94303, USA
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License version 2.1, as published by the Free Software Foundation.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this library; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston,
+ * MA 02111-1307 USA
+ *
+ *
+ * Sun Industry Standards Source License Version 1.1
+ * =================================================
+ * The contents of this file are subject to the Sun Industry Standards
+ * Source License Version 1.1 (the "License"); You may not use this file
+ * except in compliance with the License. You may obtain a copy of the
+ * License at http://www.openoffice.org/license.html.
+ *
+ * Software provided under this License is provided on an "AS IS" basis,
+ * WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING,
+ * WITHOUT LIMITATION, WARRANTIES THAT THE SOFTWARE IS FREE OF DEFECTS,
+ * MERCHANTABLE, FIT FOR A PARTICULAR PURPOSE, OR NON-INFRINGING.
+ * See the License for the specific provisions governing your rights and
+ * obligations concerning the Software.
+ *
+ * The Initial Developer of the Original Code is: Sun Microsystems, Inc.
+ *
+ * Copyright: 2000 by Sun Microsystems, Inc.
+ *
+ * All Rights Reserved.
+ *
+ * Contributor(s): _______________________________________
+ *
+ *
+ ************************************************************************/
+
+
+#pragma hdrstop
+#include <vcl/sound.hxx>
+
+// #define ITEMID_SEARCH SID_SEARCH_ITEM
+#define _SVX_NOIDERESIDS
+#include <basidesh.hrc>
+#include <brkdlg.hxx>
+#include <brkdlg.hrc>
+
+#ifndef _SFXDISPATCH_HXX //autogen
+#include <sfx2/dispatch.hxx>
+#endif
+#include <sfx2/viewfrm.hxx>
+
+
+/**************************
+ Soll-Aufbau des Strings:
+ # <LineNr>
+**************************/
+
+BOOL lcl_ParseText( String aText, USHORT& rLineNr )
+{
+ // Blanks ?
+ aText.EraseLeadingChars( ' ' );
+ if ( !aText.Len() )
+ return FALSE;
+ if ( aText.GetChar( 0 ) != '#' )
+ return FALSE;
+ aText.EraseLeadingChars( ' ' );
+ if ( !aText.Len() )
+ return FALSE;
+
+ rLineNr = (USHORT) aText.ToInt32();
+ return TRUE;
+}
+
+
+
+BreakPointDialog::BreakPointDialog( Window* pParent, BreakPointList& rBrkPntList ) :
+ ModalDialog( pParent, IDEResId( RID_BASICIDE_BREAKPOINTDLG ) ),
+ aComboBox( this, IDEResId( RID_CB_BRKPOINTS ) ),
+ aOKButton( this, IDEResId( RID_PB_OK ) ),
+ aCancelButton( this, IDEResId( RID_PB_CANCEL ) ),
+ aNewButton( this, IDEResId( RID_PB_NEW ) ),
+ aDelButton( this, IDEResId( RID_PB_DEL ) ),
+// aShowButton( this, IDEResId( RID_PB_SHOW ) ),
+ aCheckBox( this, IDEResId( RID_CHKB_ACTIVE ) ),
+ aBrkText( this, IDEResId( RID_FT_BRKPOINTS ) ),
+ aPassText( this, IDEResId( RID_FT_PASS ) ),
+ aNumericField( this, IDEResId( RID_FLD_PASS ) ),
+ rBrkPointList( rBrkPntList )
+{
+ FreeResource();
+
+ aComboBox.SetUpdateMode( FALSE );
+ BreakPoint* pBrk = rBrkPointList.First();
+ BreakPoint* pFirstBrk = pBrk;
+ while ( pBrk )
+ {
+ String aEntryStr( RTL_CONSTASCII_USTRINGPARAM( "# " ) );
+ aEntryStr += String::CreateFromInt32( pBrk->nLine );
+ aComboBox.InsertEntry( aEntryStr, COMBOBOX_APPEND );
+ pBrk = rBrkPointList.Next();
+ }
+ aComboBox.SetUpdateMode( TRUE );
+
+ aOKButton.SetClickHdl( LINK( this, BreakPointDialog, ButtonHdl ) );
+ aNewButton.SetClickHdl( LINK( this, BreakPointDialog, ButtonHdl ) );
+ aDelButton.SetClickHdl( LINK( this, BreakPointDialog, ButtonHdl ) );
+// aShowButton.SetClickHdl( LINK( this, BreakPointDialog, ButtonHdl ) );
+
+ aCheckBox.SetClickHdl( LINK( this, BreakPointDialog, CheckBoxHdl ) );
+ aComboBox.SetSelectHdl( LINK( this, BreakPointDialog, ComboBoxHighlightHdl ) );
+ aComboBox.SetModifyHdl( LINK( this, BreakPointDialog, EditModifyHdl ) );
+ aComboBox.GrabFocus();
+
+ aNumericField.SetMin( 0 );
+ aNumericField.SetMax( 0x7FFFFFFF );
+ aNumericField.SetSpinSize( 1 );
+ aNumericField.SetStrictFormat( TRUE );
+ aNumericField.SetModifyHdl( LINK( this, BreakPointDialog, EditModifyHdl ) );
+
+ aComboBox.SetText( aComboBox.GetEntry( 0 ) );
+ UpdateFields( pFirstBrk );
+
+ CheckButtons();
+}
+
+void BreakPointDialog::SetCurrentBreakPoint( const BreakPoint& rBrk )
+{
+ String aStr( RTL_CONSTASCII_USTRINGPARAM( "# " ) );
+ aStr += String::CreateFromInt32( rBrk.nLine );
+ aComboBox.SetText( aStr );
+}
+
+void BreakPointDialog::CheckButtons()
+{
+ BOOL bEnableAdd = FALSE;
+
+ String aEditText( aComboBox.GetText() );
+ if ( aEditText.Len() )
+ bEnableAdd = TRUE; // es besteht die Moeglichkeit.
+
+ for ( USHORT i = 0; i < aComboBox.GetEntryCount(); i++ )
+ {
+ String aStr( aComboBox.GetEntry( i ) );
+ if ( aStr.CompareIgnoreCaseToAscii( aEditText ) == COMPARE_EQUAL )
+ {
+ bEnableAdd = FALSE;
+ break;
+ }
+ }
+
+ if ( bEnableAdd )
+ {
+ aNewButton.Enable();
+ aOKButton.Disable();
+ aDelButton.Disable();
+ }
+ else
+ {
+ aNewButton.Disable();
+ aOKButton.Enable();
+ aDelButton.Enable();
+ }
+}
+
+
+
+IMPL_LINK_INLINE_START( BreakPointDialog, CheckBoxHdl, CheckBox *, pChkBx )
+{
+ BreakPoint* pBrk = GetSelectedBreakPoint();
+ if ( pBrk )
+ pBrk->bEnabled = pChkBx->IsChecked();
+
+ return 0;
+}
+IMPL_LINK_INLINE_END( BreakPointDialog, CheckBoxHdl, CheckBox *, pChkBx )
+
+
+
+IMPL_LINK( BreakPointDialog, ComboBoxHighlightHdl, ComboBox *, pBox )
+{
+ aNewButton.Disable();
+ aOKButton.Enable();
+ aDelButton.Enable();
+
+ USHORT nEntry = pBox->GetEntryPos( pBox->GetText() );
+ BreakPoint* pBrk = rBrkPointList.GetObject( nEntry );
+ DBG_ASSERT( pBrk, "Kein passender Breakpoint zur Liste ?" );
+ UpdateFields( pBrk );
+
+ return 0;
+}
+
+
+
+IMPL_LINK( BreakPointDialog, EditModifyHdl, Edit *, pEdit )
+{
+ if ( pEdit == &aComboBox )
+ CheckButtons();
+ else if ( pEdit == &aNumericField )
+ {
+ BreakPoint* pBrk = GetSelectedBreakPoint();
+ if ( pBrk )
+ pBrk->nStopAfter = pEdit->GetText().ToInt32();
+ }
+ return 0;
+}
+
+
+
+IMPL_LINK( BreakPointDialog, ButtonHdl, Button *, pButton )
+{
+ if ( pButton == &aOKButton )
+ EndDialog( 1 );
+ else if ( pButton == &aNewButton )
+ {
+ // Checkbox beruecksichtigen!
+ String aText( aComboBox.GetText() );
+ USHORT nLine;
+ BOOL bValid = lcl_ParseText( aText, nLine );
+ if ( bValid )
+ {
+ BreakPoint* pBrk = new BreakPoint( nLine );
+ pBrk->bEnabled = aCheckBox.IsChecked();
+ pBrk->nStopAfter = aNumericField.GetValue();
+ rBrkPointList.InsertSorted( pBrk );
+ String aEntryStr( RTL_CONSTASCII_USTRINGPARAM( "# " ) );
+ aEntryStr += String::CreateFromInt32( pBrk->nLine );
+ aComboBox.InsertEntry( aEntryStr, COMBOBOX_APPEND );
+ SfxViewFrame* pCurFrame = SfxViewFrame::Current();
+ DBG_ASSERT( pCurFrame != NULL, "No current view frame!" );
+ SfxDispatcher* pDispatcher = pCurFrame ? pCurFrame->GetDispatcher() : NULL;
+ if( pDispatcher )
+ {
+ pDispatcher->Execute( SID_BASICIDE_BRKPNTSCHANGED );
+ }
+ }
+ else
+ {
+ aComboBox.SetText( aText );
+ aComboBox.GrabFocus();
+ Sound::Beep();
+ }
+ CheckButtons();
+ }
+ else if ( pButton == &aDelButton )
+ {
+ USHORT nEntry = aComboBox.GetEntryPos( aComboBox.GetText() );
+ BreakPoint* pBrk = rBrkPointList.GetObject( nEntry );
+ if ( pBrk )
+ {
+ delete rBrkPointList.Remove( pBrk );
+ aComboBox.RemoveEntry( nEntry );
+ if ( nEntry && !( nEntry < aComboBox.GetEntryCount() ) )
+ nEntry--;
+ aComboBox.SetText( aComboBox.GetEntry( nEntry ) );
+ SfxViewFrame* pCurFrame = SfxViewFrame::Current();
+ DBG_ASSERT( pCurFrame != NULL, "No current view frame!" );
+ SfxDispatcher* pDispatcher = pCurFrame ? pCurFrame->GetDispatcher() : NULL;
+ if( pDispatcher )
+ {
+ pDispatcher->Execute( SID_BASICIDE_BRKPNTSCHANGED );
+ }
+ }
+ CheckButtons();
+ }
+// else if ( pButton == &aShowButton )
+// {
+// ;
+// }
+
+ return 0;
+}
+
+
+
+void BreakPointDialog::UpdateFields( BreakPoint* pBrk )
+{
+ if ( pBrk )
+ {
+ aCheckBox.Check( pBrk->bEnabled );
+ aNumericField.SetValue( pBrk->nStopAfter );
+ }
+}
+
+
+
+BreakPoint* BreakPointDialog::GetSelectedBreakPoint()
+{
+ USHORT nEntry = aComboBox.GetEntryPos( aComboBox.GetText() );
+ BreakPoint* pBrk = rBrkPointList.GetObject( nEntry );
+ return pBrk;
+}
+
+
+
+
diff --git a/basctl/source/basicide/brkdlg.hrc b/basctl/source/basicide/brkdlg.hrc
new file mode 100644
index 000000000000..0700d022b56e
--- /dev/null
+++ b/basctl/source/basicide/brkdlg.hrc
@@ -0,0 +1,80 @@
+/*************************************************************************
+ *
+ * $RCSfile: brkdlg.hrc,v $
+ *
+ * $Revision: 1.1.1.1 $
+ *
+ * last change: $Author: mh $ $Date: 2000-09-29 11:02:36 $
+ *
+ * The Contents of this file are made available subject to the terms of
+ * either of the following licenses
+ *
+ * - GNU Lesser General Public License Version 2.1
+ * - Sun Industry Standards Source License Version 1.1
+ *
+ * Sun Microsystems Inc., October, 2000
+ *
+ * GNU Lesser General Public License Version 2.1
+ * =============================================
+ * Copyright 2000 by Sun Microsystems, Inc.
+ * 901 San Antonio Road, Palo Alto, CA 94303, USA
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License version 2.1, as published by the Free Software Foundation.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this library; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston,
+ * MA 02111-1307 USA
+ *
+ *
+ * Sun Industry Standards Source License Version 1.1
+ * =================================================
+ * The contents of this file are subject to the Sun Industry Standards
+ * Source License Version 1.1 (the "License"); You may not use this file
+ * except in compliance with the License. You may obtain a copy of the
+ * License at http://www.openoffice.org/license.html.
+ *
+ * Software provided under this License is provided on an "AS IS" basis,
+ * WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING,
+ * WITHOUT LIMITATION, WARRANTIES THAT THE SOFTWARE IS FREE OF DEFECTS,
+ * MERCHANTABLE, FIT FOR A PARTICULAR PURPOSE, OR NON-INFRINGING.
+ * See the License for the specific provisions governing your rights and
+ * obligations concerning the Software.
+ *
+ * The Initial Developer of the Original Code is: Sun Microsystems, Inc.
+ *
+ * Copyright: 2000 by Sun Microsystems, Inc.
+ *
+ * All Rights Reserved.
+ *
+ * Contributor(s): _______________________________________
+ *
+ *
+ ************************************************************************/
+#ifndef _BRKDLG_HRC
+#define _BRKDLG_HRC
+
+#include <svtools/solar.hrc>
+
+#define RID_BASICIDE_BREAKPOINTDLG ( RID_BASICIDE_START + 80 )
+
+#define RID_CB_BRKPOINTS 2
+#define RID_PB_OK 3
+#define RID_PB_CANCEL 4
+#define RID_PB_NEW 5
+#define RID_PB_DEL 6
+#define RID_CHKB_ACTIVE 7
+#define RID_FT_PASS 8
+#define RID_FT_BRKPOINTS 9
+#define RID_FLD_PASS 10
+// #define RID_PB_SHOW 11
+
+#endif // _BRKDLG_HRC
+
diff --git a/basctl/source/basicide/brkdlg.hxx b/basctl/source/basicide/brkdlg.hxx
new file mode 100644
index 000000000000..ca3f9b389ee9
--- /dev/null
+++ b/basctl/source/basicide/brkdlg.hxx
@@ -0,0 +1,118 @@
+/*************************************************************************
+ *
+ * $RCSfile: brkdlg.hxx,v $
+ *
+ * $Revision: 1.1.1.1 $
+ *
+ * last change: $Author: mh $ $Date: 2000-09-29 11:02:36 $
+ *
+ * The Contents of this file are made available subject to the terms of
+ * either of the following licenses
+ *
+ * - GNU Lesser General Public License Version 2.1
+ * - Sun Industry Standards Source License Version 1.1
+ *
+ * Sun Microsystems Inc., October, 2000
+ *
+ * GNU Lesser General Public License Version 2.1
+ * =============================================
+ * Copyright 2000 by Sun Microsystems, Inc.
+ * 901 San Antonio Road, Palo Alto, CA 94303, USA
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License version 2.1, as published by the Free Software Foundation.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this library; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston,
+ * MA 02111-1307 USA
+ *
+ *
+ * Sun Industry Standards Source License Version 1.1
+ * =================================================
+ * The contents of this file are subject to the Sun Industry Standards
+ * Source License Version 1.1 (the "License"); You may not use this file
+ * except in compliance with the License. You may obtain a copy of the
+ * License at http://www.openoffice.org/license.html.
+ *
+ * Software provided under this License is provided on an "AS IS" basis,
+ * WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING,
+ * WITHOUT LIMITATION, WARRANTIES THAT THE SOFTWARE IS FREE OF DEFECTS,
+ * MERCHANTABLE, FIT FOR A PARTICULAR PURPOSE, OR NON-INFRINGING.
+ * See the License for the specific provisions governing your rights and
+ * obligations concerning the Software.
+ *
+ * The Initial Developer of the Original Code is: Sun Microsystems, Inc.
+ *
+ * Copyright: 2000 by Sun Microsystems, Inc.
+ *
+ * All Rights Reserved.
+ *
+ * Contributor(s): _______________________________________
+ *
+ *
+ ************************************************************************/
+
+#ifndef _BRKDLG_HXX
+#define _BRKDLG_HXX
+
+#ifndef _SVHEADER_HXX
+#include <svheader.hxx>
+#endif
+#include <bastypes.hxx>
+
+#ifndef _SV_DIALOG_HXX //autogen
+#include <vcl/dialog.hxx>
+#endif
+
+#ifndef _SV_BUTTON_HXX //autogen
+#include <vcl/button.hxx>
+#endif
+
+#ifndef _SV_FIELD_HXX //autogen
+#include <vcl/field.hxx>
+#endif
+
+#ifndef _SV_FIXED_HXX //autogen
+#include <vcl/fixed.hxx>
+#endif
+
+class BreakPointDialog : public ModalDialog
+{
+private:
+ ComboBox aComboBox;
+ OKButton aOKButton;
+ CancelButton aCancelButton;
+ PushButton aNewButton;
+ PushButton aDelButton;
+// PushButton aShowButton;
+ CheckBox aCheckBox;
+ FixedText aBrkText;
+ FixedText aPassText;
+ NumericField aNumericField;
+
+ BreakPointList& rBrkPointList;
+
+protected:
+ void CheckButtons();
+ DECL_LINK( CheckBoxHdl, CheckBox * );
+ DECL_LINK( ComboBoxHighlightHdl, ComboBox * );
+ DECL_LINK( EditModifyHdl, Edit * );
+ DECL_LINK( ButtonHdl, Button * );
+ void UpdateFields( BreakPoint* pBrk );
+ BreakPoint* GetSelectedBreakPoint();
+
+
+public:
+ BreakPointDialog( Window* pParent, BreakPointList& rBrkList );
+
+ void SetCurrentBreakPoint( const BreakPoint& rBrk );
+};
+
+#endif // _BRKDLG_HXX
diff --git a/basctl/source/basicide/brkdlg.src b/basctl/source/basicide/brkdlg.src
new file mode 100644
index 000000000000..70f838e81460
--- /dev/null
+++ b/basctl/source/basicide/brkdlg.src
@@ -0,0 +1,252 @@
+/*************************************************************************
+ *
+ * $RCSfile: brkdlg.src,v $
+ *
+ * $Revision: 1.1.1.1 $
+ *
+ * last change: $Author: mh $ $Date: 2000-09-29 11:02:36 $
+ *
+ * The Contents of this file are made available subject to the terms of
+ * either of the following licenses
+ *
+ * - GNU Lesser General Public License Version 2.1
+ * - Sun Industry Standards Source License Version 1.1
+ *
+ * Sun Microsystems Inc., October, 2000
+ *
+ * GNU Lesser General Public License Version 2.1
+ * =============================================
+ * Copyright 2000 by Sun Microsystems, Inc.
+ * 901 San Antonio Road, Palo Alto, CA 94303, USA
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License version 2.1, as published by the Free Software Foundation.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this library; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston,
+ * MA 02111-1307 USA
+ *
+ *
+ * Sun Industry Standards Source License Version 1.1
+ * =================================================
+ * The contents of this file are subject to the Sun Industry Standards
+ * Source License Version 1.1 (the "License"); You may not use this file
+ * except in compliance with the License. You may obtain a copy of the
+ * License at http://www.openoffice.org/license.html.
+ *
+ * Software provided under this License is provided on an "AS IS" basis,
+ * WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING,
+ * WITHOUT LIMITATION, WARRANTIES THAT THE SOFTWARE IS FREE OF DEFECTS,
+ * MERCHANTABLE, FIT FOR A PARTICULAR PURPOSE, OR NON-INFRINGING.
+ * See the License for the specific provisions governing your rights and
+ * obligations concerning the Software.
+ *
+ * The Initial Developer of the Original Code is: Sun Microsystems, Inc.
+ *
+ * Copyright: 2000 by Sun Microsystems, Inc.
+ *
+ * All Rights Reserved.
+ *
+ * Contributor(s): _______________________________________
+ *
+ *
+ ************************************************************************/
+
+#include "helpid.hrc"
+#include <brkdlg.hrc>
+ModalDialog RID_BASICIDE_BREAKPOINTDLG
+{
+ // HelpId = HID_BASICIDE_BRKPNTS ;
+ OutputSize = TRUE ;
+ SVLook = TRUE ;
+ Size = MAP_APPFONT ( 178 , 116 ) ;
+ Text = "Haltepunkte" ;
+ Text [ ENGLISH ] = "Breakpoints" ;
+ Moveable = TRUE ;
+ // Closeable = TRUE;
+ ComboBox RID_CB_BRKPOINTS
+ {
+ Pos = MAP_APPFONT ( 6 , 14 ) ;
+ Size = MAP_APPFONT ( 110 , 70 ) ;
+ TabStop = TRUE ;
+ };
+ OKButton RID_PB_OK
+ {
+ Pos = MAP_APPFONT ( 122 , 6 ) ;
+ Size = MAP_APPFONT ( 50 , 14 ) ;
+ TabStop = TRUE ;
+ };
+ CancelButton RID_PB_CANCEL
+ {
+ Pos = MAP_APPFONT ( 122 , 23 ) ;
+ Size = MAP_APPFONT ( 50 , 14 ) ;
+ TabStop = TRUE ;
+ };
+ PushButton RID_PB_NEW
+ {
+ Pos = MAP_APPFONT ( 122 , 57 ) ;
+ Size = MAP_APPFONT ( 50 , 14 ) ;
+ Text = "Neu" ;
+ Text [ ENGLISH ] = "New" ;
+ TabStop = TRUE ;
+ Text [ dutch ] = "Nieuw" ;
+ Text [ english_us ] = "New" ;
+ Text [ italian ] = "Nuovo" ;
+ Text [ spanish ] = "Nuevo" ;
+ Text [ french ] = "Nouveau" ;
+ Text [ swedish ] = "Ny" ;
+ Text [ danish ] = "Ny" ;
+ Text [ portuguese ] = "Novo" ;
+ Text [ portuguese_brazilian ] = "Novo" ;
+ Text[ chinese_simplified ] = "н¨";
+ Text[ russian ] = "Ñîçäàòü";
+ Text[ polish ] = "Nowy";
+ Text[ japanese ] = "V‹K";
+ Text[ chinese_traditional ] = "¶}±Ò·sÀÉ";
+ Text[ arabic ] = "ÌÏíÏ";
+ Text[ greek ] = "Äçìéïõñãßá";
+ Text[ korean ] = "»õ·Î";
+ Text[ turkish ] = "Yeni";
+ Text[ language_user1 ] = " ";
+ };
+ PushButton RID_PB_DEL
+ {
+ Pos = MAP_APPFONT ( 122 , 74 ) ;
+ Size = MAP_APPFONT ( 50 , 14 ) ;
+ /* ### ACHTUNG: Neuer Text in Resource? Löschen : L÷schen */
+ Text = "Löschen" ;
+ Text [ ENGLISH ] = "Delete" ;
+ TabStop = TRUE ;
+ Text [ dutch ] = "Wissen" ;
+ Text [ english_us ] = "Delete" ;
+ Text [ italian ] = "Elimina" ;
+ Text [ spanish ] = "Eliminar" ;
+ Text [ french ] = "Supprimer" ;
+ Text [ swedish ] = "Radera" ;
+ Text [ danish ] = "Slet" ;
+ Text [ portuguese ] = "Eliminar" ;
+ Text [ portuguese_brazilian ] = "Löschen" ;
+ Text[ chinese_simplified ] = "ɾ³ý";
+ Text[ russian ] = "Óäàëèòü";
+ Text[ polish ] = "Usuñ";
+ Text[ japanese ] = "íœ";
+ Text[ chinese_traditional ] = "§R°£";
+ Text[ arabic ] = "ÍÐÝ";
+ Text[ greek ] = "ÄéáãñáöÞ";
+ Text[ korean ] = "»èÁ¦";
+ Text[ turkish ] = "Sil";
+ Text[ language_user1 ] = " ";
+ };
+ CheckBox RID_CHKB_ACTIVE
+ {
+ Pos = MAP_APPFONT ( 6 , 87 ) ;
+ Size = MAP_APPFONT ( 40 , 12 ) ;
+ Text = "Aktiv" ;
+ Text [ ENGLISH ] = "Active" ;
+ TabStop = TRUE ;
+ Text [ english_us ] = "Active" ;
+ Text [ italian ] = "Attivo" ;
+ Text [ spanish ] = "Activo" ;
+ Text [ french ] = "Actif" ;
+ Text [ dutch ] = "Actief" ;
+ Text [ swedish ] = "Aktiv" ;
+ Text [ danish ] = "Aktiv" ;
+ Text [ portuguese_brazilian ] = "Aktiv" ;
+ Text [ portuguese ] = "Activo" ;
+ Text[ chinese_simplified ] = "¼¤»î";
+ Text[ russian ] = "Àêòèâíûé";
+ Text[ polish ] = "Aktywny";
+ Text[ japanese ] = "±¸Ã¨ÌÞ";
+ Text[ chinese_traditional ] = "¿E¬¡";
+ Text[ arabic ] = "äÔØ";
+ Text[ greek ] = "ÅíåñãÜ";
+ Text[ korean ] = "Ȱ¼º";
+ Text[ turkish ] = "Etkin";
+ Text[ language_user1 ] = " ";
+ };
+ FixedText RID_FT_PASS
+ {
+ Pos = MAP_APPFONT ( 6 , 102 ) ;
+ Size = MAP_APPFONT ( 35 , 10 ) ;
+ Text = "Durchlauf:" ;
+ Text [ English ] = "Pass Count:" ;
+ Text [ english_us ] = "Pass Count:" ;
+ Text [ portuguese_brazilian ] = "Durchlauf:" ;
+ Text [ swedish ] = "Passager:" ;
+ Text [ danish ] = "Gennemløb:" ;
+ Text [ italian ] = "Passaggi:" ;
+ Text [ spanish ] = "Adaptación:" ;
+ Text [ french ] = "Adaptation :" ;
+ Text [ dutch ] = "Doorloop:" ;
+ Text [ portuguese ] = "Adaptação:" ;
+ Text[ chinese_simplified ] = "´©Í¸£º";
+ Text[ russian ] = "Ïðîãîíîâ:";
+ Text[ polish ] = "Przep³yw tekstu:";
+ Text[ japanese ] = "Ü‚è•Ô‚µ‚È‚µ:";
+ Text[ chinese_traditional ] = "¬ï³z¡G";
+ Text[ arabic ] = "ÚÈÑ:";
+ Text[ greek ] = "Äéá ìÝóïõ:";
+ Text[ korean ] = "ÆÐ½º Ƚ¼ö:";
+ Text[ turkish ] = "Pass count:";
+ Text[ language_user1 ] = " ";
+ };
+ FixedText RID_FT_BRKPOINTS
+ {
+ Pos = MAP_APPFONT ( 6 , 3 ) ;
+ Size = MAP_APPFONT ( 40 , 10 ) ;
+ Text = "Haltepunkte" ;
+ Text [ ENGLISH ] = "Breakpoints" ;
+ Text [ english_us ] = "Breakpoints" ;
+ Text [ italian ] = "Punti di interruzione" ;
+ Text [ spanish ] = "Puntos de ruptura" ;
+ Text [ french ] = "Points d'arrêt" ;
+ Text [ dutch ] = "Stoppunten" ;
+ Text [ swedish ] = "Brytpunkter" ;
+ Text [ danish ] = "Pausepunkter" ;
+ Text [ portuguese_brazilian ] = "Haltepunkte" ;
+ Text [ portuguese ] = "Pontos de ruptura" ;
+ Text[ chinese_simplified ] = "ÖÐÖ¹µã";
+ Text[ russian ] = "Òî÷êè îñòàíîâà";
+ Text[ polish ] = "Punkty przerwania";
+ Text[ japanese ] = "ÌÞÚ°¸Îß²ÝÄ";
+ Text[ chinese_traditional ] = "¤¤¤îÂI";
+ Text[ arabic ] = "äÞÇØ ÇáÅíÞÇÝ";
+ Text[ greek ] = "Óçìåßá äéáêïðÞò";
+ Text[ korean ] = "Áß´ÜÁ¡";
+ Text[ turkish ] = "Kesme noktalarý";
+ Text[ language_user1 ] = " ";
+ };
+ NumericField RID_FLD_PASS
+ {
+ Border = TRUE ;
+ Pos = MAP_APPFONT ( 41 , 100 ) ;
+ Size = MAP_APPFONT ( 40 , 12 ) ;
+ TabStop = TRUE ;
+ };
+ Text [ english_us ] = "Breakpoints" ;
+ Text [ italian ] = "Punto di interruzione" ;
+ Text [ spanish ] = "Puntos de ruptura" ;
+ Text [ french ] = "Points d'arrêt" ;
+ Text [ dutch ] = "Stoppunten" ;
+ Text [ swedish ] = "Brytpunkter" ;
+ Text [ danish ] = "Pausepunkter" ;
+ Text [ portuguese_brazilian ] = "Haltepunkte" ;
+ Text [ portuguese ] = "Pontos de ruptura" ;
+ Text[ chinese_simplified ] = "ÖÐÖ¹µã";
+ Text[ russian ] = "Òî÷êè îñòàíîâà";
+ Text[ polish ] = "Punkty przerwania";
+ Text[ japanese ] = "ÌÞÚ°¸Îß²ÝÄ";
+ Text[ chinese_traditional ] = "¤¤¤îÂI";
+ Text[ arabic ] = "äÞÇØ ÇáÅíÞÇÝ";
+ Text[ greek ] = "Óçìåßá äéáêïðÞò";
+ Text[ korean ] = "Áß´ÜÁ¡";
+ Text[ turkish ] = "Kesme noktalarý";
+ Text[ language_user1 ] = " ";
+};
diff --git a/basctl/source/basicide/ide_pch.cxx b/basctl/source/basicide/ide_pch.cxx
new file mode 100644
index 000000000000..2ed6865f38f0
--- /dev/null
+++ b/basctl/source/basicide/ide_pch.cxx
@@ -0,0 +1,63 @@
+/*************************************************************************
+ *
+ * $RCSfile: ide_pch.cxx,v $
+ *
+ * $Revision: 1.1.1.1 $
+ *
+ * last change: $Author: mh $ $Date: 2000-09-29 11:02:36 $
+ *
+ * The Contents of this file are made available subject to the terms of
+ * either of the following licenses
+ *
+ * - GNU Lesser General Public License Version 2.1
+ * - Sun Industry Standards Source License Version 1.1
+ *
+ * Sun Microsystems Inc., October, 2000
+ *
+ * GNU Lesser General Public License Version 2.1
+ * =============================================
+ * Copyright 2000 by Sun Microsystems, Inc.
+ * 901 San Antonio Road, Palo Alto, CA 94303, USA
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License version 2.1, as published by the Free Software Foundation.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this library; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston,
+ * MA 02111-1307 USA
+ *
+ *
+ * Sun Industry Standards Source License Version 1.1
+ * =================================================
+ * The contents of this file are subject to the Sun Industry Standards
+ * Source License Version 1.1 (the "License"); You may not use this file
+ * except in compliance with the License. You may obtain a copy of the
+ * License at http://www.openoffice.org/license.html.
+ *
+ * Software provided under this License is provided on an "AS IS" basis,
+ * WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING,
+ * WITHOUT LIMITATION, WARRANTIES THAT THE SOFTWARE IS FREE OF DEFECTS,
+ * MERCHANTABLE, FIT FOR A PARTICULAR PURPOSE, OR NON-INFRINGING.
+ * See the License for the specific provisions governing your rights and
+ * obligations concerning the Software.
+ *
+ * The Initial Developer of the Original Code is: Sun Microsystems, Inc.
+ *
+ * Copyright: 2000 by Sun Microsystems, Inc.
+ *
+ * All Rights Reserved.
+ *
+ * Contributor(s): _______________________________________
+ *
+ *
+ ************************************************************************/
+#include <ide_pch.hxx>
+#pragma hdrstop
+
diff --git a/basctl/source/basicide/ide_pch.hxx b/basctl/source/basicide/ide_pch.hxx
new file mode 100644
index 000000000000..4c9ab484f17f
--- /dev/null
+++ b/basctl/source/basicide/ide_pch.hxx
@@ -0,0 +1,181 @@
+/*************************************************************************
+ *
+ * $RCSfile: ide_pch.hxx,v $
+ *
+ * $Revision: 1.1.1.1 $
+ *
+ * last change: $Author: mh $ $Date: 2000-09-29 11:02:36 $
+ *
+ * The Contents of this file are made available subject to the terms of
+ * either of the following licenses
+ *
+ * - GNU Lesser General Public License Version 2.1
+ * - Sun Industry Standards Source License Version 1.1
+ *
+ * Sun Microsystems Inc., October, 2000
+ *
+ * GNU Lesser General Public License Version 2.1
+ * =============================================
+ * Copyright 2000 by Sun Microsystems, Inc.
+ * 901 San Antonio Road, Palo Alto, CA 94303, USA
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License version 2.1, as published by the Free Software Foundation.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this library; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston,
+ * MA 02111-1307 USA
+ *
+ *
+ * Sun Industry Standards Source License Version 1.1
+ * =================================================
+ * The contents of this file are subject to the Sun Industry Standards
+ * Source License Version 1.1 (the "License"); You may not use this file
+ * except in compliance with the License. You may obtain a copy of the
+ * License at http://www.openoffice.org/license.html.
+ *
+ * Software provided under this License is provided on an "AS IS" basis,
+ * WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING,
+ * WITHOUT LIMITATION, WARRANTIES THAT THE SOFTWARE IS FREE OF DEFECTS,
+ * MERCHANTABLE, FIT FOR A PARTICULAR PURPOSE, OR NON-INFRINGING.
+ * See the License for the specific provisions governing your rights and
+ * obligations concerning the Software.
+ *
+ * The Initial Developer of the Original Code is: Sun Microsystems, Inc.
+ *
+ * Copyright: 2000 by Sun Microsystems, Inc.
+ *
+ * All Rights Reserved.
+ *
+ * Contributor(s): _______________________________________
+ *
+ *
+ ************************************************************************/
+#include <svheader.hxx>
+
+#include <vcl/wrkwin.hxx>
+#include <vcl/msgbox.hxx>
+#include <vcl/menu.hxx>
+
+#include <svtools/svarray.hxx>
+#include <svtools/itemset.hxx>
+#include <svtools/aeitem.hxx>
+#include <svtools/stritem.hxx>
+#include <svtools/whiter.hxx>
+
+#define _BASIC_TEXTPORTIONS
+#include <basic/sbdef.hxx>
+#include <basic/sbstar.hxx>
+#include <basic/sbmeth.hxx>
+#include <basic/sbmod.hxx>
+#include <basic/basmgr.hxx>
+
+#include <sfx2/app.hxx>
+#include <sfx2/objface.hxx>
+#include <sfx2/printer.hxx>
+#include <sfx2/viewsh.hxx>
+#include <sfx2/event.hxx>
+#include <sfx2/bindings.hxx>
+#include <sfx2/request.hxx>
+#include <sfx2/childwin.hxx>
+#include <sfx2/viewfrm.hxx>
+#include <sfx2/dispatch.hxx>
+#include <sfx2/objsh.hxx>
+#include <sfx2/genlink.hxx>
+#include <sfx2/dispatch.hxx>
+#include <sfx2/tbxmgr.hxx>
+#include <sfx2/minfitem.hxx>
+#include <sfx2/dinfdlg.hxx>
+#include <sfx2/stbmgr.hxx>
+#include <sfx2/docfac.hxx>
+#include <sfx2/progress.hxx>
+
+
+#define ITEMID_FONT 0
+#define ITEMID_POSTURE 0
+#define ITEMID_WEIGHT 0
+#define ITEMID_SHADOWED 0
+#define ITEMID_CONTOUR 0
+#define ITEMID_CROSSEDOUT 0
+#define ITEMID_UNDERLINE 0
+#define ITEMID_FONTHEIGHT 0
+#define ITEMID_COLOR 0
+#define ITEMID_ADJUST 0
+#define ITEMID_LINESPACING 0
+#define ITEMID_TABSTOP 0
+#define ITEMID_LRSPACE 0
+#define ITEMID_ULSPACE 0
+#define ITEMID_SEARCH 0
+#define ITEMID_SEARCH 0
+#define ITEMID_SIZE 0
+#define ITEMID_FONTLIST 0
+#define ITEMID_AUTOKERN 0
+#define ITEMID_WORDLINEMODE 0
+#define ITEMID_PROPSIZE 0
+#define ITEMID_CHARSETCOLOR 0
+#define ITEMID_KERNING 0
+#define ITEMID_CASEMAP 0
+#define ITEMID_ESCAPEMENT 0
+#define ITEMID_LANGUAGE 0
+#define ITEMID_NOLINEBREAK 0
+#define ITEMID_NOHYPHENHERE 0
+#define ITEMID_BLINK 0
+#define ITEMID_PAPERBIN 0
+#define ITEMID_PRINT 0
+#define ITEMID_OPAQUE 0
+#define ITEMID_PROTECT 0
+#define ITEMID_SHADOW 0
+#define ITEMID_BOX 0
+#define ITEMID_BOXINFO 0
+#define ITEMID_FMTBREAK 0
+#define ITEMID_FMTKEEP 0
+#define ITEMID_LINE 0
+#define ITEMID_BRUSH 0
+
+#include <svx/srchitem.hxx>
+#include <svx/flstitem.hxx>
+#include <svx/fontitem.hxx>
+#include <svx/postitem.hxx>
+#include <svx/wghtitem.hxx>
+#include <svx/fhgtitem.hxx>
+#include <svx/fwdtitem.hxx>
+#include <svx/udlnitem.hxx>
+#include <svx/crsditem.hxx>
+#include <svx/shdditem.hxx>
+#include <svx/akrnitem.hxx>
+#include <svx/wrlmitem.hxx>
+#include <svx/cntritem.hxx>
+#include <svx/prszitem.hxx>
+#include <svx/colritem.hxx>
+#include <svx/cscoitem.hxx>
+#include <svx/kernitem.hxx>
+
+#include <svx/cmapitem.hxx>
+#include <svx/escpitem.hxx>
+#include <svx/langitem.hxx>
+#include <svx/nlbkitem.hxx>
+#include <svx/nhypitem.hxx>
+#include <svx/lcolitem.hxx>
+#include <svx/blnkitem.hxx>
+
+#include <svx/pbinitem.hxx>
+#include <svx/sizeitem.hxx>
+#include <svx/lrspitem.hxx>
+#include <svx/ulspitem.hxx>
+#include <svx/prntitem.hxx>
+#include <svx/opaqitem.hxx>
+#include <svx/protitem.hxx>
+#include <svx/shaditem.hxx>
+#include <svx/boxitem.hxx>
+#include <svx/brkitem.hxx>
+#include <svx/keepitem.hxx>
+#include <svx/bolnitem.hxx>
+#include <svx/brshitem.hxx>
+
diff --git a/basctl/source/basicide/iderdll.cxx b/basctl/source/basicide/iderdll.cxx
new file mode 100644
index 000000000000..bbfb09831bd1
--- /dev/null
+++ b/basctl/source/basicide/iderdll.cxx
@@ -0,0 +1,273 @@
+/*************************************************************************
+ *
+ * $RCSfile: iderdll.cxx,v $
+ *
+ * $Revision: 1.1.1.1 $
+ *
+ * last change: $Author: mh $ $Date: 2000-09-29 11:02:37 $
+ *
+ * The Contents of this file are made available subject to the terms of
+ * either of the following licenses
+ *
+ * - GNU Lesser General Public License Version 2.1
+ * - Sun Industry Standards Source License Version 1.1
+ *
+ * Sun Microsystems Inc., October, 2000
+ *
+ * GNU Lesser General Public License Version 2.1
+ * =============================================
+ * Copyright 2000 by Sun Microsystems, Inc.
+ * 901 San Antonio Road, Palo Alto, CA 94303, USA
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License version 2.1, as published by the Free Software Foundation.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this library; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston,
+ * MA 02111-1307 USA
+ *
+ *
+ * Sun Industry Standards Source License Version 1.1
+ * =================================================
+ * The contents of this file are subject to the Sun Industry Standards
+ * Source License Version 1.1 (the "License"); You may not use this file
+ * except in compliance with the License. You may obtain a copy of the
+ * License at http://www.openoffice.org/license.html.
+ *
+ * Software provided under this License is provided on an "AS IS" basis,
+ * WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING,
+ * WITHOUT LIMITATION, WARRANTIES THAT THE SOFTWARE IS FREE OF DEFECTS,
+ * MERCHANTABLE, FIT FOR A PARTICULAR PURPOSE, OR NON-INFRINGING.
+ * See the License for the specific provisions governing your rights and
+ * obligations concerning the Software.
+ *
+ * The Initial Developer of the Original Code is: Sun Microsystems, Inc.
+ *
+ * Copyright: 2000 by Sun Microsystems, Inc.
+ *
+ * All Rights Reserved.
+ *
+ * Contributor(s): _______________________________________
+ *
+ *
+ ************************************************************************/
+
+
+#include <ide_pch.hxx>
+
+#pragma hdrstop
+
+#include <svheader.hxx>
+
+#ifndef _SFXAPP_HXX //autogen
+#include <sfx2/app.hxx>
+#endif
+
+#ifndef _SFXDISPATCH_HXX //autogen
+#include <sfx2/dispatch.hxx>
+#endif
+
+#ifndef _SFXGENLINK_HXX //autogen
+#include <sfx2/genlink.hxx>
+#endif
+
+#pragma hdrstop
+
+#include <svtools/solar.hrc>
+#include <iderdll.hxx>
+#include <iderdll2.hxx>
+#include <iderid.hxx>
+#include <svx/svxids.hrc>
+#include <basidesh.hxx>
+#include <basidesh.hrc>
+#include <basobj.hxx>
+#include <bastypes.hxx>
+
+#define ITEMID_SEARCH 0
+#include <svx/srchitem.hxx>
+
+IDEResId::IDEResId( USHORT nId ):
+ ResId( nId, (*(BasicIDEDLL**)GetAppData(SHL_IDE))->GetResMgr() )
+{
+}
+
+
+BasicIDEDLL::BasicIDEDLL()
+{
+ *(BasicIDEDLL**)GetAppData(SHL_IDE) = this;
+
+ ByteString aResMgrName( "basctl" );
+ aResMgrName += ByteString::CreateFromInt32( SOLARUPD );
+ pResMgr = ResMgr::CreateResMgr(
+ aResMgrName.GetBuffer(), Application::GetAppInternational().GetLanguage() );
+ pShell = 0;
+ pExtraData = 0;
+ GetExtraData(); // damit GlobalErrorHdl gesetzt wird.
+}
+
+BasicIDEDLL::~BasicIDEDLL()
+{
+ delete pResMgr;
+ delete pExtraData;
+ *(BasicIDEDLL**)GetAppData(SHL_IDE) = NULL;
+}
+
+BasicIDEData* BasicIDEDLL::GetExtraData()
+{
+ if ( !pExtraData )
+ pExtraData = new BasicIDEData;
+ return pExtraData;
+}
+
+BasicIDEData::BasicIDEData() : aObjCatPos( INVPOSITION, INVPOSITION )
+{
+ nBasicDialogCount = 0;
+ bChoosingMacro = FALSE;
+ bShellInCriticalSection = FALSE;
+ pSearchItem = new SvxSearchItem( SID_SEARCH_ITEM );
+ StarBASIC::SetGlobalErrorHdl( LINK( this, BasicIDEData, GlobalBasicErrorHdl ) );
+ StarBASIC::SetGlobalBreakHdl( LINK( this, BasicIDEData, GlobalBasicBreakHdl ) );
+
+ pAccelerator = 0;
+}
+
+BasicIDEData::~BasicIDEData()
+{
+ // ErrorHdl zuruecksetzen ist zwar sauberer, aber diese Instanz wird
+ // sowieso sehr spaet, nach dem letzten Basic, zerstoert.
+ // Durch den Aufruf werden dann aber wieder AppDaten erzeugt und nicht
+ // mehr zerstoert => MLK's beim Purify
+// StarBASIC::SetGlobalErrorHdl( Link() );
+// StarBASIC::SetGlobalBreakHdl( Link() );
+// StarBASIC::setGlobalStarScriptListener( XEngineListenerRef() );
+
+ delete pSearchItem;
+ delete pAccelerator;
+}
+
+void BasicIDEData::InitAccelerator()
+{
+ if ( !pAccelerator )
+ {
+ pAccelerator = new Accelerator;
+ pAccelerator->InsertItem( 1, KeyCode( KEY_F5 ) );
+ pAccelerator->InsertItem( 2, KeyCode( KEY_F5, KEY_SHIFT ) );
+ pAccelerator->InsertItem( 3, KeyCode( KEY_F5, KEY_MOD2 ) );
+ pAccelerator->InsertItem( 4, KeyCode( KEY_F7 ) );
+ pAccelerator->InsertItem( 5, KeyCode( KEY_F8 ) );
+ pAccelerator->InsertItem( 6, KeyCode( KEY_F8, KEY_SHIFT ) );
+ pAccelerator->InsertItem( 7, KeyCode( KEY_F9 ) );
+ }
+}
+
+SvxSearchItem& BasicIDEData::GetSearchItem() const
+{
+ return *pSearchItem;
+}
+
+void BasicIDEData::SetSearchItem( const SvxSearchItem& rItem )
+{
+ delete pSearchItem;
+ pSearchItem = (SvxSearchItem*)rItem.Clone();
+}
+
+IMPL_LINK( BasicIDEData, GlobalBasicErrorHdl, StarBASIC *, pBasic )
+{
+ BasicIDE::BasicStopped();
+
+ // Waerend der Macroauswahl keine Fehler ausgeben:
+ if ( bChoosingMacro )
+ return 1;
+ if ( bShellInCriticalSection )
+ return 2;
+
+ long nRet = 0;
+ BasicIDEShell* pShell = 0;
+ if ( SFX_APP()->HasFeature( SFX_FEATURE_BASIC_IDE ) )
+ {
+ BasicManager* pBasicManager = BasicIDE::FindBasicManager( pBasic );
+ if ( pBasicManager )
+ {
+ USHORT nLib = pBasicManager->GetLibId( pBasic );
+ if ( !pBasicManager->HasPassword( nLib ) ||
+ pBasicManager->IsPasswordVerified( nLib ) )
+ {
+ pShell = IDE_DLL()->GetShell();
+ if ( !pShell )
+ {
+ SfxViewFrame* pCurFrame = SfxViewFrame::Current();
+ DBG_ASSERT( pCurFrame != NULL, "No current view frame!" );
+ SfxDispatcher* pDispatcher = pCurFrame ? pCurFrame->GetDispatcher() : NULL;
+ if( pDispatcher )
+ {
+ pDispatcher->Execute( SID_BASICIDE_APPEAR, SFX_CALLMODE_SYNCHRON );
+ }
+ pShell = IDE_DLL()->GetShell();
+ }
+ }
+ }
+ }
+
+ if ( pShell )
+ nRet = pShell->CallBasicErrorHdl( pBasic );
+ else
+ BasicIDE::HandleBasicError();
+
+ return nRet;
+}
+
+
+IMPL_LINK( BasicIDEData, GlobalBasicBreakHdl, StarBASIC *, pBasic )
+{
+ BasicIDEShell* pShell = IDE_DLL()->GetShell();
+ if ( pShell )
+ {
+ BasicManager* pBasicManager = BasicIDE::FindBasicManager( pBasic );
+ if ( pBasicManager )
+ {
+ USHORT nLib = pBasicManager->GetLibId( pBasic );
+ // Hier lande ich zweimal, wenn Step into protected Basic
+ // => schlecht, wenn Passwortabfrage 2x, ausserdem sieht man in
+ // dem PasswordDlg nicht, fuer welche Lib...
+ // => An dieser Stelle keine Passwort-Abfrage starten
+ if ( !pBasicManager->HasPassword( nLib ) ||
+ pBasicManager->IsPasswordVerified( nLib ) /* ||
+ QueryPassword( pBasicManager, nLib ) */ )
+ {
+ return pShell->CallBasicBreakHdl( pBasic );
+ }
+ else
+ {
+ // Ein Step-Out muesste mich aus den geschuetzten Bereich befoerdern...
+ return SbDEBUG_STEPOUT;
+ }
+ }
+ }
+
+ return 0;
+}
+
+IMPL_LINK( BasicIDEData, ExecuteMacroEvent, void *, pData )
+{
+ if ( pData )
+ {
+ SFX_APP()->EnterBasicCall();
+ SbMethod* pMethod = (SbMethod*)pData;
+
+ // Ist es eine StarScript-Methode? Am Parent erkennen
+ SbModule* pModule = pMethod->GetModule();
+ DBG_ASSERT( pMethod->GetParent()->GetFlags() & SBX_EXTSEARCH, "Kein EXTSEARCH!" );
+ BasicIDE::RunMethod( pMethod );
+ pMethod->ReleaseRef(); // muss vorher inkrementiert worden sein!
+ SFX_APP()->LeaveBasicCall();
+ }
+ return 0;
+}
+
diff --git a/basctl/source/basicide/iderdll2.hxx b/basctl/source/basicide/iderdll2.hxx
new file mode 100644
index 000000000000..5e40273e51ac
--- /dev/null
+++ b/basctl/source/basicide/iderdll2.hxx
@@ -0,0 +1,157 @@
+/*************************************************************************
+ *
+ * $RCSfile: iderdll2.hxx,v $
+ *
+ * $Revision: 1.1.1.1 $
+ *
+ * last change: $Author: mh $ $Date: 2000-09-29 11:02:37 $
+ *
+ * The Contents of this file are made available subject to the terms of
+ * either of the following licenses
+ *
+ * - GNU Lesser General Public License Version 2.1
+ * - Sun Industry Standards Source License Version 1.1
+ *
+ * Sun Microsystems Inc., October, 2000
+ *
+ * GNU Lesser General Public License Version 2.1
+ * =============================================
+ * Copyright 2000 by Sun Microsystems, Inc.
+ * 901 San Antonio Road, Palo Alto, CA 94303, USA
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License version 2.1, as published by the Free Software Foundation.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this library; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston,
+ * MA 02111-1307 USA
+ *
+ *
+ * Sun Industry Standards Source License Version 1.1
+ * =================================================
+ * The contents of this file are subject to the Sun Industry Standards
+ * Source License Version 1.1 (the "License"); You may not use this file
+ * except in compliance with the License. You may obtain a copy of the
+ * License at http://www.openoffice.org/license.html.
+ *
+ * Software provided under this License is provided on an "AS IS" basis,
+ * WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING,
+ * WITHOUT LIMITATION, WARRANTIES THAT THE SOFTWARE IS FREE OF DEFECTS,
+ * MERCHANTABLE, FIT FOR A PARTICULAR PURPOSE, OR NON-INFRINGING.
+ * See the License for the specific provisions governing your rights and
+ * obligations concerning the Software.
+ *
+ * The Initial Developer of the Original Code is: Sun Microsystems, Inc.
+ *
+ * Copyright: 2000 by Sun Microsystems, Inc.
+ *
+ * All Rights Reserved.
+ *
+ * Contributor(s): _______________________________________
+ *
+ *
+ ************************************************************************/
+
+#ifndef _IDERDLL2_HXX
+#define _IDERDLL2_HXX
+
+class StarBASIC;
+class SvxSearchItem;
+class Accelerator;
+
+#ifndef _STRING_HXX //autogen
+#include <tools/string.hxx>
+#endif
+
+#ifndef _GEN_HXX //autogen
+#include <tools/gen.hxx>
+#endif
+
+#ifndef _LINK_HXX //autogen
+#include <tools/link.hxx>
+#endif
+
+#include <bastypes.hxx>
+
+#define INVPOSITION 0x7fff
+
+class BasicIDEData
+{
+private:
+ Accelerator* pAccelerator;
+ SvxSearchItem* pSearchItem;
+
+ LibInfos aLibInfos;
+
+ String TheLastMacroInMacroDlg;
+
+ Point aObjCatPos;
+ Size aObjCatSize;
+
+ String aAddLibPath;
+ String aAddLibFilter;
+
+ USHORT nBasicDialogCount;
+
+ BOOL OLD_bRelMacroRecording;
+ BOOL bChoosingMacro;
+ BOOL bShellInCriticalSection;
+
+ void InitAccelerator();
+
+protected:
+ DECL_LINK( GlobalBasicErrorHdl, StarBASIC * );
+ DECL_LINK( GlobalBasicBreakHdl, StarBASIC * );
+
+public:
+ BasicIDEData();
+ ~BasicIDEData();
+
+ LibInfos& GetLibInfos() { return aLibInfos; }
+
+ String& GetLastMacro() { return TheLastMacroInMacroDlg; }
+ BOOL& ChoosingMacro() { return bChoosingMacro; }
+ BOOL& ShellInCriticalSection() { return bShellInCriticalSection; }
+
+ USHORT GetBasicDialogCount() const { return nBasicDialogCount; }
+ void IncBasicDialogCount() { nBasicDialogCount++; }
+ void DecBasicDialogCount() { nBasicDialogCount--; }
+
+ SvxSearchItem& GetSearchItem() const;
+ void SetSearchItem( const SvxSearchItem& rItem );
+
+ void SetObjectCatalogPos( const Point& rPnt )
+ { aObjCatPos = rPnt; }
+ const Point& GetObjectCatalogPos() const
+ { return aObjCatPos; }
+
+ void SetObjectCatalogSize( const Size& rSize )
+ { aObjCatSize = rSize; }
+ const Size& GetObjectCatalogSize() const
+ { return aObjCatSize; }
+
+ const String& GetAddLibPath() const { return aAddLibPath; }
+ void SetAddLibPath( const String& rPath ) { aAddLibPath = rPath; }
+
+ const String& GetAddLibFilter() const { return aAddLibFilter; }
+ void SetAddLibFilter( const String& rFilter ) { aAddLibFilter = rFilter; }
+
+ Accelerator* GetAccelerator()
+ {
+ if ( !pAccelerator )
+ InitAccelerator();
+ return pAccelerator;
+ }
+
+ DECL_LINK( ExecuteMacroEvent, void * );
+};
+
+
+#endif //_IDERDLL2_HXX
diff --git a/basctl/source/basicide/idetemp.hxx b/basctl/source/basicide/idetemp.hxx
new file mode 100644
index 000000000000..b12d2d9e5e67
--- /dev/null
+++ b/basctl/source/basicide/idetemp.hxx
@@ -0,0 +1,87 @@
+/*************************************************************************
+ *
+ * $RCSfile: idetemp.hxx,v $
+ *
+ * $Revision: 1.1.1.1 $
+ *
+ * last change: $Author: mh $ $Date: 2000-09-29 11:02:37 $
+ *
+ * The Contents of this file are made available subject to the terms of
+ * either of the following licenses
+ *
+ * - GNU Lesser General Public License Version 2.1
+ * - Sun Industry Standards Source License Version 1.1
+ *
+ * Sun Microsystems Inc., October, 2000
+ *
+ * GNU Lesser General Public License Version 2.1
+ * =============================================
+ * Copyright 2000 by Sun Microsystems, Inc.
+ * 901 San Antonio Road, Palo Alto, CA 94303, USA
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License version 2.1, as published by the Free Software Foundation.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this library; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston,
+ * MA 02111-1307 USA
+ *
+ *
+ * Sun Industry Standards Source License Version 1.1
+ * =================================================
+ * The contents of this file are subject to the Sun Industry Standards
+ * Source License Version 1.1 (the "License"); You may not use this file
+ * except in compliance with the License. You may obtain a copy of the
+ * License at http://www.openoffice.org/license.html.
+ *
+ * Software provided under this License is provided on an "AS IS" basis,
+ * WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING,
+ * WITHOUT LIMITATION, WARRANTIES THAT THE SOFTWARE IS FREE OF DEFECTS,
+ * MERCHANTABLE, FIT FOR A PARTICULAR PURPOSE, OR NON-INFRINGING.
+ * See the License for the specific provisions governing your rights and
+ * obligations concerning the Software.
+ *
+ * The Initial Developer of the Original Code is: Sun Microsystems, Inc.
+ *
+ * Copyright: 2000 by Sun Microsystems, Inc.
+ *
+ * All Rights Reserved.
+ *
+ * Contributor(s): _______________________________________
+ *
+ *
+ ************************************************************************/
+#ifndef _IDETEMP_HXX
+#define _IDETEMP_HXX
+
+
+enum SvxChooseControlEnum
+{
+ SVX_SNAP_PUSHBUTTON,
+ SVX_SNAP_CHECKBOX,
+ SVX_SNAP_RADIOBUTTON,
+ SVX_SNAP_SPINBUTTON,
+ SVX_SNAP_FIXEDTEXT,
+ SVX_SNAP_GROUPBOX,
+ SVX_SNAP_LISTBOX,
+ SVX_SNAP_COMBOBOX,
+ SVX_SNAP_EDIT,
+ SVX_SNAP_HSCROLLBAR,
+ SVX_SNAP_VSCROLLBAR,
+ SVX_SNAP_PREVIEW,
+ SVX_SNAP_SELECT,
+ SVX_SNAP_URLBUTTON,
+ SVX_SNAP_NOTHING
+};
+
+#define SvxChooseControlItem SfxAllEnumItem
+
+#endif
+
diff --git a/basctl/source/basicide/macrodlg.cxx b/basctl/source/basicide/macrodlg.cxx
new file mode 100644
index 000000000000..b20d5e8298ab
--- /dev/null
+++ b/basctl/source/basicide/macrodlg.cxx
@@ -0,0 +1,853 @@
+/*************************************************************************
+ *
+ * $RCSfile: macrodlg.cxx,v $
+ *
+ * $Revision: 1.1.1.1 $
+ *
+ * last change: $Author: mh $ $Date: 2000-09-29 11:02:37 $
+ *
+ * The Contents of this file are made available subject to the terms of
+ * either of the following licenses
+ *
+ * - GNU Lesser General Public License Version 2.1
+ * - Sun Industry Standards Source License Version 1.1
+ *
+ * Sun Microsystems Inc., October, 2000
+ *
+ * GNU Lesser General Public License Version 2.1
+ * =============================================
+ * Copyright 2000 by Sun Microsystems, Inc.
+ * 901 San Antonio Road, Palo Alto, CA 94303, USA
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License version 2.1, as published by the Free Software Foundation.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this library; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston,
+ * MA 02111-1307 USA
+ *
+ *
+ * Sun Industry Standards Source License Version 1.1
+ * =================================================
+ * The contents of this file are subject to the Sun Industry Standards
+ * Source License Version 1.1 (the "License"); You may not use this file
+ * except in compliance with the License. You may obtain a copy of the
+ * License at http://www.openoffice.org/license.html.
+ *
+ * Software provided under this License is provided on an "AS IS" basis,
+ * WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING,
+ * WITHOUT LIMITATION, WARRANTIES THAT THE SOFTWARE IS FREE OF DEFECTS,
+ * MERCHANTABLE, FIT FOR A PARTICULAR PURPOSE, OR NON-INFRINGING.
+ * See the License for the specific provisions governing your rights and
+ * obligations concerning the Software.
+ *
+ * The Initial Developer of the Original Code is: Sun Microsystems, Inc.
+ *
+ * Copyright: 2000 by Sun Microsystems, Inc.
+ *
+ * All Rights Reserved.
+ *
+ * Contributor(s): _______________________________________
+ *
+ *
+ ************************************************************************/
+
+
+#include <ide_pch.hxx>
+
+#pragma hdrstop
+
+#include <macrodlg.hxx>
+#include <macrodlg.hrc>
+#include <basidesh.hrc>
+#include <baside2.hrc> // ID's fuer Imagese
+#include <basobj.hxx>
+
+#include <iderdll.hxx>
+#include <iderdll2.hxx>
+#include <iderid.hxx>
+
+#include <moduldlg.hxx>
+
+#ifndef _SBXCLASS_HXX //autogen
+#include <svtools/sbx.hxx>
+#endif
+#include <bastypes.hxx>
+#include <sbxitem.hxx>
+
+#ifndef _SFX_MINFITEM_HXX //autogen
+#include <sfx2/minfitem.hxx>
+#endif
+
+DECLARE_LIST( MacroList, SbMethod* );
+
+MacroChooser::MacroChooser( Window* pParnt, BOOL bScanBasics ) :
+ SfxModalDialog( pParnt, IDEResId( RID_MACROCHOOSER ) ),
+ aMacroNameTxt( this, IDEResId( RID_TXT_MACRONAME ) ),
+ aMacroNameEdit( this, IDEResId( RID_ED_MACRONAME ) ),
+ aMacroBox( this, IDEResId( RID_CTRL_MACRO ) ),
+ aMacroFromTxT( this, IDEResId( RID_TXT_MACROFROM ) ),
+ aBasicBox( this, IDEResId( RID_CTRL_LIB ) ),
+ aRunButton( this, IDEResId( RID_PB_RUN ) ),
+ aCancelCloseButton( this, IDEResId( RID_PB_CANCEL ) ),
+ aAssignButton( this, IDEResId( RID_PB_ASSIGN ) ),
+ aEditButton( this, IDEResId( RID_PB_EDIT ) ),
+ aNewDelButton( this, IDEResId( RID_PB_DEL ) ),
+ aOrganizeButton( this, IDEResId( RID_PB_ORG ) ),
+ aHelpButton( this, IDEResId( RID_PB_HELP ) ),
+ aDescrTxt( this, IDEResId( RID_TXT_DESCRIPTION ) ),
+ aDescrEdit( this, IDEResId( RID_ML_DESCRIPTION ) )
+{
+ FreeResource();
+
+ nMode = MACROCHOOSER_ALL;
+ bNewDelIsDel = TRUE;
+ bCancelCloseIsCancel = TRUE;
+ bAcceptDescription = TRUE;
+
+ // Der Sfx fragt den BasicManager nicht, ob modified
+ // => Speichern anschmeissen, wenn Aenderung, aber kein Sprung in
+ // die BasicIDE.
+ bForceStoreBasic = FALSE;
+
+ aMacroBox.SetSelectionMode( SINGLE_SELECTION );
+ aMacroBox.SetHighlightRange(); // ueber ganze Breite selektieren
+
+ aRunButton.SetClickHdl( LINK( this, MacroChooser, ButtonHdl ) );
+ aCancelCloseButton.SetClickHdl( LINK( this, MacroChooser, ButtonHdl ) );
+ aAssignButton.SetClickHdl( LINK( this, MacroChooser, ButtonHdl ) );
+ aEditButton.SetClickHdl( LINK( this, MacroChooser, ButtonHdl ) );
+ aNewDelButton.SetClickHdl( LINK( this, MacroChooser, ButtonHdl ) );
+ aOrganizeButton.SetClickHdl( LINK( this, MacroChooser, ButtonHdl ) );
+
+ aMacroNameEdit.SetModifyHdl( LINK( this, MacroChooser, EditModifyHdl ) );
+
+ aBasicBox.SetSelectHdl( LINK( this, MacroChooser, BasicSelectHdl ) );
+
+ aMacroBox.SetDoubleClickHdl( LINK( this, MacroChooser, MacroDoubleClickHdl ) );
+ aMacroBox.SetSelectHdl( LINK( this, MacroChooser, MacroSelectHdl ) );
+
+ aBasicBox.SetMode( BROWSEMODE_MODULES /* | BROWSEMODE_SUBS */ );
+ aBasicBox.SetWindowBits( WB_HASLINES );
+
+ aDescrEdit.SetGetFocusHdl( LINK( this, MacroChooser, EditGotFocusHdl ) );
+ aDescrEdit.SetLoseFocusHdl( LINK( this, MacroChooser, EditLoseFocusHdl ) );
+ aDescrEdit.SetModifyHdl( LINK( this, MacroChooser, DescriptionModifyHdl ) );
+ aDescrEdit.SetAccHdl( LINK( this, MacroChooser, EditAccHdl ) );
+ aDescrEdit.GetAccelerator().InsertItem( 1, KeyCode( KEY_ESCAPE ) );
+
+
+ SfxViewFrame* pCurFrame = SfxViewFrame::Current();
+ DBG_ASSERT( pCurFrame != NULL, "No current view frame!" );
+ SfxDispatcher* pDispatcher = pCurFrame ? pCurFrame->GetDispatcher() : NULL;
+ if( pDispatcher )
+ {
+ pDispatcher->Execute( SID_BASICIDE_STOREALLMODULESOURCES );
+ }
+
+ if ( bScanBasics )
+ aBasicBox.ScanAllBasics();
+}
+
+MacroChooser::~MacroChooser()
+{
+ if ( bForceStoreBasic )
+ SFX_APP()->SaveBasicManager();
+}
+
+void MacroChooser::StoreMacroDescription()
+{
+ String aLastMacroDescr( CreateEntryDescription( aBasicBox, aBasicBox.FirstSelected() ) );
+ if ( aLastMacroDescr.GetTokenCount( ';' ) < 3 )
+ aLastMacroDescr += ';';
+ aLastMacroDescr += ';';
+ SvLBoxEntry* pEntry = aMacroBox.FirstSelected();
+ if ( pEntry )
+ aLastMacroDescr += aMacroBox.GetEntryText ( pEntry );
+ else
+ aLastMacroDescr += aMacroNameEdit.GetText();
+
+ /*aLastMacroDescr += pEntry ? aMacroBox.GetEntryText( pEntry ) :
+ aMacroNameEdit.GetText();*/
+ IDE_DLL()->GetExtraData()->GetLastMacro() = aLastMacroDescr;
+}
+
+void MacroChooser::RestoreMacroDescription()
+{
+ String aLastMacroDescr( IDE_DLL()->GetExtraData()->GetLastMacro() );
+ if ( aLastMacroDescr.Len() )
+ {
+ // MacroEntry: BasMgr;Bas;Mod;Macro
+ SvLBoxEntry* pEntry = FindMostMatchingEntry( aBasicBox, aLastMacroDescr );
+ if ( pEntry )
+ aBasicBox.SetCurEntry( pEntry );
+ String aLastMacro( aLastMacroDescr.GetToken( 3, ';' ) );
+ if ( aLastMacro.Len() )
+ {
+ pEntry = FindMostMatchingEntry( aMacroBox, aLastMacro );
+ if ( pEntry )
+ aMacroBox.SetCurEntry( pEntry );
+ else
+ {
+ aMacroNameEdit.SetText( aLastMacro );
+ aMacroNameEdit.SetSelection( Selection( 0, 0 ) );
+ }
+ }
+ }
+}
+
+IMPL_LINK_INLINE_START( MacroChooser, EditGotFocusHdl, MultiLineEdit *, pEdit )
+{
+ bAcceptDescription = TRUE;
+ return 0;
+}
+IMPL_LINK_INLINE_END( MacroChooser, EditGotFocusHdl, MultiLineEdit *, pEdit )
+
+IMPL_LINK( MacroChooser, EditLoseFocusHdl, MultiLineEdit *, pEdit )
+{
+ if ( bAcceptDescription )
+ {
+ SbxVariable* pVar = GetMacro();
+/*
+ if ( !pVar )
+ {
+ SvLBoxEntry* pCurEntry = aBasicBox.GetCurEntry();
+ BYTE nType = pCurEntry ? ((BasicEntry*)pCurEntry->GetUserData())->GetType() : 0;
+ if ( ( nType == OBJTYPE_OBJECT ) || ( nType == OBJTYPE_MODULE ) ||
+ ( nType == OBJTYPE_METHOD ) || ( nType == OBJTYPE_LIB ) ||
+ ( nType == OBJTYPE_SUBOBJ ) )
+ {
+ pVar = aBasicBox.FindVariable( pCurEntry );
+ }
+
+ }
+*/
+ if ( pVar )
+ SetInfo( pVar );
+ }
+ return 0;
+}
+
+IMPL_LINK_INLINE_START( MacroChooser, DescriptionModifyHdl, MultiLineEdit *, pEdit )
+{
+ CheckCancelClose();
+ return 0;
+}
+IMPL_LINK_INLINE_END( MacroChooser, DescriptionModifyHdl, MultiLineEdit *, pEdit )
+
+
+
+IMPL_LINK( MacroChooser, EditAccHdl, Accelerator *, pAcc )
+{
+ if ( pAcc->GetCurKeyCode().GetCode() == KEY_ESCAPE )
+ {
+ bAcceptDescription = FALSE;
+ UpdateFields();
+ aCancelCloseButton.GrabFocus();
+ }
+
+ return 0;
+}
+
+short __EXPORT MacroChooser::Execute()
+{
+ String aLastMacroDescr( IDE_DLL()->GetExtraData()->GetLastMacro() );
+
+ aBasicBox.ExpandAllTrees();
+ if ( aLastMacroDescr.Len() )
+ {
+ RestoreMacroDescription();
+ aRunButton.GrabFocus();
+ }
+ else
+ {
+ // Erstes Macro selektieren:
+ SvLBoxEntry* pEntry = aBasicBox.GetEntry( 0 );
+// SvLBoxEntry* pFirstEntry = pEntry;
+ SvLBoxEntry* pLastValid = pEntry;
+ while ( pEntry )
+ {
+ pLastValid = pEntry;
+ pEntry = aBasicBox.FirstChild( pEntry );
+ }
+ if ( pLastValid )
+ {
+ // Pruefen, ob er Passwort-geschuetzt ist...
+// String aLib, aDummy1, aDummy2, aDummy3;
+// BasicManager* pBasicManager = aBasicBox.GetSbx( pLastValid, aLib, aDummy1, aDummy2, aDummy3 );
+// USHORT nLib = pBasicManager->GetLibId( aLib );
+// if ( !pBasicManager->HasPassword( nLib ) ||
+// pBasicManager->IsPasswordVerified( nLib ) )
+// {
+ aBasicBox.SetCurEntry( pLastValid );
+// }
+// else
+// {
+// aBasicBox.SetCurEntry( pFirstEntry );
+// }
+ }
+ }
+
+ CheckButtons();
+ UpdateFields();
+
+ if ( StarBASIC::IsRunning() )
+ aCancelCloseButton.GrabFocus();
+
+ Window* pPrevDlgParent = Application::GetDefDialogParent();
+ Application::SetDefDialogParent( this );
+ short nRet = ModalDialog::Execute();
+ // #57314# Wenn die BasicIDE aktiviert wurde, dann nicht den DefModalDialogParent auf das inaktive Dokument zuruecksetzen.
+ if ( Application::GetDefDialogParent() == this )
+ Application::SetDefDialogParent( pPrevDlgParent );
+ return nRet;
+}
+
+void MacroChooser::CheckCancelClose()
+{
+ if ( bCancelCloseIsCancel )
+ {
+ bCancelCloseIsCancel = FALSE;
+ aCancelCloseButton.SetText( String( IDEResId( RID_STR_CLOSE ) ) );
+ }
+}
+
+void MacroChooser::EnableButton( Button& rButton, BOOL bEnable )
+{
+ if ( bEnable )
+ {
+ if ( nMode == MACROCHOOSER_CHOOSEONLY )
+ {
+ // Nur der RunButton kann enabled werden
+ if ( &rButton == &aRunButton )
+ rButton.Enable();
+ else
+ rButton.Disable();
+ }
+ else
+ rButton.Enable();
+ }
+ else
+ rButton.Disable();
+}
+
+
+
+
+SbMethod* MacroChooser::GetMacro()
+{
+ SbMethod* pMethod = 0;
+ SbModule* pModule = aBasicBox.FindModule( aBasicBox.GetCurEntry() );
+ if ( pModule )
+ {
+ SvLBoxEntry* pEntry = aMacroBox.FirstSelected();
+ if ( pEntry )
+ {
+ String aMacroName( aMacroBox.GetEntryText( pEntry ) );
+ pMethod = (SbMethod*)pModule->GetMethods()->Find( aMacroName, SbxCLASS_METHOD );
+ }
+ }
+ return pMethod;
+}
+
+
+
+void MacroChooser::DeleteMacro()
+{
+ SbMethod* pMethod = GetMacro();
+ DBG_ASSERT( pMethod, "DeleteMacro: Kein Macro !" );
+ if ( pMethod && QueryDelMacro( pMethod->GetName(), this ) )
+ {
+ SfxViewFrame* pCurFrame = SfxViewFrame::Current();
+ DBG_ASSERT( pCurFrame != NULL, "No current view frame!" );
+ SfxDispatcher* pDispatcher = pCurFrame ? pCurFrame->GetDispatcher() : NULL;
+ if( pDispatcher )
+ {
+ pDispatcher->Execute( SID_BASICIDE_STOREALLMODULESOURCES );
+ }
+
+ // Aktuelles Doc als geaendert markieren:
+ StarBASIC* pBasic = BasicIDE::FindBasic( pMethod );
+ DBG_ASSERT( pBasic, "Basic?!" );
+ BasicManager* pBasMgr = BasicIDE::FindBasicManager( pBasic );
+ DBG_ASSERT( pBasMgr, "BasMgr?" );
+ SfxObjectShell* pShell = BasicIDE::FindDocShell( pBasMgr );
+ if ( pShell ) // Muss ja nicht aus einem Document kommen...
+ {
+ pShell->SetModified();
+ BasicIDE::GetBindings().Invalidate( SID_SAVEDOC );
+ }
+
+ SbModule* pModule = pMethod->GetModule();
+ DBG_ASSERT( pModule, "DeleteMacro: Kein Modul?!" );
+ String aSource( pModule->GetSource() );
+ USHORT nStart, nEnd;
+ pMethod->GetLineRange( nStart, nEnd );
+ pModule->GetMethods()->Remove( pMethod );
+ CutLines( aSource, nStart-1, nEnd-nStart+1, TRUE );
+ pModule->SetSource( aSource );
+ SvLBoxEntry* pEntry = aMacroBox.FirstSelected();
+ DBG_ASSERT( pEntry, "DeleteMacro: Entry ?!" );
+ aMacroBox.GetModel()->Remove( pEntry );
+ bForceStoreBasic = TRUE;
+ }
+}
+
+SbMethod* MacroChooser::CreateMacro()
+{
+ String aLib, aMod, aSub;
+ BasicManager* pBasMgr = aBasicBox.GetSelectedSbx( aLib, aMod, aSub );
+ aSub = aMacroNameEdit.GetText();
+ DBG_ASSERT( pBasMgr, "Record/New: Kein BasicManager?" );
+ StarBASIC* pBasic = aLib.Len() ? pBasMgr->GetLib( aLib ) : pBasMgr->GetLib( 0 );
+ if ( !pBasic )
+ pBasic = pBasMgr->GetLib( 0 );
+ DBG_ASSERT( pBasic, "Record/New: Kein Basic?" );
+ SbModule* pModule = 0;
+ if( aMod.Len() )
+ pModule = pBasic->FindModule( aMod );
+ else if ( pBasic->GetModules()->Count() )
+ pModule = (SbModule*)pBasic->GetModules()->Get( 0 );
+
+ if ( !pModule )
+ {
+ NewObjectDialog* pNewDlg = new NewObjectDialog( this, NEWOBJECTMODE_MOD );
+ pNewDlg->SetObjectName( BasicIDE::CreateModuleName( pBasic, aMod ) );
+ if ( pNewDlg->Execute() )
+ {
+ aMod = pNewDlg->GetObjectName();
+ if ( !BasicIDE::FindModule( pBasic, aMod ) )
+ {
+ pModule = BasicIDE::CreateModule( pBasic, aMod, FALSE );
+ DBG_ASSERT( pModule , "Modul wurde nicht erzeugt!" );
+ }
+ else
+ {
+ ErrorBox( this, WB_OK | WB_DEF_OK,
+ String( IDEResId( RID_STR_SBXNAMEALLREADYUSED2 ) ) ).Execute();
+ }
+ }
+ delete pNewDlg;
+ }
+
+ DBG_ASSERT( !pModule || !pModule->GetMethods()->Find( aSub, SbxCLASS_METHOD ), "Macro existiert schon!" );
+ SbMethod* pMethod = pModule ? BasicIDE::CreateMacro( pModule, aSub ) : NULL;
+ return pMethod;
+}
+
+
+
+void MacroChooser::ScanBasic( BasicManager* pBasMgr, const String& rName )
+{
+ aBasicBox.ScanBasic( pBasMgr, rName );
+}
+
+
+
+void MacroChooser::SaveSetCurEntry( SvTreeListBox& rBox, SvLBoxEntry* pEntry )
+{
+ // Durch das Highlight wird das Edit sonst platt gemacht:
+
+ String aSaveText( aMacroNameEdit.GetText() );
+ Selection aCurSel( aMacroNameEdit.GetSelection() );
+
+ rBox.SetCurEntry( pEntry );
+ aMacroNameEdit.SetText( aSaveText );
+ aMacroNameEdit.SetSelection( aCurSel );
+}
+
+void MacroChooser::CheckButtons()
+{
+ SvLBoxEntry* pCurEntry = aBasicBox.GetCurEntry();
+ SvLBoxEntry* pMacroEntry = aMacroBox.FirstSelected();
+ SbxVariable* pVar = aBasicBox.FindVariable( pCurEntry );
+ SbMethod* pMethod = GetMacro();
+
+ // Run...
+ BOOL bEnable = pMethod ? TRUE : FALSE;
+ if ( ( nMode != MACROCHOOSER_CHOOSEONLY ) && StarBASIC::IsRunning() )
+ bEnable = FALSE;
+ EnableButton( aRunButton, bEnable );
+
+ // Organisieren immer moeglich ?
+
+ // Assign...
+ EnableButton( aAssignButton, pMethod ? TRUE : FALSE );
+
+ // Edit...
+ EnableButton( aEditButton, pMacroEntry ? TRUE : FALSE );
+
+ // aOrganizeButton
+ EnableButton( aOrganizeButton, !StarBASIC::IsRunning() && ( nMode == MACROCHOOSER_ALL ));
+
+ // aNewDelButton....
+ EnableButton( aNewDelButton,
+ !StarBASIC::IsRunning() && ( nMode == MACROCHOOSER_ALL ) && !aBasicBox.IsEntryProtected( aBasicBox.GetCurEntry() ) );
+ BOOL bPrev = bNewDelIsDel;
+ bNewDelIsDel = pMethod ? TRUE : FALSE;
+ if ( ( bPrev != bNewDelIsDel ) && ( nMode != MACROCHOOSER_CHOOSEONLY ) )
+ {
+ String aBtnText( bNewDelIsDel ? IDEResId( RID_STR_BTNDEL) : IDEResId( RID_STR_BTNNEW ) );
+ aNewDelButton.SetText( aBtnText );
+ }
+}
+
+
+
+IMPL_LINK_INLINE_START( MacroChooser, MacroDoubleClickHdl, SvTreeListBox *, EMPTYARG )
+{
+ StoreMacroDescription();
+ EndDialog( MACRO_OK_RUN );
+ return 0;
+}
+IMPL_LINK_INLINE_END( MacroChooser, MacroDoubleClickHdl, SvTreeListBox *, EMPTYARG )
+
+IMPL_LINK( MacroChooser, MacroSelectHdl, SvTreeListBox *, pBox )
+{
+ // Wird auch gerufen, wenn Deselektiert!
+ // 2 Funktionsaufrufe in jedem SelectHdl, nur weil Olli
+ // keinen separatren DeselctHdl einfuehren wollte:
+ // Also: Feststellen, ob Select oder Deselect:
+ if ( pBox->IsSelected( pBox->GetHdlEntry() ) )
+ {
+ UpdateFields();
+ CheckButtons();
+ }
+ return 0;
+}
+
+IMPL_LINK( MacroChooser, BasicSelectHdl, SvTreeListBox *, pBox )
+{
+ // Wird auch gerufen, wenn Deselektiert!
+ // 2 Funktionsaufrufe in jedem SelectHdl, nur weil Olli
+ // keinen separatren DeselctHdl einfuehren wollte:
+ // Also: Feststellen, ob Select oder Deselect:
+ if ( !pBox->IsSelected( pBox->GetHdlEntry() ) )
+ return 0;
+
+ SbModule* pModule = aBasicBox.FindModule( aBasicBox.GetCurEntry() );
+
+ aMacroBox.Clear();
+ if ( pModule )
+ {
+ // Die Macros sollen in der Reihenfolge angezeigt werden,
+ // wie sie im Modul stehen.
+ MacroList aMacros;
+ USHORT nMacros = pModule->GetMethods()->Count();
+ USHORT nMethod;
+ for ( nMethod = 0; nMethod < nMacros; nMethod++ )
+ {
+ SbMethod* pMethod = (SbMethod*)pModule->GetMethods()->Get( nMethod );
+ DBG_ASSERT( pMethod, "Methode nicht gefunden! (NULL)" );
+ ULONG nPos = LIST_APPEND;
+ // Eventuell weiter vorne ?
+ USHORT nStart, nEnd;
+ pMethod->GetLineRange( nStart, nEnd );
+ for ( ULONG n = 0; n < aMacros.Count(); n++ )
+ {
+ USHORT nS, nE;
+ SbMethod* pM = aMacros.GetObject( n );
+ DBG_ASSERT( pM, "Macro nicht in Liste ?!" );
+ pM->GetLineRange( nS, nE );
+ if ( nS > nStart )
+ {
+ nPos = n;
+ break;
+ }
+ }
+ aMacros.Insert( pMethod, nPos );
+ }
+
+ aMacroBox.SetUpdateMode( FALSE );
+ for ( nMethod = 0; nMethod < nMacros; nMethod++ )
+ aMacroBox.InsertEntry( aMacros.GetObject( nMethod )->GetName() );
+ aMacroBox.SetUpdateMode( TRUE );
+
+ if ( aMacroBox.GetEntryCount() )
+ {
+ SvLBoxEntry* pEntry = aMacroBox.GetEntry( 0 );
+ DBG_ASSERT( pEntry, "Entry ?!" );
+ aMacroBox.SetCurEntry( pEntry );
+ }
+ }
+
+ UpdateFields();
+ CheckButtons();
+ return 0;
+}
+
+
+
+IMPL_LINK( MacroChooser, EditModifyHdl, Edit *, pEdit )
+{
+ // Das Modul, in dem bei Neu das Macro landet, selektieren,
+ // wenn BasicManager oder Lib selektiert.
+ SvLBoxEntry* pCurEntry = aBasicBox.GetCurEntry();
+ if ( pCurEntry )
+ {
+ USHORT nDepth = aBasicBox.GetModel()->GetDepth( pCurEntry );
+ if ( ( nDepth == 1 ) && ( aBasicBox.IsEntryProtected( pCurEntry ) ) )
+ {
+ // Dann auf die entsprechende Std-Lib stellen...
+ SvLBoxEntry* pManagerEntry = aBasicBox.GetModel()->GetParent( pCurEntry );
+ pCurEntry = aBasicBox.GetModel()->FirstChild( pManagerEntry );
+ }
+ if ( nDepth < 2 )
+ {
+ SvLBoxEntry* pNewEntry = pCurEntry;
+ while ( pCurEntry && ( nDepth < 2 ) )
+ {