summaryrefslogtreecommitdiff
path: root/framework
diff options
context:
space:
mode:
authorCaolán McNamara <caolanm@redhat.com>2021-12-12 21:06:15 +0000
committerCaolán McNamara <caolanm@redhat.com>2021-12-13 10:02:43 +0100
commit74094ffd2a138e9776b6a8cc70e64e5f794773ae (patch)
tree662c7462c347ab9e84c1ad8b908ff99afa9c3dcf /framework
parent5ae0a6026c66632e3f6958dd70d785865be2f81c (diff)
prefer css::awt::XPopupMenu api
Change-Id: Ibb5984a588e21f9b761b6f56933394874c09dd88 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/126709 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
Diffstat (limited to 'framework')
-rw-r--r--framework/source/uielement/recentfilesmenucontroller.cxx10
1 files changed, 5 insertions, 5 deletions
diff --git a/framework/source/uielement/recentfilesmenucontroller.cxx b/framework/source/uielement/recentfilesmenucontroller.cxx
index 2fed76c36fc1..a805468850bc 100644
--- a/framework/source/uielement/recentfilesmenucontroller.cxx
+++ b/framework/source/uielement/recentfilesmenucontroller.cxx
@@ -23,15 +23,15 @@
#include <comphelper/propertyvalue.hxx>
#include <cppuhelper/supportsservice.hxx>
#include <osl/mutex.hxx>
+#include <svtools/imagemgr.hxx>
#include <svtools/popupmenucontrollerbase.hxx>
#include <tools/urlobj.hxx>
#include <toolkit/awt/vclxmenu.hxx>
#include <unotools/historyoptions.hxx>
+#include <vcl/graph.hxx>
#include <vcl/menu.hxx>
-#include <vcl/svapp.hxx>
-#include <vcl/image.hxx>
#include <vcl/settings.hxx>
-#include <svtools/imagemgr.hxx>
+#include <vcl/svapp.hxx>
using namespace css;
using namespace com::sun::star::uno;
@@ -194,8 +194,8 @@ void RecentFilesMenuController::fillPopupMenu( Reference< css::awt::XPopupMenu >
rPopupMenu->insertItem(sal_uInt16( i+1 ), aMenuShortCut.makeStringAndClear(), 0, -1);
if ( bIsIconsAllowed ) {
- Image aThumbnail = SvFileInformationManager::GetImage(aURL, false, {});
- pVCLPopupMenu->SetItemImage(sal_uInt16 ( i+1 ), aThumbnail);
+ BitmapEx aThumbnail(SvFileInformationManager::GetImageId(aURL, false));
+ rPopupMenu->setItemImage(sal_uInt16(i + 1), Graphic(aThumbnail).GetXGraphic(), false);
}
rPopupMenu->setTipHelpText(sal_uInt16(i + 1), aTipHelpText);