offapi/UnoApi_offapi.mk                               |    1 
 offapi/com/sun/star/awt/tree/DefaultTreeDataModel.idl |   38 ------------------
 svtools/source/uno/treecontrolpeer.cxx                |   10 ++--
 3 files changed, 6 insertions(+), 43 deletions(-)

New commits:
commit e1244d57bd8329ccc4177399d159923d76b1e2ce
Author: Noel Power <noel.po...@suse.com>
Date:   Fri Jul 12 14:22:30 2013 +0100

    fix fdo#66586 Revert "fdo#46808, create IDL fortree::DefaultTreeDataModel"
    
    This reverts commit fcd01fba69db6de6cfc983fae65b6ba6764de0d6.
    
    Service DefaultTreeDataModel actually doens't exist ( and we can't find
    when/where it used to :-( ) The treecontrolpeer.cxx change to
    use the new service also had the undesired effect of throwing an exception
    when the UnoTreeControl model is inserted ( previously this failed silently 
)
    The net effect is the dialog control is malformed and not initialised
    correctly
    (cherry picked from commit df9f26c22a59ae2309201d2709ea5f8a0ecbf247)
    
    also partial revert of f50553593613cbefb7f197fed66498bb6556a39a on
    DefaultTreeDataModel.idl so the revert above would apply
    
    Change-Id: Id76cc12a5360f6435bd39ca86020655feba20c9f
    Reviewed-on: https://gerrit.libreoffice.org/4865
    Reviewed-by: David Tardon <dtar...@redhat.com>
    Tested-by: David Tardon <dtar...@redhat.com>
    Reviewed-on: https://gerrit.libreoffice.org/5031
    Reviewed-by: Fridrich Strba <fridr...@documentfoundation.org>
    Reviewed-by: Thorsten Behrens <tbehr...@suse.com>
    Reviewed-by: Petr Mladek <pmla...@suse.cz>
    Tested-by: Petr Mladek <pmla...@suse.cz>

diff --git a/offapi/UnoApi_offapi.mk b/offapi/UnoApi_offapi.mk
index 678b0ed..50e68bc 100644
--- a/offapi/UnoApi_offapi.mk
+++ b/offapi/UnoApi_offapi.mk
@@ -70,7 +70,6 @@ $(eval $(call 
gb_UnoApi_add_idlfiles_nohdl,offapi,offapi/com/sun/star/awt/tab,\
        UnoControlTabPageModel \
 ))
 $(eval $(call 
gb_UnoApi_add_idlfiles_nohdl,offapi,offapi/com/sun/star/awt/tree,\
-       DefaultTreeDataModel \
        MutableTreeDataModel \
        MutableTreeNode \
        TreeControl \
diff --git a/offapi/com/sun/star/awt/tree/DefaultTreeDataModel.idl 
b/offapi/com/sun/star/awt/tree/DefaultTreeDataModel.idl
deleted file mode 100644
index f8ad7b6..0000000
--- a/offapi/com/sun/star/awt/tree/DefaultTreeDataModel.idl
+++ /dev/null
@@ -1,38 +0,0 @@
-/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
-/**
- * This file is part of the LibreOffice project.
- *
- * This Source Code Form is subject to the terms of the Mozilla Public
- * License, v. 2.0. If a copy of the MPL was not distributed with this
- * file, You can obtain one at http://mozilla.org/MPL/2.0/.
- *
- * This file incorporates work covered by the following license notice:
- *
- *   Licensed to the Apache Software Foundation (ASF) under one or more
- *   contributor license agreements. See the NOTICE file distributed
- *   with this work for additional information regarding copyright
- *   ownership. The ASF licenses this file to you under the Apache
- *   License, Version 2.0 (the "License"); you may not use this file
- *   except in compliance with the License. You may obtain a copy of
- *   the License at http://www.apache.org/licenses/LICENSE-2.0 .
- */
-#ifndef __com_sun_star_awt_tree_DefaultTreeDataModel_idl__
-#define __com_sun_star_awt_tree_DefaultTreeDataModel_idl__
-
-#include <com/sun/star/awt/tree/XTreeDataModel.idl>
-
-
-module com {  module sun {  module star {  module awt { module tree {
-
-
-/**
-    @since LibreOffice 4.1
- */
-service DefaultTreeDataModel : XTreeDataModel;
-
-
-}; }; }; }; };
-
-#endif
-
-/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/svtools/source/uno/treecontrolpeer.cxx 
b/svtools/source/uno/treecontrolpeer.cxx
index a403e31..e4976a6 100644
--- a/svtools/source/uno/treecontrolpeer.cxx
+++ b/svtools/source/uno/treecontrolpeer.cxx
@@ -22,8 +22,6 @@
 #include <com/sun/star/lang/XServiceInfo.hpp>
 #include <com/sun/star/lang/DisposedException.hpp>
 #include <com/sun/star/view/SelectionType.hpp>
-#include <com/sun/star/awt/tree/DefaultTreeDataModel.hpp>
-
 #include <toolkit/helper/property.hxx>
 #include <toolkit/helper/vclunohelper.hxx>
 
@@ -1230,8 +1228,12 @@ void TreeControlPeer::onChangeDataModel( 
UnoTreeListBoxImpl& rTree, const Refere
 
     if( !xDataModel.is() )
     {
-        Reference< XComponentContext > xORB( 
::comphelper::getProcessComponentContext() );
-        mxDataModel.query( DefaultTreeDataModel::create(xORB));
+        static const OUString aSN( RTL_CONSTASCII_USTRINGPARAM( 
"com.sun.star.awt.tree.DefaultTreeDataModel" ) );
+        Reference< XMultiServiceFactory > xORB( 
::comphelper::getProcessServiceFactory() );
+        if( xORB.is() )
+        {
+            mxDataModel.query( xORB->createInstance( aSN ) );
+        }
     }
 
     mxDataModel = xDataModel;
_______________________________________________
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

Reply via email to