diff options
author | Oliver Bolte <obo@openoffice.org> | 2004-01-20 11:57:11 +0000 |
---|---|---|
committer | Oliver Bolte <obo@openoffice.org> | 2004-01-20 11:57:11 +0000 |
commit | 3ddd1113923341384dffe3a6fd9c340d9c1b1c9c (patch) | |
tree | 88a7c7f056a843c4286e2a53ba5f11e6055a1e72 /sd | |
parent | 3c3de80a67bba2df6aa0f6bdaf5ba2f400a39047 (diff) |
INTEGRATION: CWS impress1 (1.3.262); FILE MERGED
2003/10/01 11:56:45 af 1.3.262.2: #111996# Renamed some include files.
2003/09/17 08:22:49 af 1.3.262.1: #111996# Transition to stacked sub-shells. Introduction of namespace sd.
Diffstat (limited to 'sd')
-rw-r--r-- | sd/source/ui/view/zoomlist.cxx | 52 |
1 files changed, 29 insertions, 23 deletions
diff --git a/sd/source/ui/view/zoomlist.cxx b/sd/source/ui/view/zoomlist.cxx index 6e381d05a6f3..031ca3c20dec 100644 --- a/sd/source/ui/view/zoomlist.cxx +++ b/sd/source/ui/view/zoomlist.cxx @@ -2,9 +2,9 @@ * * $RCSfile: zoomlist.cxx,v $ * - * $Revision: 1.3 $ + * $Revision: 1.4 $ * - * last change: $Author: dl $ $Date: 2000-10-18 08:54:49 $ + * last change: $Author: obo $ $Date: 2004-01-20 12:57:11 $ * * The Contents of this file are made available subject to the terms of * either of the following licenses @@ -59,6 +59,8 @@ * ************************************************************************/ +#include "zoomlist.hxx" + #ifndef _SVXIDS_HRC #include <svx/svxids.hrc> #endif @@ -74,7 +76,11 @@ #pragma hdrstop -#include "zoomlist.hxx" +#ifndef SD_VIEW_SHELL_HXX +#include "ViewShell.hxx" +#endif + +namespace sd { #define MAX_ENTRYS 10 @@ -84,10 +90,10 @@ |* \************************************************************************/ -ZoomList::ZoomList( SfxViewShell* pViewShell ) +ZoomList::ZoomList (ViewShell* pViewShell) : List(), - pViewSh( pViewShell ), - nCurPos(0) + mpViewShell (pViewShell), + mnCurPos(0) { } @@ -129,17 +135,17 @@ void ZoomList::InsertZoomRect(const Rectangle& rRect) } else if (nCount == 0) { - nCurPos = 0; + mnCurPos = 0; } else { - nCurPos++; + mnCurPos++; } Rectangle* pRect = new Rectangle(rRect); - Insert(pRect, nCurPos); + Insert(pRect, mnCurPos); - SfxBindings& rBindings = pViewSh->GetViewFrame()->GetBindings(); + SfxBindings& rBindings = mpViewShell->GetViewFrame()->GetBindings(); rBindings.Invalidate( SID_ZOOM_NEXT ); rBindings.Invalidate( SID_ZOOM_PREV ); } @@ -153,7 +159,7 @@ void ZoomList::InsertZoomRect(const Rectangle& rRect) Rectangle ZoomList::GetCurrentZoomRect() const { - Rectangle aRect(*(Rectangle*) GetObject(nCurPos)); + Rectangle aRect(*(Rectangle*) GetObject(mnCurPos)); return (aRect); } @@ -165,19 +171,19 @@ Rectangle ZoomList::GetCurrentZoomRect() const Rectangle ZoomList::GetNextZoomRect() { - nCurPos++; + mnCurPos++; ULONG nCount = Count(); - if (nCount > 0 && nCurPos > nCount - 1) + if (nCount > 0 && mnCurPos > nCount - 1) { - nCurPos = nCount - 1; + mnCurPos = nCount - 1; } - SfxBindings& rBindings = pViewSh->GetViewFrame()->GetBindings(); + SfxBindings& rBindings = mpViewShell->GetViewFrame()->GetBindings(); rBindings.Invalidate( SID_ZOOM_NEXT ); rBindings.Invalidate( SID_ZOOM_PREV ); - Rectangle aRect(*(Rectangle*) GetObject(nCurPos)); + Rectangle aRect(*(Rectangle*) GetObject(mnCurPos)); return (aRect); } @@ -189,16 +195,16 @@ Rectangle ZoomList::GetNextZoomRect() Rectangle ZoomList::GetPreviousZoomRect() { - if (nCurPos > 0) + if (mnCurPos > 0) { - nCurPos--; + mnCurPos--; } - SfxBindings& rBindings = pViewSh->GetViewFrame()->GetBindings(); + SfxBindings& rBindings = mpViewShell->GetViewFrame()->GetBindings(); rBindings.Invalidate( SID_ZOOM_NEXT ); rBindings.Invalidate( SID_ZOOM_PREV ); - Rectangle aRect(*(Rectangle*) GetObject(nCurPos)); + Rectangle aRect(*(Rectangle*) GetObject(mnCurPos)); return (aRect); } @@ -213,7 +219,7 @@ BOOL ZoomList::IsNextPossible() const BOOL bPossible = FALSE; ULONG nCount = Count(); - if (nCount > 0 && nCurPos < nCount - 1) + if (nCount > 0 && mnCurPos < nCount - 1) { bPossible = TRUE; } @@ -231,7 +237,7 @@ BOOL ZoomList::IsPreviousPossible() const { BOOL bPossible = FALSE; - if (nCurPos > 0) + if (mnCurPos > 0) { bPossible = TRUE; } @@ -239,4 +245,4 @@ BOOL ZoomList::IsPreviousPossible() const return (bPossible); } - +} // end of namespace sd |