[ooo-build-commit] .: 109 commits - basic/inc basic/source configmgr/source desktop/inc desktop/source desktop/util desktop/win32 editeng/source framework/inc framework/prj framework/source framework/util officecfg/registry oovbaapi/ooo scripting/source sfx2/inc sfx2/source svx/source ucb/source uui/source vbahelper/inc vbahelper/source

Jan Holesovsky kendy at kemper.freedesktop.org
Wed Sep 8 08:36:12 PDT 2010


 basic/inc/basic/sbmod.hxx                                                      |    4 
 basic/inc/basic/sbxvar.hxx                                                     |   12 
 basic/source/classes/sb.cxx                                                    |  130 ++
 basic/source/classes/sbunoobj.cxx                                              |   23 
 basic/source/comp/codegen.cxx                                                  |   12 
 basic/source/comp/dim.cxx                                                      |   70 +
 basic/source/comp/exprgen.cxx                                                  |   73 -
 basic/source/comp/exprtree.cxx                                                 |   10 
 basic/source/comp/makefile.mk                                                  |   33 
 basic/source/comp/sbcomp.cxx                                                   |    2 
 basic/source/inc/expr.hxx                                                      |    3 
 basic/source/inc/parser.hxx                                                    |    5 
 basic/source/inc/sbintern.hxx                                                  |    6 
 basic/source/inc/sbunoobj.hxx                                                  |    1 
 basic/source/inc/symtbl.hxx                                                    |    3 
 basic/source/runtime/methods1.cxx                                              |   14 
 basic/source/runtime/step0.cxx                                                 |  229 +--
 basic/source/sbx/sbxbool.cxx                                                   |   18 
 basic/source/sbx/sbxbyte.cxx                                                   |   10 
 basic/source/sbx/sbxchar.cxx                                                   |   15 
 basic/source/sbx/sbxconv.hxx                                                   |   16 
 basic/source/sbx/sbxcurr.cxx                                                   |   26 
 basic/source/sbx/sbxdate.cxx                                                   |   12 
 basic/source/sbx/sbxdbl.cxx                                                    |   10 
 basic/source/sbx/sbxdec.cxx                                                    |   20 
 basic/source/sbx/sbxdec.hxx                                                    |    4 
 basic/source/sbx/sbxint.cxx                                                    |   38 
 basic/source/sbx/sbxlng.cxx                                                    |   10 
 basic/source/sbx/sbxres.cxx                                                    |    2 
 basic/source/sbx/sbxres.hxx                                                    |    2 
 basic/source/sbx/sbxscan.cxx                                                   |   37 
 basic/source/sbx/sbxsng.cxx                                                    |   10 
 basic/source/sbx/sbxstr.cxx                                                    |   50 
 basic/source/sbx/sbxuint.cxx                                                   |   10 
 basic/source/sbx/sbxulng.cxx                                                   |   10 
 basic/source/sbx/sbxvalue.cxx                                                  |  105 -
 basic/source/sbx/sbxvar.cxx                                                    |   40 
 configmgr/source/README                                                        |    1 
 configmgr/source/access.cxx                                                    |   23 
 configmgr/source/additions.hxx                                                 |   43 
 configmgr/source/broadcaster.cxx                                               |   63 -
 configmgr/source/components.cxx                                                |  140 +-
 configmgr/source/components.hxx                                                |   15 
 configmgr/source/data.cxx                                                      |   44 
 configmgr/source/data.hxx                                                      |   23 
 configmgr/source/modifications.cxx                                             |   21 
 configmgr/source/modifications.hxx                                             |    2 
 configmgr/source/rootaccess.cxx                                                |    5 
 configmgr/source/update.cxx                                                    |   17 
 configmgr/source/xcdparser.cxx                                                 |    2 
 configmgr/source/xcsparser.cxx                                                 |   10 
 configmgr/source/xcuparser.cxx                                                 |   30 
 configmgr/source/xcuparser.hxx                                                 |    6 
 desktop/inc/app.hxx                                                            |    3 
 desktop/source/app/app.cxx                                                     |  599 +++++++---
 desktop/source/app/appfirststart.cxx                                           |  102 +
 desktop/source/deployment/gui/dp_gui_dialog2.cxx                               |   12 
 desktop/source/deployment/manager/dp_extensionmanager.cxx                      |    8 
 desktop/source/deployment/manager/dp_properties.cxx                            |    2 
 desktop/source/deployment/manager/dp_properties.hxx                            |    5 
 desktop/source/deployment/misc/dp_misc.cxx                                     |    5 
 desktop/source/deployment/registry/configuration/dp_configuration.cxx          |   88 -
 desktop/source/deployment/registry/configuration/dp_configurationbackenddb.cxx |    5 
 desktop/source/deployment/registry/configuration/dp_configurationbackenddb.hxx |    5 
 desktop/source/deployment/registry/dp_registry.cxx                             |    7 
 desktop/source/deployment/registry/executable/dp_executablebackenddb.cxx       |    5 
 desktop/source/deployment/registry/executable/dp_executablebackenddb.hxx       |    5 
 desktop/source/deployment/registry/help/dp_helpbackenddb.cxx                   |    5 
 desktop/source/deployment/registry/help/dp_helpbackenddb.hxx                   |    5 
 desktop/source/deployment/registry/package/dp_package.cxx                      |   22 
 desktop/source/deployment/registry/script/dp_scriptbackenddb.cxx               |    5 
 desktop/source/deployment/registry/script/dp_scriptbackenddb.hxx               |    5 
 desktop/source/migration/services/cexportsoo3.cxx                              |    5 
 desktop/source/migration/services/oo3extensionmigration.cxx                    |    7 
 desktop/source/migration/services/oo3extensionmigration.hxx                    |    7 
 desktop/source/pkgchk/unopkg/unopkg_app.cxx                                    |   33 
 desktop/source/pkgchk/unopkg/unopkg_misc.cxx                                   |  105 +
 desktop/source/pkgchk/unopkg/unopkg_shared.h                                   |    6 
 desktop/util/verinfo.rc                                                        |    8 
 desktop/win32/source/applauncher/ooo/verinfo.rc                                |    4 
 desktop/win32/source/applauncher/verinfo.rc                                    |    8 
 desktop/win32/source/officeloader/officeloader.cxx                             |    1 
 editeng/source/editeng/eehtml.cxx                                              |   12 
 editeng/source/editeng/impedit.hxx                                             |    3 
 editeng/source/editeng/impedit4.cxx                                            |  369 +++++-
 editeng/source/misc/svxacorr.cxx                                               |   24 
 framework/inc/classes/framelistanalyzer.hxx                                    |   25 
 framework/inc/uiconfiguration/moduleuiconfigurationmanager.hxx                 |    1 
 framework/prj/d.lst                                                            |    1 
 framework/source/accelerators/acceleratorconfiguration.cxx                     |   36 
 framework/source/loadenv/loadenv.cxx                                           |    3 
 framework/source/uiconfiguration/moduleuiconfigurationmanager.cxx              |   78 -
 framework/util/makefile.mk                                                     |    2 
 officecfg/registry/schema/org/openoffice/Office/OOoImprovement/Settings.xcs    |    2 
 officecfg/registry/schema/org/openoffice/Setup.xcs                             |    9 
 oovbaapi/ooo/vba/excel/XGlobals.idl                                            |    7 
 oovbaapi/ooo/vba/excel/XWorksheet.idl                                          |    6 
 scripting/source/basprov/basmodnode.cxx                                        |   14 
 scripting/source/basprov/basprov.cxx                                           |    2 
 sfx2/inc/sfx2/docfile.hxx                                                      |    1 
 sfx2/source/dialog/taskpane.cxx                                                |    6 
 sfx2/source/doc/DocumentMetadataAccess.cxx                                     |   25 
 sfx2/source/doc/docfile.cxx                                                    |   47 
 sfx2/source/doc/doctemplates.cxx                                               |    2 
 sfx2/source/doc/objmisc.cxx                                                    |    2 
 sfx2/source/doc/objserv.cxx                                                    |    9 
 sfx2/source/doc/objstor.cxx                                                    |   36 
 sfx2/source/doc/sfxbasemodel.cxx                                               |    3 
 sfx2/source/view/viewfrm.cxx                                                   |   21 
 svx/source/svdraw/svdmrkv.cxx                                                  |    5 
 ucb/source/core/ucb.cxx                                                        |  153 +-
 ucb/source/core/ucb.hxx                                                        |    6 
 ucb/source/ucp/package/makefile.mk                                             |    1 
 ucb/source/ucp/package/pkguri.cxx                                              |   36 
 uui/source/iahndl-authentication.cxx                                           |    2 
 vbahelper/inc/vbahelper/vbahelper.hxx                                          |    7 
 vbahelper/source/msforms/vbauserform.cxx                                       |   47 
 vbahelper/source/vbahelper/vbahelper.cxx                                       |   24 
 118 files changed, 2456 insertions(+), 1168 deletions(-)

New commits:
commit 72832ea6fb8fa69b3cfbbcadab8f49a803448b4e
Merge: 1445d9d7... b47d587...
Author: Jan Holesovsky <kendy at suse.cz>
Date:   Wed Sep 8 11:34:08 2010 +0200

    Merge commit 'ooo/OOO330_m7'

commit 1445d9d7744618b41e0b09eef274613cc0cfd57b
Merge: 09877be... faf3732...
Author: Jan Holesovsky <kendy at suse.cz>
Date:   Tue Sep 7 09:33:02 2010 +0200

    Merge commit 'ooo/OOO330_m6'

commit b47d58784ee1d6592f721e9fa0a66a4d801e95cc
Merge: 1c5054b... 5fba505...
Author: Kurt Zenker <kz at openoffice.org>
Date:   Fri Sep 3 14:39:55 2010 +0200

    CWS-TOOLING: integrate CWS fs33a

commit 1c5054b57b89575e686b6f59da89abdd24012cd4
Merge: 1843c8d... 8ace426...
Author: Kurt Zenker <kz at openoffice.org>
Date:   Tue Aug 31 15:51:23 2010 +0200

    CWS-TOOLING: integrate CWS fwk154

commit 1843c8d96d714f34d713a8ca1a3a1848f9c9310d
Merge: be6516c... 5be137f...
Author: Kurt Zenker <kz at openoffice.org>
Date:   Tue Aug 31 15:43:02 2010 +0200

    CWS-TOOLING: integrate CWS fwk153

diff --cc framework/source/accelerators/acceleratorconfiguration.cxx
index 34c799f,cc565f4..88a9412
--- a/framework/source/accelerators/acceleratorconfiguration.cxx
+++ b/framework/source/accelerators/acceleratorconfiguration.cxx
@@@ -1248,11 -1246,13 +1248,12 @@@ void SAL_CALL XCUBasedAcceleratorConfig
      if (! xHAccess.is ())
          return;
  
-     const sal_Int32 c = aEvent.Changes.getLength();
+     css::util::ChangesEvent aReceivedEvents( aEvent );
+     const sal_Int32 c = aReceivedEvents.Changes.getLength();
            sal_Int32 i = 0;
 -
      for (i=0; i<c; ++i)
      {
-         const css::util::ElementChange& aChange  =   aEvent.Changes[i];
+         const css::util::ElementChange& aChange  =   aReceivedEvents.Changes[i];
  
          // Only path of form "PrimaryKeys/Modules/Module['<module_name>']/Key['<command_url>']/Command[<locale>]" will
          // be interesting for use. Sometimes short path values are given also by the broadcaster ... but they must be ignored :-)
commit be6516cfa383d391a5c1620076c72f7d5dfbd15e
Merge: faf3732... be3b926...
Author: Kurt Zenker <kz at openoffice.org>
Date:   Tue Aug 31 15:26:29 2010 +0200

    CWS-TOOLING: integrate CWS sb130

commit faf3732ff2f34712f6e974aa46f132cd734d22a5
Author: obo <obo at openoffice.org>
Date:   Fri Aug 27 13:01:02 2010 +0200

    masterfix OOO330: #i10000# solve merge problem / WaE

diff --git a/desktop/source/app/app.cxx b/desktop/source/app/app.cxx
index b326e0b..045970e 100644
--- a/desktop/source/app/app.cxx
+++ b/desktop/source/app/app.cxx
@@ -1558,6 +1558,7 @@ void Desktop::Main()
     std::auto_ptr<SvtLanguageOptions> pLanguageOptions;
     std::auto_ptr<SvtPathOptions> pPathOptions;
 
+    Reference< ::com::sun::star::task::XRestartManager > xRestartManager;
     sal_Bool bRestartRequested( sal_False );
     sal_Bool bUseSystemFileDialog(sal_True);
     int		 nAcquireCount( 0 );
@@ -1761,7 +1762,6 @@ void Desktop::Main()
         impl_checkRecoveryState(bCrashed, bExistsRecoveryData, bExistsSessionData);
         RTL_LOGFILE_CONTEXT_TRACE( aLog, "} impl_checkRecoveryState" );
 
-        Reference< ::com::sun::star::task::XRestartManager > xRestartManager;
         {
             ::comphelper::ComponentContext aContext( xSMgr );
             xRestartManager.set( aContext.getSingleton( ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "com.sun.star.task.OfficeRestartManager" ) ) ), UNO_QUERY );
@@ -1929,7 +1929,6 @@ void Desktop::Main()
         // call Application::Execute to process messages in vcl message loop
         RTL_LOGFILE_PRODUCT_TRACE( "PERFORMANCE - enter Application::Execute()" );
 
-        Reference< ::com::sun::star::task::XRestartManager > xRestartManager;
         try
         {
             // The JavaContext contains an interaction handler which is used when
@@ -1937,9 +1936,10 @@ void Desktop::Main()
             com::sun::star::uno::ContextLayer layer2(
                 new svt::JavaContext( com::sun::star::uno::getCurrentContext() ) );
 
-            ::comphelper::ComponentContext aContext( xSMgr );
-            xRestartManager.set( aContext.getSingleton( ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "com.sun.star.task.OfficeRestartManager" ) ) ), UNO_QUERY );
-            if ( !xRestartManager.is() || !xRestartManager->isRestartRequested( sal_True ) )
+            // check whether the shutdown is caused by restart just before entering the Execute
+            bRestartRequested = bRestartRequested || ( xRestartManager.is() && xRestartManager->isRestartRequested( sal_True ) );
+
+            if ( !bRestartRequested )
             {
                 // if this run of the office is triggered by restart, some additional actions should be done
                 DoRestartActionsIfNecessary( !pCmdLineArgs->IsInvisible() && !pCmdLineArgs->IsNoQuickstart() );
@@ -1957,13 +1957,11 @@ void Desktop::Main()
             OfficeIPCThread::SetDowning();
             FatalError( MakeStartupErrorMessage(exAnyCfg.Message) );
         }
-
-        // check whether the shutdown is caused by restart
-        sal_Bool bRestartRequested = ( xRestartManager.is() && xRestartManager->isRestartRequested( sal_True ) );
-        if ( bRestartRequested )
-            SetRestartState();
     }
     
