summaryrefslogtreecommitdiff
path: root/vcl
diff options
context:
space:
mode:
authormm <mm@openoffice.org>2001-02-22 15:03:13 +0000
committermm <mm@openoffice.org>2001-02-22 15:03:13 +0000
commit4b0b0bef6e9288dd170b8350a53172a1d6ee0b56 (patch)
tree967eff8852eecef592e1938c908641b20c03334e /vcl
parent109b0e5ea423660e705d51dc7f03ef55ec57ad8b (diff)
vcl possibly without main
Diffstat (limited to 'vcl')
-rw-r--r--vcl/workben/makefile.mk7
-rw-r--r--vcl/workben/svdem.cxx32
2 files changed, 30 insertions, 9 deletions
diff --git a/vcl/workben/makefile.mk b/vcl/workben/makefile.mk
index a12a98182174..f942436c12b6 100644
--- a/vcl/workben/makefile.mk
+++ b/vcl/workben/makefile.mk
@@ -2,9 +2,9 @@
#
# $RCSfile: makefile.mk,v $
#
-# $Revision: 1.1.1.1 $
+# $Revision: 1.2 $
#
-# last change: $Author: hr $ $Date: 2000-09-18 17:05:50 $
+# last change: $Author: mm $ $Date: 2001-02-22 16:03:13 $
#
# The Contents of this file are made available subject to the terms of
# either of the following licenses
@@ -81,7 +81,8 @@ OBJFILES= $(OBJ)$/svdem.obj
APP1NOSAL= TRUE
APP1TARGET= $(TARGET)
APP1OBJS= $(OBJFILES) \
- $(OBJ)$/salmain.obj
+
+# $(OBJ)$/salmain.obj
APP1STDLIBS= $(CPPULIB) \
$(TOOLSLIB) \
diff --git a/vcl/workben/svdem.cxx b/vcl/workben/svdem.cxx
index db5666d21bbb..7d318e6b6b81 100644
--- a/vcl/workben/svdem.cxx
+++ b/vcl/workben/svdem.cxx
@@ -2,9 +2,9 @@
*
* $RCSfile: svdem.cxx,v $
*
- * $Revision: 1.1.1.1 $
+ * $Revision: 1.2 $
*
- * last change: $Author: hr $ $Date: 2000-09-18 17:05:50 $
+ * last change: $Author: mm $ $Date: 2001-02-22 16:03:13 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@@ -63,18 +63,39 @@
#include <wrkwin.hxx>
#include <msgbox.hxx>
+#include <sal/main.h>
+
+#include <com/sun/star/lang/XMultiServiceFactory.hpp>
+
// -----------------------------------------------------------------------
+void Main();
+/*
class MyApp : public Application
{
public:
- void Main();
+ void Main()
+ {
+ ::Main();
+ }
};
MyApp aMyApp;
+*/
// -----------------------------------------------------------------------
+
+SAL_IMPLEMENT_MAIN()
+{
+ ::com::sun::star::uno::Reference< ::com::sun::star::lang::XMultiServiceFactory > xMS;
+ InitVCL( xMS );
+ Main();
+ DeInitVCL();
+ return 0;
+}
+
+
class MyWin : public WorkWindow
{
public:
@@ -90,14 +111,13 @@ public:
};
// -----------------------------------------------------------------------
-
-void MyApp::Main()
+void Main()
{
MyWin aMainWin( NULL, WB_APP | WB_STDWORK );
aMainWin.SetText( XubString( RTL_CONSTASCII_USTRINGPARAM( "VCL - Workbench" ) ) );
aMainWin.Show();
- Execute();
+ Application::Execute();
}
// -----------------------------------------------------------------------