summaryrefslogtreecommitdiff
path: root/sd/source/ui/slidesorter/controller
diff options
context:
space:
mode:
Diffstat (limited to 'sd/source/ui/slidesorter/controller')
-rw-r--r--sd/source/ui/slidesorter/controller/SlsClipboard.cxx2
-rw-r--r--sd/source/ui/slidesorter/controller/SlsScrollBarManager.cxx14
-rw-r--r--sd/source/ui/slidesorter/controller/SlsSelectionFunction.cxx2
-rw-r--r--sd/source/ui/slidesorter/controller/SlsSlotManager.cxx4
4 files changed, 11 insertions, 11 deletions
diff --git a/sd/source/ui/slidesorter/controller/SlsClipboard.cxx b/sd/source/ui/slidesorter/controller/SlsClipboard.cxx
index b65926d52844..66b518187ef5 100644
--- a/sd/source/ui/slidesorter/controller/SlsClipboard.cxx
+++ b/sd/source/ui/slidesorter/controller/SlsClipboard.cxx
@@ -307,7 +307,7 @@ sal_Int32 Clipboard::PasteTransferable (sal_Int32 nInsertPosition)
const std::vector<OUString> &rBookmarkList = pClipTransferable->GetPageBookmarks();
const SolarMutexGuard aGuard;
- nInsertPageCount = (sal_uInt16) rBookmarkList.size();
+ nInsertPageCount = static_cast<sal_uInt16>(rBookmarkList.size());
rModel.GetDocument()->InsertBookmarkAsPage(
rBookmarkList,
nullptr,
diff --git a/sd/source/ui/slidesorter/controller/SlsScrollBarManager.cxx b/sd/source/ui/slidesorter/controller/SlsScrollBarManager.cxx
index 9d34a23dbb2c..ebc6a5c2b109 100644
--- a/sd/source/ui/slidesorter/controller/SlsScrollBarManager.cxx
+++ b/sd/source/ui/slidesorter/controller/SlsScrollBarManager.cxx
@@ -143,7 +143,7 @@ void ScrollBarManager::PlaceHorizontalScrollBar (const ::tools::Rectangle& aAvai
// Restore the relative position.
mpHorizontalScrollBar->SetThumbPos(
- (long)(0.5 + mnHorizontalPosition * mpHorizontalScrollBar->GetRange().Len()));
+ static_cast<long>(0.5 + mnHorizontalPosition * mpHorizontalScrollBar->GetRange().Len()));
}
void ScrollBarManager::PlaceVerticalScrollBar (const ::tools::Rectangle& aArea)
@@ -278,8 +278,8 @@ void ScrollBarManager::SetWindowOrigin (
sd::Window *pWindow (mrSlideSorter.GetContentWindow().get());
Size aViewSize (pWindow->GetViewSize());
Point aOrigin (
- (long int) (mnHorizontalPosition * aViewSize.Width()),
- (long int) (mnVerticalPosition * aViewSize.Height()));
+ static_cast<long int>(mnHorizontalPosition * aViewSize.Width()),
+ static_cast<long int>(mnVerticalPosition * aViewSize.Height()));
pWindow->SetWinViewPos (aOrigin);
pWindow->UpdateMapMode ();
@@ -448,14 +448,14 @@ void ScrollBarManager::CalcAutoScrollOffset (const Point& rMouseWindowPosition)
if (rMouseWindowPosition.X() < maScrollBorder.Width()
&& aWindowArea.Left() > aViewPixelArea.Left())
{
- nDx = -1 + (int)(mnHorizontalScrollFactor
+ nDx = -1 + static_cast<int>(mnHorizontalScrollFactor
* (rMouseWindowPosition.X() - maScrollBorder.Width()));
}
if (rMouseWindowPosition.X() >= (aWindowSize.Width() - maScrollBorder.Width())
&& aWindowArea.Right() < aViewPixelArea.Right())
{
- nDx = 1 + (int)(mnHorizontalScrollFactor
+ nDx = 1 + static_cast<int>(mnHorizontalScrollFactor
* (rMouseWindowPosition.X() - aWindowSize.Width()
+ maScrollBorder.Width()));
}
@@ -467,14 +467,14 @@ void ScrollBarManager::CalcAutoScrollOffset (const Point& rMouseWindowPosition)
if (rMouseWindowPosition.Y() < maScrollBorder.Height()
&& aWindowArea.Top() > aViewPixelArea.Top())
{
- nDy = -1 + (int)(mnVerticalScrollFactor
+ nDy = -1 + static_cast<int>(mnVerticalScrollFactor
* (rMouseWindowPosition.Y() - maScrollBorder.Height()));
}
if (rMouseWindowPosition.Y() >= (aWindowSize.Height() - maScrollBorder.Height())
&& aWindowArea.Bottom() < aViewPixelArea.Bottom())
{
- nDy = 1 + (int)(mnVerticalScrollFactor
+ nDy = 1 + static_cast<int>(mnVerticalScrollFactor
* (rMouseWindowPosition.Y() - aWindowSize.Height()
+ maScrollBorder.Height()));
}
diff --git a/sd/source/ui/slidesorter/controller/SlsSelectionFunction.cxx b/sd/source/ui/slidesorter/controller/SlsSelectionFunction.cxx
index b299f00ed748..255b3a3792f8 100644
--- a/sd/source/ui/slidesorter/controller/SlsSelectionFunction.cxx
+++ b/sd/source/ui/slidesorter/controller/SlsSelectionFunction.cxx
@@ -623,7 +623,7 @@ void SelectionFunction::GotoNextPage (int nOffset)
void SelectionFunction::GotoPage (int nIndex)
{
- sal_uInt16 nPageCount = (sal_uInt16)mrSlideSorter.GetModel().GetPageCount();
+ sal_uInt16 nPageCount = static_cast<sal_uInt16>(mrSlideSorter.GetModel().GetPageCount());
if (nIndex >= nPageCount)
nIndex = nPageCount - 1;
diff --git a/sd/source/ui/slidesorter/controller/SlsSlotManager.cxx b/sd/source/ui/slidesorter/controller/SlsSlotManager.cxx
index a21f520af711..461e079f8304 100644
--- a/sd/source/ui/slidesorter/controller/SlsSlotManager.cxx
+++ b/sd/source/ui/slidesorter/controller/SlsSlotManager.cxx
@@ -500,7 +500,7 @@ void SlotManager::GetAttrState (SfxItemSet& rSet)
rSet.Put (
SfxUInt16Item (
nSlotId,
- (sal_uInt16)mrSlideSorter.GetView().GetLayouter().GetColumnCount()
+ static_cast<sal_uInt16>(mrSlideSorter.GetView().GetLayouter().GetColumnCount())
)
);
break;
@@ -1054,7 +1054,7 @@ void SlotManager::InsertSlide (SfxRequest& rRequest)
// Create shapes for the default layout.
pNewPage = pDocument->GetMasterSdPage(
- (sal_uInt16)(nInsertionIndex+1), PageKind::Standard);
+ static_cast<sal_uInt16>(nInsertionIndex+1), PageKind::Standard);
pNewPage->CreateTitleAndLayout (true,true);
}
}