[Libreoffice-commits] .: sd/source

Joseph Powers jpowers at kemper.freedesktop.org
Tue Nov 16 21:22:17 PST 2010


 sd/source/ui/annotations/annotationmanager.cxx    |  234 +++++++++++-----------
 sd/source/ui/app/tbxww.cxx                        |   15 -
 sd/source/ui/controller/slidelayoutcontroller.cxx |   64 ++----
 sd/source/ui/inc/OutlineView.hxx                  |   31 +-
 sd/source/ui/slideshow/slideshowimpl.cxx          |  140 ++++++-------
 sd/source/ui/view/outlview.cxx                    |   18 -
 6 files changed, 239 insertions(+), 263 deletions(-)

New commits:
commit ec1aa5483ea1b0f785decb834bb18abc14bafd92
Author: Joseph Powers <jpowers27 at cox.net>
Date:   Tue Nov 16 19:01:00 2010 -0800

    HC Cleanup - Impress

diff --git a/sd/source/ui/annotations/annotationmanager.cxx b/sd/source/ui/annotations/annotationmanager.cxx
index 2609cde..4c8ce20 100644
--- a/sd/source/ui/annotations/annotationmanager.cxx
+++ b/sd/source/ui/annotations/annotationmanager.cxx
@@ -2,7 +2,7 @@
 /*************************************************************************
  *
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- * 
+ *
  * Copyright 2000, 2010 Oracle and/or its affiliates.
  *
  * OpenOffice.org - a multi-platform office productivity suite
@@ -152,12 +152,12 @@ static SfxDispatcher* getDispatcher( ViewShellBase& rBase )
 }
 
 com::sun::star::util::DateTime getCurrentDateTime()
-{        
+{
     TimeValue osltime;
     osl_getSystemTime( &osltime );
     oslDateTime osldt;
     osl_getDateTimeFromTimeValue( &osltime, &osldt );
-    return com::sun::star::util::DateTime( 0, osldt.Seconds, osldt.Minutes, osldt.Hours, osldt.Day, osldt.Month, osldt.Year );	    
+    return com::sun::star::util::DateTime( 0, osldt.Seconds, osldt.Minutes, osldt.Hours, osldt.Day, osldt.Month, osldt.Year );
 }
 
 OUString getAnnotationDateTimeString( const Reference< XAnnotation >& xAnnotation )
@@ -169,7 +169,7 @@ OUString getAnnotationDateTimeString( const Reference< XAnnotation >& xAnnotatio
         const LocaleDataWrapper& rLocalData = aSysLocale.GetLocaleData();
 
         com::sun::star::util::DateTime aDateTime( xAnnotation->getDateTime() );
-                
+
         Date aDate = Date( aDateTime.Day, aDateTime.Month, aDateTime.Year );
         if (aDate==Date())
             sRet = sRet + String(SdResId(STR_ANNOTATION_TODAY));
@@ -179,8 +179,8 @@ OUString getAnnotationDateTimeString( const Reference< XAnnotation >& xAnnotatio
         else
         if (aDate.IsValid() )
             sRet = sRet + rLocalData.getDate(aDate);
-            
-        Time aTime( aDateTime.Hours, aDateTime.Minutes, aDateTime.Seconds, aDateTime.HundredthSeconds );		
+
+        Time aTime( aDateTime.Hours, aDateTime.Minutes, aDateTime.Seconds, aDateTime.HundredthSeconds );
         if(aTime.GetTime() != 0)
             sRet = sRet + rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(" "))  + rLocalData.getTime( aTime,false );
     }
@@ -198,7 +198,7 @@ AnnotationManagerImpl::AnnotationManagerImpl( ViewShellBase& rViewShellBase )
 {
     SdOptions* pOptions = SD_MOD()->GetSdOptions(mpDoc->GetDocumentType());
     if( pOptions )
-        mbShowAnnotations = pOptions->IsShowComments() == TRUE;	
+        mbShowAnnotations = pOptions->IsShowComments() == TRUE;
 }
 
 // --------------------------------------------------------------------
@@ -208,7 +208,7 @@ void AnnotationManagerImpl::init()
     // get current controller and initialize listeners
     try
     {
-        addListener();	
+        addListener();
         mxView = Reference< XDrawView >::query(mrBase.GetController());
     }
     catch( Exception& e )
@@ -225,7 +225,7 @@ void AnnotationManagerImpl::init()
     }
     catch( Exception& )
     {
-    }    
+    }
 }
 
 // --------------------------------------------------------------------
@@ -241,7 +241,7 @@ void SAL_CALL AnnotationManagerImpl::disposing ()
     }
     catch( Exception& )
     {
-    }    
+    }
 
     removeListener();
     DisposeTags();
@@ -257,7 +257,7 @@ void SAL_CALL AnnotationManagerImpl::disposing ()
 }
 
 // --------------------------------------------------------------------
-    
+
 // XEventListener
 void SAL_CALL AnnotationManagerImpl::notifyEvent( const ::com::sun::star::document::EventObject& aEvent ) throw (::com::sun::star::uno::RuntimeException)
 {
@@ -282,9 +282,9 @@ void AnnotationManagerImpl::ShowAnnotations( bool bShow )
 
         SdOptions* pOptions = SD_MOD()->GetSdOptions(mpDoc->GetDocumentType());
            if( pOptions )
-            pOptions->SetShowComments( mbShowAnnotations ? sal_True : sal_False );	
-            
-        UpdateTags();	        
+            pOptions->SetShowComments( mbShowAnnotations ? sal_True : sal_False );
+
+        UpdateTags();
     }
 }
 
@@ -305,7 +305,7 @@ void AnnotationManagerImpl::ExecuteAnnotation(SfxRequest& rReq )
     case SID_PREVIOUS_POSTIT:
     case SID_NEXT_POSTIT:
         SelectNextAnnotation( rReq.GetSlot() == SID_NEXT_POSTIT );
-        break;    
+        break;
     case SID_REPLYTO_POSTIT:
         ExecuteReplyToAnnotation( rReq );
         break;
@@ -320,7 +320,7 @@ void AnnotationManagerImpl::ExecuteAnnotation(SfxRequest& rReq )
 void AnnotationManagerImpl::ExecuteInsertAnnotation(SfxRequest& /*rReq*/)
 {
     ShowAnnotations(true);
-    InsertAnnotation();    
+    InsertAnnotation();
 }
 
 // --------------------------------------------------------------------
@@ -330,7 +330,7 @@ void AnnotationManagerImpl::ExecuteDeleteAnnotation(SfxRequest& rReq)
     ShowAnnotations( true );
 
     const SfxItemSet* pArgs = rReq.GetArgs();
-    
+
     switch( rReq.GetSlot() )
     {
     case SID_DELETEALL_POSTIT:
@@ -347,12 +347,12 @@ void AnnotationManagerImpl::ExecuteDeleteAnnotation(SfxRequest& rReq)
             }
         }
         break;