+    if ( bRestartRequested )
+        SetRestartState();
+
     if (xGlobalBroadcaster.is())
     {
         css::document::EventObject aEvent;
commit be3b92624ef45dbeab7c96393199a3eeaff144da
Author: sb <sb at openoffice.org>
Date:   Thu Aug 26 17:11:05 2010 +0200

    sb130: #i113096# previous configmgr::Components::removeExtensionXcuFile changes were still not good

diff --git a/configmgr/source/components.cxx b/configmgr/source/components.cxx
index e76460d..33b0eca 100644
--- a/configmgr/source/components.cxx
+++ b/configmgr/source/components.cxx
@@ -120,26 +120,26 @@ rtl::OUString expand(rtl::OUString const & str) {
     return s;
 }
 
-bool hasOnlyEmptySets(rtl::Reference< Node > const & node) {
+bool canRemoveFromLayer(int layer, rtl::Reference< Node > const & node) {
     OSL_ASSERT(node.is());
+    if (node->getLayer() > layer && node->getLayer() < Data::NO_LAYER) {
+        return false;
+    }
     switch (node->kind()) {
-    default: // Node::KIND_LOCALIZED_VALUE
-        OSL_ASSERT(false);
-        // fall through
-    case Node::KIND_PROPERTY:
     case Node::KIND_LOCALIZED_PROPERTY:
-        return true;
     case Node::KIND_GROUP:
         for (NodeMap::iterator i(node->getMembers().begin());
              i != node->getMembers().end(); ++i)
         {
-            if (!hasOnlyEmptySets(i->second)) {
+            if (!canRemoveFromLayer(layer, i->second)) {
                 return false;
             }
         }
         return true;
     case Node::KIND_SET:
         return node->getMembers().empty();
+    default: // Node::KIND_PROPERTY, Node::KIND_LOCALIZED_VALUE
+        return true;
     }
 }
 
@@ -282,7 +282,8 @@ void Components::removeExtensionXcuFile(
     // be removed.  However, not enough information is recorded in the in-memory
     // data structures to do so.  So, as a workaround, all those set elements
     // that were freshly added by the xcu and have afterwards been left
-    // unchanged are removed (and nothing else).  The heuristic to determine
+    // unchanged or have only had their properties changed in the user layer are
+    // removed (and nothing else).  The heuristic to determine
     // whether a node has been left unchanged is to check the layer ID (as
     // usual) and additionally to check that the node does not recursively
     // contain any non-empty sets (multiple extension xcu files are merged into
@@ -302,7 +303,7 @@ void Components::removeExtensionXcuFile(
             rtl::Reference< Node > node;
             for (Path::const_iterator j(i->begin()); j != i->end(); ++j) {
                 parent = node;
-                node = Data::findNode(item->layer, *map, *j);
+                node = Data::findNode(Data::NO_LAYER, *map, *j);
                 if (!node.is()) {
                     break;
                 }
@@ -314,14 +315,15 @@ void Components::removeExtensionXcuFile(
                     OSL_ASSERT(
                         node->kind() == Node::KIND_GROUP ||
                         node->kind() == Node::KIND_SET);
-                    if (hasOnlyEmptySets(node)) {
+                    if (canRemoveFromLayer(item->layer, node)) {
                         parent->getMembers().erase(i->back());
-                        addModification(*i);
+                        data_.modifications.remove(*i);
                         modifications->add(*i);
                     }
                 }
             }
         }
+        writeModifications();
     }
 }
 
diff --git a/configmgr/source/modifications.cxx b/configmgr/source/modifications.cxx
index 2ad3b5e..add18ce 100644
--- a/configmgr/source/modifications.cxx
+++ b/configmgr/source/modifications.cxx
@@ -59,6 +59,27 @@ void Modifications::add(Path const & path) {
     p->children.clear();
 }
 
+void Modifications::remove(Path const & path) {
+    OSL_ASSERT(!path.empty());
+    Node * p = &root_;
+    for (Path::const_iterator i(path.begin());;) {
+        Node::Children::iterator j(p->children.find(*i));
+        if (j == p->children.end()) {
+            break;
+        }
+        if (++i == path.end()) {
+            p->children.erase(j);
+            if (p->children.empty()) {
+                Path parent(path);
+                parent.pop_back();
+                remove(parent);
+            }
+            break;
+        }
+        p = &j->second;
+    }
+}
+
 Modifications::Node const & Modifications::getRoot() const {
     return root_;
 }
diff --git a/configmgr/source/modifications.hxx b/configmgr/source/modifications.hxx
index e29a101..c28b1aa 100644
--- a/configmgr/source/modifications.hxx
+++ b/configmgr/source/modifications.hxx
@@ -54,6 +54,8 @@ public:
 
     void add(Path const & path);
 
+    void remove(Path const & path);
+
     Node const & getRoot() const;
 
 private:
commit d85fe96f67e46d1b65257509c09b8453cd9b8510
Author: sb <sb at openoffice.org>
Date:   Thu Aug 26 13:28:53 2010 +0200

    sb130: #i113096# UniversalContentBroker::changesOccurred is now also called for removed items

diff --git a/ucb/source/core/ucb.cxx b/ucb/source/core/ucb.cxx
index fadadd0..75a7f8b 100644
--- a/ucb/source/core/ucb.cxx
+++ b/ucb/source/core/ucb.cxx
@@ -43,6 +43,7 @@
 #include <com/sun/star/ucb/XParameterizedContentProvider.hpp>
 #include <com/sun/star/ucb/XContentProviderFactory.hpp>
 #include <com/sun/star/beans/PropertyValue.hpp>
+#include <com/sun/star/container/XHierarchicalNameAccess.hpp>
 #include <com/sun/star/container/XNameAccess.hpp>
 #include <com/sun/star/uno/Any.hxx>
 #include <ucbhelper/cancelcommandexecution.hxx>
@@ -182,6 +183,63 @@ void makeAndAppendXMLName(
     }
 }
 
+bool createContentProviderData(
+    const rtl::OUString & rProvider,
+    const uno::Reference< container::XHierarchicalNameAccess >& rxHierNameAccess,
+    ContentProviderData & rInfo)
+{
+    // Obtain service name.
+    rtl::OUStringBuffer aKeyBuffer (rProvider);
+    aKeyBuffer.appendAscii( "/ServiceName" );
+
+    rtl::OUString aValue;
+    try
+    {
+        if ( !( rxHierNameAccess->getByHierarchicalName(
+                    aKeyBuffer.makeStringAndClear() ) >>= aValue ) )
+        {
+            OSL_ENSURE( false,
+                        "UniversalContentBroker::getContentProviderData - "
+                        "Error getting item value!" );
+        }
+    }
+    catch (container::NoSuchElementException &)
+    {
+        return false;
+    }
+
+    rInfo.ServiceName = aValue;
+
+    // Obtain URL Template.
+    aKeyBuffer.append(rProvider);
+    aKeyBuffer.appendAscii( "/URLTemplate" );
+
+    if ( !( rxHierNameAccess->getByHierarchicalName(
+                aKeyBuffer.makeStringAndClear() ) >>= aValue ) )
+    {
+        OSL_ENSURE( false,
+                    "UniversalContentBroker::getContentProviderData - "
+                    "Error getting item value!" );
+    }
+
+    rInfo.URLTemplate = aValue;
+
+    // Obtain Arguments.
+    aKeyBuffer.append(rProvider);
+    aKeyBuffer.appendAscii( "/Arguments" );
+
+    if ( !( rxHierNameAccess->getByHierarchicalName(
+                aKeyBuffer.makeStringAndClear() ) >>= aValue ) )
+    {
+        OSL_ENSURE( false,
+                    "UniversalContentBroker::getContentProviderData - "
+                    "Error getting item value!" );
+    }
+
+    rInfo.Arguments = aValue;
+    return true;
+}
+
 }
 
 //=========================================================================
@@ -664,9 +722,18 @@ void SAL_CALL UniversalContentBroker::changesOccurred( const util::ChangesEvent&
 
             ContentProviderData aInfo;
 
-            createContentProviderData(aKey, xHierNameAccess, aInfo);
-
-            aData.push_back(aInfo);
+            // Removal of UCPs from the configuration leads to changesOccurred
+            // notifications, too, but it is hard to tell for a given
+            // ElementChange whether it is an addition or a removal, so as a
+            // heuristic consider as removals those that cause a
+            // NoSuchElementException in createContentProviderData.
+            //
+            // For now, removal of UCPs from the configuration is simply ignored
+            // (and not reflected in the UCB's data structures):
+            if (createContentProviderData(aKey, xHierNameAccess, aInfo))
+            {
+                aData.push_back(aInfo);
+            }
         }
 
         prepareAndRegister(aData);
@@ -834,7 +901,10 @@ bool UniversalContentBroker::getContentProviderData(
                     makeAndAppendXMLName( aElemBuffer, pElems[ n ] );
                     aElemBuffer.appendAscii( "']" );
                     
-                    createContentProviderData(aElemBuffer.makeStringAndClear(), xHierNameAccess, aInfo);
+                    OSL_VERIFY(
+                        createContentProviderData(
+                            aElemBuffer.makeStringAndClear(), xHierNameAccess,
+                            aInfo));
                     
                     rListToFill.push_back( aInfo );
                 }
@@ -866,55 +936,6 @@ bool UniversalContentBroker::getContentProviderData(
     return true;
 }
 
-void UniversalContentBroker::createContentProviderData( 
-    const rtl::OUString & rProvider, 
-    const uno::Reference< container::XHierarchicalNameAccess >& rxHierNameAccess, 
-    ContentProviderData & rInfo)
-{
-    // Obtain service name.
-    rtl::OUStringBuffer aKeyBuffer (rProvider);
-    aKeyBuffer.appendAscii( "/ServiceName" );
-
-    rtl::OUString aValue;
-    if ( !( rxHierNameAccess->getByHierarchicalName(
-                aKeyBuffer.makeStringAndClear() ) >>= aValue ) )
-    {
-        OSL_ENSURE( false,
-                    "UniversalContentBroker::getContentProviderData - "
-                    "Error getting item value!" );
-    }
-
-    rInfo.ServiceName = aValue;
-
-    // Obtain URL Template.
-    aKeyBuffer.append(rProvider);
-    aKeyBuffer.appendAscii( "/URLTemplate" );
-
-    if ( !( rxHierNameAccess->getByHierarchicalName(
-                aKeyBuffer.makeStringAndClear() ) >>= aValue ) )
-    {
-        OSL_ENSURE( false,
-                    "UniversalContentBroker::getContentProviderData - "
-                    "Error getting item value!" );
-    }
-
-    rInfo.URLTemplate = aValue;
-
-    // Obtain Arguments.
-    aKeyBuffer.append(rProvider);
-    aKeyBuffer.appendAscii( "/Arguments" );
-
-    if ( !( rxHierNameAccess->getByHierarchicalName(
-                aKeyBuffer.makeStringAndClear() ) >>= aValue ) )
-    {
-        OSL_ENSURE( false,
-                    "UniversalContentBroker::getContentProviderData - "
-                    "Error getting item value!" );
-    }
-
-    rInfo.Arguments = aValue;
-}
-
 //=========================================================================
 //
 // ProviderListEntry_Impl implementation.
diff --git a/ucb/source/core/ucb.hxx b/ucb/source/core/ucb.hxx
index db54af4..f7318ad 100644
--- a/ucb/source/core/ucb.hxx
+++ b/ucb/source/core/ucb.hxx
@@ -40,7 +40,6 @@
 #include <com/sun/star/util/XChangesListener.hpp>
 #include <com/sun/star/util/XChangesNotifier.hpp>
 #include <com/sun/star/container/XContainer.hpp>
-#include <com/sun/star/container/XHierarchicalNameAccess.hpp>
 
 #include <rtl/ustrbuf.hxx>
 #include <cppuhelper/weak.hxx>
@@ -204,11 +203,6 @@ private:
 
     void prepareAndRegister( const ucbhelper::ContentProviderDataList& rData);
 
-    void createContentProviderData( 
-    const rtl::OUString& rProvider, 
-    const com::sun::star::uno::Reference< com::sun::star::container::XHierarchicalNameAccess >& rxHierNameAccess, 
-    ucbhelper::ContentProviderData& rInfo);
-
     com::sun::star::uno::Reference<
         com::sun::star::lang::XMultiServiceFactory > m_xSMgr;
 
commit f6b87d8f5b9ad9cc5a49e35ff0c567a3b8083bc3
Author: sb <sb at openoffice.org>
Date:   Thu Aug 26 13:26:56 2010 +0200

    sb130: #i113096# previous change contained an error in configmgr::Components::removeExtensionXcuFile

diff --git a/configmgr/source/components.cxx b/configmgr/source/components.cxx
index 733ca05..e76460d 100644
--- a/configmgr/source/components.cxx
+++ b/configmgr/source/components.cxx
@@ -290,6 +290,7 @@ void Components::removeExtensionXcuFile(
     // item->additions records all additions of set members in textual order,
     // the latter check works well when iterating through item->additions in
     // reverse order.
+    OSL_ASSERT(modifications != 0);
     rtl::Reference< Data::ExtensionXcu > item(
         data_.removeExtensionXcuAdditions(fileUri));
     if (item.is()) {
@@ -315,6 +316,7 @@ void Components::removeExtensionXcuFile(
                         node->kind() == Node::KIND_SET);
                     if (hasOnlyEmptySets(node)) {
                         parent->getMembers().erase(i->back());
+                        addModification(*i);
                         modifications->add(*i);
                     }
                 }
commit 864045890b84b8307b673b39bad1540d102a6414
Merge: 505336a... dffbec9...
Author: Ivo Hinkelmann <ihi at openoffice.org>
Date:   Thu Aug 26 13:07:19 2010 +0200

    CWS-TOOLING: integrate CWS fwk152

diff --cc desktop/source/app/app.cxx
index 399d3aa,dd59e0c..b326e0b
--- a/desktop/source/app/app.cxx
+++ b/desktop/source/app/app.cxx
@@@ -1869,83 -1573,115 +1869,101 @@@ void Desktop::Main(
      aOptions.SetVCLSettings();
  //    SetSplashScreenProgress(60);
  
 -    Application::SetFilterHdl( LINK( this, Desktop, ImplInitFilterHdl ) );
 -
 -    sal_Bool bTerminateRequested = sal_False;
 -
 -    // Preload function depends on an initialized sfx application!
 -    SetSplashScreenProgress(75);
 -
 -    sal_Bool bUseSystemFileDialog(sal_True);
 -    if ( pCmdLineArgs->IsHeadless() )
 +    if ( !bRestartRequested )
      {
 -        // Ensure that we use not the system file dialogs as
 -        // headless mode relies on Application::EnableHeadlessMode()
 -        // which does only work for VCL dialogs!!
 -        SvtMiscOptions aMiscOptions;
 -        bUseSystemFileDialog = aMiscOptions.UseSystemFileDialog();
 -        aMiscOptions.SetUseSystemFileDialog( sal_False );
 -    }
 +        Application::SetFilterHdl( LINK( this, Desktop, ImplInitFilterHdl ) );
  
 -    // use system window dialogs
 -    Application::SetSystemWindowMode( SYSTEMWINDOW_MODE_DIALOG );
 +        sal_Bool bTerminateRequested = sal_False;
  
 -//    SetSplashScreenProgress(80);
 +        // Preload function depends on an initialized sfx application!
 +        SetSplashScreenProgress(75);
  
 -    if ( !bTerminateRequested && !pCmdLineArgs->IsInvisible() &&
 -         !pCmdLineArgs->IsNoQuickstart() )
 -        InitializeQuickstartMode( xSMgr );
 +        // use system window dialogs
 +        Application::SetSystemWindowMode( SYSTEMWINDOW_MODE_DIALOG );
  
 -    RTL_LOGFILE_CONTEXT( aLog2, "desktop (cd100003) createInstance com.sun.star.frame.Desktop" );
 -    try
 -    {
 -        Reference< XDesktop > xDesktop( xSMgr->createInstance(
 -            OUString( RTL_CONSTASCII_USTRINGPARAM( "com.sun.star.frame.Desktop" ))), UNO_QUERY );
 -        if ( xDesktop.is() )
 -            xDesktop->addTerminateListener( new OfficeIPCThreadController );
 -        SetSplashScreenProgress(100);
 -    }
 -    catch ( com::sun::star::uno::Exception& e )
 -    {
 -        FatalError( MakeStartupErrorMessage(e.Message) );
 -        return;
 -    }
 -    /*
 -    catch ( ... )
 -    {
 -        FatalError( MakeStartupErrorMessage(
 -            OUString::createFromAscii(
 -            "Unknown error during startup (TD/Desktop service).\nInstallation could be damaged.")));
 -        return;
 -    }
 -    */
 +    //    SetSplashScreenProgress(80);
  
 -    // Release solar mutex just before we wait for our client to connect
 -    int nAcquireCount = 0;
 -    ::vos::IMutex& rMutex = Application::GetSolarMutex();
 -    if ( rMutex.tryToAcquire() )
 -        nAcquireCount = Application::ReleaseSolarMutex() - 1;
 +        if ( !bTerminateRequested && !pCmdLineArgs->IsInvisible() &&
 +             !pCmdLineArgs->IsNoQuickstart() )
 +            InitializeQuickstartMode( xSMgr );
  
 -    // Post user event to startup first application component window
 -    // We have to send this OpenClients message short before execute() to
 -    // minimize the risk that this message overtakes type detection contruction!!
 -    Application::PostUserEvent( LINK( this, Desktop, OpenClients_Impl ) );
 +        RTL_LOGFILE_CONTEXT( aLog2, "desktop (cd100003) createInstance com.sun.star.frame.Desktop" );
 +        try
 +        {
 +            Reference< XDesktop > xDesktop( xSMgr->createInstance(
 +                OUString( RTL_CONSTASCII_USTRINGPARAM( "com.sun.star.frame.Desktop" ))), UNO_QUERY );
 +            if ( xDesktop.is() )
 +                xDesktop->addTerminateListener( new OfficeIPCThreadController );
 +            SetSplashScreenProgress(100);
 +        }
 +        catch ( com::sun::star::uno::Exception& e )
 +        {
 +            FatalError( MakeStartupErrorMessage(e.Message) );
 +            return;
 +        }
 +        /*
 +        catch ( ... )
 +        {
 +            FatalError( MakeStartupErrorMessage(
 +                OUString::createFromAscii(
 +                "Unknown error during startup (TD/Desktop service).\nInstallation could be damaged.")));
 +            return;
 +        }
 +        */
  
 -    // Post event to enable acceptors
 -    Application::PostUserEvent( LINK( this, Desktop, EnableAcceptors_Impl) );
 +        // Post user event to startup first application component window
 +        // We have to send this OpenClients message short before execute() to
 +        // minimize the risk that this message overtakes type detection contruction!!
 +        Application::PostUserEvent( LINK( this, Desktop, OpenClients_Impl ) );
  
 -    // The configuration error handler currently is only for startup
 -    aConfigErrHandler.deactivate();
 +        // Post event to enable acceptors
 +        Application::PostUserEvent( LINK( this, Desktop, EnableAcceptors_Impl) );
  
 -   // Acquire solar mutex just before we enter our message loop
 -    if ( nAcquireCount )
 -        Application::AcquireSolarMutex( nAcquireCount );
 +        // The configuration error handler currently is only for startup
 +        aConfigErrHandler.deactivate();
  
 -    // call Application::Execute to process messages in vcl message loop
 -    RTL_LOGFILE_PRODUCT_TRACE( "PERFORMANCE - enter Application::Execute()" );
++       // Acquire solar mutex just before we enter our message loop
++        if ( nAcquireCount )
++            Application::AcquireSolarMutex( nAcquireCount );
+ 
 -    Reference< ::com::sun::star::task::XRestartManager > xRestartManager;
 -    try
 -    {
 -        // The JavaContext contains an interaction handler which is used when
 -        // the creation of a Java Virtual Machine fails
 -        com::sun::star::uno::ContextLayer layer2(
 -            new svt::JavaContext( com::sun::star::uno::getCurrentContext() ) );
 -
 -        ::comphelper::ComponentContext aContext( xSMgr );
 -        xRestartManager.set( aContext.getSingleton( ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "com.sun.star.task.OfficeRestartManager" ) ) ), UNO_QUERY );
 -        if ( !xRestartManager.is() || !xRestartManager->isRestartRequested( sal_True ) )
 +        // call Application::Execute to process messages in vcl message loop
 +        RTL_LOGFILE_PRODUCT_TRACE( "PERFORMANCE - enter Application::Execute()" );
 +
++        Reference< ::com::sun::star::task::XRestartManager > xRestartManager;
 +        try
          {
 -            // if this run of the office is triggered by restart, some additional actions should be done
 -            DoRestartActionsIfNecessary( !pCmdLineArgs->IsInvisible() && !pCmdLineArgs->IsNoQuickstart() );
 +            // The JavaContext contains an interaction handler which is used when
 +            // the creation of a Java Virtual Machine fails
 +            com::sun::star::uno::ContextLayer layer2(
 +                new svt::JavaContext( com::sun::star::uno::getCurrentContext() ) );
 +
-             Execute();
++            ::comphelper::ComponentContext aContext( xSMgr );
++            xRestartManager.set( aContext.getSingleton( ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "com.sun.star.task.OfficeRestartManager" ) ) ), UNO_QUERY );
++            if ( !xRestartManager.is() || !xRestartManager->isRestartRequested( sal_True ) )
++            {
++                // if this run of the office is triggered by restart, some additional actions should be done
++                DoRestartActionsIfNecessary( !pCmdLineArgs->IsInvisible() && !pCmdLineArgs->IsNoQuickstart() );
+ 
 -            Execute();
++                Execute();
++            }
 +        }
 +        catch(const com::sun::star::document::CorruptedFilterConfigurationException& exFilterCfg)
 +        {
 +            OfficeIPCThread::SetDowning();
 +            FatalError( MakeStartupErrorMessage(exFilterCfg.Message) );
 +        }
 +        catch(const com::sun::star::configuration::CorruptedConfigurationException& exAnyCfg)
 +        {
 +            OfficeIPCThread::SetDowning();
 +            FatalError( MakeStartupErrorMessage(exAnyCfg.Message) );
          }
 -    }
 -    catch(const com::sun::star::document::CorruptedFilterConfigurationException& exFilterCfg)
 -    {
 -        OfficeIPCThread::SetDowning();
 -        FatalError( MakeStartupErrorMessage(exFilterCfg.Message) );
 -    }
 -    catch(const com::sun::star::configuration::CorruptedConfigurationException& exAnyCfg)
 -    {
 -        OfficeIPCThread::SetDowning();
 -        FatalError( MakeStartupErrorMessage(exAnyCfg.Message) );
 -    }
 -
 -    // check whether the shutdown is caused by restart
 -    sal_Bool bRestartRequested = ( xRestartManager.is() && xRestartManager->isRestartRequested( sal_True ) );
 -    if ( bRestartRequested )
 -        SetRestartState();
