vbahelper.cxx (e1f63238) | vbahelper.cxx (0848378b) |
---|---|
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 --- 206 unchanged lines hidden (view full) --- 215{ 216 lclIterateDocuments( &lclEnableContainerWindows, rxModel, bEnableWindows ); 217} 218 219// ============================================================================ 220 221void registerCurrentDirectory( const uno::Reference< frame::XModel >& rxModel, const ::rtl::OUString& rPath ) 222{ | 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 --- 206 unchanged lines hidden (view full) --- 215{ 216 lclIterateDocuments( &lclEnableContainerWindows, rxModel, bEnableWindows ); 217} 218 219// ============================================================================ 220 221void registerCurrentDirectory( const uno::Reference< frame::XModel >& rxModel, const ::rtl::OUString& rPath ) 222{ |
223 if( rPath.getLength() > 0 ) | 223 if( !rPath.isEmpty() ) |
224 { 225 CurrDirPool& rPool = StaticCurrDirPool::get(); 226 ::osl::MutexGuard aGuard( rPool.maMutex ); 227 try 228 { 229 uno::Reference< frame::XModuleManager > xModuleManager( lclCreateModuleManager(), uno::UNO_SET_THROW ); 230 ::rtl::OUString aIdentifier = xModuleManager->identify( rxModel ); | 224 { 225 CurrDirPool& rPool = StaticCurrDirPool::get(); 226 ::osl::MutexGuard aGuard( rPool.maMutex ); 227 try 228 { 229 uno::Reference< frame::XModuleManager > xModuleManager( lclCreateModuleManager(), uno::UNO_SET_THROW ); 230 ::rtl::OUString aIdentifier = xModuleManager->identify( rxModel ); |
231 if( aIdentifier.getLength() > 0 ) | 231 if( !aIdentifier.isEmpty() ) |
232 rPool.maCurrDirs[ aIdentifier ] = rPath; 233 } 234 catch( uno::Exception& ) 235 { 236 } 237 } 238} 239 --- 23 unchanged lines hidden --- | 232 rPool.maCurrDirs[ aIdentifier ] = rPath; 233 } 234 catch( uno::Exception& ) 235 { 236 } 237 } 238} 239 --- 23 unchanged lines hidden --- |