From 83f45b0a9b0ed59736e7de796ec6db14c90be5c8 Mon Sep 17 00:00:00 2001 From: Neil Hodgson Date: Mon, 17 Jul 2017 15:17:18 +1000 Subject: Casts required for Unix LP64 after changes to Sci_Position/Sci_PositionU. --- cocoa/ScintillaCocoa.mm | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) (limited to 'cocoa') diff --git a/cocoa/ScintillaCocoa.mm b/cocoa/ScintillaCocoa.mm index 9f7a4cbf8..7fc0a8c89 100644 --- a/cocoa/ScintillaCocoa.mm +++ b/cocoa/ScintillaCocoa.mm @@ -1144,7 +1144,8 @@ void ScintillaCocoa::ClaimSelection() { * as a row:column pair. The result is zero-based. */ NSPoint ScintillaCocoa::GetCaretPosition() { - const Sci::Line line = pdoc->LineFromPosition(sel.RangeMain().caret.Position()); + const Sci::Line line = static_cast( + pdoc->LineFromPosition(sel.RangeMain().caret.Position())); NSPoint result; result.y = line; @@ -1167,7 +1168,7 @@ void ScintillaCocoa::DragScroll() { } // TODO: does not work for wrapped lines, fix it. - Sci::Line line = pdoc->LineFromPosition(posDrag.Position()); + Sci::Line line = static_cast(pdoc->LineFromPosition(posDrag.Position())); Sci::Line currentVisibleLine = cs.DisplayFromDoc(line); Sci::Line lastVisibleLine = std::min(topLine + LinesOnScreen(), cs.LinesDisplayed()) - 2; @@ -1264,8 +1265,8 @@ void ScintillaCocoa::StartDrag() { PRectangle client = GetTextRectangle(); Sci::Position selStart = sel.RangeMain().Start().Position(); Sci::Position selEnd = sel.RangeMain().End().Position(); - Sci::Line startLine = pdoc->LineFromPosition(selStart); - Sci::Line endLine = pdoc->LineFromPosition(selEnd); + Sci::Line startLine = static_cast(pdoc->LineFromPosition(selStart)); + Sci::Line endLine = static_cast(pdoc->LineFromPosition(selEnd)); Point pt; long startPos, endPos, ep; PRectangle rcSel; -- cgit v1.2.3