convert SdrHitKind to scoped enum

Change-Id: Ia7a18814fed7787e47ac2d3c02654a3648c5491e
diff --git a/chart2/source/controller/main/ChartController_Window.cxx b/chart2/source/controller/main/ChartController_Window.cxx
index 12b8341..d28252d 100644
--- a/chart2/source/controller/main/ChartController_Window.cxx
+++ b/chart2/source/controller/main/ChartController_Window.cxx
@@ -581,7 +581,7 @@ void ChartController::execute_MouseButtonDown( const MouseEvent& rMEvt )
        SdrViewEvent aVEvt;
        if ( pDrawViewWrapper->IsTextEditHit( aMPos ) ||
             // #i12587# support for shapes in chart
             ( rMEvt.IsRight() && pDrawViewWrapper->PickAnything( rMEvt, SdrMouseEventKind::BUTTONDOWN, aVEvt ) == SDRHIT_MARKEDOBJECT ) )
             ( rMEvt.IsRight() && pDrawViewWrapper->PickAnything( rMEvt, SdrMouseEventKind::BUTTONDOWN, aVEvt ) == SdrHitKind::MarkedObject ) )
        {
            pDrawViewWrapper->MouseButtonDown(rMEvt,m_pChartWindow);
            return;
diff --git a/include/svx/svdmrkv.hxx b/include/svx/svdmrkv.hxx
index 3bfc6eb..db67b26a 100644
--- a/include/svx/svdmrkv.hxx
+++ b/include/svx/svdmrkv.hxx
@@ -56,19 +56,21 @@ namespace o3tl
    template<> struct typed_flags<SdrSearchOptions> : is_typed_flags<SdrSearchOptions, 0xbfff> {};
}

enum SdrHitKind {SDRHIT_NONE,      // No hit
                 SDRHIT_OBJECT,    // Hit
                 /*SDRHIT_REFPOINT*/ // Reference point (Rotation axis, axis of reflextion) hit
                 SDRHIT_HANDLE,          // Marking handle
                 SDRHIT_HELPLINE,        // Reference line
                 SDRHIT_GLUEPOINT,       // Glue point
                 SDRHIT_TEXTEDIT,        // Open OutlinerView was hit
                 SDRHIT_TEXTEDITOBJ,     // Object for SdrBeginTextEdit (Textbereich)
                 SDRHIT_URLFIELD,        // Field in TextObj was hit (while it is currently not edited)
                 SDRHIT_MACRO,           // Object for BegMacroObj
                 SDRHIT_MARKEDOBJECT,    // Marked object (e.g. for dragging)
                 SDRHIT_UNMARKEDOBJECT, // non-marked Object (e.g. for marking)
                 SDRHIT_CELL};          // hit on a cell inside a table shape (outside of the cells text area)
enum class SdrHitKind
{
    NONE,            // No hit
    Object,          // Hit
    Handle,          // Marking handle
    HelpLine,        // Reference line
    Gluepoint,       // Glue point
    TextEdit,        // Open OutlinerView was hit
    TextEditObj,     // Object for SdrBeginTextEdit (Textbereich)
    UrlField,        // Field in TextObj was hit (while it is currently not edited)
    Macro,           // Object for BegMacroObj
    MarkedObject,    // Marked object (e.g. for dragging)
    UnmarkedObject,  // non-marked Object (e.g. for marking)
    Cell             // hit on a cell inside a table shape (outside of the cells text area)
};