+ 
++        // check whether the shutdown is caused by restart
++        sal_Bool bRestartRequested = ( xRestartManager.is() && xRestartManager->isRestartRequested( sal_True ) );
++        if ( bRestartRequested )
++            SetRestartState();
 +    }
 +    
      if (xGlobalBroadcaster.is())
      {
          css::document::EventObject aEvent;
commit 5fba505261c17ecd9bd2c877cff47fd941045f25
Merge: cde29b4... 45ba31b...
Author: Frank Schoenheit [fs] <frank.schoenheit at oracle.com>
Date:   Wed Aug 25 16:07:39 2010 +0200

    fs33a: merge after pulling OOO330.m5's changes

commit 505336af510bead37a4777f230c2d004a3e9b176
Merge: cb033b9... 4aa0a02...
Author: Ivo Hinkelmann <ihi at openoffice.org>
Date:   Wed Aug 25 14:19:19 2010 +0200

    CWS-TOOLING: integrate CWS sw33bf08

commit cde29b4edf7669ed8f48bc6e81f5513cf09780a8
Author: Frank Schoenheit [fs] <frank.schoenheit at sun.com>
Date:   Wed Aug 25 13:29:38 2010 +0200

    fs33a: when all panels claim to be invisible, make the first one visible

diff --git a/sfx2/source/dialog/taskpane.cxx b/sfx2/source/dialog/taskpane.cxx
index 35da8e2..ef6fb38 100644
--- a/sfx2/source/dialog/taskpane.cxx
+++ b/sfx2/source/dialog/taskpane.cxx
@@ -584,6 +584,7 @@ namespace sfx2
             return;
 
         ::rtl::OUString sFirstVisiblePanelResource;
+        ::rtl::OUString sFirstPanelResource;
 
         const Sequence< ::rtl::OUString > aUIElements( aWindowStateConfig.getNodeNames() );
         for (   const ::rtl::OUString* resource = aUIElements.getConstArray();
@@ -594,6 +595,8 @@ namespace sfx2
             if ( !impl_isToolPanelResource( *resource ) )
                 continue;
 
+            sFirstPanelResource = *resource;
+
             ::utl::OConfigurationNode aResourceNode( aWindowStateConfig.openNode( *resource ) );
             ::svt::PToolPanel pCustomPanel( new CustomToolPanel( aResourceNode, m_xFrame ) );
 
@@ -620,6 +623,9 @@ namespace sfx2
                 sFirstVisiblePanelResource = *resource;
         }
 
+        if ( sFirstVisiblePanelResource.getLength() == 0 )
+            sFirstVisiblePanelResource = sFirstPanelResource;
+
         if ( sFirstVisiblePanelResource.getLength() )
         {
             ::boost::optional< size_t > aPanelPos( GetPanelPos( sFirstVisiblePanelResource ) );
commit cb033b9acb08fb718d7eaffa2b093b395b971cf9
Merge: 45ba31b... 68c3203...
Author: Ivo Hinkelmann <ihi at openoffice.org>
Date:   Wed Aug 25 12:49:35 2010 +0200

    CWS-TOOLING: integrate CWS mib18

commit 8ace426a170164f6e90792de26213ea0eaab7efb
Merge: e087040... 836a0fa...
Author: Dirk Voelzke <dv at openoffice.org>
Date:   Wed Aug 25 10:35:59 2010 +0200

    fwk154: merged heads

commit 836a0fa49c8198c185a14a3b3690621294644c80
Author: Dirk Voelzke <dv at openoffice.org>
Date:   Wed Aug 25 08:25:36 2010 +0200

    fwk154#i114083# fixed some file properies for the Oracle Open Office executables

diff --git a/desktop/util/verinfo.rc b/desktop/util/verinfo.rc
old mode 100644
new mode 100755
index 038953f..7d58995
--- a/desktop/util/verinfo.rc
+++ b/desktop/util/verinfo.rc
@@ -68,25 +68,25 @@ VS_VERSION_INFO versioninfo
 			block "040704E4"
 			{
 				// German StringTable
-				value "CompanyName",		"Oracle, Inc.\0"
+				value "CompanyName",		"Oracle\0"
 				value "FileDescription", "xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx\0"
 				value "FileVersion",		PPS(VER_LEVEL) "\0"
 				value "ProductVersion",		PPS(VER_LEVEL) "\0"
 				value "OriginalFilename",	"SOFFICE.EXE\0"
 				value "InternalName",		"SOFFICE\0"
-				value "LegalCopyright",		S_CRIGHT " Oracle, Inc.\0"
+				value "LegalCopyright",		S_CRIGHT " Oracle and/or its affiliates. All rights reserved.\0"
 			}
 #else
 			block "040904E4"
 			{
 				// International StringTable
-				value "CompanyName", 		"Oracle, Inc.\0"
+				value "CompanyName", 		"Oracle\0"
 				value "FileDescription",	"xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx\0"
 				value "FileVersion",		PPS(VER_LEVEL) "\0"
 				value "ProductVersion",		PPS(VER_LEVEL) "\0"
 				value "OriginalFilename",	"SOFFICE.EXE\0"
 				value "InternalName", 		"SOFFICE\0"
-				value "LegalCopyright", 	S_CRIGHT " Oracle, Inc.\0"
+				value "LegalCopyright", 	S_CRIGHT " Oracle and/or its affiliates. All rights reserved.\0"
 			}
 #endif
 		}
diff --git a/desktop/win32/source/applauncher/ooo/verinfo.rc b/desktop/win32/source/applauncher/ooo/verinfo.rc
old mode 100644
new mode 100755
index ce698ba..c13e723
--- a/desktop/win32/source/applauncher/ooo/verinfo.rc
+++ b/desktop/win32/source/applauncher/ooo/verinfo.rc
@@ -69,7 +69,7 @@ VS_VERSION_INFO versioninfo
 				value "ProductVersion",		PPS(VER_LEVEL) "\0"
 				value "OriginalFilename",	PPS(RES_APP_NAME) ".exe\0"
 				value "InternalName",		PPS(RES_APP_NAME) "\0"
-				value "LegalCopyright",		S_CRIGHT " Sun Microsystems, Inc.\0"
+				value "LegalCopyright",		S_CRIGHT " Oracle and/or its affiliates. All rights reserved.\0"
 			}
 #else
 			block "040904E4"
@@ -81,7 +81,7 @@ VS_VERSION_INFO versioninfo
 				value "ProductVersion",		PPS(VER_LEVEL) "\0"
 				value "OriginalFilename",	PPS(RES_APP_NAME) ".exe\0"
 				value "InternalName",		PPS(RES_APP_NAME) "\0"
-				value "LegalCopyright", 	S_CRIGHT " Sun Microsystems, Inc.\0"
+				value "LegalCopyright", 	S_CRIGHT " Oracle and/or its affiliates. All rights reserved.\0"
 			}
 #endif
 		}
