Commits

obo  committed 2b574f8

CWS-TOOLING: integrate CWS impress167
2009-02-02 16:32:46 +0100 sj r267276 : build problem, removing build dependency to vcl
2009-01-30 16:45:22 +0100 sj r267210 : CWS-TOOLING: rebase CWS impress167 to trunk@267171 (milestone: DEV300:m41)
2009-01-23 16:14:11 +0100 sj r266833 : #98331# fixed: crop information is not saved and not read on loading
2009-01-23 10:45:11 +0100 af r266780 : #158592# Made processing of slidesorter queue entries more robust.
2009-01-23 09:58:16 +0100 af r266773 : #i93848# Fixed termination of timer thread.

  • Participants
  • Parent commits ead5500

Comments (0)

Files changed (7)

File sd/source/ui/slidesorter/cache/SlsQueueProcessor.cxx

     CacheKey aKey,
     const RequestPriorityClass ePriorityClass)
 {
-    const SdrPage* pPage = mpCacheContext->GetPage(aKey);
-    SSCD_SET_STATUS(pPage,RENDERING);
-    
-#ifdef VERBOSE
-    OSL_TRACE ("processing request for page %d with priority class %d",
-        (pPage->GetPageNum()-1)/2,
-        ePriorityClass);
-#endif
     try
     {
         ::osl::MutexGuard aGuard (maMutex);
+
         // Create a new preview bitmap and store it in the cache.
-        if (mpCache.get() != NULL)
+        if (mpCache.get() != NULL
+            && mpCacheContext.get() != NULL)
         {
-            const SdPage* pSdPage = dynamic_cast<const SdPage*>(pPage);
+            const SdPage* pSdPage = dynamic_cast<const SdPage*>(mpCacheContext->GetPage(aKey));
             if (pSdPage != NULL)
             {
                 const ::boost::shared_ptr<BitmapEx> pPreview (
                     maBitmapFactory.CreateBitmap(*pSdPage, maPreviewSize));
                 mpCache->SetBitmap (
-                    pPage,
+                    pSdPage,
                     pPreview,
                     ePriorityClass!=NOT_VISIBLE);
 
                 // Initiate a repaint of the new preview.
                 mpCacheContext->NotifyPreviewCreation(aKey, pPreview);
-                
-                SSCD_SET_STATUS(pPage,NONE);
             }
         }
     }
     catch (::com::sun::star::uno::RuntimeException aException)
     {
+        (void) aException;
         OSL_ASSERT("RuntimeException caught in QueueProcessor");
-        (void) aException;
     }
     catch (::com::sun::star::uno::Exception aException)
     {
+        (void) aException;
         OSL_ASSERT("Exception caught in QueueProcessor");
-        (void) aException;
     }
 }
 

File sd/source/ui/slidesorter/cache/SlsQueueProcessor.hxx

 #include "view/SlsPageObjectViewObjectContact.hxx"
 #include "tools/IdleDetection.hxx"
 #include "SlsBitmapCache.hxx"
-#include "taskpane/SlideSorterCacheDisplay.hxx"
 #include "sdpage.hxx"
 #include "Window.hxx"
  
 #include <boost/function.hpp>
 
 
-// Uncomment the define below to have some more OSL_TRACE messages.
-#ifdef DEBUG
-//#define VERBOSE
-#endif
-
 namespace sd { namespace slidesorter { namespace view {
 class SlideSorterView;
 } } }