-    case SID_DELETE_POSTIT:        
-        {   
+    case SID_DELETE_POSTIT:
+        {
             Reference< XAnnotation > xAnnotation;
 
             if( rReq.GetSlot() == SID_DELETE_POSTIT )
-            {        
+            {
                 if( pArgs )
                 {
                     const SfxPoolItem*  pPoolItem = NULL;
@@ -360,10 +360,10 @@ void AnnotationManagerImpl::ExecuteDeleteAnnotation(SfxRequest& rReq)
                         ( ( const SfxUnoAnyItem* ) pPoolItem )->GetValue() >>= xAnnotation;
                 }
             }
-            
-            if( !xAnnotation.is() )        
+
+            if( !xAnnotation.is() )
                 GetSelectedAnnotation( xAnnotation );
-           
+
             DeleteAnnotation( xAnnotation );
         }
         break;
@@ -381,23 +381,23 @@ void AnnotationManagerImpl::InsertAnnotation()
     {
         if( mpDoc->IsUndoEnabled() )
             mpDoc->BegUndo( String( SdResId( STR_ANNOTATION_UNDO_INSERT ) ) );
-    
+
         // find free space for new annotation
         int y = 0, x = 0;
-        
+
            AnnotationVector aAnnotations( pPage->getAnnotations() );
            if( !aAnnotations.empty() )
-           {       	
+           {
                const int page_width = pPage->GetSize().Width();
             const int width = 1000;
             const int height = 800;
             Rectangle aTagRect;
-                            
+
                while( true )
-               {  
+               {
                 Rectangle aNewRect( x, y, x + width - 1, y + height - 1 );
                    bool bFree = true;
-                   
+
                    for( AnnotationVector::iterator iter = aAnnotations.begin(); iter != aAnnotations.end(); iter++ )
                    {
                        RealPoint2D aPoint( (*iter)->getPosition() );
@@ -405,14 +405,14 @@ void AnnotationManagerImpl::InsertAnnotation()
                        aTagRect.nTop    = sal::static_int_cast< long >( aPoint.Y * 100.0 );
                        aTagRect.nRight  = aTagRect.nLeft + width - 1;
                        aTagRect.nBottom = aTagRect.nTop + height - 1;
-                       
+
                        if( aNewRect.IsOver( aTagRect ) )
                        {
                            bFree = false;
                            break;
                        }
                    }
-                   
+
                    if( bFree == false)
                    {
                        x += width;
@@ -420,32 +420,32 @@ void AnnotationManagerImpl::InsertAnnotation()
                        {
                            x = 0;
                            y += height;
-                       }       	            
+                       }
                    }
                    else
                    {
                        break;
                    }
                }
-           }       	
-    
+           }
+
         Reference< XAnnotation > xAnnotation;
         pPage->createAnnotation( xAnnotation );
-        
+
         // set current author to new annotation
         SvtUserOptions aUserOptions;
         xAnnotation->setAuthor( aUserOptions.GetFullName() );
-        
+
         // set current time to new annotation
         xAnnotation->setDateTime( getCurrentDateTime() );
-        
+
         // set position
         RealPoint2D aPos( ((double)x) / 100.0, ((double)y) / 100.0 );
         xAnnotation->setPosition( aPos );
 
         if( mpDoc->IsUndoEnabled() )
             mpDoc->EndUndo();
-        
+
         UpdateTags(true);
         SelectAnnotation( xAnnotation, true );
     }
@@ -469,7 +469,7 @@ void AnnotationManagerImpl::ExecuteReplyToAnnotation( SfxRequest& rReq )
     if( pTextApi )
     {
         std::auto_ptr< ::Outliner > pOutliner( new ::Outliner(GetAnnotationPool(),OUTLINERMODE_TEXTOBJECT) );
-        
+
         mpDoc->SetCalcFieldValueHdl( pOutliner.get() );
         pOutliner->SetUpdateMode( TRUE );
 
@@ -477,7 +477,7 @@ void AnnotationManagerImpl::ExecuteReplyToAnnotation( SfxRequest& rReq )
         OUString sAuthor( xAnnotation->getAuthor() );
         if( sAuthor.getLength() == 0 )
             sAuthor = String( SdResId( STR_ANNOTATION_NOAUTHOR ) );
-            
+
         aStr.SearchAndReplaceAscii("%1", sAuthor);
 
         aStr.Append( String(RTL_CONSTASCII_USTRINGPARAM(" (") ) );
@@ -490,32 +490,32 @@ void AnnotationManagerImpl::ExecuteReplyToAnnotation( SfxRequest& rReq )
             sQuote = String( RTL_CONSTASCII_USTRINGPARAM( "..." ) );
         aStr.Append( sQuote );
         aStr.Append( String(RTL_CONSTASCII_USTRINGPARAM("\"\n") ) );
-        
+
         USHORT nParaCount = aStr.GetTokenCount( '\n' );
         for( USHORT nPara = 0; nPara < nParaCount; nPara++ )
             pOutliner->Insert( aStr.GetToken( nPara, '\n' ), LIST_APPEND, -1 );
-        
+
         if( pOutliner->GetParagraphCount() > 1 )
         {
             SfxItemSet aAnswerSet( pOutliner->GetEmptyItemSet() );
-            aAnswerSet.Put(SvxPostureItem(ITALIC_NORMAL,EE_CHAR_ITALIC));	    
-            
+            aAnswerSet.Put(SvxPostureItem(ITALIC_NORMAL,EE_CHAR_ITALIC));
+
             ESelection aSel;
             aSel.nEndPara = (USHORT)pOutliner->GetParagraphCount()-2;
             aSel.nEndPos = pOutliner->GetText( pOutliner->GetParagraph( aSel.nEndPara ) ).Len();
-            
+
             pOutliner->QuickSetAttribs( aAnswerSet, aSel );
         }
-                
+
         std::auto_ptr< OutlinerParaObject > pOPO( pOutliner->CreateParaObject() );
         pTextApi->SetText( *pOPO.get() );
-        
+
         SvtUserOptions aUserOptions;
-        xAnnotation->setAuthor( aUserOptions.GetFullName() );        
+        xAnnotation->setAuthor( aUserOptions.GetFullName() );
 
         // set current time to reply
         xAnnotation->setDateTime( getCurrentDateTime() );
-                
+
         UpdateTags(true);
         SelectAnnotation( xAnnotation, true );
     }
@@ -524,7 +524,7 @@ void AnnotationManagerImpl::ExecuteReplyToAnnotation( SfxRequest& rReq )
 // --------------------------------------------------------------------
 
 void AnnotationManagerImpl::DeleteAnnotation( Reference< XAnnotation > xAnnotation )
-{     
+{
     SdPage* pPage = GetCurrentPage();
 
     if( xAnnotation.is() && pPage )
@@ -550,9 +550,9 @@ void AnnotationManagerImpl::DeleteAnnotationsByAuthor( const rtl::OUString& sAut
     do
     {
         pPage = GetNextPage( pPage, true );
-        
+
         if( pPage && !pPage->getAnnotations().empty() )
-        {     
+        {
             AnnotationVector aAnnotations( pPage->getAnnotations() );
             for( AnnotationVector::iterator iter = aAnnotations.begin(); iter != aAnnotations.end(); iter++ )
             {
@@ -580,14 +580,14 @@ void AnnotationManagerImpl::DeleteAllAnnotations()
     do
     {
         pPage = GetNextPage( pPage, true );
-        
+
         if( pPage && !pPage->getAnnotations().empty() )
-        {     
+        {
 
             AnnotationVector aAnnotations( pPage->getAnnotations() );
             for( AnnotationVector::iterator iter = aAnnotations.begin(); iter != aAnnotations.end(); iter++ )
             {
-                pPage->removeAnnotation( (*iter) );            
+                pPage->removeAnnotation( (*iter) );
             }
          }
     }
@@ -604,31 +604,31 @@ void AnnotationManagerImpl::DeleteAllAnnotations()
 void AnnotationManagerImpl::GetAnnotationState(SfxItemSet& rSet)
 {
     SdPage* pCurrentPage = GetCurrentPage();
- 
+
     const bool bReadOnly = mrBase.GetDocShell()->IsReadOnly();
     const bool bWrongPageKind = (pCurrentPage == 0) || (pCurrentPage->GetPageKind() != PK_STANDARD);
-   
+
     const SvtSaveOptions::ODFDefaultVersion nCurrentODFVersion( SvtSaveOptions().GetODFDefaultVersion() );
 
     if( bReadOnly || bWrongPageKind || (nCurrentODFVersion != SvtSaveOptions::ODFVER_LATEST) )
-        rSet.DisableItem( SID_INSERT_POSTIT ); 
+        rSet.DisableItem( SID_INSERT_POSTIT );
 
     rSet.Put(SfxBoolItem(SID_SHOW_POSTIT, mbShowAnnotations));
-     
+
     Reference< XAnnotation > xAnnotation;
     GetSelectedAnnotation( xAnnotation );
-    
+
     if( !xAnnotation.is() || bReadOnly )
-        rSet.DisableItem( SID_DELETE_POSTIT );        
+        rSet.DisableItem( SID_DELETE_POSTIT );
 
     SdPage* pPage = 0;
-    
+
     bool bHasAnnotations = false;
     do
     {
         pPage = GetNextPage( pPage, true );
-        
-        if( pPage && !pPage->getAnnotations().empty() )        
+
+        if( pPage && !pPage->getAnnotations().empty() )
             bHasAnnotations = true;
     }
     while( pPage && !bHasAnnotations );
@@ -636,7 +636,7 @@ void AnnotationManagerImpl::GetAnnotationState(SfxItemSet& rSet)
     if( !bHasAnnotations || bReadOnly )
     {
         rSet.DisableItem( SID_DELETEALL_POSTIT );
-    }	    
+    }
 
     if( bWrongPageKind || !bHasAnnotations )
     {
@@ -684,7 +684,7 @@ void AnnotationManagerImpl::SelectNextAnnotation(bool bForeward)
         }
     }
     else
-    {       
+    {
         if( xCurrent.is() )
         {
                for( AnnotationVector::iterator iter = aAnnotations.begin(); iter != aAnnotations.end(); iter++ )
@@ -703,7 +703,7 @@ void AnnotationManagerImpl::SelectNextAnnotation(bool bForeward)
                }
         }
         else if( !aAnnotations.empty() )
-        {        
+        {
             AnnotationVector::iterator iter( aAnnotations.end() );
             SelectAnnotation( *(--iter) );
             return;
@@ -716,8 +716,8 @@ void AnnotationManagerImpl::SelectNextAnnotation(bool bForeward)
         do
         {
             pPage = GetNextPage( pPage, bForeward );
-            
-            if( pPage && !pPage->getAnnotations().empty() )        
+
+            if( pPage && !pPage->getAnnotations().empty() )
             {
                 // switch to next/previous slide with annotations
                 ::boost::shared_ptr<DrawViewShell> pDrawViewShell(::boost::dynamic_pointer_cast<DrawViewShell>(mrBase.GetMainViewShell()));
@@ -725,17 +725,17 @@ void AnnotationManagerImpl::SelectNextAnnotation(bool bForeward)
                 {
                     pDrawViewShell->ChangeEditMode(pPage->IsMasterPage() ? EM_MASTERPAGE : EM_PAGE, FALSE);
                     pDrawViewShell->SwitchPage((pPage->GetPageNum() - 1) >> 1);
-                    
+
                     SfxDispatcher* pDispatcher = getDispatcher( mrBase );
                     if( pDispatcher )
                         pDispatcher->Execute( bForeward ? SID_NEXT_POSTIT : SID_PREVIOUS_POSTIT );
-                        
+
                     return;
-                }            
+                }
             }
         }
         while( pPage );
-            
+
         // The question text depends on the search direction.
         bool bImpress = mpDoc->GetDocumentType() == DOCUMENT_TYPE_IMPRESS;
         sal_uInt16 nStringId;
@@ -780,14 +780,14 @@ void AnnotationManagerImpl::onTagDeselected( AnnotationTag& rTag )
 // --------------------------------------------------------------------
 
 void AnnotationManagerImpl::SelectAnnotation( ::com::sun::star::uno::Reference< ::com::sun::star::office::XAnnotation > xAnnotation, bool bEdit /* = FALSE */ )
-{      
+{
     mxSelectedAnnotation = xAnnotation;
-    
+
     for( AnnotationTagVector::iterator iter( maTagVector.begin() ); iter != maTagVector.end(); iter++ )
     {
         if( (*iter)->GetAnnotation() == xAnnotation )
         {
-               SmartTagReference xTag( (*iter).get() );      
+               SmartTagReference xTag( (*iter).get() );
             mrBase.GetMainViewShell()->GetView()->getSmartTags().select( xTag );
             (*iter)->OpenPopup( bEdit );
             break;
@@ -811,8 +811,8 @@ void AnnotationManagerImpl::invalidateSlots()
         pBindings->Invalidate( SID_DELETE_POSTIT );
         pBindings->Invalidate( SID_DELETEALL_POSTIT );
         pBindings->Invalidate( SID_PREVIOUS_POSTIT );
-        pBindings->Invalidate( SID_NEXT_POSTIT );   
-        pBindings->Invalidate( SID_UNDO );   
+        pBindings->Invalidate( SID_NEXT_POSTIT );
+        pBindings->Invalidate( SID_UNDO );
         pBindings->Invalidate( SID_REDO );
     }
 }
@@ -828,9 +828,9 @@ void AnnotationManagerImpl::onSelectionChanged()
         if( xPage != mxCurrentPage )
         {
             mxCurrentPage = xPage;
-            
+
             UpdateTags(true);
-        }	 
+        }
     }
     catch( Exception& )
     {
@@ -844,7 +844,7 @@ void AnnotationManagerImpl::UpdateTags( bool bSynchron )
     {
         if( mnUpdateTagsEvent )
             Application::RemoveUserEvent( mnUpdateTagsEvent );
-            
+
             UpdateTagsHdl(0);
     }
     else
@@ -858,15 +858,15 @@ IMPL_LINK(AnnotationManagerImpl,UpdateTagsHdl, void *, EMPTYARG)
 {
     mnUpdateTagsEvent  = 0;
     DisposeTags();
-        
+
     if( mbShowAnnotations )
         CreateTags();
-        
+
     if(  mrBase.GetDrawView() )
-        static_cast< ::sd::View* >( mrBase.GetDrawView() )->updateHandles();        
+        static_cast< ::sd::View* >( mrBase.GetDrawView() )->updateHandles();
 
     invalidateSlots();
-    
+
     return 0;
 }
 
@@ -879,7 +879,7 @@ void AnnotationManagerImpl::CreateTags()
         maFont = Application::GetSettings().GetStyleSettings().GetAppFont();
 
         rtl::Reference< AnnotationTag > xSelectedTag;
-        
+
         Reference< XAnnotationEnumeration > xEnum( mxCurrentPage->createAnnotationEnumeration() );
         while( xEnum->hasMoreElements() )
         {
@@ -887,16 +887,16 @@ void AnnotationManagerImpl::CreateTags()
             Color aColor( GetColorLight( mpDoc->GetAnnotationAuthorIndex( xAnnotation->getAuthor() ) ) );
             rtl::Reference< AnnotationTag > xTag( new AnnotationTag( *this, *mrBase.GetMainViewShell()->GetView(), xAnnotation, aColor, nIndex++, maFont  ) );
             maTagVector.push_back(xTag);
-            
+
             if( xAnnotation == mxSelectedAnnotation )
             {
                 xSelectedTag = xTag;
             }
         }
-        
+
         if( xSelectedTag.is() )
         {
-               SmartTagReference xTag( xSelectedTag.get() );      	    
+               SmartTagReference xTag( xSelectedTag.get() );
             mrBase.GetMainViewShell()->GetView()->getSmartTags().select( xTag );
         }
         else
@@ -923,7 +923,7 @@ void AnnotationManagerImpl::DisposeTags()
             (*iter++)->Dispose();
         }
         while( iter != maTagVector.end() );
-        
+
         maTagVector.clear();
     }
 }
@@ -979,29 +979,29 @@ void AnnotationManagerImpl::ExecuteAnnotationContextMenu( Reference< XAnnotation
     SfxDispatcher* pDispatcher( getDispatcher( mrBase ) );
     if( !pDispatcher )
         return;
-    
+
     const bool bReadOnly = mrBase.GetDocShell()->IsReadOnly();
-    
+
     AnnotationWindow* pAnnotationWindow = bButtonMenu ? 0 : dynamic_cast< AnnotationWindow* >( pParent );
-    
+
     if( bReadOnly && !pAnnotationWindow )
         return;
-   
+
     std::auto_ptr< PopupMenu > pMenu( new PopupMenu( SdResId( pAnnotationWindow ? RID_ANNOTATION_CONTEXTMENU : RID_ANNOTATION_TAG_CONTEXTMENU ) ) );
 
     SvtUserOptions aUserOptions;
-    OUString sCurrentAuthor( aUserOptions.GetFullName() );	
+    OUString sCurrentAuthor( aUserOptions.GetFullName() );
     OUString sAuthor( xAnnotation->getAuthor() );
-    
+
     String aStr( pMenu->GetItemText( SID_DELETEALLBYAUTHOR_POSTIT ) ), aReplace( sAuthor );
     if( aReplace.Len() == 0 )
         aReplace = String( SdResId( STR_ANNOTATION_NOAUTHOR ) );
     aStr.SearchAndReplaceAscii("%1", aReplace);
     pMenu->SetItemText( SID_DELETEALLBYAUTHOR_POSTIT, aStr );
     pMenu->EnableItem( SID_REPLYTO_POSTIT, (sAuthor != sCurrentAuthor) && !bReadOnly );
-    pMenu->EnableItem( SID_DELETE_POSTIT, (xAnnotation.is() && !bReadOnly) ? TRUE : FALSE );  
-    pMenu->EnableItem( SID_DELETEALLBYAUTHOR_POSTIT, !bReadOnly );  
-    pMenu->EnableItem( SID_DELETEALL_POSTIT, !bReadOnly );  
+    pMenu->EnableItem( SID_DELETE_POSTIT, (xAnnotation.is() && !bReadOnly) ? TRUE : FALSE );
+    pMenu->EnableItem( SID_DELETEALLBYAUTHOR_POSTIT, !bReadOnly );
+    pMenu->EnableItem( SID_DELETEALL_POSTIT, !bReadOnly );
 
     if( pAnnotationWindow )
     {
@@ -1016,18 +1016,18 @@ void AnnotationManagerImpl::ExecuteAnnotationContextMenu( Reference< XAnnotation
         else
         {
             SfxItemSet aSet(pAnnotationWindow->getView()->GetAttribs());
-            
+
             if ( aSet.GetItemState( EE_CHAR_WEIGHT ) == SFX_ITEM_ON )
             {
                 if( ((const SvxWeightItem&)aSet.Get( EE_CHAR_WEIGHT )).GetWeight() == WEIGHT_BOLD )
                     pMenu->CheckItem( SID_ATTR_CHAR_WEIGHT );
             }
-            
+
             if ( aSet.GetItemState( EE_CHAR_ITALIC ) == SFX_ITEM_ON )
             {
                 if( ((const SvxPostureItem&)aSet.Get( EE_CHAR_ITALIC )).GetPosture() != ITALIC_NONE )
                     pMenu->CheckItem( SID_ATTR_CHAR_POSTURE );
-                
+
             }
             if ( aSet.GetItemState( EE_CHAR_UNDERLINE ) == SFX_ITEM_ON )
             {
@@ -1043,24 +1043,24 @@ void AnnotationManagerImpl::ExecuteAnnotationContextMenu( Reference< XAnnotation
             TransferableDataHelper aDataHelper( TransferableDataHelper::CreateFromSystemClipboard( pAnnotationWindow ) );
             pMenu->EnableItem( SID_PASTE, aDataHelper.GetFormatCount() != 0 );
         }
-        
+
         pMenu->EnableItem( SID_COPY, pAnnotationWindow->getView()->HasSelection() );
     }
 
     USHORT nId = 0;
-    
+
     // set slot images
     Reference< ::com::sun::star::frame::XFrame > xFrame( mrBase.GetMainViewShell()->GetViewFrame()->GetFrame().GetFrameInterface() );
     if( xFrame.is() )
     {
         for( USHORT nPos = 0; nPos < pMenu->GetItemCount(); nPos++ )
         {
-            nId = pMenu->GetItemId( nPos );    
+            nId = pMenu->GetItemId( nPos );
             if( pMenu->IsItemEnabled( nId ) )
             {
                 OUString sSlotURL( RTL_CONSTASCII_USTRINGPARAM( "slot:" ));
                 sSlotURL += OUString::valueOf( sal_Int32( nId ));
-                
+
                 Image aImage( GetImage( xFrame, sSlotURL, false ) );
                 if( !!aImage )
                     pMenu->SetItemImage( nId, aImage );
@@ -1091,10 +1091,10 @@ void AnnotationManagerImpl::ExecuteAnnotationContextMenu( Reference< XAnnotation
     }
     case SID_DELETEALL_POSTIT:
         pDispatcher->Execute( SID_DELETEALL_POSTIT );
-        break;	
+        break;
     case SID_COPY:
     case SID_PASTE:
-    case SID_ATTR_CHAR_WEIGHT: 
+    case SID_ATTR_CHAR_WEIGHT:
     case SID_ATTR_CHAR_POSTURE:
     case SID_ATTR_CHAR_UNDERLINE:
     case SID_ATTR_CHAR_STRIKEOUT:
@@ -1155,14 +1155,14 @@ SdPage* AnnotationManagerImpl::GetNextPage( SdPage* pPage, bool bForeward )
 {
     if( pPage == 0 )
         return bForeward ? GetFirstPage() : GetLastPage();
-        
+
     sal_uInt16 nPageNum = (pPage->GetPageNum() - 1) >> 1;
 
     // first all non master pages
     if( !pPage->IsMasterPage() )
     {
         if( bForeward )
-        {            
+        {
             if( nPageNum >= mpDoc->GetSdPageCount(PK_STANDARD)-1 )
             {
                 // we reached end of draw pages, start with master pages (skip handout master for draw)
@@ -1174,15 +1174,15 @@ SdPage* AnnotationManagerImpl::GetNextPage( SdPage* pPage, bool bForeward )
         {
             if( nPageNum == 0 )
                 return 0; // we are already on the first draw page, finished
-                
-            nPageNum--;            
+
+            nPageNum--;
         }
         return mpDoc->GetSdPage(nPageNum, PK_STANDARD);
     }
     else
     {
         if( bForeward )
-        {            
+        {
             if( nPageNum >= mpDoc->GetMasterSdPageCount(PK_STANDARD)-1 )
             {
                 return 0;   // we reached the end, there is nothing more to see here
@@ -1195,12 +1195,12 @@ SdPage* AnnotationManagerImpl::GetNextPage( SdPage* pPage, bool bForeward )
             {
                 // we reached beginning of master pages, start with end if pages
                 return mpDoc->GetSdPage( mpDoc->GetSdPageCount(PK_STANDARD)-1, PK_STANDARD );
-            }        
-                
-            nPageNum--;            
+            }
+
+            nPageNum--;
         }
         return mpDoc->GetMasterSdPage(nPageNum,PK_STANDARD);
-    }       
+    }
 }
 
 SdPage* AnnotationManagerImpl::GetFirstPage()
diff --git a/sd/source/ui/app/tbxww.cxx b/sd/source/ui/app/tbxww.cxx
index c86c6fb..e4a7d38 100644
--- a/sd/source/ui/app/tbxww.cxx
+++ b/sd/source/ui/app/tbxww.cxx
@@ -2,7 +2,7 @@
  /*************************************************************************
  *
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- * 
+ *
  * Copyright 2000, 2010 Oracle and/or its affiliates.
  *
  * OpenOffice.org - a multi-platform office productivity suite
@@ -38,7 +38,7 @@
 #include <sfx2/imagemgr.hxx>
 #include <rtl/ustring.hxx>
 #include <rtl/ustrbuf.hxx>
-    
+
 #include "sddll.hxx"
 #include "GraphicDocShell.hxx"
 
@@ -78,7 +78,7 @@ SdPopupWindowTbx::SdPopupWindowTbx( USHORT nId, WindowAlign eAlign,
     {
         if ( aSdResIdWin.GetId() != RID_TEXT )
             aTbx.GetToolBox().SetAlign( WINDOWALIGN_LEFT );
-        
+
         SetText( String() );
     }
 
@@ -271,10 +271,10 @@ SfxPopupWindow*	SdTbxControl::CreatePopupWindow()
             aToolBarResStr = aTbxResName.makeStringAndClear();
         break;
     }
-    
+
     if ( aToolBarResStr.getLength() > 0 )
         createAndPositionSubToolBar( aToolBarResStr );
-        
+
     return( pWin );
 }
 
@@ -304,9 +304,10 @@ void SdTbxControl::StateChanged( USHORT nSId,
             {
                 rtl::OUString aSlotURL( RTL_CONSTASCII_USTRINGPARAM( "slot:" ));
                 aSlotURL += rtl::OUString::valueOf( sal_Int32( nImage ));
-                Image aImage = GetImage( m_xFrame, 
+                Image aImage = GetImage( m_xFrame,
                                          aSlotURL,
-                                         hasBigImages() );
+                                         hasBigImages()
+                                       );
 
                 // !-Operator prueft, ob Image nicht vorhanden ist
                 if( !!aImage )
diff --git a/sd/source/ui/controller/slidelayoutcontroller.cxx b/sd/source/ui/controller/slidelayoutcontroller.cxx
index 606fd81..569b91f 100644
--- a/sd/source/ui/controller/slidelayoutcontroller.cxx
+++ b/sd/source/ui/controller/slidelayoutcontroller.cxx
@@ -24,7 +24,7 @@
  * <http://www.openoffice.org/license.html>
  * for a copy of the LGPLv3 License.
  *
- ************************************************************************/ 
+ ************************************************************************/
 
 // MARKER(update_precomp.py): autogen include statement, do not remove
 #include "precompiled_sd.hxx"
@@ -110,52 +110,45 @@ struct snewfoil_value_info
 
 static snewfoil_value_info notes[] =
 {
-    {BMP_FOILN_01, STR_AUTOLAYOUT_NOTES, WritingMode_LR_TB,
-     AUTOLAYOUT_NOTES},
+    {BMP_FOILN_01, STR_AUTOLAYOUT_NOTES, WritingMode_LR_TB, AUTOLAYOUT_NOTES},
     {0, 0, WritingMode_LR_TB, AUTOLAYOUT_NONE},
 };
 
 static snewfoil_value_info handout[] =
 {
-    {BMP_FOILH_01, STR_AUTOLAYOUT_HANDOUT1, WritingMode_LR_TB,
-     AUTOLAYOUT_HANDOUT1},
-    {BMP_FOILH_02, STR_AUTOLAYOUT_HANDOUT2, WritingMode_LR_TB,
-     AUTOLAYOUT_HANDOUT2},
-    {BMP_FOILH_03, STR_AUTOLAYOUT_HANDOUT3, WritingMode_LR_TB,
-     AUTOLAYOUT_HANDOUT3},
-    {BMP_FOILH_04, STR_AUTOLAYOUT_HANDOUT4, WritingMode_LR_TB,
-     AUTOLAYOUT_HANDOUT4},
-    {BMP_FOILH_06, STR_AUTOLAYOUT_HANDOUT6, WritingMode_LR_TB,
-     AUTOLAYOUT_HANDOUT6},
-    {BMP_FOILH_09, STR_AUTOLAYOUT_HANDOUT9, WritingMode_LR_TB,
-     AUTOLAYOUT_HANDOUT9},
+    {BMP_FOILH_01, STR_AUTOLAYOUT_HANDOUT1, WritingMode_LR_TB, AUTOLAYOUT_HANDOUT1},
+    {BMP_FOILH_02, STR_AUTOLAYOUT_HANDOUT2, WritingMode_LR_TB, AUTOLAYOUT_HANDOUT2},
+    {BMP_FOILH_03, STR_AUTOLAYOUT_HANDOUT3, WritingMode_LR_TB, AUTOLAYOUT_HANDOUT3},
+    {BMP_FOILH_04, STR_AUTOLAYOUT_HANDOUT4, WritingMode_LR_TB, AUTOLAYOUT_HANDOUT4},
+    {BMP_FOILH_06, STR_AUTOLAYOUT_HANDOUT6, WritingMode_LR_TB, AUTOLAYOUT_HANDOUT6},
+    {BMP_FOILH_09, STR_AUTOLAYOUT_HANDOUT9, WritingMode_LR_TB, AUTOLAYOUT_HANDOUT9},
     {0, 0, WritingMode_LR_TB, AUTOLAYOUT_NONE},
 };
 
 static snewfoil_value_info standard[] =
 {
-    {BMP_LAYOUT_EMPTY, STR_AUTOLAYOUT_NONE, WritingMode_LR_TB,        AUTOLAYOUT_NONE},
-    {BMP_LAYOUT_HEAD03, STR_AUTOLAYOUT_TITLE, WritingMode_LR_TB,       AUTOLAYOUT_TITLE},
-    {BMP_LAYOUT_HEAD02, STR_AUTOLAYOUT_CONTENT, WritingMode_LR_TB,        AUTOLAYOUT_ENUM},
-    {BMP_LAYOUT_HEAD02A, STR_AUTOLAYOUT_2CONTENT, WritingMode_LR_TB,       AUTOLAYOUT_2TEXT},
-    {BMP_LAYOUT_HEAD01, STR_AUTOLAYOUT_ONLY_TITLE, WritingMode_LR_TB,  AUTOLAYOUT_ONLY_TITLE},
-    {BMP_LAYOUT_TEXTONLY, STR_AUTOLAYOUT_ONLY_TEXT, WritingMode_LR_TB,   AUTOLAYOUT_ONLY_TEXT},
-    {BMP_LAYOUT_HEAD03B, STR_AUTOLAYOUT_2CONTENT_CONTENT, WritingMode_LR_TB,    AUTOLAYOUT_2OBJTEXT},
-    {BMP_LAYOUT_HEAD03C, STR_AUTOLAYOUT_CONTENT_2CONTENT, WritingMode_LR_TB,    AUTOLAYOUT_TEXT2OBJ},
-    {BMP_LAYOUT_HEAD03A, STR_AUTOLAYOUT_2CONTENT_OVER_CONTENT,WritingMode_LR_TB, AUTOLAYOUT_2OBJOVERTEXT},
-    {BMP_LAYOUT_HEAD02B, STR_AUTOLAYOUT_CONTENT_OVER_CONTENT, WritingMode_LR_TB, AUTOLAYOUT_OBJOVERTEXT},
-    {BMP_LAYOUT_HEAD04, STR_AUTOLAYOUT_4CONTENT, WritingMode_LR_TB,        AUTOLAYOUT_4OBJ},
-    {BMP_LAYOUT_HEAD06, STR_AUTOLAYOUT_6CONTENT, WritingMode_LR_TB,    AUTOLAYOUT_6CLIPART},
+    {BMP_LAYOUT_EMPTY,    STR_AUTOLAYOUT_NONE,                 WritingMode_LR_TB, AUTOLAYOUT_NONE         },
+    {BMP_LAYOUT_HEAD03,   STR_AUTOLAYOUT_TITLE,                WritingMode_LR_TB, AUTOLAYOUT_TITLE        },
+    {BMP_LAYOUT_HEAD02,   STR_AUTOLAYOUT_CONTENT,              WritingMode_LR_TB, AUTOLAYOUT_ENUM         },
+    {BMP_LAYOUT_HEAD02A,  STR_AUTOLAYOUT_2CONTENT,             WritingMode_LR_TB, AUTOLAYOUT_2TEXT        },
+    {BMP_LAYOUT_HEAD01,   STR_AUTOLAYOUT_ONLY_TITLE,           WritingMode_LR_TB, AUTOLAYOUT_ONLY_TITLE   },
+    {BMP_LAYOUT_TEXTONLY, STR_AUTOLAYOUT_ONLY_TEXT,            WritingMode_LR_TB, AUTOLAYOUT_ONLY_TEXT    },
+    {BMP_LAYOUT_HEAD03B,  STR_AUTOLAYOUT_2CONTENT_CONTENT,     WritingMode_LR_TB, AUTOLAYOUT_2OBJTEXT     },
+    {BMP_LAYOUT_HEAD03C,  STR_AUTOLAYOUT_CONTENT_2CONTENT,     WritingMode_LR_TB, AUTOLAYOUT_TEXT2OBJ     },
+    {BMP_LAYOUT_HEAD03A,  STR_AUTOLAYOUT_2CONTENT_OVER_CONTENT,WritingMode_LR_TB, AUTOLAYOUT_2OBJOVERTEXT },
+    {BMP_LAYOUT_HEAD02B,  STR_AUTOLAYOUT_CONTENT_OVER_CONTENT, WritingMode_LR_TB, AUTOLAYOUT_OBJOVERTEXT  },
+    {BMP_LAYOUT_HEAD04,   STR_AUTOLAYOUT_4CONTENT,             WritingMode_LR_TB, AUTOLAYOUT_4OBJ         },
+    {BMP_LAYOUT_HEAD06,   STR_AUTOLAYOUT_6CONTENT,             WritingMode_LR_TB, AUTOLAYOUT_6CLIPART     },
     {0, 0, WritingMode_LR_TB, AUTOLAYOUT_NONE}
 };
 
 static snewfoil_value_info v_standard[] =
 {
     // vertical
-    {BMP_LAYOUT_VERTICAL02, STR_AL_VERT_TITLE_TEXT_CHART, WritingMode_TB_RL,AUTOLAYOUT_VERTICAL_TITLE_TEXT_CHART},
-    {BMP_LAYOUT_VERTICAL01, STR_AL_VERT_TITLE_VERT_OUTLINE, WritingMode_TB_RL, AUTOLAYOUT_VERTICAL_TITLE_VERTICAL_OUTLINE},
-    {BMP_LAYOUT_HEAD02, STR_AL_TITLE_VERT_OUTLINE, WritingMode_TB_RL, AUTOLAYOUT_TITLE_VERTICAL_OUTLINE},
-    {BMP_LAYOUT_HEAD02A, STR_AL_TITLE_VERT_OUTLINE_CLIPART,   WritingMode_TB_RL, AUTOLAYOUT_TITLE_VERTICAL_OUTLINE_CLIPART},
+    {BMP_LAYOUT_VERTICAL02, STR_AL_VERT_TITLE_TEXT_CHART,      WritingMode_TB_RL, AUTOLAYOUT_VERTICAL_TITLE_TEXT_CHART       },
+    {BMP_LAYOUT_VERTICAL01, STR_AL_VERT_TITLE_VERT_OUTLINE,    WritingMode_TB_RL, AUTOLAYOUT_VERTICAL_TITLE_VERTICAL_OUTLINE },
+    {BMP_LAYOUT_HEAD02,     STR_AL_TITLE_VERT_OUTLINE,         WritingMode_TB_RL, AUTOLAYOUT_TITLE_VERTICAL_OUTLINE          },
+    {BMP_LAYOUT_HEAD02A,    STR_AL_TITLE_VERT_OUTLINE_CLIPART, WritingMode_TB_RL, AUTOLAYOUT_TITLE_VERTICAL_OUTLINE_CLIPART  },
     {0, 0, WritingMode_LR_TB, AUTOLAYOUT_NONE}
 };
 
@@ -166,12 +159,12 @@ static void fillLayoutValueSet( ValueSet* pValue, snewfoil_value_info* pInfo )
     Size aLayoutItemSize;
     for( ; pInfo->mnBmpResId; pInfo++ )
     {
-        String aText( SdResId( pInfo->mnStrResId ) );
-        BitmapEx aBmp( SdResId( pInfo->mnBmpResId ) );
+        String   aText( SdResId( pInfo->mnStrResId ) );
+        BitmapEx aBmp(  SdResId( pInfo->mnBmpResId ) );
 
         pValue->InsertItem( static_cast<USHORT>(pInfo->maAutoLayout)+1, aBmp, aText );
 
-        aLayoutItemSize.Width() = std::max( aLayoutItemSize.Width(), aBmp.GetSizePixel().Width() );
+        aLayoutItemSize.Width()  = std::max( aLayoutItemSize.Width(),  aBmp.GetSizePixel().Width()  );
         aLayoutItemSize.Height() = std::max( aLayoutItemSize.Height(), aBmp.GetSizePixel().Height() );
     }
 
@@ -207,7 +200,7 @@ LayoutToolbarMenu::LayoutToolbarMenu( SlideLayoutController& rController, const
 
     String aTitle1( SdResId( STR_GLUE_ESCDIR_HORZ ) );
     String aTitle2( SdResId( STR_GLUE_ESCDIR_VERT ) );
-  
+
     SvtLanguageOptions aLanguageOptions;
     const bool bVerticalEnabled = aLanguageOptions.IsVerticalTextEnabled();
 
@@ -242,7 +235,6 @@ LayoutToolbarMenu::LayoutToolbarMenu( SlideLayoutController& rController, const
     if( bVerticalEnabled && (eMode == DrawViewMode_DRAW) )
     {
         mpLayoutSet2 = new ValueSet( this, WB_TABSTOP | WB_MENUSTYLEVALUESET | WB_FLATVALUESET | WB_NOBORDER | WB_NO_DIRECTSELECT );
-    //	mpLayoutSet2->SetHelpId( HID_VALUESET_EXTRUSION_LIGHTING );
 
         mpLayoutSet2->SetSelectHdl( LINK( this, LayoutToolbarMenu, SelectHdl ) );
         mpLayoutSet2->SetColCount( 4 );
diff --git a/sd/source/ui/inc/OutlineView.hxx b/sd/source/ui/inc/OutlineView.hxx
index b6a372f..512b276 100644
--- a/sd/source/ui/inc/OutlineView.hxx
+++ b/sd/source/ui/inc/OutlineView.hxx
@@ -2,7 +2,7 @@
 /*************************************************************************
  *
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- * 
+ *
  * Copyright 2000, 2010 Oracle and/or its affiliates.
  *
  * OpenOffice.org - a multi-platform office productivity suite
@@ -62,12 +62,12 @@ static const int MAX_OUTLINERVIEWS = 4;
 |*
 \************************************************************************/
 
-class OutlineView 
+class OutlineView
     : public ::sd::View
 {
     friend class OutlineViewModelChangeGuard;
 public:
-    OutlineView (DrawDocShell* pDocSh, 
+    OutlineView (DrawDocShell* pDocSh,
         ::Window* pWindow,
         OutlineViewShell* pOutlineViewSh);
     ~OutlineView (void);
@@ -105,7 +105,7 @@ public:
 
     virtual void Paint (const Rectangle& rRect, ::sd::Window* pWin);
     virtual void AdjustPosSizePixel(
-        const Point &rPos, 
+        const Point &rPos,
         const Size &rSize,
         ::sd::Window* pWindow);
 
@@ -139,16 +139,16 @@ public:
     void               SetSelectedPages();
 
     virtual sal_Int8 AcceptDrop (
-        const AcceptDropEvent& rEvt, 
-        DropTargetHelper& rTargetHelper, 
-        ::sd::Window* pTargetWindow = NULL, 
-        USHORT nPage = SDRPAGE_NOTFOUND, 
+        const AcceptDropEvent& rEvt,
+        DropTargetHelper& rTargetHelper,
+        ::sd::Window* pTargetWindow = NULL,
+        USHORT nPage = SDRPAGE_NOTFOUND,
         USHORT nLayer = SDRPAGE_NOTFOUND);
     virtual sal_Int8 ExecuteDrop (
-        const ExecuteDropEvent& rEvt, 
-        DropTargetHelper& rTargetHelper, 
-        ::sd::Window* pTargetWindow = NULL, 
-        USHORT nPage = SDRPAGE_NOTFOUND, 
+        const ExecuteDropEvent& rEvt,
+        DropTargetHelper& rTargetHelper,
+        ::sd::Window* pTargetWindow = NULL,
+        USHORT nPage = SDRPAGE_NOTFOUND,
         USHORT nLayer = SDRPAGE_NOTFOUND);
 
 
@@ -174,7 +174,7 @@ protected:
     virtual void OnEndPasteOrDrop( PasteOrDropInfos* pInfos );
 
 private:
-    /** call this method before you do anything that can modify the outliner 
+    /** call this method before you do anything that can modify the outliner
         and or the drawing document model. It will create needed undo actions */
     void BeginModelChange();
 
@@ -202,11 +202,6 @@ private:
 
     SfxProgress*		mpProgress;
 
-    /** stores the last used high contrast mode.
-        this is changed in onUpdateStyleSettings()
-    */
-    bool mbHighContrastMode;
-
     /** stores the last used document color.
         this is changed in onUpdateStyleSettings()
     */
diff --git a/sd/source/ui/slideshow/slideshowimpl.cxx b/sd/source/ui/slideshow/slideshowimpl.cxx
index 8244183..3362f29 100644
--- a/sd/source/ui/slideshow/slideshowimpl.cxx
+++ b/sd/source/ui/slideshow/slideshowimpl.cxx
@@ -2,7 +2,7 @@
 /*************************************************************************
  *
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- * 
+ *
  * Copyright 2000, 2010 Oracle and/or its affiliates.
  *
  * OpenOffice.org - a multi-platform office productivity suite
@@ -169,7 +169,7 @@ public:
     bool nextSlide();
     bool previousSlide();
 
-    void displayCurrentSlide( const Reference< XSlideShow >& xShow, 
+    void displayCurrentSlide( const Reference< XSlideShow >& xShow,
                               const Reference< XDrawPagesSupplier>& xDrawPages,
                               const bool bSkipAllMainSequenceEffects );
 
@@ -405,7 +405,7 @@ sal_Int32 AnimationSlideController::getNextSlideIndex() const
     case FROM:
     case CUSTOM:
         return mnHiddenSlideNumber == -1 ? mnCurrentSlideIndex + 1 : mnCurrentSlideIndex;
-        
+
     default:
     case PREVIEW:
         return -1;
@@ -468,7 +468,7 @@ bool AnimationSlideController::previousSlide()
     return jumpToSlideIndex( getPreviousSlideIndex() );
 }
 
-void AnimationSlideController::displayCurrentSlide( const Reference< XSlideShow >& xShow, 
+void AnimationSlideController::displayCurrentSlide( const Reference< XSlideShow >& xShow,
                                                     const Reference< XDrawPagesSupplier>& xDrawPages,
                                                     const bool bSkipAllMainSequenceEffects )
 {
@@ -479,7 +479,7 @@ void AnimationSlideController::displayCurrentSlide( const Reference< XSlideShow
         Reference< XDrawPage > xSlide;
         Reference< XAnimationNode > xAnimNode;
         ::std::vector<PropertyValue> aProperties;
-        
+
         const sal_Int32 nNextSlideNumber = getNextSlideNumber();
         if( getSlideAPI( nNextSlideNumber, xSlide, xAnimNode )  )
         {
@@ -517,7 +517,7 @@ void AnimationSlideController::displayCurrentSlide( const Reference< XSlideShow
         Sequence< PropertyValue > aPropertySequence (aProperties.size());
         for (int nIndex=0,nCount=aProperties.size();nIndex<nCount; ++nIndex)
             aPropertySequence[nIndex] = aProperties[nIndex];
-        
+
         if( getSlideAPI( nCurrentSlideNumber, xSlide, xAnimNode ) )
             xShow->displaySlide( xSlide, xDrawPages, xAnimNode, aPropertySequence );
     }
@@ -577,7 +577,7 @@ SlideshowImpl::SlideshowImpl( const Reference< XPresentation2 >& xPresentation,
         mpOldActiveWindow = mpViewShell->GetActiveWindow();
 
     maUpdateTimer.SetTimeoutHdl(LINK(this, SlideshowImpl, updateHdl));
-    
+
     maDeactivateTimer.SetTimeoutHdl(LINK(this, SlideshowImpl, deactivateHdl));
     maDeactivateTimer.SetTimeout( 20 );
 
@@ -683,7 +683,7 @@ void SAL_CALL SlideshowImpl::disposing()
         mpViewShell->SetActiveWindow(mpOldActiveWindow);
         mpShowWindow->SetViewShell( NULL );
     }
-    
+
     if( mpView )
         mpView->InvalidateAllWin();
 
@@ -731,7 +731,7 @@ void SAL_CALL SlideshowImpl::disposing()
         delete mpTimeButton;
         mpTimeButton = 0;
     }
-    
+
     if( mpShowWindow )
         mpShowWindow->Hide();
 
@@ -775,13 +775,13 @@ void SAL_CALL SlideshowImpl::disposing()
     mbDisposed = true;
 }
 
-bool SlideshowImpl::startPreview( 
+bool SlideshowImpl::startPreview(
         const Reference< XDrawPage >& xDrawPage,
         const Reference< XAnimationNode >& xAnimationNode,
         ::Window* pParent )
 {
     bool bRet = false;
-    
+
     try
     {
         const Reference<lang::XServiceInfo> xServiceInfo( xDrawPage, UNO_QUERY );
@@ -798,7 +798,7 @@ bool SlideshowImpl::startPreview(
                 }
             }
         }
-        
+
         mxPreviewDrawPage = xDrawPage;
         mxPreviewAnimationNode = xAnimationNode;
         meAnimationMode = ANIMATIONMODE_PREVIEW;
@@ -901,7 +901,7 @@ bool SlideshowImpl::startPreview(
 bool SlideshowImpl::startShow( PresentationSettingsEx* pPresSettings )
 {
     const rtl::Reference<SlideshowImpl> this_(this);
-    
+
     DBG_ASSERT( !mxShow.is(), "sd::SlideshowImpl::startShow(), called twice!" );
     if( mxShow.is() )
         return true;
@@ -910,7 +910,7 @@ bool SlideshowImpl::startShow( PresentationSettingsEx* pPresSettings )
         return false;
 
     bool bRet = false;
-    
+
     try
     {
         if( pPresSettings )
@@ -1096,14 +1096,14 @@ bool SlideshowImpl::startShow( PresentationSettingsEx* pPresSettings )
                     OUString( RTL_CONSTASCII_USTRINGPARAM("AdvanceOnClick") ),
                     -1, Any( ! (maPresSettings.mbLockedPages != sal_False) ),
                     beans::PropertyState_DIRECT_VALUE ) );
-            
+
             aProperties.push_back(
                 beans::PropertyValue(
                     OUString( RTL_CONSTASCII_USTRINGPARAM("ImageAnimationsAllowed") ),
                     -1, Any( maPresSettings.mbAnimationAllowed != sal_False ),
                     beans::PropertyState_DIRECT_VALUE ) );
 
-            const sal_Bool bZOrderEnabled( 
+            const sal_Bool bZOrderEnabled(
                 SD_MOD()->GetSdOptions( mpDoc->GetDocumentType() )->IsSlideshowRespectZOrder() );
             aProperties.push_back(
                 beans::PropertyValue(
@@ -1111,19 +1111,19 @@ bool SlideshowImpl::startShow( PresentationSettingsEx* pPresSettings )
                     -1, Any( bZOrderEnabled == sal_False ),
                     beans::PropertyState_DIRECT_VALUE ) );
 
-/*        
+/*
             aProperties.push_back(
                 beans::PropertyValue(
                     OUString( RTL_CONSTASCII_USTRINGPARAM("MouseVisible") ),
                     -1, Any( maPresSettings.mbMouseVisible != sal_False ),
                     beans::PropertyState_DIRECT_VALUE ) );
-*/		
+*/
             aProperties.push_back(
                 beans::PropertyValue(
                     OUString( RTL_CONSTASCII_USTRINGPARAM("ForceManualAdvance") ),
                     -1, Any( maPresSettings.mbManual != sal_False ),
                     beans::PropertyState_DIRECT_VALUE ) );
-            
+
             if( maPresSettings.mbMouseAsPen )
              {
                 aProperties.push_back(
@@ -1133,7 +1133,7 @@ bool SlideshowImpl::startShow( PresentationSettingsEx* pPresSettings )
                         -1, Any( static_cast<sal_Int32>(0x00000000L) ),
                         beans::PropertyState_DIRECT_VALUE ) );
             }
-            
+
             if (mbRehearseTimings) {
                 aProperties.push_back(
                     beans::PropertyValue(
@@ -1142,7 +1142,7 @@ bool SlideshowImpl::startShow( PresentationSettingsEx* pPresSettings )
             }
 
             bRet = startShowImpl( Sequence<beans::PropertyValue>(
-                                      &aProperties[0], aProperties.size() ) ); 
+                                      &aProperties[0], aProperties.size() ) );
 
         }
 
@@ -1168,10 +1168,10 @@ bool SlideshowImpl::startShowImpl( const Sequence< beans::PropertyValue >& aProp
     try
     {
         mxShow = Reference< XSlideShow >( createSlideShow(), UNO_QUERY_THROW );
-        mxView = mxView.createFromQuery( new SlideShowView( 
-                                             *mpShowWindow, 
-                                             mpDoc, 
-                                             meAnimationMode, 
+        mxView = mxView.createFromQuery( new SlideShowView(
+                                             *mpShowWindow,
+                                             mpDoc,
+                                             meAnimationMode,
                                              this,
                                              maPresSettings.mbFullScreen) );
 
@@ -1375,7 +1375,7 @@ void SlideshowImpl::registerShapeEvents( Reference< XShapes >& xShapes ) throw(
             Reference< XPropertySet > xSet( xShape, UNO_QUERY );
             if( !xSet.is() )
                 continue;
-            
+
             Reference< XPropertySetInfo > xSetInfo( xSet->getPropertySetInfo() );
             if( !xSetInfo.is() || !xSetInfo->hasPropertyByName( msOnClick ) )
                 continue;
@@ -1440,7 +1440,7 @@ void SlideshowImpl::displayCurrentSlide (const bool bSkipAllMainSequenceEffects)
 
     if( mpSlideController.get() && mxShow.is() )
     {
-        Reference< XDrawPagesSupplier > xDrawPages( mpDoc->getUnoModel(), 
+        Reference< XDrawPagesSupplier > xDrawPages( mpDoc->getUnoModel(),
                                                     UNO_QUERY_THROW );
         mpSlideController->displayCurrentSlide( mxShow, xDrawPages, bSkipAllMainSequenceEffects );
         registerShapeEvents(mpSlideController->getCurrentSlideNumber());
@@ -1919,7 +1919,7 @@ sal_Int32 SlideshowImpl::updateSlideShow (void)
         double fUpdate = 0.0;
         if( !xShow->update(fUpdate) )
             fUpdate = -1.0;
-        
+
         if (mxShow.is() && (fUpdate >= 0.0))
         {
             if (::basegfx::fTools::equalZero(fUpdate))
@@ -1945,7 +1945,7 @@ sal_Int32 SlideshowImpl::updateSlideShow (void)
                 // too high (only then conversion to milliseconds and long
                 // integer may lead to zero value.)
                 OSL_ASSERT(static_cast<ULONG>(fUpdate * 1000.0) > 0);
-                
+
                 Application::EnableNoYieldMode(false);
                 Application::RemovePostYieldListener(LINK(this, SlideshowImpl, PostYieldListener));
 
@@ -2210,7 +2210,7 @@ IMPL_LINK( SlideshowImpl, ContextMenuHdl, void*, EMPTYARG )
     pMenu->EnableItem( CM_PEN_MODE, (maPresSettings.mbMouseAsPen));
     // Adding button to displau if in Erase Mode
     pMenu->EnableItem( CM_ERASE_MODE, (maPresSettings.mbMouseAsPen));
-#endif	
+#endif
 
     const ShowWindowMode eMode = mpShowWindow->GetShowWindowMode();
     pMenu->EnableItem( CM_NEXT_SLIDE, ( mpSlideController->getNextSlideIndex() != -1 ) );
@@ -2281,7 +2281,7 @@ IMPL_LINK( SlideshowImpl, ContextMenuHdl, void*, EMPTYARG )
 #ifdef ENABLE_PRESENTER_EXTRA_UI
 
     PopupMenu* pWidthMenu = pMenu->GetPopupMenu( CM_WIDTH_PEN);
-    
+
     // populate color width list
     if( pWidthMenu )
     {
@@ -2293,7 +2293,7 @@ IMPL_LINK( SlideshowImpl, ContextMenuHdl, void*, EMPTYARG )
         {
             sal_Int32 nIterator;
             double nWidth;
-                
+
             nWidth = 4.0;
             for( nIterator = 1; nIterator < 6; nIterator++)
             {
@@ -2317,18 +2317,18 @@ IMPL_LINK( SlideshowImpl, ContextMenuHdl, void*, EMPTYARG )
                     default:
                         break;
                 }
-                    
+
                 pWidthMenu->EnableItem( (USHORT)(CM_WIDTH_PEN + nIterator), TRUE);
                 if( nWidth ==  mdUserPaintStrokeWidth)
                     pWidthMenu->CheckItem( (USHORT)(CM_WIDTH_PEN + nIterator) );
-                
+
             }
         }
     }
 
 
     PopupMenu* pEraseWidthMenu = pMenu->GetPopupMenu( CM_ERASE_INK_PEN);
-        
+
     // populate eraser width list
     if( pEraseWidthMenu )
     {
@@ -2340,7 +2340,7 @@ IMPL_LINK( SlideshowImpl, ContextMenuHdl, void*, EMPTYARG )
         {
             sal_Int32 nEIterator;
             double nEWidth;
-            
+
             nEWidth = 100.0;
             for( nEIterator = 1; nEIterator < 6; nEIterator++)
             {
@@ -2364,15 +2364,15 @@ IMPL_LINK( SlideshowImpl, ContextMenuHdl, void*, EMPTYARG )
                     default:
                         break;
                 }
-                
+
                 pEraseWidthMenu->EnableItem( (USHORT)(CM_ERASE_INK_PEN + nEIterator), TRUE);
                 if( nEWidth ==  mnEraseInkSize)
                     pEraseWidthMenu->CheckItem( (USHORT)(CM_ERASE_INK_PEN + nEIterator) );
         if( mbSwitchPenMode )
-           pMenu->CheckItem( (USHORT)(CM_PEN_MODE));           		
+           pMenu->CheckItem( (USHORT)(CM_PEN_MODE));
         if( mbSwitchEraserMode )
-           pMenu->CheckItem( (USHORT)(CM_ERASE_MODE));             
-  
+           pMenu->CheckItem( (USHORT)(CM_ERASE_MODE));
+
             }
         }
     }
@@ -2449,7 +2449,7 @@ IMPL_LINK( SlideshowImpl, ContextMenuSelectHdl, Menu *, pMenu )
                     ::Color aColor( mnUserPaintColor );
                     SvColorDialog aColorDlg( mpShowWindow);
                     aColorDlg.SetColor( aColor );
-                    
+
                     if (aColorDlg.Execute() )
                     {
                         aColor = aColorDlg.GetColor();
@@ -2459,45 +2459,45 @@ IMPL_LINK( SlideshowImpl, ContextMenuSelectHdl, Menu *, pMenu )
                     mbWasPaused = false;
                 }
                 break;
-                        
+
             case CM_WIDTH_PEN_VERY_THIN:
                 {
                     setPenWidth(4.0);
                     mbWasPaused = false;
                 }
                 break;
-                            
+
             case CM_WIDTH_PEN_THIN:
                 {
                     setPenWidth(100.0);
                     mbWasPaused = false;
                 }
                 break;
-                            
+
             case CM_WIDTH_PEN_NORMAL:
                 {
                     setPenWidth(150.0);
                     mbWasPaused = false;
                 }
                 break;
-                       
+
             case CM_WIDTH_PEN_THICK:
                 {
                     setPenWidth(200.0);
                     mbWasPaused = false;
                 }
                 break;
-                        
+
             case CM_WIDTH_PEN_VERY_THICK:
                 {
                     setPenWidth(400.0);
                     mbWasPaused = false;
                 }
-                break;                
+                break;
             case CM_ERASE_ALLINK:
                 {
                     setEraseAllInk(true);
-                    mbWasPaused = false;	
+                    mbWasPaused = false;
                 }
                 break;
             case CM_PEN_MODE:
@@ -2518,7 +2518,7 @@ IMPL_LINK( SlideshowImpl, ContextMenuSelectHdl, Menu *, pMenu )
                     mbWasPaused = false;
                 }
                 break;
-                       
+
             case CM_ERASE_INK_PEN_THIN:
                 {
                     setEraseInk(200);
@@ -2532,7 +2532,7 @@ IMPL_LINK( SlideshowImpl, ContextMenuSelectHdl, Menu *, pMenu )
                     mbWasPaused = false;
                 }
                 break;
-                     
+
             case CM_ERASE_INK_PEN_THICK:
                 {
                     setEraseInk(400);
@@ -2544,7 +2544,7 @@ IMPL_LINK( SlideshowImpl, ContextMenuSelectHdl, Menu *, pMenu )
                     setEraseInk(500);
                     mbWasPaused = false;
                 }
-                break;  
+                break;
         }
 #endif
 
@@ -2575,7 +2575,7 @@ IMPL_LINK( SlideshowImpl, ContextMenuSelectHdl, Menu *, pMenu )
                 break;
         }
     }
-    
+
     return 0;
 }
 
@@ -2587,11 +2587,11 @@ Reference< XSlideShow > SlideshowImpl::createSlideShow() const
 
     try
     {
-        Reference< lang::XMultiServiceFactory > xFactory( 
+        Reference< lang::XMultiServiceFactory > xFactory(
             ::comphelper::getProcessServiceFactory(),
             UNO_QUERY_THROW );
 
-        Reference< XInterface > xInt( xFactory->createInstance( 
+        Reference< XInterface > xInt( xFactory->createInstance(
                 OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.presentation.SlideShow")) ) );
 
         xShow.set( xInt, UNO_QUERY_THROW );
@@ -2626,7 +2626,7 @@ void SlideshowImpl::createSlideList( bool bAll, bool bStartWithActualSlide, cons
             pCustomShow = NULL;
 
         // create animation slide controller
-        AnimationSlideController::Mode eMode = 
+        AnimationSlideController::Mode eMode =
             ( pCustomShow && pCustomShow->Count() ) ? AnimationSlideController::CUSTOM :
                 (bAll ? AnimationSlideController::ALL : AnimationSlideController::FROM);
 
@@ -2854,7 +2854,7 @@ void SlideshowImpl::setActiveXToolbarsVisible( sal_Bool bVisible )
                                 >>= xLayoutManager )
                       && xLayoutManager.is() )
                     {
-                        xLayoutManager->setVisible( bVisible );                            
+                        xLayoutManager->setVisible( bVisible );
                     }
                 }
                 catch( uno::Exception& )
@@ -3017,7 +3017,7 @@ void SlideshowImpl::setAutoSaveState( bool bOn)
         util::URL aURL;
         aURL.Complete = OUString(RTL_CONSTASCII_USTRINGPARAM("vnd.sun.star.autorecovery:/setAutoSaveState"));
         xParser->parseStrict(aURL);
-        
+
         Sequence< beans::PropertyValue > aArgs(1);
         aArgs[0].Name = OUString(RTL_CONSTASCII_USTRINGPARAM("AutoSaveState"));
         aArgs[0].Value <<= bOn ? sal_True : sal_False;
@@ -3088,7 +3088,7 @@ Reference< XDrawPage > SAL_CALL SlideshowImpl::getSlideByIndex(::sal_Int32 Index
 {
     if( (mpSlideController.get() == 0 ) || (Index < 0) || (Index >= mpSlideController->getSlideIndexCount() ) )
         throw IndexOutOfBoundsException();
-    
+
     return mpSlideController->getSlideByNumber( mpSlideController->getSlideNumber( Index ) );
 }
 
@@ -3169,11 +3169,11 @@ void SAL_CALL SlideshowImpl::setUsePen( sal_Bool bMouseAsPen ) throw (RuntimeExc
         Any aValueWidth;
         if( maPresSettings.mbMouseAsPen )
             aValueWidth <<= mdUserPaintStrokeWidth;
-         
+
         beans::PropertyValue aPenPropWidth;
         aPenPropWidth.Name = OUString( RTL_CONSTASCII_USTRINGPARAM( "UserPaintStrokeWidth" ));
         aPenPropWidth.Value = aValueWidth;
-         
+
         mxShow->setProperty( aPenPropWidth );
 
     // for Pen Mode
@@ -3182,7 +3182,7 @@ void SAL_CALL SlideshowImpl::setUsePen( sal_Bool bMouseAsPen ) throw (RuntimeExc
             aValueSwitchPenMode <<= mbSwitchPenMode;
         beans::PropertyValue aPenPropSwitchPenMode;
         aPenPropSwitchPenMode.Name = OUString( RTL_CONSTASCII_USTRINGPARAM( "SwitchPenMode" ));
-        aPenPropSwitchPenMode.Value = aValueSwitchPenMode;         
+        aPenPropSwitchPenMode.Value = aValueSwitchPenMode;
         mxShow->setProperty( aPenPropSwitchPenMode );
 
     //for EraseAllInk :
@@ -3231,7 +3231,7 @@ void SAL_CALL SlideshowImpl::setUseEraser( sal_Bool bMouseAsPen ) throw (Runtime
             aValueSwitchEraserMode <<= mbSwitchEraserMode;
         beans::PropertyValue aPenPropSwitchEraserMode;
         aPenPropSwitchEraserMode.Name = OUString( RTL_CONSTASCII_USTRINGPARAM( "SwitchEraserMode" ));
-        aPenPropSwitchEraserMode.Value = aValueSwitchEraserMode;         
+        aPenPropSwitchEraserMode.Value = aValueSwitchEraserMode;
         mxShow->setProperty( aPenPropSwitchEraserMode );
     }
     catch( Exception& e )
@@ -3267,7 +3267,7 @@ void SAL_CALL SlideshowImpl::setPenWidth( double dStrokeWidth ) throw (RuntimeEx
 }
 #endif
 // --------------------------------------------------------------------
-    
+
 sal_Int32 SAL_CALL SlideshowImpl::getPenColor() throw (RuntimeException)
 {
     SolarMutexGuard aSolarGuard;
@@ -3295,7 +3295,7 @@ void SAL_CALL SlideshowImpl::setPenMode( bool bSwitchPenMode ) throw (RuntimeExc
 {
     SolarMutexGuard aSolarGuard;
     mbSwitchPenMode = bSwitchPenMode;
-    
+
     if(mbSwitchPenMode == true){
         mbSwitchEraserMode = false;
     }else{
@@ -3303,13 +3303,13 @@ void SAL_CALL SlideshowImpl::setPenMode( bool bSwitchPenMode ) throw (RuntimeExc
     }
     if( maPresSettings.mbMouseAsPen )
         setUsePen( sal_True ); // Switch to Pen Mode
-    
+
 }
 
 void SAL_CALL SlideshowImpl::setEraserMode(bool bSwitchEraserMode ) throw (RuntimeException)
 {
     SolarMutexGuard aSolarGuard;
-    mbSwitchEraserMode = bSwitchEraserMode;	
+    mbSwitchEraserMode = bSwitchEraserMode;
     if(mbSwitchEraserMode = true){
         mbSwitchPenMode = false;
     }else{
@@ -3318,7 +3318,7 @@ void SAL_CALL SlideshowImpl::setEraserMode(bool bSwitchEraserMode ) throw (Runti
 
     if( maPresSettings.mbMouseAsPen )
         setUseEraser( sal_True ); // Switch to EraseMode
-    
+
 }
 
 
@@ -3334,14 +3334,14 @@ void SAL_CALL SlideshowImpl::setEraseAllInk( bool bEraseAllInk ) throw (RuntimeE
         setUsePen( sal_True ); // update erase all ink bool
 }
 
-    
+
 void SAL_CALL SlideshowImpl::setEraseInk( sal_Int32 nEraseInkSize ) throw (RuntimeException)
 {
     SolarMutexGuard aSolarGuard;
     mnEraseInkSize=nEraseInkSize;
     mbSwitchPenMode = false;
     mbSwitchEraserMode = true;
-    if( maPresSettings.mbMouseAsPen )			
+    if( maPresSettings.mbMouseAsPen )
         setUseEraser( sal_True ); // update erase ink size
 }
 #endif
@@ -3696,7 +3696,7 @@ Reference< XSlideShow > SAL_CALL SlideshowImpl::getSlideShow() throw (RuntimeExc
 }
 
 // --------------------------------------------------------------------
-    
+
 
 PresentationSettingsEx::PresentationSettingsEx( const PresentationSettingsEx& r )
 : PresentationSettings( r )
diff --git a/sd/source/ui/view/outlview.cxx b/sd/source/ui/view/outlview.cxx
index dd7434d..58c59ea 100644
--- a/sd/source/ui/view/outlview.cxx
+++ b/sd/source/ui/view/outlview.cxx
@@ -2,7 +2,7 @@
 /*************************************************************************
  *
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- * 
+ *
  * Copyright 2000, 2010 Oracle and/or its affiliates.
  *
  * OpenOffice.org - a multi-platform office productivity suite
@@ -120,7 +120,6 @@ OutlineView::OutlineView( DrawDocShell* pDocSh, ::Window* pWindow, OutlineViewSh
 , mnPagesProcessed(0)
 , mbFirstPaint(TRUE)
 , mpProgress(NULL)
-, mbHighContrastMode( false )
 , maDocColor( COL_WHITE )
 , mnPageNumberWidthPixel( 0 )
 , maLRSpaceItem( 0, 0, 2000, 0, EE_PARA_OUTLLRSPACE )
@@ -277,7 +276,7 @@ void OutlineView::Paint(const Rectangle& rRect, ::sd::Window* pWin)
 }
 
 void OutlineView::InvalidateSlideNumberArea()
-{   
+{
 /*
     for( sal_Int16 nView = 0; nView < MAX_OUTLINERVIEWS; ++nView )
     {
@@ -1281,7 +1280,7 @@ void OutlineView::FillOutliner()
 
         if (!pTO) // if no subtile found, try outline
             pTO = GetOutlineTextObject(pPage);
-        
+
         if(pTO && !(pTO->IsEmptyPresObj())) // found some text
         {
             OutlinerParaObject* pOPO = pTO->GetOutlinerParaObject();
@@ -1609,17 +1608,6 @@ sal_uInt16 OutlineView::GetScriptType() const
 
 void OutlineView::onUpdateStyleSettings( bool bForceUpdate /* = false */ )
 {
-    const bool bHighContrastMode = Application::GetSettings().GetStyleSettings().GetHighContrastMode() != 0;
-    if( bForceUpdate || (mbHighContrastMode != bHighContrastMode) )
-    {
-        if( mpOutliner )
-        {
-            mpOutliner->ForceAutoColor( bHighContrastMode );
-        }
-        mbHighContrastMode = bHighContrastMode;
-
-    }
-
     svtools::ColorConfig aColorConfig;
     const Color aDocColor( aColorConfig.GetColorValue( svtools::DOCCOLOR ).nColor );
     if( bForceUpdate || (maDocColor != aDocColor) )


More information about the Libreoffice-commits mailing list