Tag: cws_src680_rpt23fix02
User: oj      
Date: 2007-07-31 12:39:22+0000
Modified:
   dba/reportdesign/source/ui/report/ViewsWindow.cxx

Log:
 i79963 overlap check not for shapes

File Changes:

Directory: /dba/reportdesign/source/ui/report/
==============================================

File [changed]: ViewsWindow.cxx
Url: 
http://dba.openoffice.org/source/browse/dba/reportdesign/source/ui/report/ViewsWindow.cxx?r1=1.2.4.3&r2=1.2.4.4
Delta lines:  +90 -83
---------------------
--- ViewsWindow.cxx     2007-07-30 05:36:12+0000        1.2.4.3
+++ ViewsWindow.cxx     2007-07-31 12:39:20+0000        1.2.4.4
@@ -126,7 +126,8 @@
                     aNewRect.Move(_nXMov,_nYMov);
                     break;
             }
-                
+            if ( dynamic_cast<OUnoObject*>(_pObj) )
+            {                
             pOverlappedObj = 
isOver(aNewRect,*_pObj->GetPage(),*_pView,true,_pObj);
             if ( pOverlappedObj && _pObj != pOverlappedObj )
             {
@@ -210,6 +211,7 @@
             else
                 pOverlappedObj = NULL;
         }
+        }
         while ( pOverlappedObj && bMoveAllowed );
        }
     return bMoveAllowed;
@@ -872,6 +874,7 @@
 // 
-----------------------------------------------------------------------------
 void OViewsWindow::collectBoundResizeRect(const TRectangleMap& 
_rSortRectangles,sal_Int32 _nControlModification,bool _bAlignAtSection, bool 
_bBoundRects,Rectangle& _rBound,Rectangle& _rResize)
 {
+    bool bOnlyOnce = false;
     TRectangleMap::const_iterator aRectIter = _rSortRectangles.begin();
     TRectangleMap::const_iterator aRectEnd = _rSortRectangles.end();
        for (;aRectIter != aRectEnd ; ++aRectIter)
@@ -909,6 +912,9 @@
         {
                    if ( _bAlignAtSection || _rSortRectangles.size() == 1 )
             { // einzelnes Obj an der Seite ausrichten
+                if ( ! bOnlyOnce )
+                {
+                    bOnlyOnce = true;
                 OReportSection* pReportSection = 
aRectIter->second.second->getSectionWindow();
                        uno::Reference< report::XSection> xSection = 
pReportSection->getSection();
                 try
@@ -920,6 +926,7 @@
                 }
                 catch(uno::Exception){}
                    } 
+                   } 
             else 
             {
                            if (_bBoundRects) 
@@ -1023,7 +1030,7 @@
                 TRectangleMap::iterator aInterSectRectIter = 
aSortRectangles.begin();
                 for (; aInterSectRectIter != aRectIter; ++aInterSectRectIter)
                 {
-                    if ( pView == aInterSectRectIter->second.second )
+                    if ( pView == aInterSectRectIter->second.second && 
dynamic_cast<OUnoObject*>(aInterSectRectIter->second.first) )
                     {
                         SdrObject* pPreviousObj = 
aInterSectRectIter->second.first;
                         Rectangle aIntersectRect = 
aTest.GetIntersection(_bBoundRects ? pPreviousObj->GetCurrentBoundRect() : 
pPreviousObj->GetSnapRect());




---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to