File sd/source/ui/slidesorter/view/SlsViewCacheContext.cxx

     const model::SharedPageDescriptor pDescriptor (GetDescriptor(aKey));
     if (pDescriptor.get() != NULL)
     {
-        // use direct view-invalidate here and no ActionChanged() at the VC
-        // ince the VC is a PageObjectViewObjectContact and in it's ActionChanged()
-        // implementation invalidates the cache entry again
-        pDescriptor->GetViewObjectContact()->GetObjectContact().InvalidatePartOfView(
-            pDescriptor->GetViewObjectContact()->getObjectRange());
+        // Use direct view-invalidate here and no ActionChanged() at the VC
+        // since the VC is a PageObjectViewObjectContact and in its ActionChanged()
+        // implementation invalidates the cache entry again.
+        view::PageObjectViewObjectContact* pContact = pDescriptor->GetViewObjectContact();
+        if (pContact != NULL)
+            pContact->GetObjectContact().InvalidatePartOfView(pContact->getObjectRange());
     }
     else
     {

File sdext/source/pdfimport/misc/pdfihelper.cxx

 #include "pdfihelper.hxx"
 
 #include <rtl/ustrbuf.hxx>
-#include <vcl/canvastools.hxx>
+#include <basegfx/numeric/ftools.hxx>
 
 using namespace pdfi;
 using namespace com::sun::star;
 rtl::OUString pdfi::getColorString( const rendering::ARGBColor& rCol )
 {
     rtl::OUStringBuffer aBuf( 7 );
-    const sal_uInt8 nRed  ( vcl::unotools::toByteColor(rCol.Red)   );
-    const sal_uInt8 nGreen( vcl::unotools::toByteColor(rCol.Green) );
-    const sal_uInt8 nBlue ( vcl::unotools::toByteColor(rCol.Blue)  );
+    const sal_uInt8 nRed  ( sal::static_int_cast<sal_Int8>( basegfx::fround( rCol.Red * 255.0 ) ) );
+    const sal_uInt8 nGreen( sal::static_int_cast<sal_Int8>( basegfx::fround( rCol.Green * 255.0 ) ) );
+    const sal_uInt8 nBlue ( sal::static_int_cast<sal_Int8>( basegfx::fround( rCol.Blue * 255.0 ) ) );
     aBuf.append( sal_Unicode('#') );
     if( nRed < 10 )
         aBuf.append( sal_Unicode('0') );

File sdext/source/presenter/PresenterPaneBorderPainter.hxx

 #ifndef SDEXT_PRESENTER_PRESENTER_PANE_BORDER_PAINTER_HXX
 #define SDEXT_PRESENTER_PRESENTER_PANE_BORDER_PAINTER_HXX
 
-#include <vcl/bitmap.hxx>
 #include <com/sun/star/uno/XComponentContext.hpp>
 #include <com/sun/star/awt/Rectangle.hpp>
 #include <com/sun/star/drawing/framework/XPaneBorderPainter.hpp>

File sdext/source/presenter/PresenterTimer.cxx

 {
 public:
     static ::boost::shared_ptr<TimerScheduler> Instance (void);
-    static void Release (void);
     static SharedTimerTask CreateTimerTask (
         const PresenterTimer::Task& rTask,
         const TimeValue& rDueTime,
     ::osl::Mutex maCurrentTaskMutex;
     SharedTimerTask mpCurrentTask;
 
+    static void Release (void);
+
     TimerScheduler (void);
     virtual ~TimerScheduler (void);
     class Deleter {public: void operator () (TimerScheduler* pScheduler) { delete pScheduler; } };
     friend class Deleter;
     
     virtual void SAL_CALL run (void);
+    virtual void SAL_CALL onTerminated (void);
 };
 
 
             mpCurrentTask.reset();
         }
     }
+}
 
+
+
+
+void SAL_CALL TimerScheduler::onTerminated (void)
+{
     Release();
 }
 

File xmloff/inc/xmloff/xmltypes.hxx

 #define XML_TYPE_NUMBER16_AUTO			(XML_TEXT_TYPES_START + 105)
 #define XML_TYPE_TEXT_SOFT_PAGE_BREAK   (XML_TEXT_TYPES_START + 106)
 #define XML_TYPE_TEXT_USE_SOFT_PAGE_BREAKS (XML_TEXT_TYPES_START + 107)
-#define XML_TYPE_TEXT_CLIP	(XML_TEXT_TYPES_START + 108)
-
-#define XML_TYPE_TEXT_OVERLINE_TYPE     (XML_TEXT_TYPES_START + 108)
-#define XML_TYPE_TEXT_OVERLINE_STYLE    (XML_TEXT_TYPES_START + 109)
-#define XML_TYPE_TEXT_OVERLINE_WIDTH    (XML_TEXT_TYPES_START + 110)
-#define XML_TYPE_TEXT_OVERLINE_COLOR    (XML_TEXT_TYPES_START + 111)
-#define XML_TYPE_TEXT_OVERLINE_HASCOLOR (XML_TEXT_TYPES_START + 112)
+#define XML_TYPE_TEXT_CLIP				(XML_TEXT_TYPES_START + 108)
+#define XML_TYPE_TEXT_OVERLINE_TYPE     (XML_TEXT_TYPES_START + 109)
+#define XML_TYPE_TEXT_OVERLINE_STYLE    (XML_TEXT_TYPES_START + 110)
+#define XML_TYPE_TEXT_OVERLINE_WIDTH    (XML_TEXT_TYPES_START + 111)
+#define XML_TYPE_TEXT_OVERLINE_COLOR    (XML_TEXT_TYPES_START + 112)
+#define XML_TYPE_TEXT_OVERLINE_HASCOLOR (XML_TEXT_TYPES_START + 113)
 
 #define XML_SCH_TYPES_START	(0x4 << XML_TYPE_APP_SHIFT)
 #define XML_PM_TYPES_START	(0x5 << XML_TYPE_APP_SHIFT)	// page master