summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorhg <hg@oosvn01.>2009-10-08 16:03:52 +0000
committerhg <hg@oosvn01.>2009-10-08 16:03:52 +0000
commit6c454a61745f73825b843a24a912c2976d1308e5 (patch)
treefe864e8fb5be16523ba689b3fa152976226cf9a5
parentaccedbb3caa51b0d9686dbdef56e17c9fcf4bd99 (diff)
parent219c155e515255b8b040d853b598fb1d6c009e8c (diff)
merge with m55
-rw-r--r--bridges/source/cpp_uno/gcc3_linux_m68k/makefile.mk6
-rw-r--r--cppu/inc/uno/lbnames.h7
-rw-r--r--offapi/com/sun/star/awt/tree/XTreeDataModelListener.idl2
-rw-r--r--offapi/com/sun/star/deployment/XPackage.idl22
-rw-r--r--offapi/com/sun/star/deployment/ui/UpdateRequiredDialog.idl54
-rw-r--r--offapi/com/sun/star/deployment/ui/makefile.mk5
-rw-r--r--offapi/com/sun/star/sheet/FilterFormulaParser.idl55
-rw-r--r--offapi/com/sun/star/sheet/FilterOperator2.idl164
-rw-r--r--offapi/com/sun/star/sheet/FormulaParser.idl7
-rw-r--r--offapi/com/sun/star/sheet/TableFilterField2.idl106
-rw-r--r--offapi/com/sun/star/sheet/XFilterFormulaParser.idl62
-rw-r--r--offapi/com/sun/star/sheet/XFormulaParser.idl14
-rw-r--r--offapi/com/sun/star/sheet/XSheetFilterDescriptor2.idl79
-rw-r--r--offapi/com/sun/star/sheet/makefile.mk5
-rw-r--r--offapi/com/sun/star/task/DocumentMSPasswordRequest.idl67
-rw-r--r--offapi/com/sun/star/task/makefile.mk2
-rw-r--r--offapi/com/sun/star/ui/dialogs/FilePicker.idl5
-rwxr-xr-xoffapi/util/checknewapi.pl10
-rw-r--r--offapi/util/makefile.mk3
-rw-r--r--rdbmaker/inc/codemaker/dependency.hxx1
-rw-r--r--rdbmaker/inc/codemaker/global.hxx4
-rw-r--r--rdbmaker/source/codemaker/dependency.cxx29
-rw-r--r--sal/inc/systools/win32/snprintf.h4
-rw-r--r--sal/osl/os2/util.c5
-rw-r--r--sal/osl/unx/file.cxx69
-rw-r--r--sal/osl/unx/file_impl.hxx48
-rw-r--r--sal/osl/unx/file_path_helper.cxx10
-rw-r--r--sal/osl/unx/file_path_helper.h17
-rw-r--r--sal/osl/unx/file_path_helper.hxx19
-rw-r--r--sal/osl/unx/file_stat.cxx70
-rw-r--r--sal/osl/unx/file_url.cxx56
-rw-r--r--sal/osl/unx/process.c12
-rw-r--r--sal/osl/unx/security.c9
-rw-r--r--sal/osl/unx/util.c77
-rw-r--r--sal/osl/w32/conditn.c3
-rw-r--r--sal/osl/w32/diagnose.c4
-rw-r--r--sal/osl/w32/util.c9
37 files changed, 849 insertions, 272 deletions
diff --git a/bridges/source/cpp_uno/gcc3_linux_m68k/makefile.mk b/bridges/source/cpp_uno/gcc3_linux_m68k/makefile.mk
index 32d4b0d27dc9..8371d653a25b 100644
--- a/bridges/source/cpp_uno/gcc3_linux_m68k/makefile.mk
+++ b/bridges/source/cpp_uno/gcc3_linux_m68k/makefile.mk
@@ -61,8 +61,7 @@ CFLAGSNOOPT=-O0
SLOFILES= \
$(SLO)$/cpp2uno.obj \
$(SLO)$/except.obj \
- $(SLO)$/uno2cpp.obj \
- $(SLO)$/m68khelper.obj
+ $(SLO)$/uno2cpp.obj
SHL1TARGET= $(TARGET)
@@ -83,6 +82,3 @@ SHL1STDLIBS= \
# --- Targets ------------------------------------------------------
.INCLUDE : target.mk
-
-$(SLO)$/%.obj: %.s
- $(CXX) -c -o $(SLO)$/$(@:b).o $< -fPIC ; touch $@
diff --git a/cppu/inc/uno/lbnames.h b/cppu/inc/uno/lbnames.h
index 27a6f1094a0a..481180fda953 100644
--- a/cppu/inc/uno/lbnames.h
+++ b/cppu/inc/uno/lbnames.h
@@ -46,12 +46,9 @@
#endif /* (_MSC_VER < 1000) */
/* sunpro cc */
#elif defined (__SUNPRO_CC)
-#if (__SUNPRO_CC < 0x500)
-#error "sunpro cc must be at least 5.x"
-provoking error here, because PP ignores #error
-#elif (__SUNPRO_CC < 0x600)
+#if ((__SUNPRO_CC >= 0x5000 && __SUNPRO_CC < 0x6000) || (__SUNPRO_CC >= 0x500 && __SUNPRO_CC < 0x600))
#define TMP_CPPU_ENV sunpro5
-#else
+#elif
#error "sunpro cc version must be 5.x"
provoking error here, because PP ignores #error
#endif /* defined (__SUNPRO_CC) */
diff --git a/offapi/com/sun/star/awt/tree/XTreeDataModelListener.idl b/offapi/com/sun/star/awt/tree/XTreeDataModelListener.idl
index 81e98b301954..8ea308f69a6f 100644
--- a/offapi/com/sun/star/awt/tree/XTreeDataModelListener.idl
+++ b/offapi/com/sun/star/awt/tree/XTreeDataModelListener.idl
@@ -62,7 +62,7 @@ interface XTreeDataModelListener: com::sun::star::lang::XEventListener
Example: the name of a file has changed, but it is in the same location in the file system.
To indicate the root has changed, <member>TreeDataModelEvent::Nodes</member> will contain
- the root node and and <member>TreeDataModelEvent::ParentNode</member will be empty.
+ the root node and <member>TreeDataModelEvent::ParentNode</member> will be empty.
*/
void treeNodesChanged( [in] TreeDataModelEvent Event );
diff --git a/offapi/com/sun/star/deployment/XPackage.idl b/offapi/com/sun/star/deployment/XPackage.idl
index 4847f09090a2..36799875eee1 100644
--- a/offapi/com/sun/star/deployment/XPackage.idl
+++ b/offapi/com/sun/star/deployment/XPackage.idl
@@ -6,9 +6,6 @@
*
* OpenOffice.org - a multi-platform office productivity suite
*
- * $RCSfile: XPackage.idl,v $
- * $Revision: 1.14 $
- *
* This file is part of OpenOffice.org.
*
* OpenOffice.org is free software: you can redistribute it and/or modify
@@ -102,6 +99,25 @@ interface XPackage
com::sun::star::ucb::CommandFailedException,
com::sun::star::ucb::CommandAbortedException);
+ /** checks if the dependencies for this package are still satisfied
+
+ After updateing the OpenOffice.org, some dependencies for packages might
+ no longer be satisfied.
+
+ @since OOo 3.2.0
+
+ @param xCmdEnv
+ command environment for error handling and other interaction.
+
+ @return
+ true - all dependencies are satisfied
+ false - at least one dependency failed.
+ */
+ boolean checkDependencies(
+ [in] com::sun::star::ucb::XCommandEnvironment xCmdEnv )
+ raises (DeploymentException,
+ com::sun::star::ucb::CommandFailedException);
+
/** determines whether the package is currently is registered, i.e.
whether it is active.
diff --git a/offapi/com/sun/star/deployment/ui/UpdateRequiredDialog.idl b/offapi/com/sun/star/deployment/ui/UpdateRequiredDialog.idl
new file mode 100644
index 000000000000..761070eb7443
--- /dev/null
+++ b/offapi/com/sun/star/deployment/ui/UpdateRequiredDialog.idl
@@ -0,0 +1,54 @@
+/*************************************************************************
+ *
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * Copyright 2009 by Sun Microsystems, Inc.
+ *
+ * OpenOffice.org - a multi-platform office productivity suite
+ *
+ * This file is part of OpenOffice.org.
+ *
+ * OpenOffice.org is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU Lesser General Public License version 3
+ * only, as published by the Free Software Foundation.
+ *
+ * OpenOffice.org 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 version 3 for more details
+ * (a copy is included in the LICENSE file that accompanied this code).
+ *
+ * You should have received a copy of the GNU Lesser General Public License
+ * version 3 along with OpenOffice.org. If not, see
+ * <http://www.openoffice.org/license.html>
+ * for a copy of the LGPLv3 License.
+ *
+ ************************************************************************/
+
+#if ! defined INCLUDED_com_sun_star_deployment_ui_UpdateRequiredDialog_idl
+#define INCLUDED_com_sun_star_deployment_ui_UpdateRequiredDialog_idl
+
+#include <com/sun/star/ui/dialogs/XExecutableDialog.idl>
+#include <com/sun/star/awt/XWindow.idl>
+
+
+module com { module sun { module star { module deployment { module ui {
+
+/** The <type>UpdateRequiredDialog</type> is used to show a list of extensions not compatible with this office version.
+
+ @since OOo 3.2.0
+*/
+service UpdateRequiredDialog : com::sun::star::ui::dialogs::XExecutableDialog
+{
+ /** Create a GUI using the specific parent window and focus on the
+ given context.
+
+ @param xParent
+ parent window
+ */
+ create();
+};
+
+}; }; }; }; };
+
+#endif
diff --git a/offapi/com/sun/star/deployment/ui/makefile.mk b/offapi/com/sun/star/deployment/ui/makefile.mk
index d91d20001bb5..f733c762a80c 100644
--- a/offapi/com/sun/star/deployment/ui/makefile.mk
+++ b/offapi/com/sun/star/deployment/ui/makefile.mk
@@ -39,8 +39,9 @@ PACKAGE = com$/sun$/star$/deployment$/ui
.INCLUDE : $(PRJ)$/util$/makefile.pmk
IDLFILES = \
- PackageManagerDialog.idl \
- LicenseDialog.idl
+ PackageManagerDialog.idl \
+ LicenseDialog.idl \
+ UpdateRequiredDialog.idl
.INCLUDE : target.mk
.INCLUDE : $(PRJ)$/util$/target.pmk
diff --git a/offapi/com/sun/star/sheet/FilterFormulaParser.idl b/offapi/com/sun/star/sheet/FilterFormulaParser.idl
new file mode 100644
index 000000000000..ed1a1d073e29
--- /dev/null
+++ b/offapi/com/sun/star/sheet/FilterFormulaParser.idl
@@ -0,0 +1,55 @@
+/*************************************************************************
+ *
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * Copyright 2008 by Sun Microsystems, Inc.
+ *
+ * OpenOffice.org - a multi-platform office productivity suite
+ *
+ * $RCSfile: FilterFormulaParser.idl,v $
+ * $Revision: 1.1 $
+ *
+ * This file is part of OpenOffice.org.
+ *
+ * OpenOffice.org is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU Lesser General Public License version 3
+ * only, as published by the Free Software Foundation.
+ *
+ * OpenOffice.org 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 version 3 for more details
+ * (a copy is included in the LICENSE file that accompanied this code).
+ *
+ * You should have received a copy of the GNU Lesser General Public License
+ * version 3 along with OpenOffice.org. If not, see
+ * <http://www.openoffice.org/license.html>
+ * for a copy of the LGPLv3 License.
+ *
+ ************************************************************************/
+
+#ifndef __com_sun_star_sheet_FilterFormulaParser_idl__
+#define __com_sun_star_sheet_FilterFormulaParser_idl__
+
+#include <com/sun/star/sheet/XFilterFormulaParser.idl>
+#include <com/sun/star/lang/XComponent.idl>
+
+//=============================================================================
+
+module com { module sun { module star { module sheet {
+
+//=============================================================================
+
+/** A service used to implement parsing and printing formula strings in a
+ specific formula language.
+ */
+service FilterFormulaParser : XFilterFormulaParser
+{
+};
+
+//=============================================================================
+
+}; }; }; };
+
+#endif
+
diff --git a/offapi/com/sun/star/sheet/FilterOperator2.idl b/offapi/com/sun/star/sheet/FilterOperator2.idl
new file mode 100644
index 000000000000..94935979c8f5
--- /dev/null
+++ b/offapi/com/sun/star/sheet/FilterOperator2.idl
@@ -0,0 +1,164 @@
+/*************************************************************************
+ *
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * Copyright 2008 by Sun Microsystems, Inc.
+ *
+ * OpenOffice.org - a multi-platform office productivity suite
+ *
+ * $RCSfile: FilterOperator2.idl,v $
+ * $Revision: 1.7 $
+ *
+ * This file is part of OpenOffice.org.
+ *
+ * OpenOffice.org is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU Lesser General Public License version 3
+ * only, as published by the Free Software Foundation.
+ *
+ * OpenOffice.org 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 version 3 for more details
+ * (a copy is included in the LICENSE file that accompanied this code).
+ *
+ * You should have received a copy of the GNU Lesser General Public License
+ * version 3 along with OpenOffice.org. If not, see
+ * <http://www.openoffice.org/license.html>
+ * for a copy of the LGPLv3 License.
+ *
+ ************************************************************************/
+
+#ifndef __com_sun_star_sheet_FilterOperator2_idl__
+#define __com_sun_star_sheet_FilterOperator2_idl__
+
+//=============================================================================
+
+module com { module sun { module star { module sheet {
+
+//=============================================================================
+
+/** specifies the type of a single condition in a filter descriptor.
+
+ <p>This constants group extends the <type>FilterOperator</type> enum by
+ additional filter operators.</p>
+
+ @since OOo 3.2
+ */
+published constants FilterOperator2
+{
+
+ //-------------------------------------------------------------------------
+
+ /** selects empty entries.
+ */
+ const long EMPTY = 0;
+
+ //-------------------------------------------------------------------------
+
+ /** selects non-empty entries.
+ */
+ const long NOT_EMPTY = 1;
+
+ //-------------------------------------------------------------------------
+
+ /** value has to be equal to the specified value.
+ */
+ const long EQUAL = 2;
+
+ //-------------------------------------------------------------------------
+
+ /** value must not be equal to the specified value.
+ */
+ const long NOT_EQUAL = 3;
+
+ //-------------------------------------------------------------------------
+
+ /** value has to be greater than the specified value.
+ */
+ const long GREATER = 4;
+
+ //-------------------------------------------------------------------------
+
+ /** value has to be greater than or equal to the specified value.
+ */
+ const long GREATER_EQUAL = 5;
+
+ //-------------------------------------------------------------------------
+
+ /** value has to be less than the specified value.
+ */
+ const long LESS = 6;
+
+ //-------------------------------------------------------------------------
+
+ /** value has to be less than or equal to the specified value.
+ */
+ const long LESS_EQUAL = 7;
+
+ //-------------------------------------------------------------------------
+
+ /** selects a specified number of entries with the greatest values.
+ */
+ const long TOP_VALUES = 8;
+
+ //-------------------------------------------------------------------------
+
+ /** selects a specified percentage of entries with the greatest values.
+ */
+ const long TOP_PERCENT = 9;
+
+ //-------------------------------------------------------------------------
+
+ /** selects a specified number of entries with the lowest values.
+ */
+ const long BOTTOM_VALUES = 10;
+
+ //-------------------------------------------------------------------------
+
+ /** selects a specified percentage of entries with the lowest values.
+ */
+ const long BOTTOM_PERCENT = 11;
+
+ //-------------------------------------------------------------------------
+
+ /** selects contains entries.
+ */
+ const long CONTAINS = 12;
+
+ //-------------------------------------------------------------------------
+
+ /** selects does-not-contain entries.
+ */
+ const long DOES_NOT_CONTAIN = 13;
+
+ //-------------------------------------------------------------------------
+
+ /** selects begins-with entries.
+ */
+ const long BEGINS_WITH = 14;
+
+ //-------------------------------------------------------------------------
+
+ /** selects does-not-begin-with entries.
+ */
+ const long DOES_NOT_BEGIN_WITH = 15;
+ //-------------------------------------------------------------------------
+
+ /** selects ends-with entries.
+ */
+ const long ENDS_WITH = 16;
+
+ //-------------------------------------------------------------------------
+
+ /** selects does-not-end-with entries.
+ */
+ const long DOES_NOT_END_WITH = 17;
+
+};
+
+//=============================================================================
+
+}; }; }; };
+
+#endif
+
diff --git a/offapi/com/sun/star/sheet/FormulaParser.idl b/offapi/com/sun/star/sheet/FormulaParser.idl
index ba38acf791b0..2f8be7e8ee9b 100644
--- a/offapi/com/sun/star/sheet/FormulaParser.idl
+++ b/offapi/com/sun/star/sheet/FormulaParser.idl
@@ -37,9 +37,6 @@
#ifndef __com_sun_star_sheet_XFormulaParser_idl__
#include <com/sun/star/sheet/XFormulaParser.idl>
#endif
-#ifndef __com_sun_star_table_CellAddress_idl__
-#include <com/sun/star/table/CellAddress.idl>
-#endif
#ifndef __com_sun_star_sheet_FormulaOpCodeMapEntry_idl__
#include <com/sun/star/sheet/FormulaOpCodeMapEntry.idl>
#endif
@@ -65,10 +62,6 @@ service FormulaParser
// ------------------------------------------------------------------------
- [property] com::sun::star::table::CellAddress ReferencePosition;
-
- // ------------------------------------------------------------------------
-
/** specifies whether to use English parser and formatter.
<p>Note: When changing this, an already existing <member>OpCodeMap
diff --git a/offapi/com/sun/star/sheet/TableFilterField2.idl b/offapi/com/sun/star/sheet/TableFilterField2.idl
new file mode 100644
index 000000000000..1cf50ddd547b
--- /dev/null
+++ b/offapi/com/sun/star/sheet/TableFilterField2.idl
@@ -0,0 +1,106 @@
+/*************************************************************************
+ *
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * Copyright 2008 by Sun Microsystems, Inc.
+ *
+ * OpenOffice.org - a multi-platform office productivity suite
+ *
+ * $RCSfile: TableFilterField2.idl,v $
+ * $Revision: 1.7 $
+ *
+ * This file is part of OpenOffice.org.
+ *
+ * OpenOffice.org is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU Lesser General Public License version 3
+ * only, as published by the Free Software Foundation.
+ *
+ * OpenOffice.org 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 version 3 for more details
+ * (a copy is included in the LICENSE file that accompanied this code).
+ *
+ * You should have received a copy of the GNU Lesser General Public License
+ * version 3 along with OpenOffice.org. If not, see
+ * <http://www.openoffice.org/license.html>
+ * for a copy of the LGPLv3 License.
+ *
+ ************************************************************************/
+
+#ifndef __com_sun_star_sheet_TableFilterField2_idl__
+#define __com_sun_star_sheet_TableFilterField2_idl__
+
+
+#ifndef __com_sun_star_sheet_FilterConnection_idl__
+#include <com/sun/star/sheet/FilterConnection.idl>
+#endif
+
+#ifndef __com_sun_star_sheet_FilterOperator2_idl__
+#include <com/sun/star/sheet/FilterOperator2.idl>
+#endif
+
+//=============================================================================
+
+module com { module sun { module star { module sheet {
+
+//=============================================================================
+
+/** describes a single condition in a filter descriptor.
+
+ <p>This struct has the <type>FilterOperator2</type> constants group as
+ member, whereas the <type>TableFilterField</type> struct uses the
+ <type>FilterOperator</type> enum.</p>
+
+ @see com::sun::star::sheet::SheetFilterDescriptor
+ @since OOo 3.2
+ */
+published struct TableFilterField2
+{
+ //-------------------------------------------------------------------------
+
+ /** specifies how the condition is connected to the previous condition.
+ */
+ com::sun::star::sheet::FilterConnection Connection;
+
+ //-------------------------------------------------------------------------
+
+ /** specifies which field (column) is used for the condition.
+ */
+ long Field;
+
+ //-------------------------------------------------------------------------
+
+ /** specifies the type of the condition as defined in
+ <type>FilterOperator2</type>.
+ */
+ long Operator;
+
+ //-------------------------------------------------------------------------
+
+ /** selects whether the <member>TableFilterField2::NumericValue</member>
+ or the <member>TableFilterField2::StringValue</member> is used.
+ */
+ boolean IsNumeric;
+
+ //-------------------------------------------------------------------------
+
+ /** specifies a numeric value for the condition.
+ */
+ double NumericValue;
+
+ //-------------------------------------------------------------------------
+
+ /** specifies a string value for the condition.
+ */
+ string StringValue;
+
+};
+
+//=============================================================================
+
+}; }; }; };
+
+
+#endif
+
diff --git a/offapi/com/sun/star/sheet/XFilterFormulaParser.idl b/offapi/com/sun/star/sheet/XFilterFormulaParser.idl
new file mode 100644
index 000000000000..300a0981d09d
--- /dev/null
+++ b/offapi/com/sun/star/sheet/XFilterFormulaParser.idl
@@ -0,0 +1,62 @@
+/*************************************************************************
+ *
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * Copyright 2008 by Sun Microsystems, Inc.
+ *
+ * OpenOffice.org - a multi-platform office productivity suite
+ *
+ * $RCSfile: XFilterFormulaParser.idl,v $
+ * $Revision: 1.1 $
+ *
+ * This file is part of OpenOffice.org.
+ *
+ * OpenOffice.org is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU Lesser General Public License version 3
+ * only, as published by the Free Software Foundation.
+ *
+ * OpenOffice.org 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 version 3 for more details
+ * (a copy is included in the LICENSE file that accompanied this code).
+ *
+ * You should have received a copy of the GNU Lesser General Public License
+ * version 3 along with OpenOffice.org. If not, see
+ * <http://www.openoffice.org/license.html>
+ * for a copy of the LGPLv3 License.
+ *
+ ************************************************************************/
+
+#ifndef __com_sun_star_sheet_XFilterFormulaParser_idl__
+#define __com_sun_star_sheet_XFilterFormulaParser_idl__
+
+#include <com/sun/star/sheet/XFormulaParser.idl>
+
+//=============================================================================
+
+module com { module sun { module star { module sheet {
+
+//=============================================================================
+
+/** Extends the interface <type>XFormulaParser</type> by an attribute that
+ specifies the namespace URL of the supported formula language.
+ */
+interface XFilterFormulaParser : XFormulaParser
+{
+ //-------------------------------------------------------------------------
+
+ /** Specifies the namespace URL of the formula language supported by this
+ implementation.
+ */
+ [attribute, readonly] string SupportedNamespace;
+
+ //-------------------------------------------------------------------------
+};
+
+//=============================================================================
+
+}; }; }; };
+
+#endif
+
diff --git a/offapi/com/sun/star/sheet/XFormulaParser.idl b/offapi/com/sun/star/sheet/XFormulaParser.idl
index b4c02cea3bd1..de78f00f02dd 100644
--- a/offapi/com/sun/star/sheet/XFormulaParser.idl
+++ b/offapi/com/sun/star/sheet/XFormulaParser.idl
@@ -31,13 +31,9 @@
#ifndef __com_sun_star_sheet_XFormulaParser_idl__
#define __com_sun_star_sheet_XFormulaParser_idl__
-#ifndef __com_sun_star_uno_XInterface_idl__
#include <com/sun/star/uno/XInterface.idl>
-#endif
-
-#ifndef __com_sun_star_sheet_FormulaToken_idl__
#include <com/sun/star/sheet/FormulaToken.idl>
-#endif
+#include <com/sun/star/table/CellAddress.idl>
//=============================================================================
@@ -53,13 +49,17 @@ interface XFormulaParser
/** parses a formula into a sequence of tokens.
*/
- sequence< FormulaToken > parseFormula( [in] string aFormula );
+ sequence< FormulaToken > parseFormula(
+ [in] string aFormula,
+ [in] ::com::sun::star::table::CellAddress aReferencePos );
//-------------------------------------------------------------------------
/** converts a formula into a string.
*/
- string printFormula( [in] sequence< FormulaToken > aTokens );
+ string printFormula(
+ [in] sequence< FormulaToken > aTokens,
+ [in] ::com::sun::star::table::CellAddress aReferencePos );
};
diff --git a/offapi/com/sun/star/sheet/XSheetFilterDescriptor2.idl b/offapi/com/sun/star/sheet/XSheetFilterDescriptor2.idl
new file mode 100644
index 000000000000..cc26a73c1674
--- /dev/null
+++ b/offapi/com/sun/star/sheet/XSheetFilterDescriptor2.idl
@@ -0,0 +1,79 @@
+/*************************************************************************
+ *
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * Copyright 2008 by Sun Microsystems, Inc.
+ *
+ * OpenOffice.org - a multi-platform office productivity suite
+ *
+ * $RCSfile: XSheetFilterDescriptor2.idl,v $
+ * $Revision: 1.9 $
+ *
+ * This file is part of OpenOffice.org.
+ *
+ * OpenOffice.org is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU Lesser General Public License version 3
+ * only, as published by the Free Software Foundation.
+ *
+ * OpenOffice.org 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 version 3 for more details
+ * (a copy is included in the LICENSE file that accompanied this code).
+ *
+ * You should have received a copy of the GNU Lesser General Public License
+ * version 3 along with OpenOffice.org. If not, see
+ * <http://www.openoffice.org/license.html>
+ * for a copy of the LGPLv3 License.
+ *
+ ************************************************************************/
+
+#ifndef __com_sun_star_sheet_XSheetFilterDescriptor2_idl__
+#define __com_sun_star_sheet_XSheetFilterDescriptor2_idl__
+
+#ifndef __com_sun_star_sheet_TableFilterField2_idl__
+#include <com/sun/star/sheet/TableFilterField2.idl>
+#endif
+
+#ifndef __com_sun_star_uno_XInterface_idl__
+#include <com/sun/star/uno/XInterface.idl>
+#endif
+
+//=============================================================================
+
+module com { module sun { module star { module sheet {
+
+//=============================================================================
+
+/** provides access to a collection of filter conditions (filter fields).
+
+ <p>This interface uses the <type>TableFilterField2</type> struct,
+ whereas the <type>XSheetFilterDescriptor</type> interface uses the
+ <type>TableFilterField</type> struct.</p>
+
+ @see com::sun::star::sheet::SheetFilterDescriptor
+ @since OOo 3.2
+ */
+published interface XSheetFilterDescriptor2: com::sun::star::uno::XInterface
+{
+ //-------------------------------------------------------------------------
+
+ /** returns the collection of filter fields.
+ */
+ sequence< com::sun::star::sheet::TableFilterField2 > getFilterFields2();
+
+ //-------------------------------------------------------------------------
+
+ /** sets a new collection of filter fields.
+ */
+ void setFilterFields2(
+ [in] sequence< com::sun::star::sheet::TableFilterField2 > aFilterFields );
+
+};
+
+//=============================================================================
+
+}; }; }; };
+
+#endif
+
diff --git a/offapi/com/sun/star/sheet/makefile.mk b/offapi/com/sun/star/sheet/makefile.mk
index f6ca0810604e..468e96b9860b 100644
--- a/offapi/com/sun/star/sheet/makefile.mk
+++ b/offapi/com/sun/star/sheet/makefile.mk
@@ -137,7 +137,9 @@ IDLFILES=\
FillDirection.idl\
FillMode.idl\
FilterConnection.idl\
+ FilterFormulaParser.idl\
FilterOperator.idl\
+ FilterOperator2.idl\
FormulaLanguage.idl\
FormulaMapGroup.idl\
FormulaMapGroupSpecialOffset.idl\
@@ -219,6 +221,7 @@ IDLFILES=\
TableConditionalEntryEnumeration.idl\
TableConditionalFormat.idl\
TableFilterField.idl\
+ TableFilterField2.idl\
TableOperationMode.idl\
TablePageBreakData.idl\
TablePageStyle.idl\
@@ -274,6 +277,7 @@ IDLFILES=\
XExternalSheetCache.idl\
XExternalSheetName.idl\
XFillAcrossSheet.idl\
+ XFilterFormulaParser.idl\
XFormulaOpCodeMapper.idl\
XFormulaParser.idl\
XFormulaQuery.idl\
@@ -315,6 +319,7 @@ IDLFILES=\
XSheetConditionalEntries.idl\
XSheetConditionalEntry.idl\
XSheetFilterDescriptor.idl\
+ XSheetFilterDescriptor2.idl\
XSheetFilterable.idl\
XSheetFilterableEx.idl\
XSheetLinkable.idl\
diff --git a/offapi/com/sun/star/task/DocumentMSPasswordRequest.idl b/offapi/com/sun/star/task/DocumentMSPasswordRequest.idl
new file mode 100644
index 000000000000..6e4adec10720
--- /dev/null
+++ b/offapi/com/sun/star/task/DocumentMSPasswordRequest.idl
@@ -0,0 +1,67 @@
+/*************************************************************************
+ *
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * Copyright IBM Corporation 2009.
+ * Copyright 2009 by Sun Microsystems, Inc.
+ *
+ * OpenOffice.org - a multi-platform office productivity suite
+ *
+ * $RCSfile: DocumentMSPasswordRequest.idl,v $
+ * $Revision: 1.0 $
+ *
+ * This file is part of OpenOffice.org.
+ *
+ * OpenOffice.org is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU Lesser General Public License version 3
+ * only, as published by the Free Software Foundation.
+ *
+ * OpenOffice.org 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 version 3 for more details
+ * (a copy is included in the LICENSE file that accompanied this code).
+ *
+ * You should have received a copy of the GNU Lesser General Public License
+ * version 3 along with OpenOffice.org. If not, see
+ * <http://www.openoffice.org/license.html>
+ * for a copy of the LGPLv3 License.
+ *
+ ************************************************************************/
+#ifndef __com_sun_star_task_DocumentMSPasswordRequest_idl__
+#define __com_sun_star_task_DocumentMSPasswordRequest_idl__
+
+#ifndef __com_sun_star_task_PasswordRequest_idl__
+#include <com/sun/star/task/PasswordRequest.idl>
+#endif
+
+
+//=============================================================================
+
+module com { module sun { module star { module task {
+
+//=============================================================================
+/** this request specifies the mode in which the password for Microsoft Office file format encryption should be asked
+
+ <P>
+ It is supported by <type>InteractionHandler</type> service, and can
+ be used to interact for a document password. Continuations for using with
+ the mentioned service are Abort and Approve.
+ </P>
+
+ @since OOo 3.x.x
+*/
+published exception DocumentMSPasswordRequest: PasswordRequest
+{
+ //-------------------------------------------------------------------------
+ /** the name of the document
+ */
+ string Name;
+
+};
+
+//=============================================================================
+
+}; }; }; };
+
+#endif
diff --git a/offapi/com/sun/star/task/makefile.mk b/offapi/com/sun/star/task/makefile.mk
index 366d531fc847..1559901f740c 100644
--- a/offapi/com/sun/star/task/makefile.mk
+++ b/offapi/com/sun/star/task/makefile.mk
@@ -3,6 +3,7 @@
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
#
# Copyright 2008 by Sun Microsystems, Inc.
+# Copyright IBM Corporation 2009.
#
# OpenOffice.org - a multi-platform office productivity suite
#
@@ -45,6 +46,7 @@ IDLFILES=\
ClassifiedInteractionRequest.idl\
DocumentMacroConfirmationRequest.idl\
DocumentPasswordRequest.idl\
+ DocumentMSPasswordRequest.idl\
ErrorCodeRequest.idl\
ErrorCodeIOException.idl\
FutureDocumentVersionProductUpdateRequest.idl\
diff --git a/offapi/com/sun/star/ui/dialogs/FilePicker.idl b/offapi/com/sun/star/ui/dialogs/FilePicker.idl
index b2f4d8ed258c..c15ab0287631 100644
--- a/offapi/com/sun/star/ui/dialogs/FilePicker.idl
+++ b/offapi/com/sun/star/ui/dialogs/FilePicker.idl
@@ -60,6 +60,11 @@ module com { module sun { module star { module ui { module dialogs {
//=============================================================================
/** A FilePicker.
+ It is <strong>NOT</strong> recommended to cache a reference to a file
+ picker instance. Due to restrictions by the underlying system there can
+ be specific limitations possible. To overcome these problems it'
+ s recommended to create a new instance on demand.
+
@see XFilePicker
*/
diff --git a/offapi/util/checknewapi.pl b/offapi/util/checknewapi.pl
index 9c810d695461..e3141cda0737 100755
--- a/offapi/util/checknewapi.pl
+++ b/offapi/util/checknewapi.pl
@@ -6,23 +6,25 @@
# Copyright (c) 2005 Sun Microsystems, Inc.
#
-if($#ARGV != 2)
+if($#ARGV != 3)
{
- die "usage: checknewapi <new_type_library> <reference_type_library> <buildinfodescr>\n";
+ die "usage: checknewapi <new_type_library> <reference_type_library> <buildinfodescr> <fullpath_regview>\n";
}
-e "$ARGV[0]" || die "ERROR: type library \"$ARGV[0]\" does not exist\n";
-e "$ARGV[1]" || die "ERROR: reference type library \"$ARGV[1]\" does not exist\n";
+-e "$ARGV[3]" || die "ERROR: invalid path to the regview tool \"$ARGV[3]\", please specify the full qualified path\n";
# debug flag
$DEBUG = 0;
$main::buildinfo = "$ARGV[2]";
+$main::regview = "$ARGV[3]";
%{$main::reftypes} = ();
%{$main::currenttypes} = ();
%{$main::removedtypes} = ();
-open ( FILEIN, "regview \"$ARGV[0]\" |" ) || die "could not use content of current typelibrary \"$ARGV[0]\", regview doesn't work\n";
+open ( FILEIN, "$main::regview \"$ARGV[0]\" |" ) || die "could not use content of current typelibrary \"$ARGV[0]\", regview doesn't work\n";
if ($DEBUG == 1)
{
@@ -74,7 +76,7 @@ while (<FILEIN>)
close( FILEIN );
close( CURRENT );
-open ( FILEIN, "regview \"$ARGV[1]\" |" ) || die "could not use content of reference type library \"$ARGV[1]\", regview doesn't work\n";
+open ( FILEIN, "$main::regview \"$ARGV[1]\" |" ) || die "could not use content of reference type library \"$ARGV[1]\", regview doesn't work\n";
if ($DEBUG == 1)
{
diff --git a/offapi/util/makefile.mk b/offapi/util/makefile.mk
index 6e4a41503a56..52b63249839a 100644
--- a/offapi/util/makefile.mk
+++ b/offapi/util/makefile.mk
@@ -152,6 +152,7 @@ REGISTRYCHECKFLAG=$(MISC)$/registrycheck.flag
UNOTYPE_STATISTICS=$(MISC)$/unotype_statistics.txt
+REGVIEWTOOL=$(SOLARBINDIR)$/regview$(EXECPOST)
# --- Targets ------------------------------------------------------
@@ -183,6 +184,6 @@ $(REGISTRYCHECKFLAG) : $(UCR)$/types.db $(OUT)$/ucrdoc$/types_doc.db
#JSC: new target to prepare some UNO type statistics, the ouput will be later used
# for versioning of UNO cli type libraries
$(UNOTYPE_STATISTICS) : $(REGISTRYCHECKFLAG)
- $(AUGMENT_LIBRARY_PATH) $(PERL) checknewapi.pl $(UCR)$/types.db $(REFERENCE_RDB) "$(RSCREVISION)" > $@
+ $(AUGMENT_LIBRARY_PATH) $(PERL) checknewapi.pl $(UCR)$/types.db $(REFERENCE_RDB) "$(RSCREVISION)" "$(REGVIEWTOOL)" > $@
.INCLUDE : target.mk
diff --git a/rdbmaker/inc/codemaker/dependency.hxx b/rdbmaker/inc/codemaker/dependency.hxx
index c0fff9da7c7d..648564d8f50b 100644
--- a/rdbmaker/inc/codemaker/dependency.hxx
+++ b/rdbmaker/inc/codemaker/dependency.hxx
@@ -154,7 +154,6 @@ public:
sal_Bool insert(const ::rtl::OString& type, const ::rtl::OString& depend, sal_uInt16);
TypeUsingSet getDependencies(const ::rtl::OString& type);
- sal_Bool lookupDependency(const ::rtl::OString& type, const ::rtl::OString& depend, sal_uInt16);
sal_Bool hasDependencies(const ::rtl::OString& type);
void setGenerated(const ::rtl::OString& type, sal_uInt16 genFlag=CODEGEN_DEFAULT);
diff --git a/rdbmaker/inc/codemaker/global.hxx b/rdbmaker/inc/codemaker/global.hxx
index df1f588f5ffc..26133477dfa0 100644
--- a/rdbmaker/inc/codemaker/global.hxx
+++ b/rdbmaker/inc/codemaker/global.hxx
@@ -75,10 +75,6 @@ typedef ::std::set< ::rtl::OString, LessString > StringSet;
::rtl::OString makeTempName();
const ::rtl::OString inGlobalSet(const ::rtl::OUString & r);
-inline const ::rtl::OString inGlobalSet(sal_Char* p)
-{
- return inGlobalSet( ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM(p) ) );
-}
::rtl::OUString convertToFileUrl(const ::rtl::OString& fileName);
diff --git a/rdbmaker/source/codemaker/dependency.cxx b/rdbmaker/source/codemaker/dependency.cxx
index 091b379aa298..692184a8be3f 100644
--- a/rdbmaker/source/codemaker/dependency.cxx
+++ b/rdbmaker/source/codemaker/dependency.cxx
@@ -100,35 +100,6 @@ TypeUsingSet TypeDependency::getDependencies(const OString& type)
return TypeUsingSet();
}
-sal_Bool TypeDependency::lookupDependency(const OString& type, const OString& depend, sal_uInt16 use)
-{
- sal_Bool ret = sal_False;
-
- if (type.getLength() > 0 && depend.getLength() > 0)
- {
- if (m_pImpl->m_dependencies.count(type) > 0)
- {
- TypeUsingSet::const_iterator iter = m_pImpl->m_dependencies[type].begin();
-
- while (iter != m_pImpl->m_dependencies[type].end())
- {
- if (depend == (*iter).m_type &&
- (use & (*iter).m_use))
- {
- ret = sal_True;
- break;
- }
- iter++;
- }
- } else
- {
- ret = sal_False;
- }
- }
-
- return ret;
-}
-
sal_Bool TypeDependency::hasDependencies(const OString& type)
{
if (type.getLength() > 0)
diff --git a/sal/inc/systools/win32/snprintf.h b/sal/inc/systools/win32/snprintf.h
index 254726e2f37b..79441f032fee 100644
--- a/sal/inc/systools/win32/snprintf.h
+++ b/sal/inc/systools/win32/snprintf.h
@@ -1,4 +1,4 @@
-#ifndef _SMPRINTF_H
+#ifndef _SNPRINTF_H
#define _SNPRINTF_H
#if !defined(_WIN32)
@@ -77,4 +77,4 @@ _SNPRINTF_DLLIMPORT int __cdecl vsnprintf( char *buffer, size_t count, const cha
}
#endif
-#endif /* _SMPRINTF_H */
+#endif /* _SNPRINTF_H */
diff --git a/sal/osl/os2/util.c b/sal/osl/os2/util.c
index 4dd08c00aed3..217c71878838 100644
--- a/sal/osl/os2/util.c
+++ b/sal/osl/os2/util.c
@@ -32,11 +32,6 @@
-extern sal_Bool osl_getEtherAddr(sal_Char* pszAddr, sal_uInt16 BufferSize)
-{
- return sal_False;
-}
-
extern sal_Bool osl_getEthernetAddress( sal_uInt8 * pTargetAddress )
{
return sal_False;
diff --git a/sal/osl/unx/file.cxx b/sal/osl/unx/file.cxx
index e28328368a96..bd5b54a6d8c3 100644
--- a/sal/osl/unx/file.cxx
+++ b/sal/osl/unx/file.cxx
@@ -131,6 +131,42 @@ static const sal_Char* MOUNTTAB="/etc/mtab";
#endif
+#ifdef _DIRENT_HAVE_D_TYPE
+#include "file_impl.hxx"
+ oslDirectoryItemImpl* oslDirectoryItemImpl_CreateNew( rtl_uString* _ustrFilePath, bool _bHasDType, unsigned char _DType )
+ {
+ oslDirectoryItemImpl *pItemObject = (oslDirectoryItemImpl*) malloc( sizeof( oslDirectoryItemImpl ) );
+ pItemObject->RefCount = 1;
+ pItemObject->bHasType = _bHasDType;
+ pItemObject->DType = _DType;
+ pItemObject->ustrFilePath = _ustrFilePath;
+
+ return pItemObject;
+ }
+
+ void oslDirectoryItemImpl_Destroy( oslDirectoryItemImpl* pItem )
+ {
+ if( pItem->ustrFilePath ) {
+ rtl_uString_release( pItem->ustrFilePath );
+ pItem->ustrFilePath = NULL;
+ }
+ free( pItem );
+ }
+
+ void oslDirectoryItemImpl_acquire( oslDirectoryItemImpl* pItem )
+ {
+ pItem->RefCount ++;
+ }
+
+ void oslDirectoryItemImpl_release( oslDirectoryItemImpl* pItem )
+ {
+ pItem->RefCount --;
+
+ if( pItem->RefCount <= 0 )
+ oslDirectoryItemImpl_Destroy( pItem );
+ }
+#endif
+
#if OSL_DEBUG_LEVEL > 1
extern void debug_ustring(rtl_uString*);
@@ -467,8 +503,15 @@ oslFileError SAL_CALL osl_getNextDirectoryItem(oslDirectory Directory, oslDirect
osl_systemPathMakeAbsolutePath(pDirImpl->ustrPath, ustrFileName, &ustrFilePath);
rtl_uString_release( ustrFileName );
- /* use path as directory item */
- *pItem = (oslDirectoryItem) ustrFilePath;
+#ifdef _DIRENT_HAVE_D_TYPE
+ if(*pItem)
+ oslDirectoryItemImpl_release( ( oslDirectoryItemImpl* )( *pItem ) );
+
+ *pItem = (oslDirectoryItem) oslDirectoryItemImpl_CreateNew( ustrFilePath, true, pEntry->d_type );
+#else
+ /* use path as directory item */
+ *pItem = (oslDirectoryItem) ustrFilePath;
+#endif
return osl_File_E_None;
}
@@ -497,7 +540,11 @@ oslFileError SAL_CALL osl_getDirectoryItem( rtl_uString* ustrFileURL, oslDirecto
if (0 == access_u(ustrSystemPath, F_OK))
{
+#ifdef _DIRENT_HAVE_D_TYPE
+ *pItem = (oslDirectoryItem) oslDirectoryItemImpl_CreateNew( ustrSystemPath, false );
+#else
*pItem = (oslDirectoryItem)ustrSystemPath;
+#endif
osl_error = osl_File_E_None;
}
else
@@ -515,12 +562,21 @@ oslFileError SAL_CALL osl_getDirectoryItem( rtl_uString* ustrFileURL, oslDirecto
oslFileError osl_acquireDirectoryItem( oslDirectoryItem Item )
{
+#ifdef _DIRENT_HAVE_D_TYPE
+ oslDirectoryItemImpl* pImpl = (oslDirectoryItemImpl*) Item;
+#else
rtl_uString* ustrFilePath = (rtl_uString *) Item;
+#endif
OSL_ASSERT( Item );
+#ifdef _DIRENT_HAVE_D_TYPE
+ if( pImpl )
+ oslDirectoryItemImpl_acquire( pImpl );
+#else
if( ustrFilePath )
rtl_uString_acquire( ustrFilePath );
+#endif
return osl_File_E_None;
}
@@ -531,12 +587,21 @@ oslFileError osl_acquireDirectoryItem( oslDirectoryItem Item )
oslFileError osl_releaseDirectoryItem( oslDirectoryItem Item )
{
+#ifdef _DIRENT_HAVE_D_TYPE
+ oslDirectoryItemImpl* pImpl = (oslDirectoryItemImpl*) Item;
+#else
rtl_uString* ustrFilePath = (rtl_uString *) Item;
+#endif
OSL_ASSERT( Item );
+#ifdef _DIRENT_HAVE_D_TYPE
+ if( pImpl )
+ oslDirectoryItemImpl_release( pImpl );
+#else
if( ustrFilePath )
rtl_uString_release( ustrFilePath );
+#endif
return osl_File_E_None;
}
diff --git a/sal/osl/unx/file_impl.hxx b/sal/osl/unx/file_impl.hxx
new file mode 100644
index 000000000000..ae9d56ca85f3
--- /dev/null
+++ b/sal/osl/unx/file_impl.hxx
@@ -0,0 +1,48 @@
+/*************************************************************************
+ *
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * Copyright 2008 by Sun Microsystems, Inc.
+ *
+ * OpenOffice.org - a multi-platform office productivity suite
+ *
+ * $RCSfile: $
+ * $Revision: $
+ *
+ * This file is part of OpenOffice.org.
+ *
+ * OpenOffice.org is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU Lesser General Public License version 3
+ * only, as published by the Free Software Foundation.
+ *
+ * OpenOffice.org 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 version 3 for more details
+ * (a copy is included in the LICENSE file that accompanied this code).
+ *
+ * You should have received a copy of the GNU Lesser General Public License
+ * version 3 along with OpenOffice.org. If not, see
+ * <http://www.openoffice.org/license.html>
+ * for a copy of the LGPLv3 License.
+ *
+ ************************************************************************/
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+typedef struct
+{
+ rtl_uString* ustrFilePath; /* holds native file name */
+ unsigned char DType;
+ bool bHasType;
+ sal_uInt32 RefCount;
+} oslDirectoryItemImpl;
+
+ oslDirectoryItemImpl* oslDirectoryItemImpl_CreateNew( rtl_uString* _ustrFilePath, bool _bHasDType, unsigned char _DType=0 );
+ void oslDirectoryItemImpl_Destroy( oslDirectoryItemImpl* pItem );
+ void oslDirectoryItemImpl_acquire( oslDirectoryItemImpl* pItem );
+ void oslDirectoryItemImpl_release( oslDirectoryItemImpl* pItem );
+#ifdef __cplusplus
+} /* extern "C" */
+#endif
diff --git a/sal/osl/unx/file_path_helper.cxx b/sal/osl/unx/file_path_helper.cxx
index 0f6ad9e216ad..434a5a516e5c 100644
--- a/sal/osl/unx/file_path_helper.cxx
+++ b/sal/osl/unx/file_path_helper.cxx
@@ -125,16 +125,6 @@
}
/******************************************
- * osl_systemPathIsAbsolutePath
- *****************************************/
-
- sal_Bool SAL_CALL osl_systemPathIsAbsolutePath(const rtl_uString* pustrPath)
- {
- OSL_PRECOND(pustrPath, "osl_systemPathIsAbsolutePath: Invalid parameter");
- return (!osl_systemPathIsRelativePath(pustrPath));
- }
-
- /******************************************
osl_systemPathMakeAbsolutePath
*****************************************/
diff --git a/sal/osl/unx/file_path_helper.h b/sal/osl/unx/file_path_helper.h
index 17c6f0b71fba..3a89077e5633 100644
--- a/sal/osl/unx/file_path_helper.h
+++ b/sal/osl/unx/file_path_helper.h
@@ -105,23 +105,6 @@
const rtl_uString* pustrPath);
/******************************************
- osl_systemPathIsAbsolutePath
- Returns true if the given path is an
- absolute path and so starts with a '/'
-
- @param pustrPath [in] a system path
- pustrPath must not be NULL
-
- @returns sal_True if the given path
- start's with a separator else
- sal_False will be returned
-
- *****************************************/
-
- sal_Bool SAL_CALL osl_systemPathIsAbsolutePath(
- const rtl_uString* pustrPath);
-
- /******************************************
osl_systemPathMakeAbsolutePath
Append a relative path to a base path
diff --git a/sal/osl/unx/file_path_helper.hxx b/sal/osl/unx/file_path_helper.hxx
index ee38c14648c2..2a1d74687493 100644
--- a/sal/osl/unx/file_path_helper.hxx
+++ b/sal/osl/unx/file_path_helper.hxx
@@ -106,25 +106,6 @@ namespace osl
}
/******************************************
- systemPathIsAbsolutePath
- Returns true if the given path is an
- absolute path and so starts with a '/'
-
- @param pustrPath [in] a system path
- pustrPath must not be NULL
-
- @returns sal_True if the given path
- start's with a separator else
- sal_False will be returned
-
- *****************************************/
-
- inline bool systemPathIsAbsolutePath(const rtl::OUString& Path)
- {
- return osl_systemPathIsAbsolutePath(Path.pData);
- }
-
- /******************************************
systemPathMakeAbsolutePath
Append a relative path to a base path
diff --git a/sal/osl/unx/file_stat.cxx b/sal/osl/unx/file_stat.cxx
index ec8cead84620..3a710743a1b2 100644
--- a/sal/osl/unx/file_stat.cxx
+++ b/sal/osl/unx/file_stat.cxx
@@ -42,6 +42,11 @@
#ifndef _UNISTD_H
#include <unistd.h>
#endif
+
+#ifndef _DIRENT_H
+#include <dirent.h>
+#endif
+
#include <osl/file.h>
#ifndef _ERRNO_H
@@ -56,6 +61,9 @@
#include "file_path_helper.hxx"
#include "file_error_transl.h"
+#ifdef _DIRENT_HAVE_D_TYPE
+#include "file_impl.hxx"
+#endif
namespace /* private */
{
@@ -223,9 +231,19 @@ namespace /* private */
/* we only need to call stat or lstat if one of the
following flags is set */
+#ifdef _DIRENT_HAVE_D_TYPE
+ inline bool is_stat_call_necessary(sal_uInt32 field_mask, oslDirectoryItemImpl *pImpl)
+#else
inline bool is_stat_call_necessary(sal_uInt32 field_mask)
+#endif
{
- return ((field_mask & osl_FileStatus_Mask_Type) ||
+ return (
+/* on linux the dirent might have d_type */
+#ifdef _DIRENT_HAVE_D_TYPE
+ ((field_mask & osl_FileStatus_Mask_Type) && (!pImpl->bHasType || pImpl->DType == DT_UNKNOWN)) ||
+#else
+ (field_mask & osl_FileStatus_Mask_Type) ||
+#endif
(field_mask & osl_FileStatus_Mask_Attributes) ||
(field_mask & osl_FileStatus_Mask_CreationTime) ||
(field_mask & osl_FileStatus_Mask_AccessTime) ||
@@ -254,7 +272,11 @@ namespace /* private */
if ((NULL == Item) || (NULL == pStat))
return osl_File_E_INVAL;
+#ifdef _DIRENT_HAVE_D_TYPE
+ file_path = rtl::OUString(reinterpret_cast<rtl_uString*>(((oslDirectoryItemImpl* ) Item)->ustrFilePath));
+#else
file_path = rtl::OUString(reinterpret_cast<rtl_uString*>(Item));
+#endif
OSL_ASSERT(file_path.getLength() > 0);
@@ -285,10 +307,18 @@ oslFileError SAL_CALL osl_getFileStatus(oslDirectoryItem Item, oslFileStatus* pS
#else
struct stat file_stat;
#endif
- if (is_stat_call_necessary(uFieldMask) && (0 != osl::lstat(file_path, file_stat)))
+
+#ifdef _DIRENT_HAVE_D_TYPE
+ oslDirectoryItemImpl* pImpl = (oslDirectoryItemImpl*) Item;
+ bool bStatNeeded = is_stat_call_necessary(uFieldMask, pImpl);
+#else
+ bool bStatNeeded = is_stat_call_necessary(uFieldMask);
+#endif
+
+ if (bStatNeeded && (0 != osl::lstat(file_path, file_stat)))
return oslTranslateFileError(OSL_FET_ERROR, errno);
- if (is_stat_call_necessary(uFieldMask))
+ if (bStatNeeded)
{
// we set all these attributes because it's cheap
set_file_type(file_stat, pStat);
@@ -305,6 +335,40 @@ oslFileError SAL_CALL osl_getFileStatus(oslDirectoryItem Item, oslFileStatus* pS
return osl_error;
}
}
+#ifdef _DIRENT_HAVE_D_TYPE
+ else if (uFieldMask & osl_FileStatus_Mask_Type)
+ {
+ OSL_ASSERT(pImpl->bHasType);
+
+ switch(pImpl->DType)
+ {
+ case DT_LNK:
+ pStat->eType = osl_File_Type_Link;
+ break;
+ case DT_DIR:
+ pStat->eType = osl_File_Type_Directory;
+ break;
+ case DT_REG:
+ pStat->eType = osl_File_Type_Regular;
+ break;
+ case DT_FIFO:
+ pStat->eType = osl_File_Type_Fifo;
+ break;
+ case DT_SOCK:
+ pStat->eType = osl_File_Type_Socket;
+ break;
+ case DT_CHR:
+ case DT_BLK:
+ pStat->eType = osl_File_Type_Special;
+ break;
+ default:
+ OSL_ASSERT(0);
+ pStat->eType = osl_File_Type_Unknown;
+ }
+
+ pStat->uValidFields |= osl_FileStatus_Mask_Type;
+ }
+#endif
if (uFieldMask & osl_FileStatus_Mask_FileURL)
{
diff --git a/sal/osl/unx/file_url.cxx b/sal/osl/unx/file_url.cxx
index 602e8a98beac..1d6b9172bc6d 100644
--- a/sal/osl/unx/file_url.cxx
+++ b/sal/osl/unx/file_url.cxx
@@ -462,39 +462,6 @@ namespace /* private */
/*********************************************
********************************************/
- sal_Unicode* ustrcpy(const sal_Unicode* s, sal_Unicode* d)
- {
- const sal_Unicode* sc = s;
- sal_Unicode* dc = d;
-
- while ((*dc++ = *sc++))
- /**/;
-
- return d;
- }
-
- /*********************************************
-
- ********************************************/
-
- sal_Unicode* ustrncpy(const sal_Unicode* s, sal_Unicode* d, unsigned int n)
- {
- const sal_Unicode* sc = s;
- sal_Unicode* dc = d;
- unsigned int i = n;
-
- while (i--)
- *dc++ = *sc++;
-
- if (n)
- *dc = 0;
-
- return d;
- }
-
- /*********************************************
-
- ********************************************/
sal_Unicode* ustrchrcat(const sal_Unicode chr, sal_Unicode* d)
{
@@ -504,17 +471,6 @@ namespace /* private */
return d;
}
- /*********************************************
-
- ********************************************/
-
- sal_Unicode* ustrcat(const sal_Unicode* s, sal_Unicode* d)
- {
- sal_Unicode* dc = ustrtoend(d);
- ustrcpy(s, dc);
- return d;
- }
-
/******************************************************
*
******************************************************/
@@ -528,18 +484,6 @@ namespace /* private */
}
/******************************************************
- * Ensure that the given string has the specified last
- * character if necessary append it
- ******************************************************/
-
- sal_Unicode* _strensurelast(sal_Unicode* pStr, sal_Unicode Chr)
- {
- if (!_islastchr(pStr, Chr))
- ustrchrcat(Chr, pStr);
- return pStr;
- }
-
- /******************************************************
* Remove the last part of a path, a path that has
* only a '/' or no '/' at all will be returned
* unmodified
diff --git a/sal/osl/unx/process.c b/sal/osl/unx/process.c
index a163436031d2..e5faf46548a6 100644
--- a/sal/osl/unx/process.c
+++ b/sal/osl/unx/process.c
@@ -650,6 +650,18 @@ static void ChildStatusProc(void *pData)
close( stdOutput[0] );
close( stdError[0] );
+ //if pid > 0 then a process was created, even if it later failed
+ //e.g. bash searching for a command to execute, and we still
+ //need to clean it up to avoid "defunct" processes
+ if (pid > 0)
+ {
+ pid_t child_pid;
+ do
+ {
+ child_pid = waitpid(pid, &status, 0);
+ } while ( 0 > child_pid && EINTR == errno );
+ }
+
/* notify (and unblock) parent thread */
osl_setCondition(pdata->m_started);
}
diff --git a/sal/osl/unx/security.c b/sal/osl/unx/security.c
index 53dd452e220b..5b601ee138a9 100644
--- a/sal/osl/unx/security.c
+++ b/sal/osl/unx/security.c
@@ -801,7 +801,14 @@ sal_Bool SAL_CALL osl_getConfigDir(oslSecurity Security, rtl_uString **pustrDire
static sal_Bool SAL_CALL osl_psz_getConfigDir(oslSecurity Security, sal_Char* pszDirectory, sal_uInt32 nMax)
{
- return (osl_psz_getHomeDir(Security, pszDirectory, nMax));
+ sal_Char *pStr = getenv("XDG_CONFIG_HOME");
+
+ if ((pStr == NULL) || (strlen(pStr) == 0) ||
+ (access(pStr, 0) != 0))
+ return (osl_psz_getHomeDir(Security, pszDirectory, nMax));
+
+ strncpy(pszDirectory, pStr, nMax);
+ return sal_True;
}
#else
diff --git a/sal/osl/unx/util.c b/sal/osl/unx/util.c
index c0b9e3c5aa09..66746fd3ff44 100644
--- a/sal/osl/unx/util.c
+++ b/sal/osl/unx/util.c
@@ -51,11 +51,10 @@
static int osl_getHWAddr(const char *ifname, char* hard_addr);
static int osl_checkAddr(const char* addr);
-static char* osl_decodeEtherAddr(const char *ptr, char* buff);
/*****************************************************************************/
-/* osl_getEtherAddr */
+/* osl_getEthernetAddress */
/*****************************************************************************/
sal_Bool SAL_CALL osl_getEthernetAddress( sal_uInt8 * pAddr )
@@ -124,68 +123,6 @@ sal_Bool SAL_CALL osl_getEthernetAddress( sal_uInt8 * pAddr )
}
-extern sal_Bool osl_getEtherAddr(sal_Char* pszAddr, sal_uInt16 BufferSize)
-{
- char buff[1024];
- char hard_addr[64];
- struct ifconf ifc;
- struct ifreq *ifr;
- int i;
- int so;
-
- (void) BufferSize; /* unused */
-
- if ( pszAddr == 0 )
- {
- return sal_False;
- }
-
-
- /*
- * All we need is ... a network file descriptor.
- * Normally, this is a very socket.
- */
-
- so = socket(AF_INET, SOCK_DGRAM, 0);
-
-
- /*
- * The first thing we have to do, get the interface configuration.
- * It is a list of attached/configured interfaces
- */
-
- ifc.ifc_len = sizeof(buff);
- ifc.ifc_buf = buff;
- if ( ioctl(so, SIOCGIFCONF, &ifc) < 0 )
- {
-/* fprintf(stderr, "SIOCGIFCONF: %s\n", strerror(errno));*/
- close(so);
- return sal_False;
- }
-
- close(so);
-
- /*
- * For each of the interfaces in the interface list,
- * try to get the hardware address
- */
-
- ifr = ifc.ifc_req;
- for ( i = ifc.ifc_len / sizeof(struct ifreq) ; --i >= 0 ; ifr++ )
- {
- int nRet=0;
- nRet = osl_getHWAddr(ifr->ifr_name,hard_addr);
- if ( nRet > 0 )
- {
- osl_decodeEtherAddr(hard_addr,pszAddr);
- return sal_True;
- }
- }
-
- return sal_False;
-}
-
-
/*****************************************************************************/
/* osl_getHWAddr */
/*****************************************************************************/
@@ -285,18 +222,6 @@ static int osl_checkAddr(const char* addr)
}
-/*****************************************************************************/
-/* osl_decodeEtherAddr */
-/*****************************************************************************/
-
-static char* osl_decodeEtherAddr(const char *ptr, char* buff)
-{
- sprintf(buff, "%02X:%02X:%02X:%02X:%02X:%02X",
- (ptr[0] & 0377), (ptr[1] & 0377), (ptr[2] & 0377),
- (ptr[3] & 0377), (ptr[4] & 0377), (ptr[5] & 0377));
- return(buff);
-}
-
#if defined (SPARC)
#if defined (SOLARIS) && !defined(__sparcv8plus) && !defined(__sparcv9)
diff --git a/sal/osl/w32/conditn.c b/sal/osl/w32/conditn.c
index c87d161137b4..7af4398284be 100644
--- a/sal/osl/w32/conditn.c
+++ b/sal/osl/w32/conditn.c
@@ -107,8 +107,7 @@ oslConditionResult SAL_CALL osl_waitCondition(oslCondition Condition,
while ( 1 )
{
/* Only wake up if a SendMessage call to the threads message loop is detected */
-
- switch( MsgWaitForMultipleObjects( 1, &(HANDLE)Condition, FALSE, timeout, QS_SENDMESSAGE ) )
+ switch( MsgWaitForMultipleObjects( 1, (HANDLE *)(&Condition), FALSE, timeout, QS_SENDMESSAGE ) )
{
case WAIT_OBJECT_0 + 1:
{
diff --git a/sal/osl/w32/diagnose.c b/sal/osl/w32/diagnose.c
index af1b67eff5ac..6a67c1aa5b0f 100644
--- a/sal/osl/w32/diagnose.c
+++ b/sal/osl/w32/diagnose.c
@@ -73,6 +73,7 @@ void SAL_CALL osl_breakDebug(void)
void SAL_CALL osl_trace(const sal_Char* lpszFormat, ...)
{
va_list args;
+ int written = 0;
va_start(args, lpszFormat);
@@ -90,7 +91,8 @@ void SAL_CALL osl_trace(const sal_Char* lpszFormat, ...)
{
sal_Char szMessage[512];
szMessage[sizeof(szMessage)-1] = 0;
- _vsnprintf( szMessage, sizeof(szMessage) -1, lpszFormat, args );
+ written = _vsnprintf( szMessage, sizeof(szMessage) - 2, lpszFormat, args );
+ szMessage[ written == -1 ? sizeof(szMessage) - 2 : written ] = '\n';
OutputDebugString( szMessage );
}
diff --git a/sal/osl/w32/util.c b/sal/osl/w32/util.c
index a952de1dba8c..34c7b7ada53d 100644
--- a/sal/osl/w32/util.c
+++ b/sal/osl/w32/util.c
@@ -32,15 +32,6 @@
-extern sal_Bool osl_getEtherAddr(sal_Char* pszAddr, sal_uInt16 BufferSize)
-{
- /* avoid warnings */
- pszAddr = pszAddr;
- BufferSize = BufferSize;
-
- return sal_False;
-}
-
extern sal_Bool SAL_CALL osl_getEthernetAddress( sal_uInt8 *pAddr )
{
pAddr = pAddr; /* avoid warnings */