diff --git a/desktop/win32/source/applauncher/verinfo.rc b/desktop/win32/source/applauncher/verinfo.rc
old mode 100644
new mode 100755
index 0db55c5..c0ff714
--- a/desktop/win32/source/applauncher/verinfo.rc
+++ b/desktop/win32/source/applauncher/verinfo.rc
@@ -68,25 +68,25 @@ VS_VERSION_INFO versioninfo
 			block "040704E4"
 			{
 				// German StringTable
-				value "CompanyName",		"Sun Microsystems, Inc.\0"
+				value "CompanyName",		"Oracle\0"
 				value "FileDescription", "xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx\0"
 				value "FileVersion",		PPS(VER_LEVEL) "\0"
 				value "ProductVersion",		PPS(VER_LEVEL) "\0"
 				value "OriginalFilename",	PPS(RES_APP_NAME) ".exe\0"
 				value "InternalName",		PPS(RES_APP_NAME) "\0"
-				value "LegalCopyright",		S_CRIGHT " Sun Microsystems, Inc.\0"
+				value "LegalCopyright",		S_CRIGHT " Oracle and/or its affiliates. All rights reserved.\0"
 			}
 #else
 			block "040904E4"
 			{
 				// International StringTable
-				value "CompanyName", 		"Sun Microsystems, Inc.\0"
+				value "CompanyName", 		"Oracle\0"
 				value "FileDescription",	"xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx\0"
 				value "FileVersion",		PPS(VER_LEVEL) "\0"
 				value "ProductVersion",		PPS(VER_LEVEL) "\0"
 				value "OriginalFilename",	PPS(RES_APP_NAME) ".exe\0"
 				value "InternalName",		PPS(RES_APP_NAME) "\0"
-				value "LegalCopyright", 	S_CRIGHT " Sun Microsystems, Inc.\0"
+				value "LegalCopyright", 	S_CRIGHT " Oracle and/or its affiliates. All rights reserved.\0"
 			}
 #endif
 		}
commit 46cc97b7825b74b9d6f718cb4e7645ce1278a05a
Author: Juergen Schmidt <jsc at openoffice.org>
Date:   Tue Aug 24 17:53:12 2010 +0200

    fwk154: i114090: adapt listener code to reflect changes in config mgr, notification of change events
    (transplanted from 7c0cad639e0b6d74f4be88f5877270f1a8b9fa53)

diff --git a/ucb/source/core/ucb.cxx b/ucb/source/core/ucb.cxx
index e44956b..fadadd0 100644
--- a/ucb/source/core/ucb.cxx
+++ b/ucb/source/core/ucb.cxx
@@ -647,28 +647,10 @@ void SAL_CALL UniversalContentBroker::changesOccurred( const util::ChangesEvent&
     sal_Int32 nCount = Event.Changes.getLength();
     if ( nCount )
     {
-
-        uno::Reference< lang::XMultiServiceFactory > xConfigProv(
-                m_xSMgr->createInstance(
-                    rtl::OUString::createFromAscii(
-                        "com.sun.star.configuration.ConfigurationProvider" ) ),
-                uno::UNO_QUERY_THROW );
-
-        uno::Sequence< uno::Any > aArguments( 1 );
-        beans::PropertyValue      aProperty;
-        aProperty.Name
-            = rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "nodepath" ) );
-        aProperty.Value <<= Event.Base;
-        aArguments[ 0 ] <<= aProperty;
-
-        uno::Reference< uno::XInterface > xInterface(
-                xConfigProv->createInstanceWithArguments(
-                    rtl::OUString( RTL_CONSTASCII_USTRINGPARAM(
-                        "com.sun.star.configuration.ConfigurationAccess" ) ),
-                    aArguments ) );
-
-        uno::Reference< container::XHierarchicalNameAccess >
-                                xHierNameAccess( xInterface, uno::UNO_QUERY_THROW );
+        uno::Reference< container::XHierarchicalNameAccess > xHierNameAccess;
+        Event.Base >>= xHierNameAccess;
+        
+        OSL_ASSERT( xHierNameAccess.is() );
 
         const util::ElementChange* pElementChanges
             = Event.Changes.getConstArray();
commit 9f2a658025c92f5d9dac1d717e0517fba8589d69
Merge: 8325f6b... 45ba31b...
Author: sb <sb at openoffice.org>
Date:   Wed Aug 25 14:21:49 2010 +0200

    sb130: merged in OOO330_m5

diff --cc desktop/source/deployment/registry/configuration/dp_configuration.cxx
index 04adb9c,a2f81e1..bb94b5f
--- a/desktop/source/deployment/registry/configuration/dp_configuration.cxx
+++ b/desktop/source/deployment/registry/configuration/dp_configuration.cxx
@@@ -766,17 -738,21 +747,24 @@@ void BackendImpl::PackageImpl::processP
                  }
                  that->m_registeredPackages->erase(i->first);
              }
-             ::ucbhelper::Content(
-                 makeURL( that->getCachePath(), OUSTR("registry") ),
-                 xCmdEnv ).executeCommand(
-                     OUSTR("delete"), Any( true /* delete physically */ ) );
+             try
+             {
+                 ::ucbhelper::Content(
+                     makeURL( that->getCachePath(), OUSTR("registry") ),
+                     xCmdEnv ).executeCommand(
+                         OUSTR("delete"), Any( true /* delete physically */ ) );
+             }
+             catch(Exception&)
+             {
+                 OSL_ASSERT(0);
+             }
          }
 -        that->deleteDataFromDb(getURL());
 -        
 -        //TODO: revoking at runtime, possible, sensible?
 +        url = that->deleteDataFromDb(url);
 +        if (!m_isSchema) {
 +            com::sun::star::configuration::Update::get(
 +                that->m_xComponentContext)->removeExtensionXcuFile(
 +                    expandUnoRcUrl(url));
 +        }
      }
  } 
  
commit 8325f6b22551883c99c5b11cff50d454ad394a60
Author: sb <sb at openoffice.org>
Date:   Wed Aug 25 14:08:27 2010 +0200

    sb130: #i113096# fixed TODO in configmgr::Broadcaster::send (to ease debugging)

diff --git a/configmgr/source/broadcaster.cxx b/configmgr/source/broadcaster.cxx
index bb77039..ab59d33 100644
--- a/configmgr/source/broadcaster.cxx
+++ b/configmgr/source/broadcaster.cxx
@@ -32,13 +32,17 @@
 #include "com/sun/star/beans/XPropertyChangeListener.hpp"
 #include "com/sun/star/container/XContainerListener.hpp"
 #include "com/sun/star/lang/DisposedException.hpp"
+#include "com/sun/star/lang/WrappedTargetRuntimeException.hpp"
 #include "com/sun/star/lang/XEventListener.hpp"
+#include "com/sun/star/uno/Any.hxx"
 #include "com/sun/star/uno/Exception.hpp"
 #include "com/sun/star/uno/Reference.hxx"
-#include "com/sun/star/uno/RuntimeException.hpp"
 #include "com/sun/star/uno/XInterface.hpp"
 #include "com/sun/star/util/XChangesListener.hpp"
+#include "cppuhelper/exc_hlp.hxx"
 #include "osl/diagnose.hxx"
+#include "rtl/string.h"
+#include "rtl/ustrbuf.hxx"
 #include "rtl/ustring.h"
 #include "rtl/ustring.hxx"
 