enum SdrViewEditMode {SDREDITMODE_EDIT,           // Also known as arrow or pointer mode
                      SDREDITMODE_CREATE,         // Tool for object creation
diff --git a/reportdesign/source/ui/report/dlgedfunc.cxx b/reportdesign/source/ui/report/dlgedfunc.cxx
index b8bf38e..cf583d7 100644
--- a/reportdesign/source/ui/report/dlgedfunc.cxx
+++ b/reportdesign/source/ui/report/dlgedfunc.cxx
@@ -202,7 +202,7 @@ bool DlgEdFunc::MouseButtonDown( const MouseEvent& rMEvt )
    {
        SdrPageView* pPV = m_rView.GetSdrPageView();
        SdrViewEvent aVEvt;
        if ( m_rView.PickAnything(rMEvt, SdrMouseEventKind::BUTTONDOWN, aVEvt) != SDRHIT_MARKEDOBJECT && !rMEvt.IsShift() )
        if ( m_rView.PickAnything(rMEvt, SdrMouseEventKind::BUTTONDOWN, aVEvt) != SdrHitKind::MarkedObject && !rMEvt.IsShift() )
            m_pParent->getSectionWindow()->getViewsWindow()->unmarkAllObjects(nullptr);
        if ( aVEvt.pRootObj )
            m_rView.MarkObj(aVEvt.pRootObj, pPV);
@@ -490,7 +490,7 @@ void DlgEdFunc::unColorizeOverlappedObj()
bool DlgEdFunc::isOverlapping(const MouseEvent& rMEvt)
{
    SdrViewEvent aVEvt;
    bool bOverlapping = m_rView.PickAnything(rMEvt, SdrMouseEventKind::BUTTONUP, aVEvt) != SDRHIT_NONE;
    bool bOverlapping = m_rView.PickAnything(rMEvt, SdrMouseEventKind::BUTTONUP, aVEvt) != SdrHitKind::NONE;
    if (bOverlapping && aVEvt.pObj)
    {
        colorizeOverlappedObject(aVEvt.pObj);
@@ -570,7 +570,7 @@ bool DlgEdFunc::isRectangleHit(const MouseEvent& rMEvt)

    SdrViewEvent aVEvt;
    const SdrHitKind eHit = m_rView.PickAnything(rMEvt, SdrMouseEventKind::MOVE, aVEvt);
    bool bIsSetPoint = (eHit == SDRHIT_UNMARKEDOBJECT);
    bool bIsSetPoint = (eHit == SdrHitKind::UnmarkedObject);
    if ( !bIsSetPoint )
    {
        // no drag rect, we have to check every single select rect
@@ -660,7 +660,7 @@ bool DlgEdFuncInsert::MouseButtonDown( const MouseEvent& rMEvt )

    const SdrHitKind eHit = m_rView.PickAnything(rMEvt, SdrMouseEventKind::BUTTONDOWN, aVEvt);

    if (eHit == SDRHIT_UNMARKEDOBJECT && nId != OBJ_CUSTOMSHAPE)
    if (eHit == SdrHitKind::UnmarkedObject && nId != OBJ_CUSTOMSHAPE)
    {
        // there is an object under the mouse cursor, but not a customshape
        m_pParent->getSectionWindow()->getViewsWindow()->BrkAction();
@@ -797,7 +797,7 @@ bool DlgEdFuncSelect::MouseButtonDown( const MouseEvent& rMEvt )

    SdrViewEvent aVEvt;
    const SdrHitKind eHit = m_rView.PickAnything(rMEvt, SdrMouseEventKind::BUTTONDOWN, aVEvt);
    if( eHit == SDRHIT_UNMARKEDOBJECT )
    if( eHit == SdrHitKind::UnmarkedObject )
    {
        // if not multi selection, unmark all
        if ( !rMEvt.IsShift() )
diff --git a/sc/source/ui/drawfunc/fudraw.cxx b/sc/source/ui/drawfunc/fudraw.cxx
index 862f480..c09dc2ba 100644
--- a/sc/source/ui/drawfunc/fudraw.cxx
+++ b/sc/source/ui/drawfunc/fudraw.cxx
@@ -676,7 +676,7 @@ static bool lcl_UrlHit( SdrView* pView, const Point& rPosPixel, vcl::Window* pWi
    MouseEvent aMEvt( rPosPixel, 1, MouseEventModifiers::NONE, MOUSE_LEFT );
    SdrHitKind eHit = pView->PickAnything( aMEvt, SdrMouseEventKind::BUTTONDOWN, aVEvt );

    if ( eHit != SDRHIT_NONE && aVEvt.pObj != nullptr )
    if ( eHit != SdrHitKind::NONE && aVEvt.pObj != nullptr )
    {
        if ( ScDrawLayer::GetIMapInfo( aVEvt.pObj ) && ScDrawLayer::GetHitIMapObject(
                                aVEvt.pObj, pWindow->PixelToLogic(rPosPixel), *pWindow ) )
diff --git a/sc/source/ui/drawfunc/fusel.cxx b/sc/source/ui/drawfunc/fusel.cxx
index 8141c0e..df0c18bd 100644
--- a/sc/source/ui/drawfunc/fusel.cxx
+++ b/sc/source/ui/drawfunc/fusel.cxx
@@ -225,7 +225,7 @@ bool FuSelection::MouseButtonDown(const MouseEvent& rMEvt)

                SdrViewEvent aVEvt;
                if ( !bAlt &&
                    pView->PickAnything( rMEvt, SdrMouseEventKind::BUTTONDOWN, aVEvt ) != SDRHIT_NONE &&
                    pView->PickAnything( rMEvt, SdrMouseEventKind::BUTTONDOWN, aVEvt ) != SdrHitKind::NONE &&
                    aVEvt.pObj != nullptr )
                {
                    if ( ScDrawLayer::GetIMapInfo( aVEvt.pObj ) )       // ImageMap
@@ -498,7 +498,7 @@ bool FuSelection::MouseButtonUp(const MouseEvent& rMEvt)

                SdrViewEvent aVEvt;
                SdrHitKind eHit = pView->PickAnything( rMEvt, SdrMouseEventKind::BUTTONDOWN, aVEvt );
                if (eHit != SDRHIT_NONE && aVEvt.pObj == pObj &&  pViewShell)
                if (eHit != SdrHitKind::NONE && aVEvt.pObj == pObj &&  pViewShell)
                {
                    sal_uInt16 nSdrObjKind = pObj->GetObjIdentifier();

diff --git a/sc/source/ui/view/gridwin5.cxx b/sc/source/ui/view/gridwin5.cxx
index 19ef338..2424bd7 100644
--- a/sc/source/ui/view/gridwin5.cxx
+++ b/sc/source/ui/view/gridwin5.cxx
@@ -302,7 +302,7 @@ void ScGridWindow::RequestHelp(const HelpEvent& rHEvt)
            MouseEvent aMEvt( aPosPixel, 1, MouseEventModifiers::NONE, MOUSE_LEFT );
            SdrHitKind eHit = pDrView->PickAnything( aMEvt, SdrMouseEventKind::BUTTONDOWN, aVEvt );

            if ( eHit != SDRHIT_NONE && aVEvt.pObj != nullptr )
            if ( eHit != SdrHitKind::NONE && aVEvt.pObj != nullptr )
            {
                // URL for IMapObject below Pointer is help text
                if ( ScDrawLayer::GetIMapInfo( aVEvt.pObj ) )
diff --git a/sd/source/ui/func/fuconbez.cxx b/sd/source/ui/func/fuconbez.cxx
index 46de4c0..58432e8 100644
--- a/sd/source/ui/func/fuconbez.cxx
+++ b/sd/source/ui/func/fuconbez.cxx
@@ -77,7 +77,7 @@ bool FuConstructBezierPolygon::MouseButtonDown(const MouseEvent& rMEvt)
    SdrViewEvent aVEvt;
    SdrHitKind eHit = mpView->PickAnything(rMEvt, SdrMouseEventKind::BUTTONDOWN, aVEvt);

    if (eHit == SDRHIT_HANDLE || rMEvt.IsMod1())
    if (eHit == SdrHitKind::Handle || rMEvt.IsMod1())
    {
        mpView->SetEditMode(SDREDITMODE_EDIT);
    }
@@ -97,7 +97,7 @@ bool FuConstructBezierPolygon::MouseButtonDown(const MouseEvent& rMEvt)
        mpView->EnableExtendedMouseEventDispatcher(true);
    }

    if (eHit == SDRHIT_MARKEDOBJECT && nEditMode == SID_BEZIER_INSERT)
    if (eHit == SdrHitKind::MarkedObject && nEditMode == SID_BEZIER_INSERT)
    {
        // insert glue point
        mpView->BegInsObjPoint(aMDPos, rMEvt.IsMod1());
diff --git a/sd/source/ui/func/fudraw.cxx b/sd/source/ui/func/fudraw.cxx
index d37203a..d5f309d 100644
--- a/sd/source/ui/func/fudraw.cxx
+++ b/sd/source/ui/func/fudraw.cxx
@@ -516,7 +516,7 @@ void FuDraw::ForcePointer(const MouseEvent* pMEvt)
            SdrObject* pObj = nullptr;
            SdrPageView* pPV = nullptr;
            SdrViewEvent aVEvt;
            SdrHitKind eHit = SDRHIT_NONE;
            SdrHitKind eHit = SdrHitKind::NONE;
            SdrDragMode eDragMode = mpView->GetDragMode();

            if (pMEvt)
@@ -524,7 +524,7 @@ void FuDraw::ForcePointer(const MouseEvent* pMEvt)
                eHit = mpView->PickAnything(*pMEvt, SdrMouseEventKind::MOVE, aVEvt);
            }

            if ((eDragMode == SdrDragMode::Rotate) && (eHit == SDRHIT_MARKEDOBJECT))
            if ((eDragMode == SdrDragMode::Rotate) && (eHit == SdrHitKind::MarkedObject))
            {
                // The goal of this request is show always the rotation-arrow for 3D-objects at rotation-modus
                // Independent of the settings at Extras->Optionen->Grafik "Objekte immer verschieben"
@@ -539,16 +539,16 @@ void FuDraw::ForcePointer(const MouseEvent* pMEvt)
                }
            }

            if (eHit == SDRHIT_NONE)
            if (eHit == SdrHitKind::NONE)
            {
                // found nothing -> look after at the masterpage
                mpView->PickObj(aPnt, mpView->getHitTolLog(), pObj, pPV, SdrSearchOptions::ALSOONMASTER);
            }
            else if (eHit == SDRHIT_UNMARKEDOBJECT)
            else if (eHit == SdrHitKind::UnmarkedObject)
            {
                pObj = aVEvt.pObj;
            }
            else if (eHit == SDRHIT_TEXTEDITOBJ && dynamic_cast< const FuSelection *>( this ) !=  nullptr)
            else if (eHit == SdrHitKind::TextEditObj && dynamic_cast< const FuSelection *>( this ) !=  nullptr)
            {
                sal_uInt16 nSdrObjKind = aVEvt.pObj->GetObjIdentifier();

@@ -747,7 +747,7 @@ bool FuDraw::RequestHelp(const HelpEvent& rHEvt)

        SdrObject* pObj = aVEvt.pObj;

        if (eHit != SDRHIT_NONE && pObj != nullptr)
        if (eHit != SdrHitKind::NONE && pObj != nullptr)
        {
            Point aPosPixel = rHEvt.GetMousePosPixel();

diff --git a/sd/source/ui/func/fuediglu.cxx b/sd/source/ui/func/fuediglu.cxx
index 24a85a7b..472779d 100644
--- a/sd/source/ui/func/fuediglu.cxx
+++ b/sd/source/ui/func/fuediglu.cxx
@@ -100,7 +100,7 @@ bool FuEditGluePoints::MouseButtonDown(const MouseEvent& rMEvt)
        SdrViewEvent aVEvt;
        SdrHitKind eHit = mpView->PickAnything(rMEvt, SdrMouseEventKind::BUTTONDOWN, aVEvt);

        if (eHit == SDRHIT_HANDLE)
        if (eHit == SdrHitKind::Handle)
        {
            // drag handle
            SdrHdl* pHdl = aVEvt.pHdl;
@@ -117,12 +117,12 @@ bool FuEditGluePoints::MouseButtonDown(const MouseEvent& rMEvt)
                mpView->BegDragObj(aMDPos, nullptr, aVEvt.pHdl, nDrgLog);
            }
        }
        else if (eHit == SDRHIT_MARKEDOBJECT && mpView->IsInsGluePointMode())
        else if (eHit == SdrHitKind::MarkedObject && mpView->IsInsGluePointMode())
        {
            // insert glue points
            mpView->BegInsGluePoint(aMDPos);
        }
        else if (eHit == SDRHIT_MARKEDOBJECT && rMEvt.IsMod1())
        else if (eHit == SdrHitKind::MarkedObject && rMEvt.IsMod1())
        {
            // select glue points
            if (!rMEvt.IsShift())
@@ -130,12 +130,12 @@ bool FuEditGluePoints::MouseButtonDown(const MouseEvent& rMEvt)

            mpView->BegMarkGluePoints(aMDPos);
        }
        else if (eHit == SDRHIT_MARKEDOBJECT && !rMEvt.IsShift() && !rMEvt.IsMod2())
        else if (eHit == SdrHitKind::MarkedObject && !rMEvt.IsShift() && !rMEvt.IsMod2())
        {
            // move object
            mpView->BegDragObj(aMDPos, nullptr, nullptr, nDrgLog);
        }
        else if (eHit == SDRHIT_GLUEPOINT)
        else if (eHit == SdrHitKind::Gluepoint)
        {
            // select glue points
            if (!rMEvt.IsShift())
@@ -152,7 +152,7 @@ bool FuEditGluePoints::MouseButtonDown(const MouseEvent& rMEvt)
        else
        {
            // select or drag object
            if (!rMEvt.IsShift() && !rMEvt.IsMod2() && eHit == SDRHIT_UNMARKEDOBJECT)
            if (!rMEvt.IsShift() && !rMEvt.IsMod2() && eHit == SdrHitKind::UnmarkedObject)
            {
               mpView->UnmarkAllObj();
            }
@@ -172,7 +172,7 @@ bool FuEditGluePoints::MouseButtonDown(const MouseEvent& rMEvt)
            }

            if (bMarked &&
                (!rMEvt.IsShift() || eHit == SDRHIT_MARKEDOBJECT))
                (!rMEvt.IsShift() || eHit == SdrHitKind::MarkedObject))
            {
                // move object
                mpView->BegDragObj(aMDPos, nullptr, aVEvt.pHdl, nDrgLog);
@@ -241,7 +241,7 @@ bool FuEditGluePoints::MouseButtonUp(const MouseEvent& rMEvt)
        SdrViewEvent aVEvt;
        SdrHitKind eHit = mpView->PickAnything(rMEvt, SdrMouseEventKind::BUTTONDOWN, aVEvt);

        if (eHit == SDRHIT_NONE)
        if (eHit == SdrHitKind::NONE)
        {
            // click on position: deselect
            mpView->UnmarkAllObj();
diff --git a/sd/source/ui/func/fuformatpaintbrush.cxx b/sd/source/ui/func/fuformatpaintbrush.cxx
index c9e578d..dc70c36 100644
--- a/sd/source/ui/func/fuformatpaintbrush.cxx
+++ b/sd/source/ui/func/fuformatpaintbrush.cxx
@@ -97,7 +97,7 @@ bool FuFormatPaintBrush::MouseButtonDown(const MouseEvent& rMEvt)
        SdrViewEvent aVEvt;
        SdrHitKind eHit = mpView->PickAnything(rMEvt, SdrMouseEventKind::BUTTONDOWN, aVEvt);

        if( (eHit == SDRHIT_TEXTEDIT) || (eHit == SDRHIT_TEXTEDITOBJ && ( mpViewShell->GetFrameView()->IsQuickEdit() || dynamic_cast< sdr::table::SdrTableObj* >( aVEvt.pObj ) != nullptr ) ))
        if( (eHit == SdrHitKind::TextEdit) || (eHit == SdrHitKind::TextEditObj && ( mpViewShell->GetFrameView()->IsQuickEdit() || dynamic_cast< sdr::table::SdrTableObj* >( aVEvt.pObj ) != nullptr ) ))
        {
            SdrObject* pPickObj=nullptr;
            SdrPageView* pPV=nullptr;
diff --git a/sd/source/ui/func/fusel.cxx b/sd/source/ui/func/fusel.cxx
index d0c2df7..9e62290 100644
--- a/sd/source/ui/func/fusel.cxx
+++ b/sd/source/ui/func/fusel.cxx
@@ -197,7 +197,7 @@ bool FuSelection::MouseButtonDown(const MouseEvent& rMEvt)
        SdrViewEvent aVEvt;
        SdrHitKind eHit = mpView->PickAnything(rMEvt, SdrMouseEventKind::BUTTONDOWN, aVEvt);

        if ( eHit == SDRHIT_TEXTEDITOBJ && ( mpViewShell->GetFrameView()->IsQuickEdit() || dynamic_cast< sdr::table::SdrTableObj* >( aVEvt.pObj ) != nullptr ) )
        if ( eHit == SdrHitKind::TextEditObj && ( mpViewShell->GetFrameView()->IsQuickEdit() || dynamic_cast< sdr::table::SdrTableObj* >( aVEvt.pObj ) != nullptr ) )
        {
            bTextEdit = true;
        }
@@ -438,7 +438,7 @@ bool FuSelection::MouseButtonDown(const MouseEvent& rMEvt)
        SdrViewEvent aVEvt;
        SdrHitKind eHit = mpView->PickAnything(rMEvt, SdrMouseEventKind::BUTTONDOWN, aVEvt);

        if (eHit == SDRHIT_HANDLE && aVEvt.pHdl->GetKind() == HDL_BWGT)
        if (eHit == SdrHitKind::Handle && aVEvt.pHdl->GetKind() == HDL_BWGT)
        {
            /******************************************************************
            * Drag Handle
@@ -446,14 +446,14 @@ bool FuSelection::MouseButtonDown(const MouseEvent& rMEvt)
            if ( ! rMEvt.IsRight())
                mpView->BegDragObj(aMDPos, nullptr, aVEvt.pHdl, nDrgLog);
        }
        else if (eHit == SDRHIT_MARKEDOBJECT && nEditMode == SID_BEZIER_INSERT)
        else if (eHit == SdrHitKind::MarkedObject && nEditMode == SID_BEZIER_INSERT)
        {
            /******************************************************************
            * Insert glue point
            ******************************************************************/
            mpView->BegInsObjPoint(aMDPos, rMEvt.IsMod1());
        }
        else if (eHit == SDRHIT_MARKEDOBJECT && rMEvt.IsMod1())
        else if (eHit == SdrHitKind::MarkedObject && rMEvt.IsMod1())
        {
            /******************************************************************
            * Select glue point
@@ -464,7 +464,7 @@ bool FuSelection::MouseButtonDown(const MouseEvent& rMEvt)
            if ( ! rMEvt.IsRight())
                mpView->BegMarkPoints(aMDPos);
        }
        else if (eHit == SDRHIT_MARKEDOBJECT && !rMEvt.IsShift() && !rMEvt.IsMod2())
        else if (eHit == SdrHitKind::MarkedObject && !rMEvt.IsShift() && !rMEvt.IsMod2())
        {
            /******************************************************************
            * Move object
@@ -472,7 +472,7 @@ bool FuSelection::MouseButtonDown(const MouseEvent& rMEvt)
            if ( ! rMEvt.IsRight())
                mpView->BegDragObj(aMDPos, nullptr, nullptr, nDrgLog);
        }
        else if (eHit == SDRHIT_HANDLE)
        else if (eHit == SdrHitKind::Handle)
        {
            /******************************************************************
            * Select glue point
@@ -520,7 +520,7 @@ bool FuSelection::MouseButtonDown(const MouseEvent& rMEvt)
            /******************************************************************
            * Select or drag object
            ******************************************************************/
            if (!rMEvt.IsShift() && !rMEvt.IsMod2() && eHit == SDRHIT_UNMARKEDOBJECT)
            if (!rMEvt.IsShift() && !rMEvt.IsMod2() && eHit == SdrHitKind::UnmarkedObject)
            {
               mpView->UnmarkAllObj();
            }
@@ -540,7 +540,7 @@ bool FuSelection::MouseButtonDown(const MouseEvent& rMEvt)
            }

            if (bMarked &&
                (!rMEvt.IsShift() || eHit == SDRHIT_MARKEDOBJECT))
                (!rMEvt.IsShift() || eHit == SdrHitKind::MarkedObject))
            {
                // Move object
                if ( ! rMEvt.IsRight())
@@ -876,7 +876,7 @@ bool FuSelection::MouseButtonUp(const MouseEvent& rMEvt)
                    SdrViewEvent aVEvt;
                    SdrHitKind eHit = mpView->PickAnything(rMEvt, SdrMouseEventKind::BUTTONDOWN, aVEvt);

                    if (eHit == SDRHIT_NONE)
                    if (eHit == SdrHitKind::NONE)
                    {
                        // Click on the same place - unselect
                        mpView->UnmarkAllObj();
diff --git a/sd/source/ui/func/futext.cxx b/sd/source/ui/func/futext.cxx
index 775f954..0bd8273 100644
--- a/sd/source/ui/func/futext.cxx
+++ b/sd/source/ui/func/futext.cxx
@@ -257,7 +257,7 @@ bool FuText::MouseButtonDown(const MouseEvent& rMEvt)
    SdrViewEvent aVEvt;
    SdrHitKind eHit = mpView->PickAnything(rMEvt, SdrMouseEventKind::BUTTONDOWN, aVEvt);

    if (eHit == SDRHIT_TEXTEDIT)
    if (eHit == SdrHitKind::TextEdit)
    {
        // hit text -> SdrView handles event
        if (mpView->MouseButtonDown(rMEvt, mpWindow))
@@ -266,19 +266,19 @@ bool FuText::MouseButtonDown(const MouseEvent& rMEvt)

    if (rMEvt.GetClicks() == 1)
    {
        if (mpView->IsTextEdit() && eHit != SDRHIT_MARKEDOBJECT && eHit != SDRHIT_HANDLE)
        if (mpView->IsTextEdit() && eHit != SdrHitKind::MarkedObject && eHit != SdrHitKind::Handle)
        {
            // finish text input
            if(mpView->SdrEndTextEdit() == SDRENDTEXTEDIT_DELETED)
            {
                /* Bugfix from MBA: during a double click onto the unused? area
                   in text mode, we get with the second click eHit =
                   SDRHIT_TEXTEDITOBJ since it goes to the TextObject which was
                   SdrHitKind::TextEditObj since it goes to the TextObject which was
                   created with the first click. But this is removed by
                   SdrEndTextEdit since it is empty. But it is still in the mark
                   list. The call MarkObj further below accesses then the dead
                   object. As a simple fix, we determine eHit after
                   SdrEndTextEdit again, this returns then SDRHIT_NONE. */
                   SdrEndTextEdit again, this returns then SdrHitKind::NONE. */
                mxTextObj.reset( nullptr );
                eHit = mpView->PickAnything(rMEvt, SdrMouseEventKind::BUTTONDOWN, aVEvt);
            }
@@ -292,16 +292,16 @@ bool FuText::MouseButtonDown(const MouseEvent& rMEvt)
            mpWindow->CaptureMouse();
            SdrPageView* pPV = mpView->GetSdrPageView();

            if (eHit == SDRHIT_TEXTEDIT)
            if (eHit == SdrHitKind::TextEdit)
            {
                SetInEditMode(rMEvt, false);
            }
            else
            {
                if (eHit != SDRHIT_HANDLE)
                if (eHit != SdrHitKind::Handle)
                {
                    // deselect selection
                    if (!rMEvt.IsShift() && eHit == SDRHIT_TEXTEDITOBJ)
                    if (!rMEvt.IsShift() && eHit == SdrHitKind::TextEditObj)
                    {
                        mpView->UnmarkAll();
                        mpView->SetDragMode(SdrDragMode::Move);
@@ -309,14 +309,14 @@ bool FuText::MouseButtonDown(const MouseEvent& rMEvt)
                }

                if ( aVEvt.eEvent == SdrEventKind::ExecuteUrl                   ||
                     eHit == SDRHIT_HANDLE                                 ||
                     eHit == SDRHIT_MARKEDOBJECT                           ||
                     eHit == SDRHIT_TEXTEDITOBJ                            ||
                     ( eHit == SDRHIT_UNMARKEDOBJECT && bFirstObjCreated &&
                     eHit == SdrHitKind::Handle                                 ||
                     eHit == SdrHitKind::MarkedObject                           ||
                     eHit == SdrHitKind::TextEditObj                            ||
                     ( eHit == SdrHitKind::UnmarkedObject && bFirstObjCreated &&
                       !bPermanent ) )
                {
                    // Handle, hit marked or umarked object
                    if (eHit == SDRHIT_TEXTEDITOBJ)
                    if (eHit == SdrHitKind::TextEditObj)
                    {
                        /* hit text of unmarked object:
                           select object and set to EditMode */
@@ -385,7 +385,7 @@ bool FuText::MouseButtonDown(const MouseEvent& rMEvt)

                        if (!aVEvt.pHdl)
                        {
                            if( eHit == SDRHIT_UNMARKEDOBJECT )
                            if( eHit == SdrHitKind::UnmarkedObject )
                            {
                                if ( !rMEvt.IsShift() )
                                    mpView->UnmarkAll();
@@ -402,7 +402,7 @@ bool FuText::MouseButtonDown(const MouseEvent& rMEvt)
                        {
                            // we need to pick again since SdrEndTextEdit can rebuild the handles list
                            eHit = mpView->PickAnything(rMEvt, SdrMouseEventKind::BUTTONDOWN, aVEvt);
                            if( (eHit == SDRHIT_HANDLE) || (eHit == SDRHIT_MARKEDOBJECT) )
                            if( (eHit == SdrHitKind::Handle) || (eHit == SdrHitKind::MarkedObject) )
                            {
                                sal_uInt16 nDrgLog = sal_uInt16 ( mpWindow->PixelToLogic(Size(DRGPIX,0)).Width() );
                                mpView->BegDragObj(aMDPos, nullptr, aVEvt.pHdl, nDrgLog);
@@ -1074,7 +1074,7 @@ void FuText::SetInEditMode(const MouseEvent& rMEvt, bool bQuickDrag)
                        SdrViewEvent aVEvt;
                        SdrHitKind eHit = mpView->PickAnything(rMEvt, SdrMouseEventKind::BUTTONDOWN, aVEvt);

                        if (eHit == SDRHIT_TEXTEDIT)
                        if (eHit == SdrHitKind::TextEdit)
                        {
                            // hit text
                            if (nSdrObjKind == OBJ_TEXT ||
diff --git a/svx/source/dialog/graphctl.cxx b/svx/source/dialog/graphctl.cxx
index 135fcf8..4426af0 100644
--- a/svx/source/dialog/graphctl.cxx
+++ b/svx/source/dialog/graphctl.cxx
@@ -622,7 +622,7 @@ void GraphCtrl::MouseButtonDown( const MouseEvent& rMEvt )
                SdrViewEvent    aVEvt;
                SdrHitKind      eHit = pView->PickAnything( rMEvt, SdrMouseEventKind::BUTTONDOWN, aVEvt );

                if ( nPolyEdit == SID_BEZIER_INSERT && eHit == SDRHIT_MARKEDOBJECT )
                if ( nPolyEdit == SID_BEZIER_INSERT && eHit == SdrHitKind::MarkedObject )
                    pView->BegInsObjPoint( aLogPt, rMEvt.IsMod1());
                else
                    pView->MouseButtonDown( rMEvt, this );
diff --git a/svx/source/form/fmshimp.cxx b/svx/source/form/fmshimp.cxx
index dd67e6e..16a8c76 100644
--- a/svx/source/form/fmshimp.cxx
+++ b/svx/source/form/fmshimp.cxx
@@ -3915,7 +3915,7 @@ void FmXFormShell::handleMouseButtonDown( const SdrViewEvent& _rViewEvent )
    // catch simple double clicks
    if ( ( _rViewEvent.nMouseClicks == 2 ) && ( _rViewEvent.nMouseCode == MOUSE_LEFT ) )
    {
        if ( _rViewEvent.eHit == SDRHIT_MARKEDOBJECT )
        if ( _rViewEvent.eHit == SdrHitKind::MarkedObject )
        {
            if ( onlyControlsAreMarked() )
                ShowSelectionProperties( true );
diff --git a/svx/source/svdraw/svdview.cxx b/svx/source/svdraw/svdview.cxx
index f5b39d93..c935fb6 100644
--- a/svx/source/svdraw/svdview.cxx
+++ b/svx/source/svdraw/svdview.cxx
@@ -58,7 +58,7 @@ SdrViewEvent::SdrViewEvent()
      pRootObj(nullptr),
      pPV(nullptr),
      pURLField(nullptr),
      eHit(SDRHIT_NONE),
      eHit(SdrHitKind::NONE),
      eEvent(SdrEventKind::NONE),
      eEndCreateCmd(SdrCreateCmd::NextPoint),
      nMouseClicks(0),
@@ -329,7 +329,7 @@ SdrHitKind SdrView::PickAnything(const Point& rLogicPos, SdrViewEvent& rVEvt) co
    bool bShift=(rVEvt.nMouseCode & KEY_SHIFT) !=0;
    bool bCtrl=(rVEvt.nMouseCode & KEY_MOD1) !=0;
    bool bAlt=(rVEvt.nMouseCode & KEY_MOD2) !=0;
    SdrHitKind eHit=SDRHIT_NONE;
    SdrHitKind eHit=SdrHitKind::NONE;
    SdrHdl* pHdl=pOut!=nullptr && !bTextEditSel ? PickHandle(aLocalLogicPosition) : nullptr;
    SdrPageView* pPV=nullptr;
    SdrObject* pObj=nullptr;
@@ -339,24 +339,24 @@ SdrHitKind SdrView::PickAnything(const Point& rLogicPos, SdrViewEvent& rVEvt) co
    sal_uInt16 nGlueId=0;
    if (bTextEditHit || bTextEditSel)
    {
        eHit=SDRHIT_TEXTEDIT;
        eHit=SdrHitKind::TextEdit;
        bTextEditHit=true;
    }
    else if (pHdl!=nullptr)
    {
        eHit=SDRHIT_HANDLE; // handle is hit: highest priority
        eHit=SdrHitKind::Handle; // handle is hit: highest priority
    }
    else if (bEditMode && IsHlplVisible() && IsHlplFront() && pOut!=nullptr && PickHelpLine(aLocalLogicPosition,mnHitTolLog,*pOut,nHlplIdx,pPV))
    {
        eHit=SDRHIT_HELPLINE; // help line in the foreground hit: can be moved now
        eHit=SdrHitKind::HelpLine; // help line in the foreground hit: can be moved now
    }
    else if (bGluePointMode && PickGluePoint(aLocalLogicPosition,pObj,nGlueId,pPV))
    {
        eHit=SDRHIT_GLUEPOINT; // deselected glue point hit
        eHit=SdrHitKind::Gluepoint; // deselected glue point hit
    }
    else if (PickObj(aLocalLogicPosition,mnHitTolLog,pHitObj,pPV,SdrSearchOptions::DEEP|SdrSearchOptions::MARKED,&pObj,&bHitPassDirect))
    {
        eHit=SDRHIT_MARKEDOBJECT;
        eHit=SdrHitKind::MarkedObject;
        sdr::table::SdrTableObj* pTableObj = dynamic_cast< sdr::table::SdrTableObj* >( pObj );
        if( pTableObj )
        {
@@ -364,10 +364,10 @@ SdrHitKind SdrView::PickAnything(const Point& rLogicPos, SdrViewEvent& rVEvt) co
            switch( pTableObj->CheckTableHit( aLocalLogicPosition, nX, nY ) )
            {
                case sdr::table::TableHitKind::Cell:
                    eHit = SDRHIT_CELL;
                    eHit = SdrHitKind::Cell;
                    break;
                case sdr::table::TableHitKind::CellTextArea:
                    eHit = SDRHIT_TEXTEDITOBJ;
                    eHit = SdrHitKind::TextEditObj;
                    break;
                default:
                    break;
@@ -377,7 +377,7 @@ SdrHitKind SdrView::PickAnything(const Point& rLogicPos, SdrViewEvent& rVEvt) co
    else if (PickObj(aLocalLogicPosition,mnHitTolLog,pHitObj,pPV,SdrSearchOptions::DEEP|SdrSearchOptions::ALSOONMASTER|SdrSearchOptions::WHOLEPAGE,&pObj,&bHitPassDirect))
    {
        // MasterPages and WholePage for Macro and URL
        eHit=SDRHIT_UNMARKEDOBJECT;
        eHit=SdrHitKind::UnmarkedObject;
        sdr::table::SdrTableObj* pTableObj = dynamic_cast< sdr::table::SdrTableObj* >( pObj );
        if( pTableObj )
        {
@@ -385,10 +385,10 @@ SdrHitKind SdrView::PickAnything(const Point& rLogicPos, SdrViewEvent& rVEvt) co
            switch( pTableObj->CheckTableHit( aLocalLogicPosition, nX, nY, mnHitTolLog ) )
            {
                case sdr::table::TableHitKind::Cell:
                    eHit = SDRHIT_CELL;
                    eHit = SdrHitKind::Cell;
                    break;
                case sdr::table::TableHitKind::CellTextArea:
                    eHit = SDRHIT_TEXTEDITOBJ;
                    eHit = SdrHitKind::TextEditObj;
                    break;
                default:
                    break;
@@ -397,9 +397,9 @@ SdrHitKind SdrView::PickAnything(const Point& rLogicPos, SdrViewEvent& rVEvt) co
    }
    else if (bEditMode && IsHlplVisible() && !IsHlplFront() && pOut!=nullptr && PickHelpLine(aLocalLogicPosition,mnHitTolLog,*pOut,nHlplIdx,pPV))
    {
        eHit=SDRHIT_HELPLINE; // help line in foreground hit: can be moved now
        eHit=SdrHitKind::HelpLine; // help line in foreground hit: can be moved now
    }
    if (eHit==SDRHIT_UNMARKEDOBJECT)
    if (eHit==SdrHitKind::UnmarkedObject)
    {
        bool bRoot=pObj->HasMacro();
        bool bDeep=pObj!=pHitObj && pHitObj->HasMacro();
@@ -439,12 +439,12 @@ SdrHitKind SdrView::PickAnything(const Point& rLogicPos, SdrViewEvent& rVEvt) co
                rVEvt.pRootObj=pObj;
                if (!bRoot) pObj=pMidObj;
                if (!bRoot && !bMid) pObj=pHitObj;
                eHit=SDRHIT_MACRO;
                eHit=SdrHitKind::Macro;
            }
        }
    }
    // check for URL field
    if (eHit==SDRHIT_UNMARKEDOBJECT)
    if (eHit==SdrHitKind::UnmarkedObject)
    {
        SdrTextObj* pTextObj=dynamic_cast<SdrTextObj*>( pHitObj );
        if (pTextObj!=nullptr && pTextObj->HasText())
@@ -485,7 +485,7 @@ SdrHitKind SdrView::PickAnything(const Point& rLogicPos, SdrViewEvent& rVEvt) co
                        const SvxFieldData* pFld=pItem->GetField();
                        const SvxURLField* pURL=dynamic_cast<const SvxURLField*>( pFld );
                        if (pURL!=nullptr) {
                            eHit=SDRHIT_URLFIELD;
                            eHit=SdrHitKind::UrlField;
                            rVEvt.pURLField=pURL;
                        }
                    }
@@ -495,7 +495,7 @@ SdrHitKind SdrView::PickAnything(const Point& rLogicPos, SdrViewEvent& rVEvt) co
    }

    if (bHitPassDirect &&
        (eHit==SDRHIT_MARKEDOBJECT || eHit==SDRHIT_UNMARKEDOBJECT) &&
        (eHit==SdrHitKind::MarkedObject || eHit==SdrHitKind::UnmarkedObject) &&
        (IsTextTool() || (IsEditMode() && IsQuickTextEditMode())) && pHitObj->HasTextEdit())
    {
        // Around the TextEditArea there's a border to select without going into text edit mode.
@@ -538,12 +538,12 @@ SdrHitKind SdrView::PickAnything(const Point& rLogicPos, SdrViewEvent& rVEvt) co
            {
                rVEvt.pRootObj=pObj;
                pObj=pHitObj;
                eHit=SDRHIT_TEXTEDITOBJ;
                eHit=SdrHitKind::TextEditObj;
            }
        }
    }
    if (!bHitPassDirect && eHit==SDRHIT_UNMARKEDOBJECT) {
        eHit=SDRHIT_NONE;
    if (!bHitPassDirect && eHit==SdrHitKind::UnmarkedObject) {
        eHit=SdrHitKind::NONE;
        pObj=nullptr;
        pPV=nullptr;
    }
@@ -593,32 +593,32 @@ SdrHitKind SdrView::PickAnything(const Point& rLogicPos, SdrViewEvent& rVEvt) co
            eEvent=SdrEventKind::MoveAction;
        }
    }
    else if (eHit==SDRHIT_TEXTEDIT)
    else if (eHit==SdrHitKind::TextEdit)
    {
        eEvent=SdrEventKind::TextEdit;
    }
    else if (bMouseDown && bMouseLeft)
    {
        if (rVEvt.nMouseClicks==2 && rVEvt.nMouseCode==MOUSE_LEFT && pObj!=nullptr && pHitObj!=nullptr && pHitObj->HasTextEdit() && eHit==SDRHIT_MARKEDOBJECT)
        if (rVEvt.nMouseClicks==2 && rVEvt.nMouseCode==MOUSE_LEFT && pObj!=nullptr && pHitObj!=nullptr && pHitObj->HasTextEdit() && eHit==SdrHitKind::MarkedObject)
        {
            rVEvt.pRootObj=pObj;
            pObj=pHitObj;
            eEvent=SdrEventKind::BeginTextEdit;
        }
        else if (MODKEY_ForceMark && eHit!=SDRHIT_URLFIELD)
        else if (MODKEY_ForceMark && eHit!=SdrHitKind::UrlField)
        {
            eEvent=SdrEventKind::BeginMark; // AddMark,Unmark */
        }
        else if (eHit==SDRHIT_HELPLINE)
        else if (eHit==SdrHitKind::HelpLine)
        {
            eEvent=SdrEventKind::BeginDragHelpline; // nothing, actually
        }
        else if (eHit==SDRHIT_GLUEPOINT)
        else if (eHit==SdrHitKind::Gluepoint)
        {
            eEvent=SdrEventKind::MarkGluePoint; // AddMark+Drag
            rVEvt.bAddMark=MODKEY_MultiMark || MODKEY_DeepMark; // if not hit with Deep
        }
        else if (eHit==SDRHIT_HANDLE)
        else if (eHit==SdrHitKind::Handle)
        {
            eEvent=SdrEventKind::BeginDragObj;    // Mark+Drag,AddMark+Drag,DeepMark+Drag,Unmark
            bool bGlue=pHdl->GetKind()==HDL_GLUE;
@@ -658,7 +658,7 @@ SdrHitKind SdrView::PickAnything(const Point& rLogicPos, SdrViewEvent& rVEvt) co
        {
            eEvent=SdrEventKind::BeginInsertGluePoint;
        }
        else if (eHit==SDRHIT_TEXTEDITOBJ)
        else if (eHit==SdrHitKind::TextEditObj)
        {
            eEvent=SdrEventKind::BeginTextEdit; // AddMark+Drag,DeepMark+Drag,Unmark
            if (MODKEY_MultiMark || MODKEY_DeepMark)
@@ -666,7 +666,7 @@ SdrHitKind SdrView::PickAnything(const Point& rLogicPos, SdrViewEvent& rVEvt) co
                eEvent=SdrEventKind::MarkObj;
            }
        }
        else if (eHit==SDRHIT_MACRO)
        else if (eHit==SdrHitKind::Macro)
        {
            eEvent=SdrEventKind::BeginMacroObj;       // AddMark+Drag
            if (MODKEY_MultiMark || MODKEY_DeepMark)
@@ -674,7 +674,7 @@ SdrHitKind SdrView::PickAnything(const Point& rLogicPos, SdrViewEvent& rVEvt) co
                eEvent=SdrEventKind::MarkObj;
            }
        }
        else if (eHit==SDRHIT_URLFIELD)
        else if (eHit==SdrHitKind::UrlField)
        {
            eEvent=SdrEventKind::ExecuteUrl;       // AddMark+Drag
            if (MODKEY_MultiMark || MODKEY_DeepMark)
@@ -682,7 +682,7 @@ SdrHitKind SdrView::PickAnything(const Point& rLogicPos, SdrViewEvent& rVEvt) co
                eEvent=SdrEventKind::MarkObj;
            }
        }
        else if (eHit==SDRHIT_MARKEDOBJECT)
        else if (eHit==SdrHitKind::MarkedObject)
        {
            eEvent=SdrEventKind::BeginDragObj; // DeepMark+Drag,Unmark

@@ -695,7 +695,7 @@ SdrHitKind SdrView::PickAnything(const Point& rLogicPos, SdrViewEvent& rVEvt) co
        {
            eEvent=SdrEventKind::BeginCreateObj;          // nothing, actually
        }
        else if (eHit==SDRHIT_UNMARKEDOBJECT)
        else if (eHit==SdrHitKind::UnmarkedObject)
        {
            eEvent=SdrEventKind::MarkObj;  // AddMark+Drag
        }
@@ -778,7 +778,7 @@ bool SdrView::DoMouseEvent(const SdrViewEvent& rVEvt)
    SetResizeAtCenter(MODKEY_Center);
    SetCrookAtCenter(MODKEY_Center);
#endif
    if (bMouseLeft && bMouseDown && rVEvt.bIsTextEdit && (eHit==SDRHIT_UNMARKEDOBJECT || eHit==SDRHIT_NONE)) {
    if (bMouseLeft && bMouseDown && rVEvt.bIsTextEdit && (eHit==SdrHitKind::UnmarkedObject || eHit==SdrHitKind::NONE)) {
        SdrEndTextEdit(); // User has clicked beneath object, exit edit mode.
        // pHdl is invalid, then, that shouldn't matter, though, as we expect
        // pHdl==NULL (because of eHit).
@@ -807,9 +807,9 @@ bool SdrView::DoMouseEvent(const SdrViewEvent& rVEvt)
            if (MODKEY_PolyPoly) eCmd=SdrCreateCmd::NextObject;
            if (rVEvt.nMouseClicks>1) eCmd=SdrCreateCmd::ForceEnd;
            if (!EndCreateObj(eCmd)) { // Don't evaluate event for Create? -> Select
                if (eHit==SDRHIT_UNMARKEDOBJECT || eHit==SDRHIT_TEXTEDIT) {
                if (eHit==SdrHitKind::UnmarkedObject || eHit==SdrHitKind::TextEdit) {
                    MarkObj(rVEvt.pRootObj,rVEvt.pPV);
                    if (eHit==SDRHIT_TEXTEDIT)
                    if (eHit==SdrHitKind::TextEdit)
                    {
                        bool bRet2(mpActualOutDev && OUTDEV_WINDOW == mpActualOutDev->GetOutDevType() &&
                            SdrBeginTextEdit(rVEvt.pObj, rVEvt.pPV, const_cast<vcl::Window*>(static_cast<const vcl::Window*>(mpActualOutDev.get()))));
@@ -1024,14 +1024,14 @@ Pointer SdrView::GetPreferredPointer(const Point& rMousePos, const OutputDevice*

    switch(eHit)
    {
        case SDRHIT_CELL:
        case SdrHitKind::Cell:
            return Pointer(PointerStyle::Arrow);
        case SDRHIT_HELPLINE :
        case SdrHitKind::HelpLine :
            return aVEvt.pPV->GetHelpLines()[aVEvt.nHlplIdx].GetPointer();
        case SDRHIT_GLUEPOINT:
        case SdrHitKind::Gluepoint:
            return Pointer(PointerStyle::MovePoint);
        case SDRHIT_TEXTEDIT :
        case SDRHIT_TEXTEDITOBJ:
        case SdrHitKind::TextEdit :
        case SdrHitKind::TextEditObj:
        {
            SdrTextObj* pText = dynamic_cast< SdrTextObj* >( aVEvt.pObj );
            if(pText && pText->HasText())
@@ -1045,7 +1045,7 @@ Pointer SdrView::GetPreferredPointer(const Point& rMousePos, const OutputDevice*
        default: break;
    }

    bool bMarkHit=eHit==SDRHIT_MARKEDOBJECT;
    bool bMarkHit=eHit==SdrHitKind::MarkedObject;
    SdrHdl* pHdl=aVEvt.pHdl;
    // now check the pointers for dragging
    if (pHdl!=nullptr || bMarkHit) {
diff --git a/svx/source/table/tablecontroller.cxx b/svx/source/table/tablecontroller.cxx
index fedb1aa..9dd9050 100644
--- a/svx/source/table/tablecontroller.cxx
+++ b/svx/source/table/tablecontroller.cxx
@@ -272,7 +272,7 @@ bool SvxTableController::onMouseButtonDown(const MouseEvent& rMEvt, vcl::Window*
        return false;

    SdrViewEvent aVEvt;
    if( !rMEvt.IsRight() && mpView->PickAnything(rMEvt,SdrMouseEventKind::BUTTONDOWN, aVEvt) == SDRHIT_HANDLE )
    if( !rMEvt.IsRight() && mpView->PickAnything(rMEvt,SdrMouseEventKind::BUTTONDOWN, aVEvt) == SdrHitKind::Handle )
        return false;

    TableHitKind eHit = static_cast< SdrTableObj* >(mxTableObj.get())->CheckTableHit(pixelToLogic(rMEvt.GetPosPixel(), pWindow), maMouseDownPos.mnCol, maMouseDownPos.mnRow);
@@ -1911,7 +1911,7 @@ void SvxTableController::EditCell( const CellPos& rPos, vcl::Window* pWindow, co
                    SdrViewEvent aVEvt;
                    SdrHitKind eHit = mpView->PickAnything(aMEvt, SdrMouseEventKind::BUTTONDOWN, aVEvt);

                    if (eHit == SDRHIT_TEXTEDIT)
                    if (eHit == SdrHitKind::TextEdit)
                    {
                        // Text getroffen
                        pOLV->MouseButtonDown(aMEvt);
diff --git a/sw/inc/fesh.hxx b/sw/inc/fesh.hxx
index df98694..7913fbc 100644
--- a/sw/inc/fesh.hxx
+++ b/sw/inc/fesh.hxx
@@ -290,7 +290,7 @@ public:
    bool IsObjSelectable( const Point& rPt );
    /// Same as IsObjSelectable(), but return the object as well.
    SdrObject* GetObjAt(const Point& rPt);
    int IsInsideSelectedObj( const Point& rPt );    ///< returns enum values
    bool IsInsideSelectedObj( const Point& rPt );    ///< returns enum values
    /** Test if there is a draw object at that position and if it should be selected.
     The 'should' is aimed at Writer text fly frames which may be in front of
     the draw object. */
diff --git a/sw/source/core/frmedt/feshview.cxx b/sw/source/core/frmedt/feshview.cxx
index 3f276cf..ac26e80 100644
--- a/sw/source/core/frmedt/feshview.cxx
+++ b/sw/source/core/frmedt/feshview.cxx
@@ -1064,7 +1064,7 @@ void SwFEShell::EndTextEdit()
    EndAllAction();
}

int SwFEShell::IsInsideSelectedObj( const Point &rPt )
bool SwFEShell::IsInsideSelectedObj( const Point &rPt )
{
    if( Imp()->HasDrawView() )
    {
@@ -1073,10 +1073,10 @@ int SwFEShell::IsInsideSelectedObj( const Point &rPt )
        if( pDView->GetMarkedObjectList().GetMarkCount() &&
            pDView->IsMarkedObjHit( rPt ) )
        {
            return SDRHIT_OBJECT;
            return true;
        }
    }
    return SDRHIT_NONE;
    return false;
}

bool SwFEShell::IsObjSelectable( const Point& rPt )
diff --git a/sw/source/uibase/docvw/edtwin.cxx b/sw/source/uibase/docvw/edtwin.cxx
index 0eae529f..97c424f 100644
--- a/sw/source/uibase/docvw/edtwin.cxx
+++ b/sw/source/uibase/docvw/edtwin.cxx
@@ -448,13 +448,13 @@ void SwEditWin::UpdatePointer(const Point &rLPt, sal_uInt16 nModifier )
    bool bCntAtPos = false;
    bool bIsDocReadOnly = m_rView.GetDocShell()->IsReadOnly() &&
                          rSh.IsCursorReadonly();
    m_aActHitType = SDRHIT_NONE;
    m_aActHitType = SdrHitKind::NONE;
    PointerStyle eStyle = PointerStyle::Text;
    if ( !pSdrView )
        bCntAtPos = true;
    else if ( (bHitHandle = pSdrView->PickHandle( rLPt ) != nullptr) )
    {
        m_aActHitType = SDRHIT_OBJECT;
        m_aActHitType = SdrHitKind::Object;
        bPrefSdrPointer = true;
    }
    else
@@ -462,7 +462,7 @@ void SwEditWin::UpdatePointer(const Point &rLPt, sal_uInt16 nModifier )
        const bool bNotInSelObj = !rSh.IsInsideSelectedObj( rLPt );
        if ( m_rView.GetDrawFuncPtr() && !m_bInsDraw && bNotInSelObj )
        {
            m_aActHitType = SDRHIT_OBJECT;
            m_aActHitType = SdrHitKind::Object;
            if (IsObjectSelect())
                eStyle = PointerStyle::Arrow;
            else
@@ -490,7 +490,7 @@ void SwEditWin::UpdatePointer(const Point &rLPt, sal_uInt16 nModifier )
                {
                    if (pSdrView->IsTextEdit())
                    {
                        m_aActHitType = SDRHIT_NONE;
                        m_aActHitType = SdrHitKind::NONE;
                        bPrefSdrPointer = true;
                    }
                    else
@@ -498,9 +498,9 @@ void SwEditWin::UpdatePointer(const Point &rLPt, sal_uInt16 nModifier )
                        SdrViewEvent aVEvt;
                        SdrHitKind eHit = pSdrView->PickAnything(rLPt, aVEvt);

                        if (eHit == SDRHIT_URLFIELD && bExecHyperlinks)
                        if (eHit == SdrHitKind::UrlField && bExecHyperlinks)
                        {
                            m_aActHitType = SDRHIT_OBJECT;
                            m_aActHitType = SdrHitKind::Object;
                            bPrefSdrPointer = true;
                        }
                        else
@@ -518,7 +518,7 @@ void SwEditWin::UpdatePointer(const Point &rLPt, sal_uInt16 nModifier )
                            // Don't update pointer if this is a background image only.
                            if (pSelectableObj->GetLayer() != rSh.GetDoc()->getIDocumentDrawModelAccess().GetHellId())
                                eStyle = bMovable ? PointerStyle::Move : PointerStyle::Arrow;
                            m_aActHitType = SDRHIT_OBJECT;
                            m_aActHitType = SdrHitKind::Object;
                        }
                    }
                }
@@ -538,7 +538,7 @@ void SwEditWin::UpdatePointer(const Point &rLPt, sal_uInt16 nModifier )
                            eStyle = PointerStyle::NotAllowed;
                        else
                            eStyle = PointerStyle::Move;
                        m_aActHitType = SDRHIT_OBJECT;
                        m_aActHitType = SdrHitKind::Object;
                    }
                    else
                    {
@@ -3212,7 +3212,7 @@ void SwEditWin::MouseButtonDown(const MouseEvent& _rMEvt)
                    bHandledFlyClick = true;
                    // only try to select frame, if pointer already was
                    // switched accordingly
                    if ( m_aActHitType != SDRHIT_NONE && !rSh.IsSelFrameMode() &&
                    if ( m_aActHitType != SdrHitKind::NONE && !rSh.IsSelFrameMode() &&
                        !GetView().GetViewFrame()->GetDispatcher()->IsLocked() &&
                        !bExecDrawTextLink)
                    {
@@ -3263,7 +3263,7 @@ void SwEditWin::MouseButtonDown(const MouseEvent& _rMEvt)
                            bOnlyText = KEY_MOD1 != rMEvt.GetModifier();
                    }
                    else if ( rSh.IsSelFrameMode() &&
                              (m_aActHitType == SDRHIT_NONE ||
                              (m_aActHitType == SdrHitKind::NONE ||
                               !rSh.IsInsideSelectedObj( aDocPos )))
                    {
                        m_rView.NoRotate();
@@ -4975,7 +4975,7 @@ void SwEditWin::MouseButtonUp(const MouseEvent& rMEvt)
        SdrViewEvent aViewEvent;
        SdrHitKind eHit = pSdrView->PickAnything(rMEvt, SdrMouseEventKind::BUTTONUP, aViewEvent);
        const SdrMarkList& rMarkList = pSdrView->GetMarkedObjectList();
        if (eHit == SDRHIT_TEXTEDITOBJ && rMarkList.GetMarkCount() == 1)
        if (eHit == SdrHitKind::TextEditObj && rMarkList.GetMarkCount() == 1)
        {
            if (SdrObject* pObj = rMarkList.GetMark(0)->GetMarkedSdrObj())
            {
@@ -5061,7 +5061,7 @@ SwEditWin::SwEditWin(vcl::Window *pParent, SwView &rMyView):

    m_rView( rMyView ),

    m_aActHitType(SDRHIT_NONE),
    m_aActHitType(SdrHitKind::NONE),
    m_nDropFormat( SotClipboardFormatId::NONE ),
    m_nDropAction( 0 ),
    m_nDropDestination( SotExchangeDest::NONE ),
@@ -5799,7 +5799,7 @@ void SwEditWin::SelectMenuPosition(SwWrtShell& rSh, const Point& rMousePos )
        }
    }
    else if ( rSh.IsSelFrameMode() &&
              (m_aActHitType == SDRHIT_NONE ||
              (m_aActHitType == SdrHitKind::NONE ||
               !bIsInsideSelectedObj))
    {
        m_rView.NoRotate();
diff --git a/sw/source/uibase/inc/edtwin.hxx b/sw/source/uibase/inc/edtwin.hxx
index f689f1b..38772c9 100644
--- a/sw/source/uibase/inc/edtwin.hxx
+++ b/sw/source/uibase/inc/edtwin.hxx
@@ -44,6 +44,7 @@ struct  SwApplyTemplate;
struct  QuickHelpData;
class   SdrDropMarkerOverlay;
class   SwFrameControlsManager;
enum class SdrHitKind;

// input window

@@ -107,7 +108,7 @@ friend void     PageNumNotify(  SwViewShell* pVwSh,

    SwView         &m_rView;

    int             m_aActHitType;    // current mouse pointer
    SdrHitKind      m_aActHitType;    // current mouse pointer

    SotClipboardFormatId m_nDropFormat;  // format from the last QueryDrop
    sal_uInt8       m_nDropAction;       // action from the last QueryDrop
diff --git a/sw/source/uibase/ribbar/conform.cxx b/sw/source/uibase/ribbar/conform.cxx
index 401ba17..4c46d3c1 100644
--- a/sw/source/uibase/ribbar/conform.cxx
+++ b/sw/source/uibase/ribbar/conform.cxx
@@ -60,7 +60,7 @@ bool ConstFormControl::MouseButtonDown(const MouseEvent& rMEvt)

    // Only new object; if not in base mode (or pure selection mode)
    if (rMEvt.IsLeft() && !m_pWin->IsDrawAction() &&
        (eHit == SDRHIT_UNMARKEDOBJECT || eHit == SDRHIT_NONE || m_pSh->IsDrawCreate()))
        (eHit == SdrHitKind::UnmarkedObject || eHit == SdrHitKind::NONE || m_pSh->IsDrawCreate()))
    {
        g_bNoInterrupt = true;
        m_pWin->CaptureMouse();
diff --git a/sw/source/uibase/ribbar/drawbase.cxx b/sw/source/uibase/ribbar/drawbase.cxx
index 45737ab..d038250 100644
--- a/sw/source/uibase/ribbar/drawbase.cxx
+++ b/sw/source/uibase/ribbar/drawbase.cxx
@@ -86,7 +86,7 @@ bool SwDrawBase::MouseButtonDown(const MouseEvent& rMEvt)
    // Only new object, if not in the basic mode (or pure selection mode).
    if (rMEvt.IsLeft() && !m_pWin->IsDrawAction())
    {
        if (IsCreateObj() && (eHit == SDRHIT_UNMARKEDOBJECT || eHit == SDRHIT_NONE || m_pSh->IsDrawCreate()))
        if (IsCreateObj() && (eHit == SdrHitKind::UnmarkedObject || eHit == SdrHitKind::NONE || m_pSh->IsDrawCreate()))
        {
            g_bNoInterrupt = true;
            m_pWin->CaptureMouse();
@@ -107,21 +107,21 @@ bool SwDrawBase::MouseButtonDown(const MouseEvent& rMEvt)
            m_aStartPos = m_pWin->PixelToLogic(rMEvt.GetPosPixel());
            sal_uInt16 nEditMode = m_pWin->GetBezierMode();

            if (eHit == SDRHIT_HANDLE && aVEvt.pHdl->GetKind() == HDL_BWGT)
            if (eHit == SdrHitKind::Handle && aVEvt.pHdl->GetKind() == HDL_BWGT)
            {
                // Drag handle
                g_bNoInterrupt = true;
                bReturn = pSdrView->BegDragObj(m_aStartPos, nullptr, aVEvt.pHdl);
                m_pWin->SetDrawAction(true);
            }
            else if (eHit == SDRHIT_MARKEDOBJECT && nEditMode == SID_BEZIER_INSERT)
            else if (eHit == SdrHitKind::MarkedObject && nEditMode == SID_BEZIER_INSERT)
            {
                // Insert gluepoint
                g_bNoInterrupt = true;
                bReturn = pSdrView->BegInsObjPoint(m_aStartPos, rMEvt.IsMod1());
                m_pWin->SetDrawAction(true);
            }
            else if (eHit == SDRHIT_MARKEDOBJECT && rMEvt.IsMod1())
            else if (eHit == SdrHitKind::MarkedObject && rMEvt.IsMod1())
            {
                // Select gluepoint
                if (!rMEvt.IsShift())
@@ -130,12 +130,12 @@ bool SwDrawBase::MouseButtonDown(const MouseEvent& rMEvt)
                bReturn = pSdrView->BegMarkPoints(m_aStartPos);
                m_pWin->SetDrawAction(true);
            }
            else if (eHit == SDRHIT_MARKEDOBJECT && !rMEvt.IsShift() && !rMEvt.IsMod2())
            else if (eHit == SdrHitKind::MarkedObject && !rMEvt.IsShift() && !rMEvt.IsMod2())
            {
                // Move objekt
                return false;
            }
            else if (eHit == SDRHIT_HANDLE)
            else if (eHit == SdrHitKind::Handle)
            {
                // Select gluepoint
                if (pSdrView->HasMarkablePoints() && (!pSdrView->IsPointMarked(*aVEvt.pHdl) || rMEvt.IsShift()))
@@ -170,7 +170,7 @@ bool SwDrawBase::MouseButtonDown(const MouseEvent& rMEvt)
            else
            {
                // Select or drag object
                if (m_pSh->IsObjSelectable(m_aStartPos) && eHit == SDRHIT_UNMARKEDOBJECT)
                if (m_pSh->IsObjSelectable(m_aStartPos) && eHit == SdrHitKind::UnmarkedObject)
                {
                    if (pSdrView->HasMarkablePoints())
                        pSdrView->UnmarkAllPoints();