diff options
Diffstat (limited to 'sd/source/ui/view/viewshe3.cxx')
-rw-r--r-- | sd/source/ui/view/viewshe3.cxx | 40 |
1 files changed, 20 insertions, 20 deletions
diff --git a/sd/source/ui/view/viewshe3.cxx b/sd/source/ui/view/viewshe3.cxx index 0ae714598096..491fd69b93fc 100644 --- a/sd/source/ui/view/viewshe3.cxx +++ b/sd/source/ui/view/viewshe3.cxx @@ -107,7 +107,7 @@ void ViewShell::GetMenuState( SfxItemSet &rSet ) SdrView* pDrView = GetDrawView(); - if( pDrView->AreObjectsMarked() ) + if( pDrView->areSdrObjectsSelected() ) { SfxStyleSheet* pStyleSheet = pDrView->GetStyleSheet(); if( pStyleSheet ) @@ -148,13 +148,13 @@ void ViewShell::GetMenuState( SfxItemSet &rSet ) if(SFX_ITEM_AVAILABLE == rSet.GetItemState(SID_UNDO)) { ::svl::IUndoManager* pUndoManager = ImpGetUndoManager(); - sal_Bool bActivate(sal_False); + bool bActivate(false); if(pUndoManager) { if(pUndoManager->GetUndoActionCount() != 0) { - bActivate = sal_True; + bActivate = true; } } @@ -176,13 +176,13 @@ void ViewShell::GetMenuState( SfxItemSet &rSet ) if(SFX_ITEM_AVAILABLE == rSet.GetItemState(SID_REDO)) { ::svl::IUndoManager* pUndoManager = ImpGetUndoManager(); - sal_Bool bActivate(sal_False); + bool bActivate(false); if(pUndoManager) { if(pUndoManager->GetRedoActionCount() != 0) { - bActivate = sal_True; + bActivate = true; } } @@ -217,9 +217,9 @@ SdPage* ViewShell::CreateOrDuplicatePage ( { sal_uInt16 nSId = rRequest.GetSlot(); SdDrawDocument* pDocument = GetDoc(); - SdrLayerAdmin& rLayerAdmin = pDocument->GetLayerAdmin(); - sal_uInt8 aBckgrnd = rLayerAdmin.GetLayerID(String(SdResId(STR_LAYER_BCKGRND)), sal_False); - sal_uInt8 aBckgrndObj = rLayerAdmin.GetLayerID(String(SdResId(STR_LAYER_BCKGRNDOBJ)), sal_False); + SdrLayerAdmin& rLayerAdmin = pDocument->GetModelLayerAdmin(); + sal_uInt8 aBckgrnd = rLayerAdmin.GetLayerID(String(SdResId(STR_LAYER_BCKGRND)), false); + sal_uInt8 aBckgrndObj = rLayerAdmin.GetLayerID(String(SdResId(STR_LAYER_BCKGRNDOBJ)), false); SetOfByte aVisibleLayers; // Determine the page from which to copy some values, such as layers, // size, master page, to the new page. This is usually the given page. @@ -237,8 +237,8 @@ SdPage* ViewShell::CreateOrDuplicatePage ( String aNotesPageName; AutoLayout eStandardLayout (AUTOLAYOUT_NONE); AutoLayout eNotesLayout (AUTOLAYOUT_NOTES); - sal_Bool bIsPageBack = aVisibleLayers.IsSet(aBckgrnd); - sal_Bool bIsPageObj = aVisibleLayers.IsSet(aBckgrndObj); + bool bIsPageBack = aVisibleLayers.IsSet(aBckgrnd); + bool bIsPageObj = aVisibleLayers.IsSet(aBckgrndObj); // 1. Process the arguments. const SfxItemSet* pArgs = rRequest.GetArgs(); @@ -267,7 +267,7 @@ SdPage* ViewShell::CreateOrDuplicatePage ( if( eStandardLayout == AUTOLAYOUT_TITLE ) eStandardLayout = AUTOLAYOUT_ENUM; - SdPage* pNotesTemplatePage = static_cast<SdPage*>(pDocument->GetPage(pTemplatePage->GetPageNum()+1)); + SdPage* pNotesTemplatePage = static_cast<SdPage*>(pDocument->GetPage(pTemplatePage->GetPageNumber()+1)); if (pNotesTemplatePage != NULL) eNotesLayout = pNotesTemplatePage->GetAutoLayout(); } @@ -275,7 +275,7 @@ SdPage* ViewShell::CreateOrDuplicatePage ( else if (pArgs->Count() == 1) { pDocument->StopWorkStartupDelay(); - SFX_REQUEST_ARG (rRequest, pLayout, SfxUInt32Item, ID_VAL_WHATLAYOUT, sal_False); + SFX_REQUEST_ARG (rRequest, pLayout, SfxUInt32Item, ID_VAL_WHATLAYOUT ); if( pLayout ) { if (ePageKind == PK_NOTES) @@ -293,10 +293,10 @@ SdPage* ViewShell::CreateOrDuplicatePage ( // AutoLayouts muessen fertig sein pDocument->StopWorkStartupDelay(); - SFX_REQUEST_ARG (rRequest, pPageName, SfxStringItem, ID_VAL_PAGENAME, sal_False); - SFX_REQUEST_ARG (rRequest, pLayout, SfxUInt32Item, ID_VAL_WHATLAYOUT, sal_False); - SFX_REQUEST_ARG (rRequest, pIsPageBack, SfxBoolItem, ID_VAL_ISPAGEBACK, sal_False); - SFX_REQUEST_ARG (rRequest, pIsPageObj, SfxBoolItem, ID_VAL_ISPAGEOBJ, sal_False); + SFX_REQUEST_ARG (rRequest, pPageName, SfxStringItem, ID_VAL_PAGENAME ); + SFX_REQUEST_ARG (rRequest, pLayout, SfxUInt32Item, ID_VAL_WHATLAYOUT ); + SFX_REQUEST_ARG (rRequest, pIsPageBack, SfxBoolItem, ID_VAL_ISPAGEBACK ); + SFX_REQUEST_ARG (rRequest, pIsPageObj, SfxBoolItem, ID_VAL_ISPAGEOBJ ); if (CHECK_RANGE (AUTOLAYOUT__START, (AutoLayout) pLayout->GetValue (), AUTOLAYOUT__END)) { @@ -344,7 +344,7 @@ SdPage* ViewShell::CreateOrDuplicatePage ( if( bUndo ) pDrView->BegUndo( String( SdResId(STR_INSERTPAGE) ) ); - sal_uInt16 nNewPageIndex = 0xffff; + sal_uInt32 nNewPageIndex = 0xffffffff; switch (nSId) { case SID_INSERTPAGE: @@ -378,8 +378,8 @@ SdPage* ViewShell::CreateOrDuplicatePage ( bIsPageObj, nInsertPosition); // Select exactly the new page. - sal_uInt16 nPageCount (pDocument->GetSdPageCount(ePageKind)); - for (sal_uInt16 i=0; i<nPageCount; i++) + sal_uInt32 nPageCount (pDocument->GetSdPageCount(ePageKind)); + for (sal_uInt32 i=0; i<nPageCount; i++) { pDocument->GetSdPage(i, PK_STANDARD)->SetSelected( i == nNewPageIndex); @@ -423,7 +423,7 @@ SdPage* ViewShell::CreateOrDuplicatePage ( // Try to handle another slot id gracefully. } SdPage* pNewPage = 0; - if(nNewPageIndex != 0xffff) + if(nNewPageIndex != 0xffffffff) pNewPage = pDocument->GetSdPage(nNewPageIndex, PK_STANDARD); if( bUndo ) |