diff options
author | Michael Stahl <mst@openoffice.org> | 2010-01-05 16:37:41 +0100 |
---|---|---|
committer | Michael Stahl <mst@openoffice.org> | 2010-01-05 16:37:41 +0100 |
commit | 733b831970204059b9d89eff203551d6d3bf4bbe (patch) | |
tree | 4ba13335cba78b98026eedee44ebf47da129bfa9 /sw/source/ui/docvw/edtwin.cxx | |
parent | c941bb6a756a79a5c0ae1d903cc50399d8200812 (diff) |
swunolocking1: swtypes.hxx: rename frame anchor types
enum RndStdIds: rename frame anchor types (FLY_*) to be more intuitive.
[note the completely ridiculous number of files that care about anchor types]
Diffstat (limited to 'sw/source/ui/docvw/edtwin.cxx')
-rw-r--r-- | sw/source/ui/docvw/edtwin.cxx | 25 |
1 files changed, 9 insertions, 16 deletions
diff --git a/sw/source/ui/docvw/edtwin.cxx b/sw/source/ui/docvw/edtwin.cxx index 7d8e38443ca0..cdaa09f0a549 100644 --- a/sw/source/ui/docvw/edtwin.cxx +++ b/sw/source/ui/docvw/edtwin.cxx @@ -50,16 +50,12 @@ #include <sot/storage.hxx> #include <svtools/macitem.hxx> #include <svtools/securityoptions.hxx> -#ifndef __SBX_SBXVARIABLE_HXX //autogen #include <basic/sbxvar.hxx> -#endif #include <svtools/ctloptions.hxx> #include <basic/sbx.hxx> #include <svtools/eitem.hxx> #include <svtools/stritem.hxx> -#ifndef _SFX_CLIENTSH_HXX #include <sfx2/ipclient.hxx> -#endif #include <sfx2/viewfrm.hxx> #include <sfx2/request.hxx> #include <sfx2/bindings.hxx> @@ -69,9 +65,6 @@ #include <svx/langitem.hxx> #include <svx/htmlmode.hxx> #include <svx/svdview.hxx> -//#ifndef _SVDVMARK_HXX //autogen -//#include <svx/svdvmark.hxx> -//#endif #include <svx/svdhdl.hxx> #include <svx/svdoutl.hxx> #include <svx/editeng.hxx> @@ -128,12 +121,8 @@ #include <breakit.hxx> #include <checkit.hxx> -#ifndef _HELPID_H #include <helpid.h> -#endif -#ifndef _CMDID_H #include <cmdid.h> -#endif #ifndef _DOCVW_HRC #include <docvw.hrc> #endif @@ -1019,7 +1008,7 @@ void SwEditWin::ChangeFly( BYTE nDir, BOOL bWeb ) default: ASSERT( TRUE, "ChangeFly: Unknown direction." ); } BOOL bSet = FALSE; - if( FLY_IN_CNTNT == eAnchorId && ( nDir % 2 ) ) + if ((FLY_AS_CHAR == eAnchorId) && ( nDir % 2 )) { long aDiff = aTmp.Top() - aRefPoint.Y(); if( aDiff > 0 ) @@ -1064,7 +1053,8 @@ void SwEditWin::ChangeFly( BYTE nDir, BOOL bWeb ) aSet.Put( aVert ); bSet = TRUE; } - if( bWeb && FLY_AT_CNTNT == eAnchorId && ( nDir==MOVE_LEFT_SMALL || nDir==MOVE_RIGHT_BIG ) ) + if (bWeb && (FLY_AT_PARA == eAnchorId) + && ( nDir==MOVE_LEFT_SMALL || nDir==MOVE_RIGHT_BIG )) { SwFmtHoriOrient aHori( (SwFmtHoriOrient&)aSet.Get(RES_HORI_ORIENT) ); sal_Int16 eNew; @@ -1091,11 +1081,13 @@ void SwEditWin::ChangeFly( BYTE nDir, BOOL bWeb ) rSh.StartAllAction(); if( bSet ) rSh.SetFlyFrmAttr( aSet ); - BOOL bSetPos = FLY_IN_CNTNT != eAnchorId; + BOOL bSetPos = (FLY_AS_CHAR != eAnchorId); if(bSetPos && bWeb) { - if(FLY_PAGE != eAnchorId) + if (FLY_AT_PAGE != eAnchorId) + { bSetPos = FALSE; + } else { bSetPos = (::GetHtmlMode(rView.GetDocShell()) & HTMLMODE_SOME_ABS_POS) ? @@ -1185,7 +1177,8 @@ void SwEditWin::ChangeDrawing( BYTE nDir ) BOOL bDummy; const bool bVertAnchor = rSh.IsFrmVertical( TRUE, bDummy ); const bool bHoriMove = !bVertAnchor == !( nDir % 2 ); - const bool bMoveAllowed = !bHoriMove || rSh.GetAnchorId() != FLY_IN_CNTNT; + const bool bMoveAllowed = + !bHoriMove || (rSh.GetAnchorId() != FLY_AS_CHAR); if ( bMoveAllowed ) { // <-- |