@@ -50,6 +54,13 @@ namespace {
 
 namespace css = com::sun::star;
 
+void appendMessage(
+    rtl::OUStringBuffer & buffer, css::uno::Exception const & exception)
+{
+    buffer.appendAscii(RTL_CONSTASCII_STRINGPARAM("; "));
+    buffer.append(exception.Message);
+}
+
 }
 
 void Broadcaster::addDisposeNotification(
@@ -108,14 +119,16 @@ void Broadcaster::addChangesNotification(
 }
 
 void Broadcaster::send() {
-    bool exception = false;
+    css::uno::Any exception;
+    rtl::OUStringBuffer messages;
     for (DisposeNotifications::iterator i(disposeNotifications_.begin());
          i != disposeNotifications_.end(); ++i) {
         try {
             i->listener->disposing(i->event);
         } catch (css::lang::DisposedException &) {
-        } catch (css::uno::Exception &) {
-            exception = true;
+        } catch (css::uno::Exception & e) {
+            exception = cppu::getCaughtException();
+            appendMessage(messages, e);
         }
     }
     for (ContainerNotifications::iterator i(
@@ -125,8 +138,9 @@ void Broadcaster::send() {
         try {
             i->listener->elementInserted(i->event);
         } catch (css::lang::DisposedException &) {
-        } catch (css::uno::Exception &) {
-            exception = true;
+        } catch (css::uno::Exception & e) {
+            exception = cppu::getCaughtException();
+            appendMessage(messages, e);
         }
     }
     for (ContainerNotifications::iterator i(
@@ -136,8 +150,9 @@ void Broadcaster::send() {
         try {
             i->listener->elementRemoved(i->event);
         } catch (css::lang::DisposedException &) {
-        } catch (css::uno::Exception &) {
-            exception = true;
+        } catch (css::uno::Exception & e) {
+            exception = cppu::getCaughtException();
+            appendMessage(messages, e);
         }
     }
     for (ContainerNotifications::iterator i(
@@ -147,8 +162,9 @@ void Broadcaster::send() {
         try {
             i->listener->elementReplaced(i->event);
         } catch (css::lang::DisposedException &) {
-        } catch (css::uno::Exception &) {
-            exception = true;
+        } catch (css::uno::Exception & e) {
+            exception = cppu::getCaughtException();
+            appendMessage(messages, e);
         }
     }
     for (PropertyChangeNotifications::iterator i(
@@ -158,8 +174,9 @@ void Broadcaster::send() {
         try {
             i->listener->propertyChange(i->event);
         } catch (css::lang::DisposedException &) {
-        } catch (css::uno::Exception &) {
-            exception = true;
+        } catch (css::uno::Exception & e) {
+            exception = cppu::getCaughtException();
+            appendMessage(messages, e);
         }
     }
     for (PropertiesChangeNotifications::iterator i(
@@ -169,8 +186,9 @@ void Broadcaster::send() {
         try {
             i->listener->propertiesChange(i->event);
         } catch (css::lang::DisposedException &) {
-        } catch (css::uno::Exception &) {
-            exception = true;
+        } catch (css::uno::Exception & e) {
+            exception = cppu::getCaughtException();
+            appendMessage(messages, e);
         }
     }
     for (ChangesNotifications::iterator i(changesNotifications_.begin());
@@ -178,16 +196,19 @@ void Broadcaster::send() {
         try {
             i->listener->changesOccurred(i->event);
         } catch (css::lang::DisposedException &) {
-        } catch (css::uno::Exception &) {
-            exception = true;
+        } catch (css::uno::Exception & e) {
+            exception = cppu::getCaughtException();
+            appendMessage(messages, e);
         }
     }
-    if (exception) { //TODO
-        throw css::uno::RuntimeException(
-            rtl::OUString(
+    if (exception.hasValue()) {
+        throw css::lang::WrappedTargetRuntimeException(
+            (rtl::OUString(
                 RTL_CONSTASCII_USTRINGPARAM(
-                    "configmgr exceptions during listener notification")),
-            css::uno::Reference< css::uno::XInterface >());
+                    "configmgr exceptions during listener notification")) +
+             messages.makeStringAndClear()),
+            css::uno::Reference< css::uno::XInterface >(),
+            exception);
     }
 }
 
commit e087040c0d686ca1f03b95a432567a700d420bfe
Author: Juergen Schmidt <jsc at openoffice.org>
Date:   Tue Aug 24 17:53:12 2010 +0200

    fwk154: i114090: adapt listener code to reflect changes in config mgr, notification of change events

diff --git a/ucb/source/core/ucb.cxx b/ucb/source/core/ucb.cxx
index e44956b..fadadd0 100644
--- a/ucb/source/core/ucb.cxx
+++ b/ucb/source/core/ucb.cxx
@@ -647,28 +647,10 @@ void SAL_CALL UniversalContentBroker::changesOccurred( const util::ChangesEvent&
     sal_Int32 nCount = Event.Changes.getLength();
     if ( nCount )
     {
-
-        uno::Reference< lang::XMultiServiceFactory > xConfigProv(
-                m_xSMgr->createInstance(
-                    rtl::OUString::createFromAscii(
-                        "com.sun.star.configuration.ConfigurationProvider" ) ),
-                uno::UNO_QUERY_THROW );
-
-        uno::Sequence< uno::Any > aArguments( 1 );
-        beans::PropertyValue      aProperty;
-        aProperty.Name
-            = rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "nodepath" ) );
-        aProperty.Value <<= Event.Base;
-        aArguments[ 0 ] <<= aProperty;
-
-        uno::Reference< uno::XInterface > xInterface(
-                xConfigProv->createInstanceWithArguments(
-                    rtl::OUString( RTL_CONSTASCII_USTRINGPARAM(
-                        "com.sun.star.configuration.ConfigurationAccess" ) ),
-                    aArguments ) );
-
-        uno::Reference< container::XHierarchicalNameAccess >
-                                xHierNameAccess( xInterface, uno::UNO_QUERY_THROW );
+        uno::Reference< container::XHierarchicalNameAccess > xHierNameAccess;
+        Event.Base >>= xHierNameAccess;
+        
+        OSL_ASSERT( xHierNameAccess.is() );
 
         const util::ElementChange* pElementChanges
             = Event.Changes.getConstArray();
commit f4e7b133d8836e97f4a58e360405238866535cb9
Author: Carsten Driesner <cd at openoffice.org>
Date:   Mon Aug 23 13:43:42 2010 +0200

    fwk154: #i114014# Use correct compare statement

diff --git a/uui/source/iahndl-authentication.cxx b/uui/source/iahndl-authentication.cxx
index 7d379d6..d166b86 100644
--- a/uui/source/iahndl-authentication.cxx
+++ b/uui/source/iahndl-authentication.cxx
@@ -270,7 +270,7 @@ handleAuthenticationRequest_(
     aInfo.SetCanRememberPassword(
         ePreferredRememberMode != eAlternateRememberMode);
     aInfo.SetIsRememberPassword(
-        ePreferredRememberMode != eDefaultRememberMode);
+        ePreferredRememberMode == eDefaultRememberMode);
     aInfo.SetIsRememberPersistent(
         ePreferredRememberMode == ucb::RememberAuthentication_PERSISTENT);
 
commit 7e963509b1786bcabac7560e5d962359d56418a7
Author: Carsten Driesner <cd at openoffice.org>
Date:   Mon Aug 23 12:46:11 2010 +0200

    fwk154: #i114014# Fix problem with check box 'Remember Password' in login dialog

diff --git a/uui/source/iahndl-authentication.cxx b/uui/source/iahndl-authentication.cxx
old mode 100755
new mode 100644
index 57c9ead..7d379d6
--- a/uui/source/iahndl-authentication.cxx
+++ b/uui/source/iahndl-authentication.cxx
@@ -270,7 +270,7 @@ handleAuthenticationRequest_(
     aInfo.SetCanRememberPassword(
         ePreferredRememberMode != eAlternateRememberMode);
     aInfo.SetIsRememberPassword(
-        eDefaultRememberMode != ucb::RememberAuthentication_NO);
+        ePreferredRememberMode != eDefaultRememberMode);
     aInfo.SetIsRememberPersistent(
         ePreferredRememberMode == ucb::RememberAuthentication_PERSISTENT);
 
commit 5be137f8b856bc67fd6fb99a11eaee3faf1400a4
Merge: 2914220... a3652f2...
Author: Mikhail Voytenko <mav at openoffice.org>
Date:   Wed Aug 18 16:48:00 2010 +0200

    fwk153: merge

commit 29142204d1d7a495c7477c9f4cc842150a636aee
Author: Mikhail Voytenko <mav at openoffice.org>
Date:   Wed Aug 18 16:43:38 2010 +0200

    fwk153: #i113674# replace backing component if there is one

diff --git a/framework/inc/classes/framelistanalyzer.hxx b/framework/inc/classes/framelistanalyzer.hxx
index cabd25b..77f7328 100644
--- a/framework/inc/classes/framelistanalyzer.hxx
+++ b/framework/inc/classes/framelistanalyzer.hxx
@@ -29,13 +29,6 @@
 #define __FRAMEWORK_CLASSES_FRAMELISTANALYZER_HXX_
 
 //_______________________________________________
-//	my own includes
-
-#include <threadhelp/threadhelpbase.hxx>
-#include <macros/debug.hxx>
-#include <general.h>
-
-//_______________________________________________
 //	interface includes
 #include <com/sun/star/frame/XFrame.hpp>
 
@@ -88,10 +81,10 @@ class FrameListAnalyzer
     public:
 
         /** provides access to the frame container, which should be analyzed. */
-        const css::uno::Reference< css::frame::XFramesSupplier >& m_xSupplier;
+        const ::com::sun::star::uno::Reference< ::com::sun::star::frame::XFramesSupplier >& m_xSupplier;
 
         /** hold the reference frame, which is used e.g. to detect other frames with the same model. */
-        const css::uno::Reference< css::frame::XFrame >& m_xReferenceFrame;
+        const ::com::sun::star::uno::Reference< ::com::sun::star::frame::XFrame >& m_xReferenceFrame;
 
         /** enable/disable some special analyzing steps.
             see impl_analyze() for further informations. */
@@ -100,19 +93,19 @@ class FrameListAnalyzer
         /** contains all frames, which uses the same model like the reference frame.
             Will be filled only if m_eDetectMode has set the flag E_MODEL.
             The reference frame is never part of this list! */
-        css::uno::Sequence< css::uno::Reference< css::frame::XFrame > > m_lModelFrames;
+        ::com::sun::star::uno::Sequence< ::com::sun::star::uno::Reference< ::com::sun::star::frame::XFrame > > m_lModelFrames;
 
         /** contains all frames, which does not contain the same model like the reference frame.
             Filling of it can't be supressed by m_eDetectMode.
             The reference frame is never part of this list!
             All frames inside this list are visible ones. */
-        css::uno::Sequence< css::uno::Reference< css::frame::XFrame > > m_lOtherVisibleFrames;
+        ::com::sun::star::uno::Sequence< ::com::sun::star::uno::Reference< ::com::sun::star::frame::XFrame > > m_lOtherVisibleFrames;
 
         /** contains all frames, which does not contain the same model like the reference frame.
             Filling of it can't be supressed by m_eDetectMode.
             The reference frame is never part of this list!
             All frames inside this list are hidden ones. */
-        css::uno::Sequence< css::uno::Reference< css::frame::XFrame > > m_lOtherHiddenFrames;
+        ::com::sun::star::uno::Sequence< ::com::sun::star::uno::Reference< ::com::sun::star::frame::XFrame > > m_lOtherHiddenFrames;
 
         /** points to the help frame.
             Will be set only, if any other frame (means different from the reference frame)
@@ -137,7 +130,7 @@ class FrameListAnalyzer
             Analyzing of the help frame ignores the visible state of any frame.
             But note: a hidden help frame indicates a wrong state!
          */
-        css::uno::Reference< css::frame::XFrame > m_xHelp;
+        ::com::sun::star::uno::Reference< ::com::sun::star::frame::XFrame > m_xHelp;
 
         /** points to the frame, which contains the backing component.
             Will be set only, if any other frame (means different from the reference frame)
@@ -163,7 +156,7 @@ class FrameListAnalyzer
             Analyzing of the help frame ignores the visible state of any frame.
             But note: a hidden backing mode frame indicates a wrong state!
          */
-        css::uno::Reference< css::frame::XFrame > m_xBackingComponent;
+        ::com::sun::star::uno::Reference< ::com::sun::star::frame::XFrame > m_xBackingComponent;
 
         /** is set to true only, if the reference frame is a hidden one.
             This value is undefined if m_eDetectMode doesn't have set the flag E_HIDDEN! */
@@ -200,8 +193,8 @@ class FrameListAnalyzer
                     analyze steps. Note: Some member values will be undefined, if
                     an analyze step will be disabled.
          */
-                 FrameListAnalyzer( const css::uno::Reference< css::frame::XFramesSupplier >& xSupplier       ,
-                                    const css::uno::Reference< css::frame::XFrame >&          xReferenceFrame ,
+                 FrameListAnalyzer( const ::com::sun::star::uno::Reference< ::com::sun::star::frame::XFramesSupplier >& xSupplier       ,
+                                    const ::com::sun::star::uno::Reference< ::com::sun::star::frame::XFrame >&          xReferenceFrame ,
                                           sal_uInt32                                          eDetectMode     );
         virtual ~FrameListAnalyzer();
 
diff --git a/framework/prj/d.lst b/framework/prj/d.lst
index 7f260f0..fe6077f 100644
--- a/framework/prj/d.lst
+++ b/framework/prj/d.lst
@@ -42,6 +42,7 @@ mkdir: %_DEST%\xml%_EXT%\uiconfig\modules\StartModule\statusbar
 ..\inc\classes\menuextensionsupplier.hxx %_DEST%\inc%_EXT%\framework\menuextensionsupplier.hxx
 ..\inc\interaction\preventduplicateinteraction.hxx %_DEST%\inc%_EXT%\framework\preventduplicateinteraction.hxx
 ..\inc\helper\titlehelper.hxx %_DEST%\inc%_EXT%\framework\titlehelper.hxx
+..\inc\classes\framelistanalyzer.hxx %_DEST%\inc%_EXT%\framework\framelistanalyzer.hxx
 
 ..\uiconfig\startmodule\menubar\*.xml %_DEST%\xml%_EXT%\uiconfig\modules\StartModule\menubar\*.xml
 ..\uiconfig\startmodule\toolbar\*.xml %_DEST%\xml%_EXT%\uiconfig\modules\StartModule\toolbar\*.xml
diff --git a/framework/util/makefile.mk b/framework/util/makefile.mk
index 91532cd..edc5f67 100644
--- a/framework/util/makefile.mk
+++ b/framework/util/makefile.mk
@@ -50,7 +50,6 @@ LIB1OBJFILES=   \
                 $(SLO)$/protocolhandlercache.obj                \
                 $(SLO)$/networkdomain.obj                       \
                 $(SLO)$/configaccess.obj                        \
-                $(SLO)$/framelistanalyzer.obj                   \
                 $(SLO)$/shareablemutex.obj                      \
                 $(SLO)$/itemcontainer.obj                       \
                 $(SLO)$/rootitemcontainer.obj                   \
@@ -99,6 +98,7 @@ LIB2OBJFILES=   \
                 $(SLO)$/configimporter.obj                      \
                 $(SLO)$/menuextensionsupplier.obj               \
                 $(SLO)$/preventduplicateinteraction.obj         \
+                $(SLO)$/framelistanalyzer.obj                   \
                 $(SLO)$/titlehelper.obj
 
 # --- import classes library ---------------------------------------------------
diff --git a/sfx2/source/view/viewfrm.cxx b/sfx2/source/view/viewfrm.cxx
index a8edc01..01574e4 100644
--- a/sfx2/source/view/viewfrm.cxx
+++ b/sfx2/source/view/viewfrm.cxx
@@ -96,6 +96,7 @@
 #include <comphelper/storagehelper.hxx>
 #include <svtools/asynclink.hxx>
 #include <svl/sharecontrolfile.hxx>
+#include <framework/framelistanalyzer.hxx>
 
 #include <boost/optional.hpp>
 
@@ -2092,7 +2093,25 @@ SfxViewFrame* SfxViewFrame::LoadViewIntoFrame_Impl_NoThrow( const SfxObjectShell
         {
             ::comphelper::ComponentContext aContext( ::comphelper::getProcessServiceFactory() );
             Reference < XFrame > xDesktop( aContext.createComponent( "com.sun.star.frame.Desktop" ), UNO_QUERY_THROW );
-            xFrame.set( xDesktop->findFrame( DEFINE_CONST_UNICODE("_blank"), 0 ), UNO_SET_THROW );
+
+            if ( !i_bHidden )
+            {
+                try
+                {
+                    // if there is a backing component, use it
+                    Reference< XFramesSupplier > xTaskSupplier( xDesktop , css::uno::UNO_QUERY_THROW );
+                    ::framework::FrameListAnalyzer aAnalyzer( xTaskSupplier, Reference< XFrame >(), ::framework::FrameListAnalyzer::E_BACKINGCOMPONENT );
+
+                    if ( aAnalyzer.m_xBackingComponent.is() )
+                        xFrame = aAnalyzer.m_xBackingComponent;
+                }
+                catch( uno::Exception& )
+                {}
+            }
+
+            if ( !xFrame.is() )
+                xFrame.set( xDesktop->findFrame( DEFINE_CONST_UNICODE("_blank"), 0 ), UNO_SET_THROW );
+
             bOwnFrame = true;
         }
 
commit 45ba31b194bc51b16d8f0892e432b2b77fce144d
Merge: ce2c621... ad4d380...
Author: Kurt Zenker <kz at openoffice.org>
Date:   Wed Aug 18 13:23:34 2010 +0200

    CWS-TOOLING: integrate CWS ooo33gsl05

commit ce2c62170340cfe0870f58b3b557c33f9441f2bd
Merge: d939031... a6f18d1...
Author: Kurt Zenker <kz at openoffice.org>
Date:   Wed Aug 18 12:43:13 2010 +0200

    CWS-TOOLING: integrate CWS mav56

commit d939031546d7472e09a1a096d78e1e3dbbb94e42
Merge: 6e0e29c... 16a891e...
Author: Kurt Zenker <kz at openoffice.org>
Date:   Wed Aug 18 12:39:06 2010 +0200

    CWS-TOOLING: integrate CWS fwk151

commit 6e0e29c23afae5d6715405b89a0d498b89cd9d5e
Merge: 05d4c10... 0517fd2...
Author: Kurt Zenker <kz at openoffice.org>
Date:   Wed Aug 18 12:00:05 2010 +0200

    CWS-TOOLING: integrate CWS jl154

diff --cc desktop/source/deployment/gui/dp_gui_dialog2.cxx
index ed5db4c,9f5d400..9f5d400
mode 100755,100755..100644
--- a/desktop/source/deployment/gui/dp_gui_dialog2.cxx
+++ b/desktop/source/deployment/gui/dp_gui_dialog2.cxx
diff --cc desktop/source/migration/services/cexportsoo3.cxx
index b33d789,2ac1a0b..2ac1a0b
mode 100755,100755..100644
--- a/desktop/source/migration/services/cexportsoo3.cxx
+++ b/desktop/source/migration/services/cexportsoo3.cxx
diff --cc desktop/source/migration/services/oo3extensionmigration.cxx
index 578dda0,a481857..a481857
mode 100644,100755..100644
--- a/desktop/source/migration/services/oo3extensionmigration.cxx
+++ b/desktop/source/migration/services/oo3extensionmigration.cxx
diff --cc desktop/source/migration/services/oo3extensionmigration.hxx
index 124bc1b,721a1bd..721a1bd
mode 100644,100755..100644
--- a/desktop/source/migration/services/oo3extensionmigration.hxx
+++ b/desktop/source/migration/services/oo3extensionmigration.hxx
commit a3652f203372976692c4bd02e51d0b86448ec51b
Merge: cee18c6... 27e0667...
Author: Carsten Driesner <cd at openoffice.org>
Date:   Wed Aug 18 11:00:57 2010 +0200

    fwk153: Merge changes

commit cee18c6b582e045958a70cee8222a83598f4c437
Author: Carsten Driesner <cd at openoffice.org>
Date:   Wed Aug 18 10:52:09 2010 +0200

    fwk153: #i110127# Provide one instance of module accelerator manager in module ui configuration manager implementation.

diff --git a/framework/inc/uiconfiguration/moduleuiconfigurationmanager.hxx b/framework/inc/uiconfiguration/moduleuiconfigurationmanager.hxx
index ce71154..f85ff68 100644
--- a/framework/inc/uiconfiguration/moduleuiconfigurationmanager.hxx
+++ b/framework/inc/uiconfiguration/moduleuiconfigurationmanager.hxx
@@ -219,6 +219,7 @@ namespace framework
             com::sun::star::uno::Reference< com::sun::star::lang::XMultiServiceFactory >    m_xServiceManager;
             ::cppu::OMultiTypeInterfaceContainerHelper                                      m_aListenerContainer;   /// container for ALL Listener
             com::sun::star::uno::Reference< com::sun::star::lang::XComponent >              m_xModuleImageManager;
+            com::sun::star::uno::Reference< com::sun::star::uno::XInterface >               m_xModuleAcceleratorManager;
    };
 }
 
diff --git a/framework/source/accelerators/acceleratorconfiguration.cxx b/framework/source/accelerators/acceleratorconfiguration.cxx
index 6f626b2..cc565f4 100644
--- a/framework/source/accelerators/acceleratorconfiguration.cxx
+++ b/framework/source/accelerators/acceleratorconfiguration.cxx
@@ -1246,12 +1246,13 @@ void SAL_CALL XCUBasedAcceleratorConfiguration::changesOccurred(const css::util:
     if (! xHAccess.is ())
         return;
 
-    const sal_Int32 c = aEvent.Changes.getLength();
+    css::util::ChangesEvent aReceivedEvents( aEvent );
+    const sal_Int32 c = aReceivedEvents.Changes.getLength();
           sal_Int32 i = 0;
 
     for (i=0; i<c; ++i)
     {
-        const css::util::ElementChange& aChange  =   aEvent.Changes[i];
+        const css::util::ElementChange& aChange  =   aReceivedEvents.Changes[i];
 
         // Only path of form "PrimaryKeys/Modules/Module['<module_name>']/Key['<command_url>']/Command[<locale>]" will
         // be interesting for use. Sometimes short path values are given also by the broadcaster ... but they must be ignored :-)
diff --git a/framework/source/uiconfiguration/moduleuiconfigurationmanager.cxx b/framework/source/uiconfiguration/moduleuiconfigurationmanager.cxx
index a4827dc..54f8ecf 100644
--- a/framework/source/uiconfiguration/moduleuiconfigurationmanager.cxx
+++ b/framework/source/uiconfiguration/moduleuiconfigurationmanager.cxx
@@ -776,26 +776,29 @@ void SAL_CALL ModuleUIConfigurationManager::dispose() throw (::com::sun::star::u
     css::lang::EventObject aEvent( xThis );
     m_aListenerContainer.disposeAndClear( aEvent );
     
+    /* SAFE AREA ----------------------------------------------------------------------------------------------- */
+    ResetableGuard aGuard( m_aLock );
+    Reference< XComponent > xModuleImageManager( m_xModuleImageManager );
+    m_xModuleImageManager.clear();
+    m_xModuleAcceleratorManager.clear();
+    m_aUIElements[LAYER_USERDEFINED].clear();
+    m_aUIElements[LAYER_DEFAULT].clear();
+    m_xDefaultConfigStorage.clear();
+    m_xUserConfigStorage.clear();
+    m_xUserRootCommit.clear();
+    m_bConfigRead = false;
+    m_bModified = false;
+    m_bDisposed = true;
+    aGuard.unlock();
+    /* SAFE AREA ----------------------------------------------------------------------------------------------- */
+    
+    try
+    {
+        if ( xModuleImageManager.is() )
+            xModuleImageManager->dispose();
+    }
+    catch ( Exception& )
     {
-        ResetableGuard aGuard( m_aLock );
-        try
-        {
-            if ( m_xModuleImageManager.is() )
-                m_xModuleImageManager->dispose();
-        }
-        catch ( Exception& )
-        {
-        }
-        
-        m_xModuleImageManager.clear();
-        m_aUIElements[LAYER_USERDEFINED].clear();
-        m_aUIElements[LAYER_DEFAULT].clear();
-        m_xDefaultConfigStorage.clear();
-        m_xUserConfigStorage.clear();
-        m_xUserRootCommit.clear();
-        m_bConfigRead = false;
-        m_bModified = false;
-        m_bDisposed = true;
     }
 }
 
@@ -1370,30 +1373,35 @@ Reference< XInterface > SAL_CALL ModuleUIConfigurationManager::getImageManager()
     }
 
     return Reference< XInterface >( m_xModuleImageManager, UNO_QUERY );
-
-//    return Reference< XInterface >();
 }
 
 Reference< XInterface > SAL_CALL ModuleUIConfigurationManager::getShortCutManager() throw (::com::sun::star::uno::RuntimeException)
 {
     ResetableGuard aGuard( m_aLock );
+
+    if ( m_bDisposed )
+        throw DisposedException();
+
     Reference< XMultiServiceFactory > xSMGR   = m_xServiceManager;
-    ::rtl::OUString                   aModule = /*m_aModuleShortName*/m_aModuleIdentifier;
-    aGuard.unlock();
+    ::rtl::OUString                   aModule = m_aModuleIdentifier;
 
-    Reference< XInterface >      xManager = xSMGR->createInstance(SERVICENAME_MODULEACCELERATORCONFIGURATION); 
-    Reference< XInitialization > xInit    (xManager, UNO_QUERY_THROW);
-    
-    PropertyValue aProp;
-    aProp.Name    = ::rtl::OUString::createFromAscii("ModuleIdentifier");
-    aProp.Value <<= aModule;
-    
-    Sequence< Any > lArgs(1);
-    lArgs[0] <<= aProp;
-    
-    xInit->initialize(lArgs);
+    if ( !m_xModuleAcceleratorManager.is() )
+    {
+        Reference< XInterface >      xManager = xSMGR->createInstance(SERVICENAME_MODULEACCELERATORCONFIGURATION); 
+        Reference< XInitialization > xInit    (xManager, UNO_QUERY_THROW);
+        
+        PropertyValue aProp;
+        aProp.Name    = ::rtl::OUString::createFromAscii("ModuleIdentifier");
+        aProp.Value <<= aModule;
+        
+        Sequence< Any > lArgs(1);
+        lArgs[0] <<= aProp;
+        
+        xInit->initialize(lArgs);
+        m_xModuleAcceleratorManager = Reference< XInterface >( xManager, UNO_QUERY );
+    }
     
-    return xManager;
+    return m_xModuleAcceleratorManager;
 }
 
 Reference< XInterface > SAL_CALL ModuleUIConfigurationManager::getEventsManager() throw (::com::sun::star::uno::RuntimeException)
commit 4aa0a027c7994cad5529534a32b9a903f01907b1
Author: Thomas Lange [tl] <tl at openoffice.org>
Date:   Tue Aug 17 16:46:36 2010 +0200

    cws sw33bf08: #i113584#, #i113587# transliteration fixed

diff --git a/editeng/source/editeng/impedit.hxx b/editeng/source/editeng/impedit.hxx
index 9c425bc..709475a 100755
--- a/editeng/source/editeng/impedit.hxx
+++ b/editeng/source/editeng/impedit.hxx
@@ -51,6 +51,7 @@
 #include <com/sun/star/i18n/CharacterIteratorMode.hpp>
 #include <com/sun/star/i18n/WordType.hpp>
 #include <com/sun/star/i18n/XExtendedInputSequenceChecker.hpp>
+#include <com/sun/star/uno/Sequence.hxx>
 
 #include <i18npool/lang.h>
 #include <vos/ref.hxx>
@@ -1002,6 +1003,8 @@ public:
     void				SetAutoCompleteText( const String& rStr, sal_Bool bUpdateTipWindow );
 
     EditSelection		TransliterateText( const EditSelection& rSelection, sal_Int32 nTransliterationMode );
+    short               ReplaceTextOnly( ContentNode* pNode, USHORT nCurrentStart, xub_StrLen nLen, const String& rText, const ::com::sun::star::uno::Sequence< sal_Int32 >& rOffsets );
+
 
     void                SetAsianCompressionMode( USHORT n );
     USHORT              GetAsianCompressionMode() const { return nAsianCompressionMode; }
diff --git a/editeng/source/editeng/impedit4.cxx b/editeng/source/editeng/impedit4.cxx
index 6fc80ac..04888ff 100755
--- a/editeng/source/editeng/impedit4.cxx
+++ b/editeng/source/editeng/impedit4.cxx
@@ -76,6 +76,9 @@
 #include <com/sun/star/linguistic2/XThesaurus.hpp>
 #include <com/sun/star/linguistic2/XMeaning.hpp>
 #include <com/sun/star/i18n/ScriptType.hpp>
+#include <com/sun/star/i18n/WordType.hpp>
+#include <com/sun/star/i18n/TransliterationModules.hpp>
+#include <com/sun/star/i18n/TransliterationModulesExtra.hpp>
 #include <unotools/transliterationwrapper.hxx>
 #include <unotools/textsearch.hxx>
 #include <comphelper/processfactory.hxx>
@@ -83,6 +86,8 @@
 #include <svtools/rtfkeywd.hxx>
 #include <editeng/edtdlg.hxx>
 
+#include <vector>
+
 using namespace ::com::sun::star;
 using namespace ::com::sun::star::uno;
 using namespace ::com::sun::star::beans;
@@ -2798,8 +2803,23 @@ void ImpEditEngine::SetAutoCompleteText( const String& rStr, sal_Bool bClearTipW
 #endif // !SVX_LIGHT
 }
 
+
+struct TransliterationChgData
+{
+    USHORT                      nStart;
+    xub_StrLen                  nLen;
+    EditSelection               aSelection;
+    String                      aNewText;
+    uno::Sequence< sal_Int32 >  aOffsets;
+};
+
+
 EditSelection ImpEditEngine::TransliterateText( const EditSelection& rSelection, sal_Int32 nTransliterationMode )
 {
+    uno::Reference < i18n::XBreakIterator > _xBI( ImplGetBreakIterator() );
+    if (!_xBI.is())
+        return rSelection;
+
     EditSelection aSel( rSelection );
     aSel.Adjust( aEditDoc );
 
@@ -2808,8 +2828,8 @@ EditSelection ImpEditEngine::TransliterateText( const EditSelection& rSelection,
 
     EditSelection aNewSel( aSel );
 
-    USHORT nStartNode = aEditDoc.GetPos( aSel.Min().GetNode() );
-    USHORT nEndNode = aEditDoc.GetPos( aSel.Max().GetNode() );
+    const USHORT nStartNode = aEditDoc.GetPos( aSel.Min().GetNode() );
+    const USHORT nEndNode = aEditDoc.GetPos( aSel.Max().GetNode() );
 
     BOOL bChanges = FALSE;
     BOOL bLenChanged = FALSE;
@@ -2832,83 +2852,266 @@ EditSelection ImpEditEngine::TransliterateText( const EditSelection& rSelection,
         USHORT nCurrentEnd = nEndPos;
         sal_uInt16 nLanguage = LANGUAGE_SYSTEM;
 
-        do
-        {
-            if ( bConsiderLanguage )
+        // since we don't use Hiragana/Katakana or half-width/full-width transliterations here
+        // it is fine to use ANYWORD_IGNOREWHITESPACES. (ANY_WORD btw is broken and will 
+        // occasionaly miss words in consecutive sentences). Also with ANYWORD_IGNOREWHITESPACES
+        // text like 'just-in-time' will be converted to 'Just-In-Time' which seems to be the
+        // proper thing to do.
+        const sal_Int16 nWordType = i18n::WordType::ANYWORD_IGNOREWHITESPACES;
+
+        //! In order to have less trouble with changing text size, e.g. because
+        //! of ligatures or � (German small sz) being resolved, we need to process 
+        //! the text replacements from end to start. 
+        //! This way the offsets for the yet to be changed words will be 
+        //! left unchanged by the already replaced text. 
+        //! For this we temporarily save the changes to be done in this vector
+        std::vector< TransliterationChgData >   aChanges;
+        TransliterationChgData                  aChgData;
+
+        if (nTransliterationMode == i18n::TransliterationModulesExtra::TITLE_CASE)
+        {
+            // for 'capitalize every word' we need to iterate over each word
+
+            i18n::Boundary aSttBndry;
+            i18n::Boundary aEndBndry;
+            aSttBndry = _xBI->getWordBoundary(
+                        *pNode, nStartPos,
+                        SvxCreateLocale( GetLanguage( EditPaM( pNode, nStartPos + 1 ) ) ), 
+                        nWordType, TRUE /*prefer forward direction*/);
+            aEndBndry = _xBI->getWordBoundary(
+                        *pNode, nEndPos,
+                        SvxCreateLocale( GetLanguage( EditPaM( pNode, nEndPos + 1 ) ) ), 
+                        nWordType, FALSE /*prefer backward direction*/);
+
+            // prevent backtracking to the previous word if selection is at word boundary
+            if (aSttBndry.endPos <= nStartPos)
+            {
+                aSttBndry = _xBI->nextWord(
+                        *pNode, aSttBndry.endPos,
+                        SvxCreateLocale( GetLanguage( EditPaM( pNode, aSttBndry.endPos + 1 ) ) ),
+                        nWordType);
+            }
+            // prevent advancing to the next word if selection is at word boundary
+            if (aEndBndry.startPos >= nEndPos)
             {
-                nLanguage = GetLanguage( EditPaM( pNode, nCurrentStart+1 ), &nCurrentEnd );
-                if ( nCurrentEnd > nEndPos )
-                    nCurrentEnd = nEndPos;
+                aEndBndry = _xBI->previousWord(
+                        *pNode, aEndBndry.startPos,
+                        SvxCreateLocale( GetLanguage( EditPaM( pNode, aEndBndry.startPos + 1 ) ) ),
+                        nWordType);
             }
 
-            xub_StrLen nLen = nCurrentEnd - nCurrentStart;
+            i18n::Boundary aCurWordBndry( aSttBndry );
+            while (aCurWordBndry.startPos <= aEndBndry.startPos)
+            {
+                nCurrentStart = (xub_StrLen)aCurWordBndry.startPos;
+                nCurrentEnd   = (xub_StrLen)aCurWordBndry.endPos;
+                sal_Int32 nLen = nCurrentEnd - nCurrentStart;
+                DBG_ASSERT( nLen > 0, "invalid word length of 0" );
+#if OSL_DEBUG_LEVEL > 1
+                String aText( pNode->Copy( nCurrentStart, nLen ) );
+#endif
+
+                Sequence< sal_Int32 > aOffsets;
+                String aNewText( aTranslitarationWrapper.transliterate( *pNode, 
+                        GetLanguage( EditPaM( pNode, nCurrentStart + 1 ) ), 
+                        nCurrentStart, nLen, &aOffsets ));
 
-            Sequence <sal_Int32> aOffsets;
-            String aNewText( aTranslitarationWrapper.transliterate( *pNode, nLanguage, nCurrentStart, nLen, &aOffsets ) );
+                if (!pNode->Equals( aNewText, nCurrentStart, nLen ))
+                {
+                    aChgData.nStart     = nCurrentStart;
+                    aChgData.nLen       = nLen;
+                    aChgData.aSelection = EditSelection( EditPaM( pNode, nCurrentStart ), EditPaM( pNode, nCurrentEnd ) );
+                    aChgData.aNewText   = aNewText;
+                    aChgData.aOffsets   = aOffsets;
+                    aChanges.push_back( aChgData );
+                }
+#if OSL_DEBUG_LEVEL > 1
+                String aSelTxt ( GetSelected( aChgData.aSelection ) );
+                (void) aSelTxt;
+#endif
 
-            if( ( nLen != aNewText.Len() ) || !pNode->Equals( aNewText, nCurrentStart, nLen ) )
+                aCurWordBndry = _xBI->nextWord( *pNode, nCurrentEnd, 
+                        SvxCreateLocale( GetLanguage( EditPaM( pNode, nCurrentEnd + 1 ) ) ), 
+                        nWordType);
+            }
+            DBG_ASSERT( nCurrentEnd >= aEndBndry.endPos, "failed to reach end of transliteration" );
+        }
+        else if (nTransliterationMode == i18n::TransliterationModulesExtra::SENTENCE_CASE)
+        {
+            // for 'sentence case' we need to iterate sentence by sentence
+
+            sal_Int32 nLastStart = _xBI->beginOfSentence( 
+                    *pNode, nEndPos, 
+                    SvxCreateLocale( GetLanguage( EditPaM( pNode, nEndPos + 1 ) ) ) );
+            sal_Int32 nLastEnd = _xBI->endOfSentence( 
+                    *pNode, nLastStart, 
+                    SvxCreateLocale( GetLanguage( EditPaM( pNode, nLastStart + 1 ) ) ) );
+            
+            // extend nCurrentStart, nCurrentEnd to the current sentence boundaries
+            nCurrentStart = _xBI->beginOfSentence( 
+                    *pNode, nStartPos, 
+                    SvxCreateLocale( GetLanguage( EditPaM( pNode, nStartPos + 1 ) ) ) );
+            nCurrentEnd = _xBI->endOfSentence( 
+                    *pNode, nCurrentStart, 
+                    SvxCreateLocale( GetLanguage( EditPaM( pNode, nCurrentStart + 1 ) ) ) );
+
+            // prevent backtracking to the previous sentence if selection starts at end of a sentence
+            if (nCurrentEnd <= nStartPos)
             {
-                bChanges = TRUE;
-                if ( nLen != aNewText.Len() )
-                    bLenChanged = TRUE;
+                // now nCurrentStart is probably located on a non-letter word. (unless we
+                // are in Asian text with no spaces...)
+                // Thus to get the real sentence start we should locate the next real word, 
+                // that is one found by DICTIONARY_WORD
+                i18n::Boundary aBndry = _xBI->nextWord( *pNode, nCurrentEnd, 
+                        SvxCreateLocale( GetLanguage( EditPaM( pNode, nCurrentEnd + 1 ) ) ), 
+                        i18n::WordType::DICTIONARY_WORD);
+
+                // now get new current sentence boundaries
+                nCurrentStart = _xBI->beginOfSentence( 
+                        *pNode, aBndry.startPos, 
+                        SvxCreateLocale( GetLanguage( EditPaM( pNode, aBndry.startPos + 1 ) ) ) );
+                nCurrentEnd = _xBI->endOfSentence( 
+                        *pNode, nCurrentStart, 
+                        SvxCreateLocale( GetLanguage( EditPaM( pNode, nCurrentStart + 1 ) ) ) );
+            }
+            // prevent advancing to the next sentence if selection ends at start of a sentence
+            if (nLastStart >= nEndPos)
+            {
+                // now nCurrentStart is probably located on a non-letter word. (unless we
+                // are in Asian text with no spaces...)
+                // Thus to get the real sentence start we should locate the previous real word, 
+                // that is one found by DICTIONARY_WORD
+                i18n::Boundary aBndry = _xBI->previousWord( *pNode, nLastStart, 
+                        SvxCreateLocale( GetLanguage( EditPaM( pNode, nLastStart + 1 ) ) ), 
+                        i18n::WordType::DICTIONARY_WORD);
+                nLastEnd = _xBI->endOfSentence( 
+                        *pNode, aBndry.startPos, 
+                        SvxCreateLocale( GetLanguage( EditPaM( pNode, aBndry.startPos + 1 ) ) ) );
+                if (nCurrentEnd > nLastEnd)
+                    nCurrentEnd = nLastEnd;
+            }
 
-#ifndef SVX_LIGHT
-                // Create UndoAction on Demand....
-                if ( !pUndo && IsUndoEnabled() && !IsInUndo() )
-                {
-                    ESelection aESel( CreateESel( aSel ) );
-                    pUndo = new EditUndoTransliteration( this, aESel, nTransliterationMode );
+            while (nCurrentStart < nLastEnd)
+            {
+                sal_Int32 nLen = nCurrentEnd - nCurrentStart;
+                DBG_ASSERT( nLen > 0, "invalid word length of 0" );
+#if OSL_DEBUG_LEVEL > 1
+                String aText( pNode->Copy( nCurrentStart, nLen ) );
+#endif
 
-                    if ( ( nStartNode == nEndNode ) && !aSel.Min().GetNode()->GetCharAttribs().HasAttrib( aSel.Min().GetIndex(), aSel.Max().GetIndex() ) )
-                        pUndo->SetText( aSel.Min().GetNode()->Copy( aSel.Min().GetIndex(), aSel.Max().GetIndex()-aSel.Min().GetIndex() ) );
-                    else
-                        pUndo->SetText( CreateBinTextObject( aSel, NULL ) );
+                Sequence< sal_Int32 > aOffsets;
+                String aNewText( aTranslitarationWrapper.transliterate( *pNode, 
+                        GetLanguage( EditPaM( pNode, nCurrentStart + 1 ) ), 
+                        nCurrentStart, nLen, &aOffsets ));
+
+                if (!pNode->Equals( aNewText, nCurrentStart, nLen ))
+                {
+                    aChgData.nStart     = nCurrentStart;
+                    aChgData.nLen       = nLen;
+                    aChgData.aSelection = EditSelection( EditPaM( pNode, nCurrentStart ), EditPaM( pNode, nCurrentEnd ) );
+                    aChgData.aNewText   = aNewText;
+                    aChgData.aOffsets   = aOffsets;
+                    aChanges.push_back( aChgData );
                 }
-#endif
 
-                // Change text without loosing the attributes
-                USHORT nCharsAfterTransliteration =
-                    sal::static_int_cast< USHORT >(aOffsets.getLength());
-                const sal_Int32* pOffsets = aOffsets.getConstArray();
-                short nDiffs = 0;
-                for ( USHORT n = 0; n < nCharsAfterTransliteration; n++ )
+                i18n::Boundary aFirstWordBndry;
+                aFirstWordBndry = _xBI->nextWord(
+                        *pNode, nCurrentEnd,
+                        SvxCreateLocale( GetLanguage( EditPaM( pNode, nCurrentEnd + 1 ) ) ),
+                        nWordType);
+                nCurrentStart = aFirstWordBndry.startPos;
+                nCurrentEnd = _xBI->endOfSentence( 
+                        *pNode, nCurrentStart, 
+                        SvxCreateLocale( GetLanguage( EditPaM( pNode, nCurrentStart + 1 ) ) ) );
+            }
+            DBG_ASSERT( nCurrentEnd >= nLastEnd, "failed to reach end of transliteration" );
+        }
+        else
+        {
+            do
+            {
+                if ( bConsiderLanguage )
                 {
-                    USHORT nCurrentPos = nCurrentStart+n;
-                    sal_Int32 nDiff = (nCurrentPos-nDiffs) - pOffsets[n];
+                    nLanguage = GetLanguage( EditPaM( pNode, nCurrentStart+1 ), &nCurrentEnd );
+                    if ( nCurrentEnd > nEndPos )
+                        nCurrentEnd = nEndPos;
+                }
 
-                    if ( !nDiff )
-                    {
-                        DBG_ASSERT( nCurrentPos < pNode->Len(), "TransliterateText - String smaller than expected!" );
-                        pNode->SetChar( nCurrentPos, aNewText.GetChar(n) );
-                    }
-                    else if ( nDiff < 0 )
-                    {
-                        // Replace first char, delete the rest...
-                        DBG_ASSERT( nCurrentPos < pNode->Len(), "TransliterateText - String smaller than expected!" );
-                        pNode->SetChar( nCurrentPos, aNewText.GetChar(n) );
+                xub_StrLen nLen = nCurrentEnd - nCurrentStart;
 
-                        DBG_ASSERT( (nCurrentPos+1) < pNode->Len(), "TransliterateText - String smaller than expected!" );
-                        GetEditDoc().RemoveChars( EditPaM( pNode, nCurrentPos+1 ), sal::static_int_cast< USHORT >(-nDiff) );
-                    }
-                    else
-                    {
-                        DBG_ASSERT( nDiff == 1, "TransliterateText - Diff other than expected! But should work..." );
-                        GetEditDoc().InsertText( EditPaM( pNode, nCurrentPos ), aNewText.GetChar(n) );
+                Sequence< sal_Int32 > aOffsets;
+                String aNewText( aTranslitarationWrapper.transliterate( *pNode, nLanguage, nCurrentStart, nLen, &aOffsets ) );
 
-                    }
-                    nDiffs = sal::static_int_cast< short >(nDiffs + nDiff);
+                if (!pNode->Equals( aNewText, nCurrentStart, nLen ))
+                {
+                    aChgData.nStart     = nCurrentStart;
+                    aChgData.nLen       = nLen;
+                    aChgData.aSelection = EditSelection( EditPaM( pNode, nCurrentStart ), EditPaM( pNode, nCurrentEnd ) );
+                    aChgData.aNewText   = aNewText;
+                    aChgData.aOffsets   = aOffsets;
+                    aChanges.push_back( aChgData );
                 }
 
-                if ( nNode == nEndNode )
-                    aNewSel.Max().GetIndex() =
-                        aNewSel.Max().GetIndex() + nDiffs;
+                nCurrentStart = nCurrentEnd;
+            } while( nCurrentEnd < nEndPos );
+        }
 
-                ParaPortion* pParaPortion = GetParaPortions()[nNode];
-                pParaPortion->MarkSelectionInvalid( nCurrentStart, std::max< USHORT >( nCurrentStart+nLen, nCurrentStart+aNewText.Len() ) );
+        if (aChanges.size() > 0)
+        {
+#ifndef SVX_LIGHT
+            // Create a single UndoAction on Demand for all the changes ...
+            if ( !pUndo && IsUndoEnabled() && !IsInUndo() )
+            {
+                // adjust selection to include all changes
+                for (size_t i = 0; i < aChanges.size(); ++i)
+                {
+                    const EditSelection &rSel = aChanges[i].aSelection;
+                    if (aSel.Min().GetNode() == rSel.Min().GetNode() &&
+                        aSel.Min().GetIndex() > rSel.Min().GetIndex())
+                        aSel.Min().SetIndex( rSel.Min().GetIndex() );
+                    if (aSel.Max().GetNode() == rSel.Max().GetNode() &&
+                        aSel.Max().GetIndex() < rSel.Max().GetIndex())
+                        aSel.Max().SetIndex( rSel.Max().GetIndex() );
+                }
+                aNewSel = aSel;
+
+                ESelection aESel( CreateESel( aSel ) );
+                pUndo = new EditUndoTransliteration( this, aESel, nTransliterationMode );
 
+                const bool bSingleNode = aSel.Min().GetNode()== aSel.Max().GetNode();
+                const bool bHasAttribs = aSel.Min().GetNode()->GetCharAttribs().HasAttrib( aSel.Min().GetIndex(), aSel.Max().GetIndex() );
+                if (bSingleNode && !bHasAttribs)
+                    pUndo->SetText( aSel.Min().GetNode()->Copy( aSel.Min().GetIndex(), aSel.Max().GetIndex()-aSel.Min().GetIndex() ) );
+                else
+                    pUndo->SetText( CreateBinTextObject( aSel, NULL ) );
             }
-            nCurrentStart = nCurrentEnd;
-        } while( nCurrentEnd < nEndPos );
+#endif
+
+            // now apply the changes from end to start to leave the offsets of the
+            // yet unchanged text parts remain the same.
+            for (size_t i = 0; i < aChanges.size(); ++i)
+            {
+                const TransliterationChgData &rData = aChanges[ aChanges.size() - 1 - i ];
+
+                bChanges = TRUE;
+                if (rData.nLen != rData.aNewText.Len())
+                    bLenChanged = TRUE;
+
+                // Change text without loosing the attributes
+                USHORT nDiffs = ReplaceTextOnly( rData.aSelection.Min().GetNode(),
+                        rData.nStart, rData.nLen, rData.aNewText, rData.aOffsets );
+
+                // adjust selection in end node to possibly changed size
+                if (aSel.Max().GetNode() == rData.aSelection.Max().GetNode())
+                    aNewSel.Max().GetIndex() = aNewSel.Max().GetIndex() + nDiffs;
+
+                USHORT nSelNode = aEditDoc.GetPos( rData.aSelection.Min().GetNode() );
+                ParaPortion* pParaPortion = GetParaPortions()[nSelNode];
+                pParaPortion->MarkSelectionInvalid( rData.nStart, 
+                        std::max< USHORT >( rData.nStart + rData.nLen, 
+                                            rData.nStart + rData.aNewText.Len() ) );
+            }
+        } // if (aChanges.size() > 0)
     }
 
 #ifndef SVX_LIGHT
@@ -2932,6 +3135,52 @@ EditSelection ImpEditEngine::TransliterateText( const EditSelection& rSelection,
     return aNewSel;
 }
 
+
+short ImpEditEngine::ReplaceTextOnly( 
+    ContentNode* pNode,
+    USHORT nCurrentStart, xub_StrLen nLen,
+    const String& rNewText,
+    const uno::Sequence< sal_Int32 >& rOffsets )
+{
+    (void)  nLen;
+
+    // Change text without loosing the attributes
+    USHORT nCharsAfterTransliteration =
+        sal::static_int_cast< USHORT >(rOffsets.getLength());
+    const sal_Int32* pOffsets = rOffsets.getConstArray();
+    short nDiffs = 0;
+    for ( USHORT n = 0; n < nCharsAfterTransliteration; n++ )
+    {
+        USHORT nCurrentPos = nCurrentStart+n;
+        sal_Int32 nDiff = (nCurrentPos-nDiffs) - pOffsets[n];
+
+        if ( !nDiff )
+        {
+            DBG_ASSERT( nCurrentPos < pNode->Len(), "TransliterateText - String smaller than expected!" );
+            pNode->SetChar( nCurrentPos, rNewText.GetChar(n) );
+        }
+        else if ( nDiff < 0 )
+        {
+            // Replace first char, delete the rest...
+            DBG_ASSERT( nCurrentPos < pNode->Len(), "TransliterateText - String smaller than expected!" );
+            pNode->SetChar( nCurrentPos, rNewText.GetChar(n) );
+
+            DBG_ASSERT( (nCurrentPos+1) < pNode->Len(), "TransliterateText - String smaller than expected!" );
+            GetEditDoc().RemoveChars( EditPaM( pNode, nCurrentPos+1 ), sal::static_int_cast< USHORT >(-nDiff) );
+        }
+        else
+        {
+            DBG_ASSERT( nDiff == 1, "TransliterateText - Diff other than expected! But should work..." );
+            GetEditDoc().InsertText( EditPaM( pNode, nCurrentPos ), rNewText.GetChar(n) );
+
+        }
+        nDiffs = sal::static_int_cast< short >(nDiffs + nDiff);
+    }
+
+    return nDiffs;
+}
+
+
 void ImpEditEngine::SetAsianCompressionMode( USHORT n )
 {
     if ( n != nAsianCompressionMode )
commit 27e066791da4927b97824eef67cca7be9c4a0f91
Author: Mikhail Voytenko <mav at openoffice.org>
Date:   Tue Aug 17 10:13:38 2010 +0200

    fwk153: #i113914# set the new storage for duplicate libraries also

diff --git a/sfx2/source/doc/objstor.cxx b/sfx2/source/doc/objstor.cxx
index ac048a2..ff3b878 100644
--- a/sfx2/source/doc/objstor.cxx
+++ b/sfx2/source/doc/objstor.cxx
@@ -1917,7 +1917,25 @@ sal_Bool SfxObjectShell::ConnectTmpStorage_Impl(
             bResult = SaveCompleted( xTmpStorage );
 
             if ( bResult )
+            {
                 pImp->pBasicManager->setStorage( xTmpStorage );
+
+                // Get rid of this workaround after issue i113914 is fixed
+                try
+                {
+                    uno::Reference< script::XStorageBasedLibraryContainer > xBasicLibraries( pImp->xBasicLibraries, uno::UNO_QUERY_THROW );
+                    xBasicLibraries->setRootStorage( xTmpStorage );
+                }
+                catch( uno::Exception& )
+                {}
+                try
+                {
+                    uno::Reference< script::XStorageBasedLibraryContainer > xDialogLibraries( pImp->xDialogLibraries, uno::UNO_QUERY_THROW );
+                    xDialogLibraries->setRootStorage( xTmpStorage );
+                }
+                catch( uno::Exception& )
+                {}
+            }
         }
         catch( uno::Exception& )
         {}
@@ -2063,6 +2081,22 @@ sal_Bool SfxObjectShell::DoSaveCompleted( SfxMedium* pNewMed )
         // TODO/LATER: may be this code will be replaced, but not sure
         // Set storage in document library containers
         pImp->pBasicManager->setStorage( xStorage );
+
+        // Get rid of this workaround after issue i113914 is fixed
+        try
+        {
+            uno::Reference< script::XStorageBasedLibraryContainer > xBasicLibraries( pImp->xBasicLibraries, uno::UNO_QUERY_THROW );
+            xBasicLibraries->setRootStorage( xStorage );
+        }
+        catch( uno::Exception& )
+        {}
+        try
+        {
+            uno::Reference< script::XStorageBasedLibraryContainer > xDialogLibraries( pImp->xDialogLibraries, uno::UNO_QUERY_THROW );
+            xDialogLibraries->setRootStorage( xStorage );
+        }
+        catch( uno::Exception& )
+        {}
     }
     else
     {
commit 68c320362696d9d9f9cb7d6ea9ad5dbc864e64c7
Author: Daniel Rentz <dr at openoffice.org>
Date:   Fri Aug 13 17:59:32 2010 +0200

    mib18: wae

diff --git a/basic/source/classes/sb.cxx b/basic/source/classes/sb.cxx
index d2857f1..f8aef3d 100755
--- a/basic/source/classes/sb.cxx
+++ b/basic/source/classes/sb.cxx
@@ -569,10 +569,10 @@ SbClassModuleObject::SbClassModuleObject( SbModule* pClassModule )
                         SbClassModuleObject* pClassModuleObj = PTR_CAST(SbClassModuleObject,pObjBase);
                         if( pClassModuleObj != NULL )
                         {
-                            SbModule* pClassModule = pClassModuleObj->getClassModule();
-                            SbClassModuleObject* pNewObj = new SbClassModuleObject( pClassModule );
+                            SbModule* pLclClassModule = pClassModuleObj->getClassModule();
+                            SbClassModuleObject* pNewObj = new SbClassModuleObject( pLclClassModule );
                             pNewObj->SetName( pProp->GetName() );
-                            pNewObj->SetParent( pClassModule->pParent );
+                            pNewObj->SetParent( pLclClassModule->pParent );
                             pNewProp->PutObject( pNewObj );
                         }
                         else if( aObjClass.EqualsIgnoreCaseAscii( "Collection" ) )
commit 5660ff9f62ff81029d74ede7784446604e7c18c0
Author: Daniel Rentz <dr at openoffice.org>
Date:   Fri Aug 13 17:51:00 2010 +0200

    mib18: wae

diff --git a/basic/source/runtime/step0.cxx b/basic/source/runtime/step0.cxx
index e0b53ba..7d1f92f 100644
--- a/basic/source/runtime/step0.cxx
+++ b/basic/source/runtime/step0.cxx
@@ -442,7 +442,7 @@ void SbiRuntime::StepSET_Impl( SbxVariableRef& refVal, SbxVariableRef& refVar, b
 
     // Check value, !object is no error for sure if, only if type is fixed
     SbxDataType eValType = refVal->GetType();
-    bool bGetValObject = false;
+//	bool bGetValObject = false;
     if( !bHandleDefaultProp && eValType != SbxOBJECT && !(eValType & SbxARRAY) && refVal->IsFixed() )
     {
         Error( SbERR_INVALID_USAGE_OBJECT );
commit ad4d380dd22ccf85b0d0b4a6276ce27a2a9fed41
Author: Philipp Lohmann [pl] <Philipp.Lohmann at Oracle.COM>
Date:   Fri Aug 13 15:57:34 2010 +0200

    ooo33gsl05: #i113810# fix on behalf of aw

diff --git a/svx/source/svdraw/svdmrkv.cxx b/svx/source/svdraw/svdmrkv.cxx
index 3d72ef2..418a549 100644
--- a/svx/source/svdraw/svdmrkv.cxx
+++ b/svx/source/svdraw/svdmrkv.cxx
@@ -1063,8 +1063,7 @@ void SdrMarkView::AddDragModeHdl(SdrDragMode eMode)
 /** handle mouse over effects for handles */
 BOOL SdrMarkView::MouseMove(const MouseEvent& rMEvt, Window* pWin)
 {
-    const ULONG nHdlCount = aHdl.GetHdlCount();
-    if( nHdlCount )
+    if(aHdl.GetHdlCount())
     {
         SdrHdl* pMouseOverHdl = 0;
         if( !rMEvt.IsLeaveWindow() && pWin )
@@ -1074,6 +1073,8 @@ BOOL SdrMarkView::MouseMove(const MouseEvent& rMEvt, Window* pWin)
         }
 
         // notify last mouse over handle that he lost the mouse
+        const ULONG nHdlCount = aHdl.GetHdlCount();
+
         for(ULONG nHdl = 0; nHdl < nHdlCount; nHdl++ )
         {
             SdrHdl* pCurrentHdl = GetHdl(nHdl);
commit aaef5c3019e8fa0b2cf6a5d57e6842a9a2138d12
Merge: bc81a57... ae170eb...
Author: Daniel Rentz <dr at openoffice.org>
Date:   Fri Aug 13 15:03:20 2010 +0200

    mib18: merge

commit ae170eb18ad3f57a6f5e1b6ab3ad5459a8ae70f0
Author: Mikhail Voytenko <mav at openoffice.org>
Date:   Fri Aug 13 14:48:18 2010 +0200

    mib18: #163278# handle the internal VBA types correctly

diff --git a/basic/source/classes/sbunoobj.cxx b/basic/source/classes/sbunoobj.cxx
index e5403c2..3a8c224 100755
--- a/basic/source/classes/sbunoobj.cxx
+++ b/basic/source/classes/sbunoobj.cxx
@@ -301,7 +301,12 @@ SbUnoObject* createOLEObject_Impl( const String& aType )
     SbUnoObject* pUnoObj = NULL;
     if( xOLEFactory.is() )
     {
-        Reference< XInterface > xOLEObject = xOLEFactory->createInstance( aType );
+        // some type names available in VBA can not be directly used in COM
+        ::rtl::OUString aOLEType = aType;
+        if ( aOLEType.equals( ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "SAXXMLReader30" ) ) ) )
+            aOLEType = ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "Msxml2.SAXXMLReader.3.0" ) );
+
+        Reference< XInterface > xOLEObject = xOLEFactory->createInstance( aOLEType );
         if( xOLEObject.is() )
         {
             Any aAny;
commit bc81a57e8f35a06f6b607fb575d5d4c54d8a3929
Merge: 43ebc93... a768f39...
Author: Daniel Rentz <dr at openoffice.org>
Date:   Fri Aug 13 13:43:38 2010 +0200

    mib18: merge

commit 284f9a97eb9bc3c5835ec409bba8e8e646d3387b
Merge: a768f39... 7883aa8...
Author: Mikhail Voytenko <mav at openoffice.org>
Date:   Fri Aug 13 13:38:18 2010 +0200

    mib18: merging

commit 7883aa8d17c9bae21b87a8d29a3c241e82dda8d2
Author: Mikhail Voytenko <mav at openoffice.org>
Date:   Fri Aug 13 13:28:45 2010 +0200

    mib18: #163225# support long strings in basic

diff --git a/basic/inc/basic/sbxvar.hxx b/basic/inc/basic/sbxvar.hxx
index 0e44b07..7988c95 100644
--- a/basic/inc/basic/sbxvar.hxx
+++ b/basic/inc/basic/sbxvar.hxx
@@ -178,7 +178,7 @@ struct SbxValues
         sal_uInt64      uInt64;
         int             nInt;
         unsigned int    nUInt;
-        String*         pString;
+        ::rtl::OUString* pOUString;
         SbxDecimal*		pDecimal;
 
         SbxBase*        pObj;
@@ -212,7 +212,7 @@ struct SbxValues
     SbxValues( double _nDouble ): nDouble( _nDouble ), eType(SbxDOUBLE) {}
     SbxValues( int _nInt ): nInt( _nInt ), eType(SbxINT) {}
     SbxValues( unsigned int _nUInt ): nUInt( _nUInt ), eType(SbxUINT) {}
-    SbxValues( const String* _pString ): pString( (String*) _pString ), eType(SbxSTRING) {}
+    SbxValues( const ::rtl::OUString* _pString ): pOUString( (::rtl::OUString*)_pString ), eType(SbxSTRING) {}
     SbxValues( SbxBase* _pObj ): pObj( _pObj ), eType(SbxOBJECT) {}
     SbxValues( sal_Unicode* _pChar ): pChar( _pChar ), eType(SbxLPSTR) {}
     SbxValues( void* _pData ): pData( _pData ), eType(SbxPOINTER) {}
@@ -237,7 +237,8 @@ class SbxValue : public SbxBase
     SbxValue* TheRealValue() const;
 protected:
     SbxValues aData; // Data
-    String    aPic;  // Picture-String
+    ::rtl::OUString aPic;  // Picture-String
+    String          aToolString;  // tool string copy
 
     virtual void Broadcast( ULONG );   	// Broadcast-Call
     virtual ~SbxValue();
@@ -303,6 +304,7 @@ public:
     UINT16 GetErr() const;
     const  String& GetString() const;
     const  String& GetCoreString() const;
+    ::rtl::OUString GetOUString() const;
     SbxDecimal* GetDecimal() const;
     SbxBase* GetObject() const;
     BOOL	 HasObject() const;
@@ -325,8 +327,8 @@ public:
     BOOL PutDate( double );
     BOOL PutBool( BOOL );
     BOOL PutErr( USHORT );
-    BOOL PutStringExt( const String& );     // with extended analysis (International, "TRUE"/"FALSE")
-    BOOL PutString( const String& );
+    BOOL PutStringExt( const ::rtl::OUString& );     // with extended analysis (International, "TRUE"/"FALSE")
+    BOOL PutString( const ::rtl::OUString& );
     BOOL PutString( const sal_Unicode* );   // Type = SbxSTRING
     BOOL PutpChar( const sal_Unicode* );    // Type = SbxLPSTR
     BOOL PutDecimal( SbxDecimal* pDecimal );
diff --git a/basic/source/classes/sbunoobj.cxx b/basic/source/classes/sbunoobj.cxx
index 4a091bf..e5403c2 100755
--- a/basic/source/classes/sbunoobj.cxx
+++ b/basic/source/classes/sbunoobj.cxx
@@ -1461,7 +1461,7 @@ Any sbxToUnoValue( SbxVariable* pVar, const Type& rType, Property* pUnoProperty
             aRetVal.setValue( &c , getCharCppuType() );
             break;
         }
-        case TypeClass_STRING:			aRetVal <<= ::rtl::OUString( pVar->GetString() ); break;
+        case TypeClass_STRING:			aRetVal <<= pVar->GetOUString(); break;
         case TypeClass_FLOAT:			aRetVal <<= pVar->GetSingle(); break;
         case TypeClass_DOUBLE:			aRetVal <<= pVar->GetDouble(); break;
         //case TypeClass_OCTET:			break;
diff --git a/basic/source/sbx/sbxbool.cxx b/basic/source/sbx/sbxbool.cxx
index 38ca84e..7551a58 100644
--- a/basic/source/sbx/sbxbool.cxx
+++ b/basic/source/sbx/sbxbool.cxx
@@ -87,21 +87,20 @@ enum SbxBOOL ImpGetBool( const SbxValues* p )
         case SbxSTRING:
         case SbxLPSTR:
             nRes = SbxFALSE;
-            if( p->pString )
+            if ( p->pOUString )
             {
-                if( p->pString->EqualsIgnoreCaseAscii( SbxRes( STRING_TRUE ) ) )
+                if( p->pOUString->equalsIgnoreAsciiCase( SbxRes( STRING_TRUE ) ) )
                     nRes = SbxTRUE;
-                else if( !p->pString->EqualsIgnoreCaseAscii( SbxRes( STRING_FALSE ) ) )
+                else if( p->pOUString->equalsIgnoreAsciiCase( SbxRes( STRING_FALSE ) ) )
                 {
                     // Jetzt kann es noch in eine Zahl konvertierbar sein
                     BOOL bError = TRUE;
                     double n;
                     SbxDataType t;
                     USHORT nLen = 0;
-                    String s( *p->pString );
-                    if( ImpScan( s, n, t, &nLen ) == SbxERR_OK )
+                    if( ImpScan( *p->pOUString, n, t, &nLen ) == SbxERR_OK )
                     {
-                        if( nLen == s.Len() )
+                        if( nLen == p->pOUString->getLength() )
                         {
                             bError = FALSE;
                             if( n != 0.0 )
@@ -202,9 +201,10 @@ void ImpPutBool( SbxValues* p, INT16 n )
         case SbxBYREF | SbxSTRING:
         case SbxSTRING:
         case SbxLPSTR:
-            if( !p->pString )
-                p->pString = new XubString;
-            *p->pString = SbxRes( n ? STRING_TRUE : STRING_FALSE );
+            if ( !p->pOUString )
+                p->pOUString = new ::rtl::OUString( SbxRes( n ? STRING_TRUE : STRING_FALSE ) );
+            else 
+                *p->pOUString = SbxRes( n ? STRING_TRUE : STRING_FALSE );
             break;
 
         case SbxOBJECT:
diff --git a/basic/source/sbx/sbxbyte.cxx b/basic/source/sbx/sbxbyte.cxx
index 12ec2fd..b70b826 100644
--- a/basic/source/sbx/sbxbyte.cxx
+++ b/basic/source/sbx/sbxbyte.cxx
@@ -165,13 +165,13 @@ start:
         case SbxBYREF | SbxSTRING:
         case SbxSTRING:
         case SbxLPSTR:
-            if( !p->pString )
+            if( !p->pOUString )
                 nRes = 0;
             else
             {
                 double d;
                 SbxDataType t;
-                if( ImpScan( *p->pString, d, t, NULL ) != SbxERR_OK )
+                if( ImpScan( *p->pOUString, d, t, NULL ) != SbxERR_OK )
                     nRes = 0;
                 else if( d > SbxMAXBYTE )
                 {
@@ -279,9 +279,9 @@ void ImpPutByte( SbxValues* p, BYTE n )
         case SbxBYREF | SbxSTRING:
         case SbxSTRING:
         case SbxLPSTR:
-            if( !p->pString )
-                p->pString = new XubString;
-            ImpCvtNum( (double) n, 0, *p->pString );
+            if( !p->pOUString )
+                p->pOUString = new ::rtl::OUString;
+            ImpCvtNum( (double) n, 0, *p->pOUString );
             break;
         case SbxOBJECT:
         {
diff --git a/basic/source/sbx/sbxchar.cxx b/basic/source/sbx/sbxchar.cxx
index 9f0bb41..ca52057 100644
--- a/basic/source/sbx/sbxchar.cxx
+++ b/basic/source/sbx/sbxchar.cxx
@@ -39,7 +39,7 @@ using namespace rtl;
 xub_Unicode ImpGetChar( const SbxValues* p )
 {
     SbxValues aTmp;
-    xub_Unicode nRes;
+    xub_Unicode nRes = 0;
 start:

... etc. - the rest is truncated


More information about the ooo-build-commit mailing list