tdf#161853 vcl: Drop unnecessary indirection for icon choice control

Just call `SvxIconChoiceCtrl_Impl::SetEntryTextMode` directly,
instead of doing so via the `pView`, and drop the now unused
`SvtIconChoiceCtrl::SetEntryTextMode`.

Change-Id: I9b42f1bee6984e2c34814addd998cefd56dbe7f0
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/169837
Reviewed-by: Michael Weghorn <m.weghorn@posteo.de>
Tested-by: Jenkins
diff --git a/include/vcl/toolkit/ivctrl.hxx b/include/vcl/toolkit/ivctrl.hxx
index ad7aa62..7b593d0 100644
--- a/include/vcl/toolkit/ivctrl.hxx
+++ b/include/vcl/toolkit/ivctrl.hxx
@@ -222,10 +222,6 @@ public:

    SvxIconChoiceCtrlEntry* GetSelectedEntry() const;

#ifdef DBG_UTIL
    void                    SetEntryTextMode(SvxIconChoiceCtrlTextMode eMode, SvxIconChoiceCtrlEntry& rEntry);
#endif

    tools::Rectangle           GetBoundingBox( SvxIconChoiceCtrlEntry* pEntry ) const;
    tools::Rectangle           GetEntryCharacterBounds( const sal_Int32 _nEntryPos, const sal_Int32 _nCharacterIndex ) const;

diff --git a/vcl/source/control/imivctl1.cxx b/vcl/source/control/imivctl1.cxx
index ed52e38..e9dbc56 100644
--- a/vcl/source/control/imivctl1.cxx
+++ b/vcl/source/control/imivctl1.cxx
@@ -979,12 +979,12 @@ bool SvxIconChoiceCtrl_Impl::KeyInput( const KeyEvent& rKEvt )
            if( rKEvt.GetKeyCode().IsShift() )
            {
                if( pCursor )
                    pView->SetEntryTextMode(SvxIconChoiceCtrlTextMode::Full, *pCursor);
                    SetEntryTextMode(SvxIconChoiceCtrlTextMode::Full, *pCursor);
            }
            if( rKEvt.GetKeyCode().IsMod1() )
            {
                if( pCursor )
                    pView->SetEntryTextMode(SvxIconChoiceCtrlTextMode::Short, *pCursor);
                    SetEntryTextMode(SvxIconChoiceCtrlTextMode::Short, *pCursor);
            }
            break;
#endif
diff --git a/vcl/source/control/ivctrl.cxx b/vcl/source/control/ivctrl.cxx
index 2afe55a..61fa316 100644
--- a/vcl/source/control/ivctrl.cxx
+++ b/vcl/source/control/ivctrl.cxx
@@ -238,13 +238,6 @@ void SvtIconChoiceCtrl::Command(const CommandEvent& rCEvt)
        Control::Command(rCEvt);
}

#ifdef DBG_UTIL
void SvtIconChoiceCtrl::SetEntryTextMode( SvxIconChoiceCtrlTextMode eMode, SvxIconChoiceCtrlEntry& rEntry )
{
    _pImpl->SetEntryTextMode(eMode, rEntry);
}
#endif

sal_Int32 SvtIconChoiceCtrl::GetEntryCount() const
{
    return _pImpl ? _pImpl->GetEntryCount() : 0;