templwin.cxx (5900e8ec) templwin.cxx (9807c9de)
1/**************************************************************
2 *
3 * Licensed to the Apache Software Foundation (ASF) under one
4 * or more contributor license agreements. See the NOTICE file
5 * distributed with this work for additional information
6 * regarding copyright ownership. The ASF licenses this file
7 * to you under the Apache License, Version 2.0 (the
8 * "License"); you may not use this file except in compliance

--- 51 unchanged lines hidden (view full) ---

60#include <com/sun/star/awt/XWindow.hpp>
61#include <com/sun/star/document/XDocumentProperties.hpp>
62#include <com/sun/star/beans/XPropertySet.hpp>
63#include <com/sun/star/beans/XMultiPropertySet.hpp>
64#include <com/sun/star/beans/XPropertySetInfo.hpp>
65#include <com/sun/star/io/IOException.hpp>
66#include <com/sun/star/util/DateTime.hpp>
67#include <com/sun/star/script/XTypeConverter.hpp>
1/**************************************************************
2 *
3 * Licensed to the Apache Software Foundation (ASF) under one
4 * or more contributor license agreements. See the NOTICE file
5 * distributed with this work for additional information
6 * regarding copyright ownership. The ASF licenses this file
7 * to you under the Apache License, Version 2.0 (the
8 * "License"); you may not use this file except in compliance

--- 51 unchanged lines hidden (view full) ---

60#include <com/sun/star/awt/XWindow.hpp>
61#include <com/sun/star/document/XDocumentProperties.hpp>
62#include <com/sun/star/beans/XPropertySet.hpp>
63#include <com/sun/star/beans/XMultiPropertySet.hpp>
64#include <com/sun/star/beans/XPropertySetInfo.hpp>
65#include <com/sun/star/io/IOException.hpp>
66#include <com/sun/star/util/DateTime.hpp>
67#include <com/sun/star/script/XTypeConverter.hpp>
68#include <com/sun/star/system/XSystemShellExecute.hpp>
68#include <com/sun/star/system/SystemShellExecute.hpp>
69#include <com/sun/star/system/SystemShellExecuteFlags.hpp>
70#include <unotools/localedatawrapper.hxx>
71#include <com/sun/star/container/XNameContainer.hpp>
72#include <vcl/waitobj.hxx>
73#include <comphelper/processfactory.hxx>
74#include <tools/urlobj.hxx>
75#include <tools/datetime.hxx>
76#include <vcl/svapp.hxx>

--- 1903 unchanged lines hidden (view full) ---

1980
1981IMPL_LINK ( SvtDocumentTemplateDialog, OpenLinkHdl_Impl, svt::FixedHyperlink*, EMPTYARG )
1982{
1983 ::rtl::OUString sURL( aMoreTemplatesLink.GetURL() );
1984 if ( sURL.getLength() > 0 )
1985 {
1986 try
1987 {
69#include <com/sun/star/system/SystemShellExecuteFlags.hpp>
70#include <unotools/localedatawrapper.hxx>
71#include <com/sun/star/container/XNameContainer.hpp>
72#include <vcl/waitobj.hxx>
73#include <comphelper/processfactory.hxx>
74#include <tools/urlobj.hxx>
75#include <tools/datetime.hxx>
76#include <vcl/svapp.hxx>

--- 1903 unchanged lines hidden (view full) ---

1980
1981IMPL_LINK ( SvtDocumentTemplateDialog, OpenLinkHdl_Impl, svt::FixedHyperlink*, EMPTYARG )
1982{
1983 ::rtl::OUString sURL( aMoreTemplatesLink.GetURL() );
1984 if ( sURL.getLength() > 0 )
1985 {
1986 try
1987 {
1988 uno::Reference< lang::XMultiServiceFactory > xSMGR =
1989 ::comphelper::getProcessServiceFactory();
1990 uno::Reference< com::sun::star::system::XSystemShellExecute > xSystemShell(
1988 uno::Reference< com::sun::star::system::XSystemShellExecute > xSystemShell(
1991 xSMGR->createInstance( ::rtl::OUString(
1992 RTL_CONSTASCII_USTRINGPARAM( "com.sun.star.system.SystemShellExecute" ) ) ),
1993 uno::UNO_QUERY_THROW );
1989 com::sun::star::system::SystemShellExecute::create(
1990 ::comphelper::getProcessComponentContext() ) );
1994 if ( xSystemShell.is() )
1995 xSystemShell->execute( sURL, ::rtl::OUString(), com::sun::star::system::SystemShellExecuteFlags::DEFAULTS );
1996 EndDialog( RET_CANCEL );
1997 }
1998 catch( const uno::Exception& e )
1999 {
2000 OSL_TRACE( "Caught exception: %s\n thread terminated.\n",
2001 rtl::OUStringToOString(e.Message, RTL_TEXTENCODING_UTF8).getStr());

--- 13 unchanged lines hidden ---
1991 if ( xSystemShell.is() )
1992 xSystemShell->execute( sURL, ::rtl::OUString(), com::sun::star::system::SystemShellExecuteFlags::DEFAULTS );
1993 EndDialog( RET_CANCEL );
1994 }
1995 catch( const uno::Exception& e )
1996 {
1997 OSL_TRACE( "Caught exception: %s\n thread terminated.\n",
1998 rtl::OUStringToOString(e.Message, RTL_TEXTENCODING_UTF8).getStr());

--- 13 unchanged lines hidden ---