This is an automated email from the ASF dual-hosted git repository.
mseidel pushed a commit to branch trunk
in repository https://gitbox.apache.org/repos/asf/openoffice.git
The following commit(s) were added to refs/heads/trunk by this push:
new cda0808a5e Fix typos (braodcasted, brodcast, broacast)
cda0808a5e is described below
commit cda0808a5eed5f0c7ea755e4aa67d168d6e3e2ef
Author: mseidel <[email protected]>
AuthorDate: Sun Feb 9 17:56:04 2025 +0100
Fix typos (braodcasted, brodcast, broacast)
---
.../inc/comphelper/accessibleeventnotifier.hxx | 20 +-
main/embeddedobj/source/msole/ownview.cxx | 77 +++---
main/framework/source/services/desktop.cxx | 62 ++---
main/framework/source/services/frame.cxx | 302 ++++++++++-----------
main/offapi/com/sun/star/frame/FrameAction.idl | 20 +-
main/sc/inc/document.hxx | 149 +++++-----
main/sc/source/ui/docshell/docsh3.cxx | 172 ++++++------
7 files changed, 396 insertions(+), 406 deletions(-)
diff --git a/main/comphelper/inc/comphelper/accessibleeventnotifier.hxx
b/main/comphelper/inc/comphelper/accessibleeventnotifier.hxx
index 1b67592263..d0ef80c587 100644
--- a/main/comphelper/inc/comphelper/accessibleeventnotifier.hxx
+++ b/main/comphelper/inc/comphelper/accessibleeventnotifier.hxx
@@ -1,5 +1,5 @@
/**************************************************************
- *
+ *
* 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
@@ -7,20 +7,18 @@
* 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
- *
+ *
* Unless required by applicable law or agreed to in writing,
* software distributed under the License is distributed on an
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
* KIND, either express or implied. See the License for the
* specific language governing permissions and limitations
* under the License.
- *
+ *
*************************************************************/
-
-
#ifndef COMPHELPER_ACCESSIBLE_EVENT_NOTIFIER
#define COMPHELPER_ACCESSIBLE_EVENT_NOTIFIER
@@ -59,8 +57,8 @@ namespace comphelper
~AccessibleEventNotifier( ); // never implemented
private:
- COMPHELPER_DLLPRIVATE AccessibleEventNotifier( const
AccessibleEventNotifier& ); // never implemented!
- COMPHELPER_DLLPRIVATE AccessibleEventNotifier& operator=( const
AccessibleEventNotifier& ); // never implemented!
+ COMPHELPER_DLLPRIVATE AccessibleEventNotifier( const
AccessibleEventNotifier& ); // never implemented!
+ COMPHELPER_DLLPRIVATE AccessibleEventNotifier& operator=( const
AccessibleEventNotifier& ); // never implemented!
public:
/** registers a client of this class, means a broadcaster of
AccessibleEvents
@@ -79,7 +77,7 @@ namespace comphelper
When the client is disposed, you should prefer
<member>revokeClientNotifyDisposing</member></p>
<p>Any possibly pending events for this client are
removed from the queue.</p>
-
+
@seealso revokeClientNotifyDisposing
*/
static void revokeClient( const TClientId _nClient
);
@@ -129,7 +127,7 @@ namespace comphelper
static ::com::sun::star::uno::Sequence<
::com::sun::star::uno::Reference< ::com::sun::star::uno::XInterface > >
getEventListeners( const
TClientId _nClient ) SAL_THROW( ( ) );
- /** adds an event, which is to be braodcasted, to the queue
+ /** adds an event, which is to be broadcasted, to the queue
@param _nClient
the id of the client which needs to broadcast
the event
@@ -165,3 +163,5 @@ namespace comphelper
//.........................................................................
#endif // COMPHELPER_ACCESSIBLE_EVENT_NOTIFIER
+
+/* vim: set noet sw=4 ts=4: */
diff --git a/main/embeddedobj/source/msole/ownview.cxx
b/main/embeddedobj/source/msole/ownview.cxx
index 2dc36a9d71..6f41346b10 100644
--- a/main/embeddedobj/source/msole/ownview.cxx
+++ b/main/embeddedobj/source/msole/ownview.cxx
@@ -1,5 +1,5 @@
/**************************************************************
- *
+ *
* 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
@@ -7,20 +7,18 @@
* 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
- *
+ *
* Unless required by applicable law or agreed to in writing,
* software distributed under the License is distributed on an
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
* KIND, either express or implied. See the License for the
* specific language governing permissions and limitations
* under the License.
- *
+ *
*************************************************************/
-
-
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_embeddedobj.hxx"
#include <com/sun/star/frame/XFrame.hpp>
@@ -37,7 +35,7 @@
#include <com/sun/star/util/XCloseable.hpp>
#include <com/sun/star/beans/XPropertySet.hpp>
-#ifndef _COM_SUN_STAR_DOCUMENT_XEVENTBRODCASTER_HPP_
+#ifndef _COM_SUN_STAR_DOCUMENT_XEVENTBROADCASTER_HPP_
#include <com/sun/star/document/XEventBroadcaster.hpp>
#endif
#include <com/sun/star/document/XEventListener.hpp>
@@ -49,7 +47,6 @@
#include "ownview.hxx"
-
using namespace ::com::sun::star;
using namespace ::comphelper;
@@ -121,28 +118,28 @@ sal_Bool OwnView_Impl::CreateModelFromURL( const
::rtl::OUString& aFileURL )
if ( aFileURL.getLength() )
{
try {
- uno::Reference < frame::XComponentLoader >
xDocumentLoader(
-
m_xFactory->createInstance (
+ uno::Reference < frame::XComponentLoader >
xDocumentLoader(
+
m_xFactory->createInstance (
::rtl::OUString::createFromAscii( "com.sun.star.frame.Desktop" ) ),
uno::UNO_QUERY );
if ( xDocumentLoader.is() )
{
uno::Sequence< beans::PropertyValue > aArgs(
m_aFilterName.getLength() ? 5 : 4 );
-
+
aArgs[0].Name =
::rtl::OUString::createFromAscii( "URL" );
aArgs[0].Value <<= aFileURL;
-
+
aArgs[1].Name =
::rtl::OUString::createFromAscii( "ReadOnly" );
aArgs[1].Value <<= sal_True;
-
+
aArgs[2].Name =
::rtl::OUString::createFromAscii( "InteractionHandler" );
aArgs[2].Value <<= uno::Reference<
task::XInteractionHandler >(
static_cast< ::cppu::OWeakObject* >( new DummyHandler_Impl() ), uno::UNO_QUERY
);
aArgs[3].Name =
::rtl::OUString::createFromAscii( "DontEdit" );
aArgs[3].Value <<= sal_True;
-
+
if ( m_aFilterName.getLength() )
{
aArgs[4].Name =
::rtl::OUString::createFromAscii( "FilterName" );
@@ -155,7 +152,7 @@ sal_Bool OwnView_Impl::CreateModelFromURL( const
::rtl::OUString& aFileURL )
0,
aArgs ),
uno::UNO_QUERY );
-
+
if ( xModel.is() )
{
uno::Reference<
document::XEventBroadcaster > xBroadCaster( xModel, uno::UNO_QUERY );
@@ -163,16 +160,16 @@ sal_Bool OwnView_Impl::CreateModelFromURL( const
::rtl::OUString& aFileURL )
xBroadCaster->addEventListener(
uno::Reference< document::XEventListener >(
static_cast<
::cppu::OWeakObject* >( this ),
uno::UNO_QUERY ) );
-
+
uno::Reference< util::XCloseable >
xCloseable( xModel, uno::UNO_QUERY );
if ( xCloseable.is() )
{
xCloseable->addCloseListener(
uno::Reference< util::XCloseListener >(
static_cast<
::cppu::OWeakObject* >( this ),
-
uno::UNO_QUERY
) );
-
+
uno::UNO_QUERY
) );
+
::osl::MutexGuard aGuard(
m_aMutex );
- m_xModel = xModel;
+ m_xModel = xModel;
bResult = sal_True;
}
}
@@ -203,9 +200,9 @@ sal_Bool OwnView_Impl::CreateModel( sal_Bool bUseNative )
//--------------------------------------------------------
::rtl::OUString OwnView_Impl::GetFilterNameFromExtentionAndInStream(
- const
::com::sun::star::uno::Reference< ::com::sun::star::lang::XMultiServiceFactory
>& xFactory,
- const ::rtl::OUString&
aNameWithExtention,
- const uno::Reference<
io::XInputStream >& xInputStream )
+
const ::com::sun::star::uno::Reference<
::com::sun::star::lang::XMultiServiceFactory >& xFactory,
+
const ::rtl::OUString& aNameWithExtention,
+
const uno::Reference< io::XInputStream >& xInputStream )
{
if ( !xInputStream.is() )
throw uno::RuntimeException();
@@ -317,14 +314,14 @@ sal_Bool OwnView_Impl::ReadContentsAndGenerateTempFile(
const uno::Reference< io
return sal_False;
if (
- (aReadSeq[0] >= '0' && aReadSeq[0] <= '9') ||
- (aReadSeq[0] >= 'a' && aReadSeq[0] <= 'z') ||
- (aReadSeq[0] >= 'A' && aReadSeq[0] <= 'Z') ||
- aReadSeq[0] == '.'
- )
- {
+ (aReadSeq[0] >= '0' && aReadSeq[0] <= '9') ||
+ (aReadSeq[0] >= 'a' && aReadSeq[0] <= 'z') ||
+ (aReadSeq[0] >= 'A' && aReadSeq[0] <= 'Z') ||
+ aReadSeq[0] == '.'
+ )
+ {
aFileSuffix += ::rtl::OUString::valueOf(
(sal_Unicode) aReadSeq[0] );
- }
+ }
} while( aReadSeq[0] );
@@ -337,7 +334,7 @@ sal_Bool OwnView_Impl::ReadContentsAndGenerateTempFile(
const uno::Reference< io
// check the next header
if ( xInStream->readBytes( aReadSeq, 4 ) != 4
- || aReadSeq[0] || aReadSeq[1] || aReadSeq[2] != 3 ||
aReadSeq[3] )
+ || aReadSeq[0] || aReadSeq[1] || aReadSeq[2] != 3 ||
aReadSeq[3] )
return sal_False;
// get the size of the next entry
@@ -351,7 +348,7 @@ sal_Bool OwnView_Impl::ReadContentsAndGenerateTempFile(
const uno::Reference< io
sal_Int64 nTargetPos = xSeekable->getPosition() + nUrlSize;
xSeekable->seek( nTargetPos );
-
+
// get the size of stored data
if ( xInStream->readBytes( aReadSeq, 4 ) != 4 )
return sal_False;
@@ -367,8 +364,7 @@ sal_Bool OwnView_Impl::ReadContentsAndGenerateTempFile(
const uno::Reference< io
{
sal_uInt32 nToRead = ( nDataSize - nRead > 32000 ) ?
32000 : nDataSize - nRead;
sal_uInt32 nLocalRead = xInStream->readBytes( aReadSeq,
nToRead );
-
-
+
if ( !nLocalRead )
{
bFailed = sal_True;
@@ -382,7 +378,7 @@ sal_Bool OwnView_Impl::ReadContentsAndGenerateTempFile(
const uno::Reference< io
aToWrite.realloc( nLocalRead );
xNativeOutTemp->writeBytes( aToWrite );
}
-
+
nRead += nLocalRead;
}
}
@@ -390,8 +386,8 @@ sal_Bool OwnView_Impl::ReadContentsAndGenerateTempFile(
const uno::Reference< io
{
uno::Sequence< sal_Int8 > aData( 8 );
if ( xInStream->readBytes( aData, 8 ) == 8
- && aData[0] == -1 && aData[1] == -1 && aData[2] == -1 &&
aData[3] == -1
- && ( aData[4] == 2 || aData[4] == 3 ) && aData[5] == 0 &&
aData[6] == 0 && aData[7] == 0 )
+ && aData[0] == -1 && aData[1] == -1 && aData[2] == -1
&& aData[3] == -1
+ && ( aData[4] == 2 || aData[4] == 3 ) && aData[5] == 0
&& aData[6] == 0 && aData[7] == 0 )
{
// the header has to be removed
xSeekable->seek( 40 );
@@ -404,7 +400,7 @@ sal_Bool OwnView_Impl::ReadContentsAndGenerateTempFile(
const uno::Reference< io
::comphelper::OStorageHelper::CopyInputToOutput( xInStream,
xNativeOutTemp );
}
-
+
xNativeOutTemp->closeOutput();
// The temporary native file is created, now the filter must be detected
@@ -437,7 +433,7 @@ void OwnView_Impl::CreateNative()
uno::Sequence< uno::Any > aArgs( 1 );
aArgs[0] <<= xInStream;
uno::Reference< container::XNameAccess > xNameAccess(
- m_xFactory->createInstanceWithArguments(
+ m_xFactory->createInstanceWithArguments(
::rtl::OUString::createFromAscii( "com.sun.star.embed.OLESimpleStorage" ),
aArgs ),
uno::UNO_QUERY_THROW );
@@ -461,7 +457,7 @@ void OwnView_Impl::CreateNative()
if ( MimeConfigurationHelper::ClassIDsEqual(
aPackageClassID, aStorClassID ) )
{
// the storage represents Object Package
-
+
bOk = ReadContentsAndGenerateTempFile(
xSubStream->getInputStream(), sal_True );
if ( !bOk &&
m_aNativeTempURL.getLength() )
@@ -622,7 +618,7 @@ void SAL_CALL OwnView_Impl::notifyEvent( const
document::EventObject& aEvent )
xBroadCaster->removeEventListener(
uno::Reference< document::XEventListener >(
static_cast<
::cppu::OWeakObject* >( this ),
uno::UNO_QUERY
) );
-
+
uno::Reference< util::XCloseable > xCloseable( xModel,
uno::UNO_QUERY );
if ( xCloseable.is() )
xCloseable->removeCloseListener(
uno::Reference< util::XCloseListener >(
@@ -659,3 +655,4 @@ void SAL_CALL OwnView_Impl::disposing( const
lang::EventObject& Source )
m_xModel = uno::Reference< frame::XModel >();
};
+/* vim: set noet sw=4 ts=4: */
diff --git a/main/framework/source/services/desktop.cxx
b/main/framework/source/services/desktop.cxx
index 68f1dc0141..44c3465830 100644
--- a/main/framework/source/services/desktop.cxx
+++ b/main/framework/source/services/desktop.cxx
@@ -222,7 +222,7 @@ DEFINE_INIT_SERVICE ( Desktop,
Do such things in DEFINE_INIT_SERVICE() method, which is
called automatically after your ctor!!!
b) Baseclass OBroadcastHelper is a typedef in namespace cppu!
The Microsoft compiler has some problems to handle it
right BY using namespace explicitly ::cppu::OBroadcastHelper.
- If we write it without a namespace or expand the typedef
to OBrodcastHelperVar<...> -> it will be OK!?
+ If we write it without a namespace or expand the typedef
to OBroadcastHelperVar<...> -> it will be OK!?
I don't know why! (other compiler not tested .. but it
works!)
@seealso method DEFINE_INIT_SERVICE()
@@ -268,7 +268,7 @@ Desktop::Desktop( const css::uno::Reference<
css::lang::XMultiServiceFactory >&
{
// Safe impossible cases
// We don't accept all incoming parameter.
- LOG_ASSERT2( implcp_ctor( xFactory ), "Desktop::Desktop()", "Invalid
parameter detected!")
+ LOG_ASSERT2( implcp_ctor( xFactory ), "Desktop::Desktop()", "Invalid
parameter detected!")
}
/*-************************************************************************************************************//**
@@ -284,29 +284,29 @@ Desktop::Desktop( const css::uno::Reference<
css::lang::XMultiServiceFactory >&
*//*-*************************************************************************************************************/
Desktop::~Desktop()
{
- LOG_ASSERT2( m_bIsTerminated ==sal_False,
"Desktop::~Desktop()", "Who forgot to terminate the desktop service?" )
- LOG_ASSERT2( m_aTransactionManager.getWorkingMode()!=E_CLOSE ,
"Desktop::~Desktop()", "Who forgot to dispose this service?" )
+ LOG_ASSERT2( m_bIsTerminated ==sal_False,
"Desktop::~Desktop()", "Who forgot to terminate the desktop service?" )
+ LOG_ASSERT2( m_aTransactionManager.getWorkingMode()!=E_CLOSE ,
"Desktop::~Desktop()", "Who forgot to dispose this service?" )
}
//=============================================================================
sal_Bool SAL_CALL Desktop::terminate()
- throw( css::uno::RuntimeException )
+ throw( css::uno::RuntimeException )
{
- TransactionGuard aTransaction( m_aTransactionManager, E_HARDEXCEPTIONS );
+ TransactionGuard aTransaction( m_aTransactionManager, E_HARDEXCEPTIONS
);
- SYNCHRONIZED_START
- ReadGuard aReadLock( m_aLock );
+ SYNCHRONIZED_START
+ ReadGuard aReadLock( m_aLock );
- css::uno::Reference< css::frame::XTerminateListener > xPipeTerminator
= m_xPipeTerminator;
- css::uno::Reference< css::frame::XTerminateListener > xQuickLauncher
= m_xQuickLauncher;
- css::uno::Reference< css::frame::XTerminateListener > xSWThreadManager
= m_xSWThreadManager;
- css::uno::Reference< css::frame::XTerminateListener > xSfxTerminator
= m_xSfxTerminator;
+ css::uno::Reference< css::frame::XTerminateListener >
xPipeTerminator = m_xPipeTerminator;
+ css::uno::Reference< css::frame::XTerminateListener >
xQuickLauncher = m_xQuickLauncher;
+ css::uno::Reference< css::frame::XTerminateListener >
xSWThreadManager = m_xSWThreadManager;
+ css::uno::Reference< css::frame::XTerminateListener >
xSfxTerminator = m_xSfxTerminator;
- css::lang::EventObject aEvent
( static_cast< ::cppu::OWeakObject* >(this) );
- ::sal_Bool
bAskQuickStart = !m_bSuspendQuickstartVeto
;
+ css::lang::EventObject aEvent
( static_cast< ::cppu::OWeakObject* >(this) );
+ ::sal_Bool
bAskQuickStart =
!m_bSuspendQuickstartVeto ;
- aReadLock.unlock();
- SYNCHRONIZED_END
+ aReadLock.unlock();
+ SYNCHRONIZED_END
//-------------------------------------------------------------------------------------------------------------
// Ask normal terminate listener. They could stop terminate without
closing any open document.
@@ -1512,30 +1512,30 @@ sal_Bool SAL_CALL Desktop::convertFastPropertyValue(
css::uno::Any& aCon
const css::uno::Any&
aValue ) throw( css::lang::IllegalArgumentException )
{
/* UNSAFE AREA
---------------------------------------------------------------------------------------------
*/
- // Register transaction and reject wrong calls.
- TransactionGuard aTransaction( m_aTransactionManager, E_HARDEXCEPTIONS );
+ // Register transaction and reject wrong calls.
+ TransactionGuard aTransaction( m_aTransactionManager, E_HARDEXCEPTIONS
);
// Initialize state with sal_False !!!
// (Handle can be invalid)
sal_Bool bReturn = sal_False;
- switch( nHandle )
+ switch( nHandle )
{
- case DESKTOP_PROPHANDLE_SUSPENDQUICKSTARTVETO:
+ case DESKTOP_PROPHANDLE_SUSPENDQUICKSTARTVETO:
bReturn = PropHelper::willPropertyBeChanged(
css::uno::makeAny(m_bSuspendQuickstartVeto),
aValue,
aOldValue,
aConvertedValue);
break;
- case DESKTOP_PROPHANDLE_DISPATCHRECORDERSUPPLIER :
+ case DESKTOP_PROPHANDLE_DISPATCHRECORDERSUPPLIER :
bReturn = PropHelper::willPropertyBeChanged(
css::uno::makeAny(m_xDispatchRecorderSupplier),
aValue,
aOldValue,
aConvertedValue);
break;
- case DESKTOP_PROPHANDLE_TITLE :
+ case DESKTOP_PROPHANDLE_TITLE :
bReturn = PropHelper::willPropertyBeChanged(
css::uno::makeAny(m_sTitle),
aValue,
@@ -1640,30 +1640,30 @@ void SAL_CALL Desktop::getFastPropertyValue(
css::uno::Any& aValue ,
::cppu::IPropertyArrayHelper& SAL_CALL Desktop::getInfoHelper()
{
/* UNSAFE AREA
---------------------------------------------------------------------------------------------
*/
- // Register transaction and reject wrong calls.
- TransactionGuard aTransaction( m_aTransactionManager, E_HARDEXCEPTIONS );
+ // Register transaction and reject wrong calls.
+ TransactionGuard aTransaction( m_aTransactionManager, E_HARDEXCEPTIONS
);
// Optimize this method !
// We initialize a static variable only one time. And we don't must use
a mutex at every call!
// For the first call; pInfoHelper is NULL - for the second call
pInfoHelper is different from NULL!
- static ::cppu::OPropertyArrayHelper* pInfoHelper = NULL;
+ static ::cppu::OPropertyArrayHelper* pInfoHelper = NULL;
- if( pInfoHelper == NULL )
+ if( pInfoHelper == NULL )
{
// Ready for multithreading
- ::osl::MutexGuard aGuard(
LockHelper::getGlobalLock().getShareableOslMutex() );
+ ::osl::MutexGuard aGuard(
LockHelper::getGlobalLock().getShareableOslMutex() );
// Control this pointer again, another instance can be faster
then these!
- if( pInfoHelper == NULL )
+ if( pInfoHelper == NULL )
{
// Define static member to give structure of properties
to baseclass "OPropertySetHelper".
// "impl_getStaticPropertyDescriptor" is a non exported
and static function, who will define a static propertytable.
// "sal_True" say: Table is sorted by name.
- static ::cppu::OPropertyArrayHelper aInfoHelper(
impl_getStaticPropertyDescriptor(), sal_True );
+ static ::cppu::OPropertyArrayHelper aInfoHelper(
impl_getStaticPropertyDescriptor(), sal_True );
pInfoHelper = &aInfoHelper;
}
}
- return(*pInfoHelper);
+ return(*pInfoHelper);
}
/*-************************************************************************************************************//**
@@ -1992,7 +1992,7 @@ void Desktop::impl_sendNotifyTerminationEvent()
/*-----------------------------------------------------------------------------------------------------------------
The follow methods checks the parameter for other functions. If a
parameter or his value is non valid,
- we return "sal_True". (otherwise sal_False) This mechanism is used to
throw an ASSERT!
+ we return "sal_True". (otherwise sal_False) This mechanism is used to
throw an ASSERT!
-----------------------------------------------------------------------------------------------------------------*/
#ifdef ENABLE_ASSERTIONS
diff --git a/main/framework/source/services/frame.cxx
b/main/framework/source/services/frame.cxx
index fe69ab9c0c..2927f6f4ca 100644
--- a/main/framework/source/services/frame.cxx
+++ b/main/framework/source/services/frame.cxx
@@ -19,8 +19,6 @@
*
*************************************************************/
-
-
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_framework.hxx"
@@ -260,7 +258,7 @@ DEFINE_INIT_SERVICE ( Frame,
Do such things in DEFINE_INIT_SERVICE() method, which is
called automatically after your ctor!!!
b) Baseclass OBroadcastHelper is a typedef in namespace cppu!
The Microsoft compiler has some problems to handle it
right BY using namespace explicitly ::cppu::OBroadcastHelper.
- If we write it without a namespace or expand the typedef
to OBrodcastHelperVar<...> -> it will be OK!?
+ If we write it without a namespace or expand the typedef
to OBroadcastHelperVar<...> -> it will be OK!?
I don't know why! (other compiler not tested .. but it
works!)
@seealso method DEFINE_INIT_SERVICE()
@@ -419,11 +417,11 @@ css::uno::Reference< css::frame::XFrames > SAL_CALL
Frame::getFrames() throw( cs
css::uno::Reference< css::frame::XFrame > SAL_CALL Frame::getActiveFrame()
throw( css::uno::RuntimeException )
{
/* UNSAFE AREA
---------------------------------------------------------------------------------------------
*/
- // Register transaction and reject wrong calls.
- TransactionGuard aTransaction( m_aTransactionManager, E_HARDEXCEPTIONS );
+ // Register transaction and reject wrong calls.
+ TransactionGuard aTransaction( m_aTransactionManager, E_HARDEXCEPTIONS
);
- /* SAFE AREA
-----------------------------------------------------------------------------------------------
*/
- ReadGuard aReadLock( m_aLock );
+ /* SAFE AREA
-----------------------------------------------------------------------------------------------
*/
+ ReadGuard aReadLock( m_aLock );
// Return current active frame.
// This information is available on the container.
@@ -447,27 +445,27 @@ css::uno::Reference< css::frame::XFrame > SAL_CALL
Frame::getActiveFrame() throw
void SAL_CALL Frame::setActiveFrame( const css::uno::Reference<
css::frame::XFrame >& xFrame ) throw( css::uno::RuntimeException )
{
/* UNSAFE AREA
---------------------------------------------------------------------------------------------
*/
- // Check incoming parameters.
- LOG_ASSERT2( implcp_setActiveFrame( xFrame ), "Frame::setActiveFrame()",
"Invalid parameter detected!" )
- // Look for rejected calls!
- TransactionGuard aTransaction( m_aTransactionManager, E_HARDEXCEPTIONS );
+ // Check incoming parameters.
+ LOG_ASSERT2( implcp_setActiveFrame( xFrame ),
"Frame::setActiveFrame()", "Invalid parameter detected!" )
+ // Look for rejected calls!
+ TransactionGuard aTransaction( m_aTransactionManager, E_HARDEXCEPTIONS
);
/* SAFE AREA
-----------------------------------------------------------------------------------------------
*/
- WriteGuard aWriteLock( m_aLock );
+ WriteGuard aWriteLock( m_aLock );
- // Copy necessary member for threadsafe access!
- // m_aChildFrameContainer is threadsafe himself and he live if we live!!!
- // ...and our transaction is non breakable too ...
- css::uno::Reference< css::frame::XFrame > xActiveChild =
m_aChildFrameContainer.getActive();
- EActiveState eActiveState = m_eActiveState
;
+ // Copy necessary member for threadsafe access!
+ // m_aChildFrameContainer is threadsafe himself and he live if we
live!!!
+ // ...and our transaction is non breakable too ...
+ css::uno::Reference< css::frame::XFrame > xActiveChild =
m_aChildFrameContainer.getActive();
+ EActiveState eActiveState = m_eActiveState
;
- aWriteLock.unlock();
- /* UNSAFE AREA
---------------------------------------------------------------------------------------------
*/
+ aWriteLock.unlock();
+ /* UNSAFE AREA
---------------------------------------------------------------------------------------------
*/
- // Doesn't work, if "new" active frame isn't different from current one!
- // (xFrame==NULL is allowed to UNSET it!)
- if( xActiveChild != xFrame )
- {
+ // Doesn't work, if "new" active frame isn't different from current one!
+ // (xFrame==NULL is allowed to UNSET it!)
+ if( xActiveChild != xFrame )
+ {
// ... otherwise set new and deactivate old one.
m_aChildFrameContainer.setActive( xFrame );
if (
@@ -1142,7 +1140,7 @@ void SAL_CALL Frame::activate() throw(
css::uno::RuntimeException )
// Attention: Deactivation of an active path, deactivate the whole
path ... from bottom to top!
// But we wish to deactivate founded sibling-tree only.
- // [ see deactivate() / step 4) for further informations! ]
+ // [ see deactivate() / step 4) for further information! ]
xParent->setActiveFrame( xThis );
@@ -1259,7 +1257,7 @@ void SAL_CALL Frame::deactivate() throw(
css::uno::RuntimeException )
//_____________________________________________________________________________________________________
// 4) If there is a path from here to my parent ...
- // ... I'am on the top or in the middle of deactivated subtree
and action was started here.
+ // ... I am on the top or in the middle of deactivated subtree
and action was started here.
// I must deactivate all frames from here to top, which are
members of current path.
// Stop, if THESE frame not the active frame of our parent!
if (
@@ -1277,7 +1275,7 @@ void SAL_CALL Frame::deactivate() throw(
css::uno::RuntimeException )
/*-****************************************************************************************************//**
@short returns active state
- @descr Call it to get informations about current active state
of this frame.
+ @descr Call it to get information about current active state
of this frame.
@seealso method activate()
@seealso method deactivate()
@@ -1580,14 +1578,14 @@ void SAL_CALL Frame::addFrameActionListener( const
css::uno::Reference< css::fra
{
/* UNSAFE AREA
---------------------------------------------------------------------------------------------
*/
// Check incoming parameter.
- LOG_ASSERT2( implcp_addFrameActionListener( xListener ),
"Frame::addFrameActionListener()", "Invalid parameter detected." )
- // Listener container is threadsafe by himself ... but we must look for
rejected calls!
- // Our OMenuDispatch-helper (is a member of ODispatchProvider!) is create
at startup of this frame BEFORE initialize!
- // => soft exceptions!
- TransactionGuard aTransaction( m_aTransactionManager, E_SOFTEXCEPTIONS );
+ LOG_ASSERT2( implcp_addFrameActionListener( xListener ),
"Frame::addFrameActionListener()", "Invalid parameter detected." )
+ // Listener container is threadsafe by himself ... but we must look for
rejected calls!
+ // Our OMenuDispatch-helper (is a member of ODispatchProvider!) is
create at startup of this frame BEFORE initialize!
+ // => soft exceptions!
+ TransactionGuard aTransaction( m_aTransactionManager, E_SOFTEXCEPTIONS
);
/* SAFE AREA
-----------------------------------------------------------------------------------------------
*/
- m_aListenerContainer.addInterface( ::getCppuType( (const
css::uno::Reference< css::frame::XFrameActionListener >*)NULL ), xListener );
+ m_aListenerContainer.addInterface( ::getCppuType( (const
css::uno::Reference< css::frame::XFrameActionListener >*)NULL ), xListener );
}
//*****************************************************************************************************************
@@ -1595,14 +1593,14 @@ void SAL_CALL Frame::removeFrameActionListener( const
css::uno::Reference< css::
{
/* UNSAFE AREA
---------------------------------------------------------------------------------------------
*/
// Check incoming parameter.
- LOG_ASSERT2( implcp_removeFrameActionListener( xListener ),
"Frame::removeFrameActionListener()", "Invalid parameter detected." )
+ LOG_ASSERT2( implcp_removeFrameActionListener( xListener ),
"Frame::removeFrameActionListener()", "Invalid parameter detected." )
// Listener container is threadsafe by himself ... but we must look for
rejected calls after disposing!
- // But we must work with E_SOFTEXCEPTIONS ... because sometimes we are
called from our listeners
- // during dispose! Our work mode is E_BEFORECLOSE then ... and
E_HARDEXCEPTIONS would throw a DisposedException.
- TransactionGuard aTransaction( m_aTransactionManager, E_SOFTEXCEPTIONS );
+ // But we must work with E_SOFTEXCEPTIONS ... because sometimes we are
called from our listeners
+ // during dispose! Our work mode is E_BEFORECLOSE then ... and
E_HARDEXCEPTIONS would throw a DisposedException.
+ TransactionGuard aTransaction( m_aTransactionManager, E_SOFTEXCEPTIONS
);
/* SAFE AREA
-----------------------------------------------------------------------------------------------
*/
- m_aListenerContainer.removeInterface( ::getCppuType( (const
css::uno::Reference< css::frame::XFrameActionListener >*)NULL ), xListener );
+ m_aListenerContainer.removeInterface( ::getCppuType( (const
css::uno::Reference< css::frame::XFrameActionListener >*)NULL ), xListener );
}
/*-****************************************************************************************************//**
@@ -1725,27 +1723,27 @@ void SAL_CALL Frame::close( sal_Bool bDeliverOwnerShip
) throw( css::util::Close
*//*-*****************************************************************************************************/
void SAL_CALL Frame::addCloseListener( const css::uno::Reference<
css::util::XCloseListener >& xListener ) throw (css::uno::RuntimeException)
{
- TransactionGuard aTransaction( m_aTransactionManager, E_HARDEXCEPTIONS );
- // We don't need any lock here ...
- // Container lives if we live and is threadsafe by himself.
- m_aListenerContainer.addInterface( ::getCppuType( ( const
css::uno::Reference< css::util::XCloseListener >* ) NULL ), xListener );
+ TransactionGuard aTransaction( m_aTransactionManager, E_HARDEXCEPTIONS
);
+ // We don't need any lock here ...
+ // Container lives if we live and is threadsafe by himself.
+ m_aListenerContainer.addInterface( ::getCppuType( ( const
css::uno::Reference< css::util::XCloseListener >* ) NULL ), xListener );
}
//*****************************************************************************************************************
void SAL_CALL Frame::removeCloseListener( const css::uno::Reference<
css::util::XCloseListener >& xListener ) throw (css::uno::RuntimeException)
{
- // Use soft exception mode - mostly this method is called during disposing
of this frame ...
- TransactionGuard aTransaction( m_aTransactionManager, E_SOFTEXCEPTIONS );
- // We don't need any lock here ...
- // Container lives if we live and is threadsafe by himself.
- m_aListenerContainer.removeInterface( ::getCppuType( ( const
css::uno::Reference< css::util::XCloseListener >* ) NULL ), xListener );
+ // Use soft exception mode - mostly this method is called during
disposing of this frame ...
+ TransactionGuard aTransaction( m_aTransactionManager, E_SOFTEXCEPTIONS
);
+ // We don't need any lock here ...
+ // Container lives if we live and is threadsafe by himself.
+ m_aListenerContainer.removeInterface( ::getCppuType( ( const
css::uno::Reference< css::util::XCloseListener >* ) NULL ), xListener );
}
//*****************************************************************************************************************
::rtl::OUString SAL_CALL Frame::getTitle()
- throw (css::uno::RuntimeException)
+ throw (css::uno::RuntimeException)
{
- TransactionGuard aTransaction( m_aTransactionManager, E_HARDEXCEPTIONS );
+ TransactionGuard aTransaction( m_aTransactionManager, E_HARDEXCEPTIONS
);
// SAFE ->
ReadGuard aReadLock(m_aLock);
@@ -1753,14 +1751,14 @@ void SAL_CALL Frame::removeCloseListener( const
css::uno::Reference< css::util::
aReadLock.unlock();
// <- SAFE
- return xTitle->getTitle();
+ return xTitle->getTitle();
}
//*****************************************************************************************************************
void SAL_CALL Frame::setTitle( const ::rtl::OUString& sTitle )
- throw (css::uno::RuntimeException)
+ throw (css::uno::RuntimeException)
{
- TransactionGuard aTransaction( m_aTransactionManager, E_HARDEXCEPTIONS );
+ TransactionGuard aTransaction( m_aTransactionManager, E_HARDEXCEPTIONS
);
// SAFE ->
ReadGuard aReadLock(m_aLock);
@@ -1768,14 +1766,14 @@ void SAL_CALL Frame::setTitle( const ::rtl::OUString&
sTitle )
aReadLock.unlock();
// <- SAFE
- xTitle->setTitle(sTitle);
+ xTitle->setTitle(sTitle);
}
//*****************************************************************************************************************
void SAL_CALL Frame::addTitleChangeListener( const css::uno::Reference<
css::frame::XTitleChangeListener >& xListener)
- throw (css::uno::RuntimeException)
+ throw (css::uno::RuntimeException)
{
- TransactionGuard aTransaction( m_aTransactionManager, E_HARDEXCEPTIONS );
+ TransactionGuard aTransaction( m_aTransactionManager, E_HARDEXCEPTIONS
);
// SAFE ->
ReadGuard aReadLock(m_aLock);
@@ -1783,14 +1781,14 @@ void SAL_CALL Frame::addTitleChangeListener( const
css::uno::Reference< css::fra
aReadLock.unlock();
// <- SAFE
- xTitle->addTitleChangeListener(xListener);
+ xTitle->addTitleChangeListener(xListener);
}
//*****************************************************************************************************************
void SAL_CALL Frame::removeTitleChangeListener( const css::uno::Reference<
css::frame::XTitleChangeListener >& xListener )
- throw (css::uno::RuntimeException)
+ throw (css::uno::RuntimeException)
{
- TransactionGuard aTransaction( m_aTransactionManager, E_HARDEXCEPTIONS );
+ TransactionGuard aTransaction( m_aTransactionManager, E_HARDEXCEPTIONS
);
// SAFE ->
ReadGuard aReadLock(m_aLock);
@@ -1798,7 +1796,7 @@ void SAL_CALL Frame::removeTitleChangeListener( const
css::uno::Reference< css::
aReadLock.unlock();
// <- SAFE
- xTitle->removeTitleChangeListener(xListener);
+ xTitle->removeTitleChangeListener(xListener);
}
/*-****************************************************************************************************/
@@ -1831,8 +1829,8 @@ void Frame::implts_forgetSubFrames()
// SAFE ->
WriteGuard aWriteLock(m_aLock);
- m_xFramesHelper.clear(); // clear uno reference
- m_aChildFrameContainer.clear(); // clear container content
+ m_xFramesHelper.clear(); // clear uno reference
+ m_aChildFrameContainer.clear(); // clear container content
aWriteLock.unlock();
// <- SAFE
}
@@ -1845,7 +1843,7 @@ void Frame::implts_forgetSubFrames()
Furthermore this frame is removed from its
parent frame container to release
this reference. The reference attributes are
disposed and released also.
- @attention Look for globale description at beginning of file too!
+ @attention Look for global description at beginning of file too!
(DisposedException, FairRWLock ..., initialize,
dispose)
@seealso method initialize()
@@ -1996,13 +1994,13 @@ void SAL_CALL Frame::addEventListener( const
css::uno::Reference< css::lang::XEv
{
/* UNSAFE AREA
---------------------------------------------------------------------------------------------
*/
// Check incoming parameter.
- LOG_ASSERT2( implcp_addEventListener( xListener ),
"Frame::addEventListener()", "Invalid parameter detected." )
- // Look for rejected calls only!
- // Container is threadsafe.
- TransactionGuard aTransaction( m_aTransactionManager, E_HARDEXCEPTIONS );
+ LOG_ASSERT2( implcp_addEventListener( xListener ),
"Frame::addEventListener()", "Invalid parameter detected." )
+ // Look for rejected calls only!
+ // Container is threadsafe.
+ TransactionGuard aTransaction( m_aTransactionManager, E_HARDEXCEPTIONS
);
/* SAFE AREA
-----------------------------------------------------------------------------------------------
*/
- m_aListenerContainer.addInterface( ::getCppuType( ( const
css::uno::Reference< css::lang::XEventListener >* ) NULL ), xListener );
+ m_aListenerContainer.addInterface( ::getCppuType( ( const
css::uno::Reference< css::lang::XEventListener >* ) NULL ), xListener );
}
//*****************************************************************************************************************
@@ -2010,14 +2008,14 @@ void SAL_CALL Frame::removeEventListener( const
css::uno::Reference< css::lang::
{
/* UNSAFE AREA
---------------------------------------------------------------------------------------------
*/
// Check incoming parameter.
- LOG_ASSERT2( implcp_removeEventListener( xListener ),
"Frame::removeEventListener()", "Invalid parameter detected." )
- // Look for rejected calls only!
- // Container is threadsafe.
- // Use E_SOFTEXCEPTIONS to allow removing listeners during dispose call!
- TransactionGuard aTransaction( m_aTransactionManager, E_SOFTEXCEPTIONS );
+ LOG_ASSERT2( implcp_removeEventListener( xListener ),
"Frame::removeEventListener()", "Invalid parameter detected." )
+ // Look for rejected calls only!
+ // Container is threadsafe.
+ // Use E_SOFTEXCEPTIONS to allow removing listeners during dispose call!
+ TransactionGuard aTransaction( m_aTransactionManager, E_SOFTEXCEPTIONS
);
/* SAFE AREA
-----------------------------------------------------------------------------------------------
*/
- m_aListenerContainer.removeInterface( ::getCppuType( ( const
css::uno::Reference< css::lang::XEventListener >* ) NULL ), xListener );
+ m_aListenerContainer.removeInterface( ::getCppuType( ( const
css::uno::Reference< css::lang::XEventListener >* ) NULL ), xListener );
}
/*-****************************************************************************************************//**
@@ -2074,7 +2072,7 @@ css::uno::Reference< css::task::XStatusIndicator >
SAL_CALL Frame::createStatusI
@param "aURL" , URL for loading
@param "sTargetFrameName" , name of target frame
@param "nSearchFlags" , additional flags to regulate
search if sTargetFrameName isn't clear
- @return css::uno::Reference to dispatch handler.
+ @return css::uno::Reference to dispatch handler.
@onerror A null reference is returned.
*//*-*****************************************************************************************************/
@@ -2085,8 +2083,8 @@ css::uno::Reference< css::frame::XDispatch > SAL_CALL
Frame::queryDispatch( cons
const char UNO_PROTOCOL[] = ".uno:";
// Don't check incoming parameter here! Our helper do it for us and it
isn't a good idea to do it more then ones!
- // But look for rejected calls!
- TransactionGuard aTransaction( m_aTransactionManager, E_HARDEXCEPTIONS );
+ // But look for rejected calls!
+ TransactionGuard aTransaction( m_aTransactionManager, E_HARDEXCEPTIONS
);
// Remove uno and cmd protocol part as we want to support both of them.
We store only the command part
// in our hash map. All other protocols are stored with the protocol
part.
@@ -2107,7 +2105,7 @@ css::uno::Reference< css::frame::XDispatch > SAL_CALL
Frame::queryDispatch( cons
/*-****************************************************************************************************//**
@short handle more then ones dispatches at same call
- @descr Returns a sequence of dispatches. For details see the
queryDispatch method.
+ @descr Returns a sequence of dispatches. For details see the
queryDispatch method.
For failed dispatches we return empty items in
list!
@seealso method queryDispatch()
@@ -2120,18 +2118,18 @@ css::uno::Reference< css::frame::XDispatch > SAL_CALL
Frame::queryDispatch( cons
css::uno::Sequence< css::uno::Reference< css::frame::XDispatch > > SAL_CALL
Frame::queryDispatches( const css::uno::Sequence<
css::frame::DispatchDescriptor >& lDescriptor ) throw(
css::uno::RuntimeException )
{
// Don't check incoming parameter here! Our helper do it for us and it
isn't a good idea to do it more then ones!
- // But look for rejected calls!
- TransactionGuard aTransaction( m_aTransactionManager, E_HARDEXCEPTIONS );
+ // But look for rejected calls!
+ TransactionGuard aTransaction( m_aTransactionManager, E_HARDEXCEPTIONS
);
// We use a helper to support these interface and an interceptor
mechanism.
- // Our helper is threadsafe by himself!
- return m_xDispatchHelper->queryDispatches( lDescriptor );
+ // Our helper is threadsafe by himself!
+ return m_xDispatchHelper->queryDispatches( lDescriptor );
}
/*-****************************************************************************************************//**
@short register/unregister interceptor for dispatch calls
- @descr If you whish to handle some dispatches by himself ...
you should be
- an interceptor for it. Please see class
OInterceptionHelper for further informations.
+ @descr If you wish to handle some dispatches by himself ...
you should be
+ an interceptor for it. Please see class
OInterceptionHelper for further information.
@seealso class OInterceptionHelper
@@ -2143,27 +2141,27 @@ css::uno::Sequence< css::uno::Reference<
css::frame::XDispatch > > SAL_CALL Fram
void SAL_CALL Frame::registerDispatchProviderInterceptor( const
css::uno::Reference< css::frame::XDispatchProviderInterceptor >& xInterceptor )
throw( css::uno::RuntimeException )
{
// We use a helper to support these interface and an interceptor
mechanism.
- // This helper is threadsafe himself and check incoming parameter too.
- // I think we don't need any lock here!
- // But we must look for rejected calls.
- TransactionGuard aTransaction( m_aTransactionManager, E_HARDEXCEPTIONS );
+ // This helper is threadsafe himself and check incoming parameter too.
+ // I think we don't need any lock here!
+ // But we must look for rejected calls.
+ TransactionGuard aTransaction( m_aTransactionManager, E_HARDEXCEPTIONS
);
- css::uno::Reference< css::frame::XDispatchProviderInterception >
xInterceptionHelper( m_xDispatchHelper, css::uno::UNO_QUERY );
- xInterceptionHelper->registerDispatchProviderInterceptor( xInterceptor );
+ css::uno::Reference< css::frame::XDispatchProviderInterception >
xInterceptionHelper( m_xDispatchHelper, css::uno::UNO_QUERY );
+ xInterceptionHelper->registerDispatchProviderInterceptor( xInterceptor
);
}
//*****************************************************************************************************************
void SAL_CALL Frame::releaseDispatchProviderInterceptor( const
css::uno::Reference< css::frame::XDispatchProviderInterceptor >& xInterceptor )
throw( css::uno::RuntimeException )
{
// We use a helper to support these interface and an interceptor
mechanism.
- // This helper is threadsafe himself and check incoming parameter too.
- // I think we don't need any lock here!
- // But we must look for rejected calls ...
- // Sometimes we are called during our dispose() method ... => soft
exceptions!
- TransactionGuard aTransaction( m_aTransactionManager, E_SOFTEXCEPTIONS );
+ // This helper is threadsafe himself and check incoming parameter too.
+ // I think we don't need any lock here!
+ // But we must look for rejected calls ...
+ // Sometimes we are called during our dispose() method ... => soft
exceptions!
+ TransactionGuard aTransaction( m_aTransactionManager, E_SOFTEXCEPTIONS
);
- css::uno::Reference< css::frame::XDispatchProviderInterception >
xInterceptionHelper( m_xDispatchHelper, css::uno::UNO_QUERY );
- xInterceptionHelper->releaseDispatchProviderInterceptor( xInterceptor );
+ css::uno::Reference< css::frame::XDispatchProviderInterception >
xInterceptionHelper( m_xDispatchHelper, css::uno::UNO_QUERY );
+ xInterceptionHelper->releaseDispatchProviderInterceptor( xInterceptor );
}
/*-****************************************************************************************************//**
@@ -2171,16 +2169,16 @@ void SAL_CALL
Frame::releaseDispatchProviderInterceptor( const css::uno::Referen
inside the current frame environment
*//*-*****************************************************************************************************/
css::uno::Sequence< sal_Int16 > SAL_CALL Frame::getSupportedCommandGroups()
- throw(css::uno::RuntimeException)
+ throw(css::uno::RuntimeException)
{
- return m_xDispatchInfoHelper->getSupportedCommandGroups();
+ return m_xDispatchInfoHelper->getSupportedCommandGroups();
}
//*****************************************************************************************************************
css::uno::Sequence< css::frame::DispatchInformation > SAL_CALL
Frame::getConfigurableDispatchInformation(sal_Int16 nCommandGroup)
- throw(css::uno::RuntimeException)
+ throw(css::uno::RuntimeException)
{
- return
m_xDispatchInfoHelper->getConfigurableDispatchInformation(nCommandGroup);
+ return
m_xDispatchInfoHelper->getConfigurableDispatchInformation(nCommandGroup);
}
/*-****************************************************************************************************//**
@@ -2204,15 +2202,15 @@ aEvent
{
/* UNSAFE AREA
---------------------------------------------------------------------------------------------
*/
// Check incoming parameter.
- LOG_ASSERT2( implcp_windowResized( aEvent ), "Frame::windowResized()",
"Invalid parameter detected." )
- // Look for rejected calls.
- // Part of dispose-mechanism => soft exceptions
- TransactionGuard aTransaction( m_aTransactionManager, E_SOFTEXCEPTIONS );
+ LOG_ASSERT2( implcp_windowResized( aEvent ), "Frame::windowResized()",
"Invalid parameter detected." )
+ // Look for rejected calls.
+ // Part of dispose-mechanism => soft exceptions
+ TransactionGuard aTransaction( m_aTransactionManager, E_SOFTEXCEPTIONS
);
/* SAFE AREA
-----------------------------------------------------------------------------------------------
*/
// Impl-method is threadsafe!
// If we have a current component window - we must resize it!
- implts_resizeComponentWindow();
+ implts_resizeComponentWindow();
}
//*****************************************************************************************************************
@@ -2224,22 +2222,22 @@ aEvent
{
/* UNSAFE AREA
---------------------------------------------------------------------------------------------
*/
// Check incoming parameter.
- LOG_ASSERT2( implcp_focusGained( aEvent ), "Frame::focusGained()",
"Invalid parameter detected." )
- // Look for rejected calls.
- // Part of dispose() mechanism ... => soft exceptions!
- TransactionGuard aTransaction( m_aTransactionManager, E_SOFTEXCEPTIONS );
+ LOG_ASSERT2( implcp_focusGained( aEvent ), "Frame::focusGained()",
"Invalid parameter detected." )
+ // Look for rejected calls.
+ // Part of dispose() mechanism ... => soft exceptions!
+ TransactionGuard aTransaction( m_aTransactionManager, E_SOFTEXCEPTIONS
);
/* SAFE AREA
-----------------------------------------------------------------------------------------------
*/
- ReadGuard aReadLock( m_aLock );
- // Make snapshot of member!
- css::uno::Reference< css::awt::XWindow > xComponentWindow =
m_xComponentWindow;
- aReadLock.unlock();
- /* UNSAFE AREA
---------------------------------------------------------------------------------------------
*/
+ ReadGuard aReadLock( m_aLock );
+ // Make snapshot of member!
+ css::uno::Reference< css::awt::XWindow > xComponentWindow =
m_xComponentWindow;
+ aReadLock.unlock();
+ /* UNSAFE AREA
---------------------------------------------------------------------------------------------
*/
- if( xComponentWindow.is() == sal_True )
- {
- xComponentWindow->setFocus();
- }
+ if( xComponentWindow.is() == sal_True )
+ {
+ xComponentWindow->setFocus();
+ }
}
/*-****************************************************************************************************//**
@@ -2264,9 +2262,9 @@ aEvent
{
/* UNSAFE AREA
---------------------------------------------------------------------------------------------
*/
// Check incoming parameter.
- LOG_ASSERT2( implcp_windowActivated( aEvent ), "Frame::windowActivated()",
"Invalid parameter detected." )
- // Look for rejected calls.
- TransactionGuard aTransaction( m_aTransactionManager, E_HARDEXCEPTIONS );
+ LOG_ASSERT2( implcp_windowActivated( aEvent ),
"Frame::windowActivated()", "Invalid parameter detected." )
+ // Look for rejected calls.
+ TransactionGuard aTransaction( m_aTransactionManager, E_HARDEXCEPTIONS
);
/* SAFE AREA
-----------------------------------------------------------------------------------------------
*/
ReadGuard aReadLock( m_aLock );
@@ -2357,7 +2355,7 @@ void SAL_CALL Frame::windowClosing( const
css::lang::EventObject& ) throw( css::
}
// ... and try to close it
- // But do it asynchron inside the main thread.
+ // But do it asynchronous inside the main thread.
// VCL has no fun to do such things outside his main thread :-(
// Note: The used dispatch make it asynchronous for us .-)
@@ -2445,13 +2443,13 @@ void SAL_CALL Frame::windowShown( const
css::lang::EventObject& ) throw(css::uno
void SAL_CALL Frame::windowHidden( const css::lang::EventObject& )
throw(css::uno::RuntimeException)
{
- /* SAFE { */
- ReadGuard aReadLock(m_aLock);
- m_bIsHidden = sal_True;
- aReadLock.unlock();
- /* } SAFE */
+ /* SAFE { */
+ ReadGuard aReadLock(m_aLock);
+ m_bIsHidden = sal_True;
+ aReadLock.unlock();
+ /* } SAFE */
- impl_checkMenuCloser();
+ impl_checkMenuCloser();
}
/*-****************************************************************************************************//**
@@ -2473,10 +2471,10 @@ void SAL_CALL Frame::disposing( const
css::lang::EventObject& aEvent ) throw( cs
{
/* UNSAFE AREA
---------------------------------------------------------------------------------------------
*/
// Check incoming parameter.
- LOG_ASSERT2( implcp_disposing( aEvent ), "Frame::disposing()", "Invalid
parameter detected." )
- // Look for rejected calls.
- // May be we are called during releasing our windows in our in dispose
call!? => soft exceptions
- TransactionGuard aTransaction( m_aTransactionManager, E_SOFTEXCEPTIONS );
+ LOG_ASSERT2( implcp_disposing( aEvent ), "Frame::disposing()", "Invalid
parameter detected." )
+ // Look for rejected calls.
+ // May be we are called during releasing our windows in our in dispose
call!? => soft exceptions
+ TransactionGuard aTransaction( m_aTransactionManager, E_SOFTEXCEPTIONS
);
/* SAFE AREA
-----------------------------------------------------------------------------------------------
*/
WriteGuard aWriteLock( m_aLock );
@@ -2513,16 +2511,16 @@ void SAL_CALL Frame::disposing( const
css::lang::EventObject& aEvent ) throw( cs
sal_Bool SAL_CALL Frame::isActionLocked() throw( css::uno::RuntimeException )
{
/* SAFE AREA
-----------------------------------------------------------------------------------------------
*/
- ReadGuard aReadLock( m_aLock );
- return( m_nExternalLockCount!=0);
+ ReadGuard aReadLock( m_aLock );
+ return( m_nExternalLockCount!=0);
}
//*****************************************************************************************************************
void SAL_CALL Frame::addActionLock() throw( css::uno::RuntimeException )
{
/* SAFE AREA
-----------------------------------------------------------------------------------------------
*/
- WriteGuard aWriteLock( m_aLock );
- ++m_nExternalLockCount;
+ WriteGuard aWriteLock( m_aLock );
+ ++m_nExternalLockCount;
}
//*****************************************************************************************************************
@@ -2568,7 +2566,7 @@ sal_Int16 SAL_CALL Frame::resetActionLocks() throw(
css::uno::RuntimeException )
// Attention:
// external lock count is 0 here every time ... but if
// member m_bSelfClose is set to true too .... we call our own
close()/dispose().
- // See close() for further informations
+ // See close() for further information
implts_checkSuicide();
return nCurrentLocks;
@@ -2685,7 +2683,7 @@ css::uno::Any SAL_CALL Frame::impl_getPropertyValue(const
::rtl::OUString& /*sPr
{
/* There is no need to lock any mutex here. Because we share the
solar mutex with our base class. And we said to our base class: "don't
release it on calling us" .-)
- see ctor of PropertySetHelper for further informations.
+ see ctor of PropertySetHelper for further information.
*/
/* Attention: You can use nHandle only, if you are sure that all supported
@@ -2765,30 +2763,30 @@ void Frame::impl_disposeContainerWindow(
css::uno::Reference< css::awt::XWindow
*//*-*****************************************************************************************************/
void Frame::implts_sendFrameActionEvent( const css::frame::FrameAction&
aAction )
{
- /* UNSAFE AREA
---------------------------------------------------------------------------------------------
*/
- // Sometimes used by dispose() => soft exceptions!
- TransactionGuard aTransaction( m_aTransactionManager, E_SOFTEXCEPTIONS );
+ /* UNSAFE AREA
---------------------------------------------------------------------------------------------
*/
+ // Sometimes used by dispose() => soft exceptions!
+ TransactionGuard aTransaction( m_aTransactionManager, E_SOFTEXCEPTIONS
);
// Log informations about order of events to file!
// (only activated in debug version!)
LOG_FRAMEACTIONEVENT( "Frame", m_sName, aAction )
/* SAFE AREA
-----------------------------------------------------------------------------------------------
*/
- // Send css::frame::FrameAction event to all listener.
+ // Send css::frame::FrameAction event to all listener.
// Get container for right listener.
- // FOLLOW LINES ARE THREADSAFE!!!
- // ( OInterfaceContainerHelper is synchronized with m_aListenerContainer! )
- ::cppu::OInterfaceContainerHelper* pContainer =
m_aListenerContainer.getContainer( ::getCppuType( ( const css::uno::Reference<
css::frame::XFrameActionListener >*) NULL ) );
+ // FOLLOW LINES ARE THREADSAFE!!!
+ // ( OInterfaceContainerHelper is synchronized with
m_aListenerContainer! )
+ ::cppu::OInterfaceContainerHelper* pContainer =
m_aListenerContainer.getContainer( ::getCppuType( ( const css::uno::Reference<
css::frame::XFrameActionListener >*) NULL ) );
if( pContainer != NULL )
{
// Build action event.
- css::frame::FrameActionEvent aFrameActionEvent( static_cast<
::cppu::OWeakObject* >(this), this, aAction );
+ css::frame::FrameActionEvent aFrameActionEvent( static_cast<
::cppu::OWeakObject* >(this), this, aAction );
// Get iterator for access to listener.
- ::cppu::OInterfaceIteratorHelper aIterator( *pContainer );
+ ::cppu::OInterfaceIteratorHelper aIterator( *pContainer );
// Send message to all listener.
- while( aIterator.hasMoreElements() == sal_True )
+ while( aIterator.hasMoreElements() == sal_True )
{
try
{
@@ -3031,8 +3029,8 @@ void Frame::implts_stopWindowListening()
xDropTarget->setActive( sal_False );
}
}
- }
- }
+ }
+ }
}
/*-****************************************************************************************************//**
@@ -3054,7 +3052,7 @@ void Frame::implts_checkSuicide()
{
/* SAFE */
ReadGuard aReadLock(m_aLock);
- // in case of lock==0 and safed state of previous close() request
m_bSelfClose
+ // in case of lock==0 and saved state of previous close() request
m_bSelfClose
// we must force close() again. Because we had disagreed with that before.
sal_Bool bSuicide = (m_nExternalLockCount==0 && m_bSelfClose);
m_bSelfClose = sal_False;
@@ -3204,7 +3202,7 @@ void Frame::impl_checkMenuCloser()
/*-----------------------------------------------------------------------------------------------------------------
The follow methods checks the parameter for other functions. If a
parameter or his value is non valid,
- we return "sal_True". (otherwise sal_False) This mechanism is used to
throw an ASSERT!
+ we return "sal_True". (otherwise sal_False) This mechanism is used to
throw an ASSERT!
-----------------------------------------------------------------------------------------------------------------*/
#ifdef ENABLE_ASSERTIONS
@@ -3314,3 +3312,5 @@ sal_Bool Frame::implcp_disposing( const
css::lang::EventObject& aEvent )
#endif // #ifdef ENABLE_ASSERTIONS
} // namespace framework
+
+/* vim: set noet sw=4 ts=4: */
diff --git a/main/offapi/com/sun/star/frame/FrameAction.idl
b/main/offapi/com/sun/star/frame/FrameAction.idl
index 17758a68b1..b2e3a602dd 100644
--- a/main/offapi/com/sun/star/frame/FrameAction.idl
+++ b/main/offapi/com/sun/star/frame/FrameAction.idl
@@ -1,5 +1,5 @@
/**************************************************************
- *
+ *
* 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
@@ -7,23 +7,21 @@
* 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
- *
+ *
* Unless required by applicable law or agreed to in writing,
* software distributed under the License is distributed on an
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
* KIND, either express or implied. See the License for the
* specific language governing permissions and limitations
* under the License.
- *
+ *
*************************************************************/
-
#ifndef __com_sun_star_frame_FrameAction_idl__
#define __com_sun_star_frame_FrameAction_idl__
-
//=============================================================================
module com { module sun { module star { module frame {
@@ -33,7 +31,7 @@
of the desktop
<p>
- Interest listener can get informations about loaded/realoed or unloaded
+ Interest listener can get information about loaded/reloaded or unloaded
components into a <type>Frame</type>.
</p>
@@ -73,7 +71,7 @@ published enum FrameAction
COMPONENT_DETACHING,
//-------------------------------------------------------------------------
- /** an event of this kind is broadcast whenever a component is
+ /** an event of this kind is broadcast whenever a component is
attached to a new model.
<p>
@@ -88,7 +86,7 @@ published enum FrameAction
activated
<p>
- Activations are broacast from the top component which was
+ Activations are broadcast from the top component which was
not active before, down to the inner most component.
</p>
@@ -124,7 +122,7 @@ published enum FrameAction
CONTEXT_CHANGED,
//-------------------------------------------------------------------------
- /** an event of this kind is broadcast by an active frame when it
+ /** an event of this kind is broadcast by an active frame when it
is getting UI control (tool control).
@see XFrame::activate()
@@ -132,7 +130,7 @@ published enum FrameAction
FRAME_UI_ACTIVATED,
//-------------------------------------------------------------------------
- /** an event of this kind is broadcast by an active frame when it
+ /** an event of this kind is broadcast by an active frame when it
is losing UI control (tool control).
@see XFrame::deactivate()
diff --git a/main/sc/inc/document.hxx b/main/sc/inc/document.hxx
index 27c6a516c1..a481347805 100644
--- a/main/sc/inc/document.hxx
+++ b/main/sc/inc/document.hxx
@@ -1,5 +1,5 @@
/**************************************************************
- *
+ *
* 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
@@ -7,24 +7,21 @@
* 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
- *
+ *
* Unless required by applicable law or agreed to in writing,
* software distributed under the License is distributed on an
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
* KIND, either express or implied. See the License for the
* specific language governing permissions and limitations
* under the License.
- *
+ *
*************************************************************/
-
-
#ifndef SC_DOCUMENT_HXX
#define SC_DOCUMENT_HXX
-
#include <vcl/prntypes.hxx>
#include <vcl/timer.hxx>
#include <com/sun/star/uno/Reference.hxx>
@@ -140,7 +137,7 @@ class ScLookupCache;
struct ScLookupCacheMapImpl;
class SfxUndoManager;
class ScFormulaParserPool;
-struct ScClipParam;
+struct ScClipParam;
struct ScClipRangeNameData;
class ScRowBreakIterator;
@@ -281,7 +278,7 @@ private:
ScFormulaCell* pFormulaTree;
// Berechnungsbaum Start
ScFormulaCell* pEOFormulaTree;
// Berechnungsbaum Ende, letzte Zelle
ScFormulaCell* pFormulaTrack;
// BroadcastTrack Start
- ScFormulaCell* pEOFormulaTrack;
// BrodcastTrack Ende, letzte Zelle
+ ScFormulaCell* pEOFormulaTrack;
// BroadcastTrack Ende, letzte Zelle
ScBroadcastAreaSlotMachine* pBASM;
// BroadcastAreas
ScChartListenerCollection* pChartListenerCollection;
ScStrCollection* pOtherObjects;
// non-chart OLE objects
@@ -348,17 +345,17 @@ private:
LanguageType eCtlLanguage;
// default language for complex text
CharSet eSrcSet;
// Einlesen: Quell-Zeichensatz
- /** The compiler grammar used in document storage. GRAM_PODF for ODF 1.1
- documents, GRAM_ODFF for ODF 1.2 documents. */
- formula::FormulaGrammar::Grammar eStorageGrammar;
+ /** The compiler grammar used in document storage. GRAM_PODF for ODF 1.1
+ documents, GRAM_ODFF for ODF 1.2 documents. */
+ formula::FormulaGrammar::Grammar eStorageGrammar;
- /** The compiler grammar used in ODF import after brackets had been
- stripped (which they shouldn't, but until that's fixed) by the XML
- importer. */
- formula::FormulaGrammar::Grammar eXmlImportGrammar;
+ /** The compiler grammar used in ODF import after brackets had been
+ stripped (which they shouldn't, but until that's fixed) by the
XML
+ importer. */
+ formula::FormulaGrammar::Grammar eXmlImportGrammar;
sal_uLong nFormulaCodeInTree;
// FormelRPN im Formelbaum
- sal_uLong nXMLImportedFormulaCount; // progress count
during XML import
+ sal_uLong nXMLImportedFormulaCount;
// progress count during XML import
sal_uInt16 nInterpretLevel;
// >0 wenn im Interpreter
sal_uInt16 nMacroInterpretLevel;
// >0 wenn Macro im Interpreter
sal_uInt16 nInterpreterTableOpLevel;
// >0 if in Interpreter TableOp
@@ -390,10 +387,10 @@ private:
// kein Broadcast, keine Listener aufbauen waehrend aus einem anderen
// Doc (per Filter o.ae.) inserted wird, erst bei CompileAll /
CalcAfterLoad
sal_Bool bInsertingFromOtherDoc;
- bool bLoadingMedium;
- bool bImportingXML; // special handling of formula text
- bool mbImportingMSXML;
- sal_Bool bXMLFromWrapper; // distinguish
ScXMLImportWrapper from external component
+ bool bLoadingMedium;
+ bool bImportingXML; // special handling of formula text
+ bool mbImportingMSXML;
+ sal_Bool bXMLFromWrapper; // distinguish
ScXMLImportWrapper from external component
sal_Bool bCalcingAfterLoad;
// in CalcAfterLoad TRUE
// wenn temporaer keine Listener auf/abgebaut werden sollen
sal_Bool bNoListening;
@@ -419,26 +416,26 @@ private:
sal_uInt8 nAsianCompression;
sal_uInt8 nAsianKerning;
- sal_Bool bPastingDrawFromOtherDoc;
+ sal_Bool bPastingDrawFromOtherDoc;
- sal_uInt8 nInDdeLinkUpdate; // originating DDE links
(stacked bool)
+ sal_uInt8 nInDdeLinkUpdate; // originating DDE links
(stacked bool)
sal_Bool bInUnoBroadcast;
sal_Bool bInUnoListenerCall;
- formula::FormulaGrammar::Grammar eGrammar;
+ formula::FormulaGrammar::Grammar eGrammar;
- mutable sal_Bool bStyleSheetUsageInvalid;
+ mutable sal_Bool bStyleSheetUsageInvalid;
- bool mbUndoEnabled;
- bool mbAdjustHeightEnabled;
- bool mbExecuteLinkEnabled;
- bool mbChangeReadOnlyEnabled; // allow changes in
read-only document (for API import filters)
- bool mbStreamValidLocked;
+ bool mbUndoEnabled;
+ bool mbAdjustHeightEnabled;
+ bool mbExecuteLinkEnabled;
+ bool mbChangeReadOnlyEnabled; // allow changes in
read-only document (for API import filters)
+ bool mbStreamValidLocked;
- // #118840# Have a flag to know that this ScDocument is used temporary
- bool mbIsTemporary : 1;
+ // #118840# Have a flag to know that this ScDocument is used temporary
+ bool mbIsTemporary : 1;
- sal_Int16 mnNamedRangesLockCount;
+ sal_Int16 mnNamedRangesLockCount;
String msDocAccTitle;
public:
@@ -447,8 +444,8 @@ public:
virtual void setDocAccTitle( const String& rTitle ) { msDocAccTitle =
rTitle; }
virtual const String getDocAccTitle() const { return msDocAccTitle; }
-private:
- sal_Bool bReadOnly; // MT: Really needed???
+private:
+ sal_Bool bReadOnly; // MT: Really needed???
public:
virtual void setDocReadOnly( sal_Bool b){ bReadOnly = b; }
@@ -456,7 +453,7 @@ public:
sal_Bool IsCellInChangeTrack(const ScAddress &cell,Color
*pColCellBoder);
void GetCellChangeTrackNote( const ScAddress &cell,String
&strTrackText,sal_Bool &pbLeftEdge);
SC_DLLPUBLIC sal_uLong GetCellCount() const;
// alle Zellen
- SCSIZE GetCellCount(SCTAB nTab, SCCOL nCol) const;
+ SCSIZE GetCellCount(SCTAB nTab, SCCOL nCol) const;
sal_uLong GetWeightedCount() const; //
Formeln und Edit staerker gewichtet
sal_uLong GetCodeCount() const; //
RPN-Code in Formeln
DECL_LINK( GetUserDefinedColor, sal_uInt16 * );
@@ -520,37 +517,37 @@ public:
ScDBData* GetDBAtCursor(SCCOL nCol, SCROW nRow, SCTAB
nTab,
sal_Bool bStartOnly = sal_False) const;
ScDBData* GetDBAtArea(SCTAB nTab, SCCOL nCol1, SCROW
nRow1, SCCOL nCol2, SCROW nRow2) const;
- ScDBData* GetFilterDBAtTable(SCTAB nTab) const;
+ ScDBData* GetFilterDBAtTable(SCTAB nTab) const;
SC_DLLPUBLIC ScRangeData* GetRangeAtBlock( const ScRange& rBlock,
String* pName=NULL ) const;
SC_DLLPUBLIC ScDPCollection* GetDPCollection();
ScDPObject* GetDPAtCursor(SCCOL nCol, SCROW nRow,
SCTAB nTab) const;
- ScDPObject* GetDPAtBlock( const ScRange& rBlock ) const;
- // Wang Xu Ming -- 2009-8-17
- // DataPilot Migration - Cache&&Performance
- SC_DLLPUBLIC ScDPTableDataCache* GetDPObjectCache( long nID );
- SC_DLLPUBLIC ScDPTableDataCache* GetUsedDPObjectCache ( ScRange rRange
);
- SC_DLLPUBLIC long AddDPObjectCache(
ScDPTableDataCache* pData );
- SC_DLLPUBLIC void RemoveDPObjectCache(
long nID );
- SC_DLLPUBLIC void
RemoveUnusedDPObjectCaches();
- SC_DLLPUBLIC void GetUsedDPObjectCache(
std::list<ScDPTableDataCache*>& usedlist );
- SC_DLLPUBLIC long GetNewDPObjectCacheId ();
- // End Comments
+ ScDPObject* GetDPAtBlock( const ScRange& rBlock ) const;
+ // Wang Xu Ming -- 2009-8-17
+ // DataPilot Migration - Cache&&Performance
+ SC_DLLPUBLIC ScDPTableDataCache* GetDPObjectCache( long nID );
+ SC_DLLPUBLIC ScDPTableDataCache* GetUsedDPObjectCache ( ScRange
rRange );
+ SC_DLLPUBLIC long AddDPObjectCache(
ScDPTableDataCache* pData );
+ SC_DLLPUBLIC void RemoveDPObjectCache(
long nID );
+ SC_DLLPUBLIC void
RemoveUnusedDPObjectCaches();
+ SC_DLLPUBLIC void GetUsedDPObjectCache(
std::list<ScDPTableDataCache*>& usedlist );
+ SC_DLLPUBLIC long GetNewDPObjectCacheId
();
+ // End Comments
SC_DLLPUBLIC ScChartCollection* GetChartCollection() const;
- void StopTemporaryChartLock();
+ void StopTemporaryChartLock();
void EnsureGraphicNames();
SdrObject* GetObjectAtPoint( SCTAB nTab, const Point& rPos
);
sal_Bool HasChartAtPoint( SCTAB nTab, const
Point& rPos, String* pName = NULL );
- ::com::sun::star::uno::Reference< ::com::sun::star::chart2::XChartDocument
> GetChartByName( const String& rChartName );
- SC_DLLPUBLIC void GetChartRanges( const String& rChartName,
::std::vector< ScRangeList >& rRanges, ScDocument* pSheetNameDoc );
- void SetChartRanges( const String& rChartName, const
::std::vector< ScRangeList >& rRanges );
+ ::com::sun::star::uno::Reference<
::com::sun::star::chart2::XChartDocument > GetChartByName( const String&
rChartName );
+ SC_DLLPUBLIC void GetChartRanges( const String& rChartName,
::std::vector< ScRangeList >& rRanges, ScDocument* pSheetNameDoc );
+ void SetChartRanges( const String& rChartName, const
::std::vector< ScRangeList >& rRanges );
- void UpdateChartArea( const String& rChartName,
const ScRange& rNewArea,
+ void UpdateChartArea( const String& rChartName,
const ScRange& rNewArea,
sal_Bool bColHeaders, sal_Bool bRowHeaders, sal_Bool bAdd );
void UpdateChartArea( const String& rChartName,
const
ScRangeListRef& rNewList,
@@ -574,8 +571,8 @@ public:
SC_DLLPUBLIC inline SCTAB GetTableCount() const { return
nMaxTableNumber; }
SvNumberFormatterIndexTable* GetFormatExchangeList() const { return
pFormatExchangeList; }
- SC_DLLPUBLIC ScDocProtection* GetDocProtection() const;
- SC_DLLPUBLIC void SetDocProtection(const ScDocProtection*
pProtect);
+ SC_DLLPUBLIC ScDocProtection* GetDocProtection() const;
+ SC_DLLPUBLIC void SetDocProtection(const ScDocProtection*
pProtect);
SC_DLLPUBLIC sal_Bool IsDocProtected() const;
sal_Bool IsDocEditable() const;
SC_DLLPUBLIC sal_Bool IsTabProtected( SCTAB nTab )
const;
@@ -734,7 +731,7 @@ public:
SfxBroadcaster* GetDrawBroadcaster(); // zwecks
Header-Vermeidung
void BeginDrawUndo();
sal_Bool IsDrawRecording() const;
- void EndDrawUndo();//paired with BeginDrawUndo,
clear undo object if GetUndoObj is not called.
+ void EndDrawUndo();//paired with BeginDrawUndo,
clear undo object if GetUndoObj is not called.
//Not necessary
if GetUndoObj is called, but call EndDrawUndo paired with BeginDrawUndo is
recommended
void BeginUnoRefUndo();
@@ -793,7 +790,7 @@ public:
sal_uLong nFormatIndex,
sal_Bool bForceTab = sal_False);
// return sal_True = Zahlformat
gesetzt
SC_DLLPUBLIC sal_Bool SetString(
- SCCOL nCol, SCROW nRow, SCTAB nTab, const String& rString,
+ SCCOL nCol, SCROW nRow, SCTAB nTab, const String& rString,
SvNumberFormatter* pFormatter = NULL, bool bDetectNumberFormat = true
);
SC_DLLPUBLIC void SetValue( SCCOL nCol, SCROW nRow, SCTAB nTab,
const double& rVal );
void SetError( SCCOL nCol, SCROW nRow, SCTAB nTab,
const sal_uInt16 nError);
@@ -936,13 +933,13 @@ public:
sal_Bool IsForcedFormulaPending() const { return
bForcedFormulaPending; }
// if CalcFormulaTree() is currently
running
sal_Bool IsCalculatingFormulaTree() { return
bCalculatingFormulaTree; }
-
+
sal_uInt16 GetErrCode( const ScAddress& ) const;
/** Shrink a range to only include data area.
- This is not the actually used area within the
- selection, but the bounds of the sheet's data area
+ This is not the actually used area within the
+ selection, but the bounds of the sheet's data area
instead.
@returns True if the area passed intersected the data
@@ -954,7 +951,7 @@ public:
bool ShrinkToDataArea( SCTAB nTab, SCCOL& rStartCol, SCROW&
rStartRow, SCCOL& rEndCol, SCROW& rEndRow ) const;
/** Shrink a range to only include used data area.
-
+
@param o_bShrunk
Out parameter, True if area was shrunk, false
if not.
@@ -983,10 +980,10 @@ public:
SC_DLLPUBLIC sal_Bool GetDataStart( SCTAB nTab,
SCCOL& rStartCol, SCROW& rStartRow ) const;
- /**
- * Find the maximum column position that contains printable data for the
- * specified row range. The final column position must be equal or less
- * than the initial value of rEndCol.
+ /**
+ * Find the maximum column position that contains printable data for the
+ * specified row range. The final column position must be equal or less
+ * than the initial value of rEndCol.
*/
void ExtendPrintArea( OutputDevice* pDev, SCTAB nTab,
SCCOL nStartCol, SCROW nStartRow,
@@ -1072,7 +1069,7 @@ public:
SCTAB nTab,
sal_uInt16 nDelFlag);
void DeleteAreaTab(const ScRange& rRange, sal_uInt16
nDelFlag);
- void CopyToClip(const ScClipParam& rClipParam, ScDocument*
pClipDoc,
+ void CopyToClip(const ScClipParam& rClipParam, ScDocument*
pClipDoc,
const ScMarkData* pMarks = NULL, bool bAllTabs
= false, bool bKeepScenarioFlags = false,
bool bIncludeObjects = false, bool
bCloneNoteCaptions = true);
@@ -1103,8 +1100,8 @@ public:
sal_Bool bSkipAttrForEmpty = sal_False,
const ScRangeList * pDestRanges = NULL );
- void CopyMultiRangeFromClip(const ScAddress& rDestPos, const
ScMarkData& rMark,
- sal_uInt16 nInsFlag, ScDocument*
pClipDoc,
+ void CopyMultiRangeFromClip(const ScAddress& rDestPos, const
ScMarkData& rMark,
+ sal_uInt16 nInsFlag, ScDocument*
pClipDoc,
bool bResetCut = true, bool bAsLink
= false,
bool bIncludeFiltered = true,
bool bSkipAttrForEmpty = false);
@@ -1408,10 +1405,10 @@ public:
SCROW LastNonFilteredRow(SCROW nStartRow, SCROW
nEndRow, SCTAB nTab);
SCROW CountNonFilteredRows(SCROW nStartRow, SCROW
nEndRow, SCTAB nTab);
- /**
- * Write all column row flags to table's flag data, because not all column
- * row attributes are stored in the flag data members. This is necessary
- * for ods export.
+ /**
+ * Write all column row flags to table's flag data, because not all column
+ * row attributes are stored in the flag data members. This is necessary
+ * for ODS export.
*/
void SyncColRowFlags();
@@ -1861,9 +1858,9 @@ public:
private: // CLOOK-Impl-Methoden
- /**
- * Use this class as a locale variable to merge number formatter from
- * another document, and set NULL pointer to pFormatExchangeList when
+ /**
+ * Use this class as a locale variable to merge number formatter from
+ * another document, and set NULL pointer to pFormatExchangeList when
* done.
*/
class NumFmtMergeHandler
@@ -1925,3 +1922,5 @@ inline void ScDocument::SetSortParam( ScSortParam&
rParam, SCTAB nTab )
}
#endif
+
+/* vim: set noet sw=4 ts=4: */
diff --git a/main/sc/source/ui/docshell/docsh3.cxx
b/main/sc/source/ui/docshell/docsh3.cxx
index 17d6009180..9ab33d504d 100644
--- a/main/sc/source/ui/docshell/docsh3.cxx
+++ b/main/sc/source/ui/docshell/docsh3.cxx
@@ -1,5 +1,5 @@
/**************************************************************
- *
+ *
* 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
@@ -7,25 +7,21 @@
* 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
- *
+ *
* Unless required by applicable law or agreed to in writing,
* software distributed under the License is distributed on an
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
* KIND, either express or implied. See the License for the
* specific language governing permissions and limitations
* under the License.
- *
+ *
*************************************************************/
-
-
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_sc.hxx"
-
-
// INCLUDE ---------------------------------------------------------------
#include <com/sun/star/document/XDocumentPropertiesSupplier.hpp>
@@ -79,19 +75,17 @@
#include <stdio.h>
#endif // DEBUG_CHANGETRACK
-
//------------------------------------------------------------------
//
// Redraw - Benachrichtigungen
//
-
void ScDocShell::PostEditView( ScEditEngineDefaulter* pEditEngine, const
ScAddress& rCursorPos )
{
// Broadcast( ScEditViewHint( pEditEngine, rCursorPos ) );
- // Test: nur aktive ViewShell
+ // Test: nur aktive ViewShell
ScTabViewShell* pViewSh = ScTabViewShell::GetActiveViewShell();
if (pViewSh && pViewSh->GetViewData()->GetDocShell() == this)
@@ -106,7 +100,7 @@ void ScDocShell::PostDataChanged()
Broadcast( SfxSimpleHint( FID_DATACHANGED ) );
aDocument.ResetChanged( ScRange(0,0,0,MAXCOL,MAXROW,MAXTAB) );
- SFX_APP()->Broadcast(SfxSimpleHint( FID_ANYDATACHANGED ));
// Navigator
+ SFX_APP()->Broadcast(SfxSimpleHint( FID_ANYDATACHANGED )); // Navigator
//! Navigator direkt benachrichtigen!
}
@@ -121,7 +115,7 @@ void ScDocShell::PostPaint( SCCOL nStartCol, SCROW
nStartRow, SCTAB nStartTab,
if ( pPaintLockData )
{
- // #i54081# PAINT_EXTRAS still has to be brodcast because it changes
the
+ // #i54081# PAINT_EXTRAS still has to be broadcast because it changes
the
// current sheet if it's invalid. All other flags added to
pPaintLockData.
sal_uInt16 nLockPart = nPart & ~PAINT_EXTRAS;
if ( nLockPart )
@@ -422,7 +416,7 @@ double ScDocShell::GetOutputFactor() const
void ScDocShell::InitOptions(bool bForLoading) // called from InitNew and
Load
{
- // Einstellungen aus dem SpellCheckCfg kommen in Doc- und
ViewOptions
+ // Einstellungen aus dem SpellCheckCfg kommen in Doc- und ViewOptions
sal_uInt16 nDefLang, nCjkLang, nCtlLang;
sal_Bool bAutoSpell;
@@ -675,9 +669,9 @@ void ScDocShell::ExecuteChangeCommentDialog(
ScChangeAction* pAction, Window* pP
String aAuthor = pAction->GetUser();
DateTime aDT = pAction->GetDateTime();
- String aDate = ScGlobal::pLocaleData->getDate( aDT );
+ String aDate = ScGlobal::pLocaleData->getDate( aDT );
aDate += ' ';
- aDate += ScGlobal::pLocaleData->getTime( aDT, sal_False, sal_False );
+ aDate += ScGlobal::pLocaleData->getTime( aDT, sal_False, sal_False );
SfxItemSet aSet( GetPool(),
SID_ATTR_POSTIT_AUTHOR,
SID_ATTR_POSTIT_AUTHOR,
@@ -768,33 +762,33 @@ void ScDocShell::CompareDocument( ScDocument& rOtherDoc )
inline sal_Bool lcl_Equal( const ScChangeAction* pA, const ScChangeAction* pB,
sal_Bool bIgnore100Sec )
{
return pA && pB &&
- pA->GetActionNumber() == pB->GetActionNumber() &&
- pA->GetType() == pB->GetType() &&
- pA->GetUser() == pB->GetUser() &&
- (bIgnore100Sec ?
- pA->GetDateTimeUTC().IsEqualIgnore100Sec( pB->GetDateTimeUTC() ) :
- pA->GetDateTimeUTC() == pB->GetDateTimeUTC());
+ pA->GetActionNumber() == pB->GetActionNumber() &&
+ pA->GetType() == pB->GetType() &&
+ pA->GetUser() == pB->GetUser() &&
+ (bIgnore100Sec ?
+ pA->GetDateTimeUTC().IsEqualIgnore100Sec( pB->GetDateTimeUTC()
) :
+ pA->GetDateTimeUTC() == pB->GetDateTimeUTC());
// State nicht vergleichen, falls eine alte Aenderung akzeptiert
wurde
}
bool lcl_FindAction( ScDocument* pDoc, const ScChangeAction* pAction,
ScDocument* pSearchDoc, const ScChangeAction* pFirstSearchAction, const
ScChangeAction* pLastSearchAction, sal_Bool bIgnore100Sec )
{
- if ( !pDoc || !pAction || !pSearchDoc || !pFirstSearchAction ||
!pLastSearchAction )
- {
- return false;
- }
+ if ( !pDoc || !pAction || !pSearchDoc || !pFirstSearchAction ||
!pLastSearchAction )
+ {
+ return false;
+ }
- sal_uLong nLastSearchAction = pLastSearchAction->GetActionNumber();
- const ScChangeAction* pA = pFirstSearchAction;
- while ( pA && pA->GetActionNumber() <= nLastSearchAction )
- {
- if ( pAction->GetType() == pA->GetType() &&
+ sal_uLong nLastSearchAction = pLastSearchAction->GetActionNumber();
+ const ScChangeAction* pA = pFirstSearchAction;
+ while ( pA && pA->GetActionNumber() <= nLastSearchAction )
+ {
+ if ( pAction->GetType() == pA->GetType() &&
pAction->GetUser() == pA->GetUser() &&
(bIgnore100Sec ?
pAction->GetDateTimeUTC().IsEqualIgnore100Sec(
pA->GetDateTimeUTC() ) :
pAction->GetDateTimeUTC() == pA->GetDateTimeUTC() ) &&
pAction->GetBigRange() == pA->GetBigRange() )
- {
+ {
String aActionDesc;
pAction->GetDescription( aActionDesc, pDoc, sal_True );
String aADesc;
@@ -804,16 +798,16 @@ bool lcl_FindAction( ScDocument* pDoc, const
ScChangeAction* pAction, ScDocument
DBG_ERROR( "lcl_FindAction(): found equal action!" );
return true;
}
- }
- pA = pA->GetNext();
- }
+ }
+ pA = pA->GetNext();
+ }
- return false;
+ return false;
}
void ScDocShell::MergeDocument( ScDocument& rOtherDoc, bool bShared, bool
bCheckDuplicates, sal_uLong nOffset, ScChangeActionMergeMap* pMergeMap, bool
bInverseMap )
{
- ScTabViewShell* pViewSh = GetBestViewShell( sal_False ); //! Funktionen
an die DocShell
+ ScTabViewShell* pViewSh = GetBestViewShell( sal_False ); //! Funktionen
an die DocShell
if (!pViewSh)
return;
@@ -827,25 +821,25 @@ void ScDocShell::MergeDocument( ScDocument& rOtherDoc,
bool bShared, bool bCheck
aDocument.StartChangeTracking();
pThisTrack = aDocument.GetChangeTrack();
DBG_ASSERT(pThisTrack,"ChangeTracking nicht angeschaltet?");
- if ( !bShared )
- {
+ if ( !bShared )
+ {
// #51138# visuelles RedLining einschalten
ScChangeViewSettings aChangeViewSet;
aChangeViewSet.SetShowChanges(sal_True);
aDocument.SetChangeViewSettings(aChangeViewSet);
- }
+ }
}
- // #97286# include 100th seconds in compare?
- sal_Bool bIgnore100Sec = !pSourceTrack->IsTime100thSeconds() ||
+ // #97286# include 100th seconds in compare?
+ sal_Bool bIgnore100Sec = !pSourceTrack->IsTime100thSeconds() ||
!pThisTrack->IsTime100thSeconds();
// gemeinsame Ausgangsposition suchen
sal_uLong nFirstNewNumber = 0;
const ScChangeAction* pSourceAction = pSourceTrack->GetFirst();
const ScChangeAction* pThisAction = pThisTrack->GetFirst();
- // skip identical actions
- while ( lcl_Equal( pSourceAction, pThisAction, bIgnore100Sec ) )
+ // skip identical actions
+ while ( lcl_Equal( pSourceAction, pThisAction, bIgnore100Sec ) )
{
nFirstNewNumber = pSourceAction->GetActionNumber() + 1;
pSourceAction = pSourceAction->GetNext();
@@ -858,10 +852,10 @@ void ScDocShell::MergeDocument( ScDocument& rOtherDoc,
bool bShared, bool bCheck
const ScChangeAction* pFirstMergeAction = pSourceAction;
- const ScChangeAction* pFirstSearchAction = pThisAction;
+ const ScChangeAction* pFirstSearchAction = pThisAction;
- // #i94841# [Collaboration] When deleting rows is rejected, the content is
sometimes wrong
- const ScChangeAction* pLastSearchAction = pThisTrack->GetLast();
+ // #i94841# [Collaboration] When deleting rows is rejected, the content
is sometimes wrong
+ const ScChangeAction* pLastSearchAction = pThisTrack->GetLast();
// MergeChangeData aus den folgenden Aktionen erzeugen
sal_uLong nNewActionCount = 0;
@@ -882,7 +876,7 @@ void ScDocShell::MergeDocument( ScDocument& rOtherDoc, bool
bShared, bool bCheck
sal_uLong nLastMergeAction = pSourceTrack->GetLast()->GetActionNumber();
// UpdateReference-Undo, gueltige Referenzen fuer den letzten
gemeinsamen Zustand
- pSourceTrack->MergePrepare( (ScChangeAction*) pFirstMergeAction, bShared );
+ pSourceTrack->MergePrepare( (ScChangeAction*) pFirstMergeAction,
bShared );
// MergeChangeData an alle noch folgenden Aktionen in diesem
Dokument anpassen
// -> Referenzen gueltig fuer dieses Dokument
@@ -923,12 +917,12 @@ void ScDocShell::MergeDocument( ScDocument& rOtherDoc,
bool bShared, bool bCheck
{
// added to avoid warnings
}
- }
- }
+ }
+ }
pThisAction = pThisAction->GetNext();
}
- LockPaint(); // #i73877# no repainting after each action
+ LockPaint(); // #i73877# no repainting after each action
// MergeChangeData in das aktuelle Dokument uebernehmen
sal_Bool bHasRejected = sal_False;
@@ -939,9 +933,9 @@ void ScDocShell::MergeDocument( ScDocument& rOtherDoc, bool
bShared, bool bCheck
pSourceAction = pFirstMergeAction;
while ( pSourceAction && pSourceAction->GetActionNumber() <=
nLastMergeAction )
{
- bool bMergeAction = false;
- if ( bShared )
- {
+ bool bMergeAction = false;
+ if ( bShared )
+ {
if ( !bCheckDuplicates || !lcl_FindAction( &rOtherDoc,
pSourceAction, &aDocument, pFirstSearchAction, pLastSearchAction, bIgnore100Sec
) )
{
bMergeAction = true;
@@ -953,12 +947,12 @@ void ScDocShell::MergeDocument( ScDocument& rOtherDoc,
bool bShared, bool bCheck
{
bMergeAction = true;
}
- }
+ }
- if ( bMergeAction )
+ if ( bMergeAction )
{
ScChangeActionType eSourceType =
pSourceAction->GetType();
- if ( !bShared && pSourceAction->IsDeletedIn() )
+ if ( !bShared && pSourceAction->IsDeletedIn() )
{
//! muss hier noch festgestellt werden, ob
wirklich in
//! _diesem_ Dokument geloescht?
@@ -966,7 +960,7 @@ void ScDocShell::MergeDocument( ScDocument& rOtherDoc, bool
bShared, bool bCheck
// liegt in einem Bereich, der in diesem
Dokument geloescht wurde
// -> wird weggelassen
//! ??? Loesch-Aktion rueckgaengig machen
???
- //! ??? Aktion irgendwo anders speichern
???
+ //! ??? Aktion irgendwo anders speichern ???
#ifdef DBG_UTIL
String aValue;
if ( eSourceType == SC_CAT_CONTENT )
@@ -982,11 +976,11 @@ void ScDocShell::MergeDocument( ScDocument& rOtherDoc,
bool bShared, bool bCheck
pThisTrack->SetUser( pSourceAction->GetUser() );
pThisTrack->SetFixDateTimeUTC(
pSourceAction->GetDateTimeUTC() );
- sal_uLong nOldActionMax = pThisTrack->GetActionMax();
+ sal_uLong nOldActionMax =
pThisTrack->GetActionMax();
- bool bExecute = true;
+ bool bExecute = true;
sal_uLong nReject =
pSourceAction->GetRejectAction();
- if ( nReject )
+ if ( nReject )
{
if ( bShared )
{
@@ -1019,7 +1013,7 @@ void ScDocShell::MergeDocument( ScDocument& rOtherDoc,
bool bShared, bool bCheck
}
}
- if ( bExecute )
+ if ( bExecute )
{
// normal ausfuehren
ScRange aSourceRange =
pSourceAction->GetBigRange().MakeRange();
@@ -1037,7 +1031,7 @@ void ScDocShell::MergeDocument( ScDocument& rOtherDoc,
bool bShared, bool bCheck
((const
ScChangeActionContent*)pSourceAction)->GetNewString( aValue );
sal_uInt8 eMatrix =
MM_NONE;
const ScBaseCell* pCell
= ((const ScChangeActionContent*)pSourceAction)->GetNewCell();
- if ( pCell && pCell->GetCellType() ==
CELLTYPE_FORMULA )
+ if ( pCell &&
pCell->GetCellType() == CELLTYPE_FORMULA )
eMatrix =
((const ScFormulaCell*)pCell)->GetMatrixFlag();
switch ( eMatrix )
{
@@ -1133,7 +1127,7 @@ void ScDocShell::MergeDocument( ScDocument& rOtherDoc,
bool bShared, bool bCheck
if ( rComment.Len() )
{
ScChangeAction* pAct =
pThisTrack->GetLast();
- if ( pAct && pAct->GetActionNumber() > nOldActionMax )
+ if ( pAct && pAct->GetActionNumber() >
nOldActionMax )
pAct->SetComment( rComment );
#ifdef DBG_UTIL
else
@@ -1192,21 +1186,21 @@ void ScDocShell::MergeDocument( ScDocument& rOtherDoc,
bool bShared, bool bCheck
if (bHasRejected)
PostPaintGridAll(); // Reject() paintet
nicht selber
- UnlockPaint();
+ UnlockPaint();
}
bool ScDocShell::MergeSharedDocument( ScDocShell* pSharedDocShell )
{
- if ( !pSharedDocShell )
- {
- return false;
- }
+ if ( !pSharedDocShell )
+ {
+ return false;
+ }
- ScChangeTrack* pThisTrack = aDocument.GetChangeTrack();
- if ( !pThisTrack )
- {
- return false;
- }
+ ScChangeTrack* pThisTrack = aDocument.GetChangeTrack();
+ if ( !pThisTrack )
+ {
+ return false;
+ }
ScDocument& rSharedDoc = *( pSharedDocShell->GetDocument() );
ScChangeTrack* pSharedTrack = rSharedDoc.GetChangeTrack();
@@ -1382,24 +1376,26 @@ bool ScDocShell::MergeSharedDocument( ScDocShell*
pSharedDocShell )
aChangeViewSet.SetHasActionRange( true );
aChangeViewSet.SetTheActionRange( nStartShared, nEndShared );
aDocument.SetChangeViewSettings( aChangeViewSet );
- }
+ }
- // update view
- PostPaintExtras();
- PostPaintGridAll();
+ // update view
+ PostPaintExtras();
+ PostPaintGridAll();
- InfoBox aInfoBox( GetActiveDialogParent(), ScGlobal::GetRscString(
STR_DOC_UPDATED ) );
- aInfoBox.Execute();
- }
+ InfoBox aInfoBox( GetActiveDialogParent(),
ScGlobal::GetRscString( STR_DOC_UPDATED ) );
+ aInfoBox.Execute();
+ }
#if DEBUG_CHANGETRACK
- aMessage = ::rtl::OUString::createFromAscii( "\nafter merge:\n" );
- aMessage += pThisTrack->ToString();
- aMsg = ::rtl::OUStringToOString( aMessage, RTL_TEXTENCODING_UTF8 );
- OSL_ENSURE( false, aMsg.getStr() );
- //fprintf( stdout, "%s ", aMsg.getStr() );
- //fflush( stdout );
+ aMessage = ::rtl::OUString::createFromAscii( "\nafter merge:\n" );
+ aMessage += pThisTrack->ToString();
+ aMsg = ::rtl::OUStringToOString( aMessage, RTL_TEXTENCODING_UTF8 );
+ OSL_ENSURE( false, aMsg.getStr() );
+ //fprintf( stdout, "%s ", aMsg.getStr() );
+ //fflush( stdout );
#endif // DEBUG_CHANGETRACK
- return ( pThisAction != NULL );
+ return ( pThisAction != NULL );
}
+
+/* vim: set noet sw=4 ts=4: */