diff options
author | Noel Power <noel.power@novell.com> | 2012-02-13 14:19:22 +0000 |
---|---|---|
committer | Noel Power <noel.power@novell.com> | 2012-02-13 14:51:36 +0000 |
commit | 468c588875b4858711b708bbc66e0740263bb1f3 (patch) | |
tree | 68aeb3b053268e337cd911c1280c895b2b58aaf2 /toolkit/inc | |
parent | ebba94a9572b4154a4106380d949be3d83a68fa5 (diff) |
fix support for embedded images for basic Dialogs ( fdo#45992 )
Diffstat (limited to 'toolkit/inc')
-rw-r--r-- | toolkit/inc/toolkit/controls/controlmodelcontainerbase.hxx | 1 | ||||
-rw-r--r-- | toolkit/inc/toolkit/controls/dialogcontrol.hxx | 4 | ||||
-rw-r--r-- | toolkit/inc/toolkit/controls/unocontrols.hxx | 13 |
3 files changed, 17 insertions, 1 deletions
diff --git a/toolkit/inc/toolkit/controls/controlmodelcontainerbase.hxx b/toolkit/inc/toolkit/controls/controlmodelcontainerbase.hxx index 9e999687d543..d307c2aca3bb 100644 --- a/toolkit/inc/toolkit/controls/controlmodelcontainerbase.hxx +++ b/toolkit/inc/toolkit/controls/controlmodelcontainerbase.hxx @@ -234,7 +234,6 @@ protected: virtual void ImplSetPosSize( ::com::sun::star::uno::Reference< ::com::sun::star::awt::XControl >& rxCtrl ); void ImplUpdateResourceResolver(); void ImplStartListingForResourceEvents(); - ::com::sun::star::uno::Reference< ::com::sun::star::graphic::XGraphic > Impl_getGraphicFromURL_nothrow( const ::rtl::OUString& _rURL ); ControlContainerBase(); diff --git a/toolkit/inc/toolkit/controls/dialogcontrol.hxx b/toolkit/inc/toolkit/controls/dialogcontrol.hxx index 961d449241ea..7c9a6749416e 100644 --- a/toolkit/inc/toolkit/controls/dialogcontrol.hxx +++ b/toolkit/inc/toolkit/controls/dialogcontrol.hxx @@ -34,6 +34,7 @@ #include <com/sun/star/awt/XDialog2.hpp> #include <com/sun/star/awt/XSimpleTabController.hpp> #include <com/sun/star/resource/XStringResourceResolver.hpp> +#include <com/sun/star/graphic/XGraphicObject.hpp> #include "toolkit/helper/servicenames.hxx" #include "toolkit/helper/macros.hxx" #include <toolkit/controls/unocontrolcontainer.hxx> @@ -48,8 +49,11 @@ class UnoControlDialogModel : public ControlModelContainerBase { protected: + ::com::sun::star::uno::Reference< ::com::sun::star::graphic::XGraphicObject > mxGrfObj; ::com::sun::star::uno::Any ImplGetDefaultValue( sal_uInt16 nPropId ) const; ::cppu::IPropertyArrayHelper& SAL_CALL getInfoHelper(); + // ::cppu::OPropertySetHelper + void SAL_CALL setFastPropertyValue_NoBroadcast( sal_Int32 nHandle, const ::com::sun::star::uno::Any& rValue ) throw (::com::sun::star::uno::Exception); public: UnoControlDialogModel( const ::com::sun::star::uno::Reference< ::com::sun::star::lang::XMultiServiceFactory >& i_factory ); UnoControlDialogModel( const UnoControlDialogModel& rModel ); diff --git a/toolkit/inc/toolkit/controls/unocontrols.hxx b/toolkit/inc/toolkit/controls/unocontrols.hxx index 201858da0a12..2ed2cf724016 100644 --- a/toolkit/inc/toolkit/controls/unocontrols.hxx +++ b/toolkit/inc/toolkit/controls/unocontrols.hxx @@ -72,6 +72,19 @@ #define UNO_NAME_GRAPHOBJ_URLPREFIX "vnd.sun.star.GraphicObject:" #define UNO_NAME_GRAPHOBJ_URLPKGPREFIX "vnd.sun.star.Package:" +class ImageHelper +{ +public: + // The routine will always attempt to return a valid XGraphic for the + // passed _rURL, additionallly xOutGraphicObject will contain the + // associated XGraphicObject ( if url is valid for that ) and is set + // appropriately ( e.g. NULL if non GraphicObject scheme ) or a valid + // object if the rURL points to a valid object + static ::com::sun::star::uno::Reference< ::com::sun::star::graphic::XGraphic > getGraphicAndGraphicObjectFromURL_nothrow( ::com::sun::star::uno::Reference< ::com::sun::star::graphic::XGraphicObject >& xOutGraphicObject, const ::rtl::OUString& _rURL ); + static ::com::sun::star::uno::Reference< ::com::sun::star::graphic::XGraphic > getGraphicFromURL_nothrow( const ::rtl::OUString& _rURL ); + +}; + // ---------------------------------------------------- // class UnoControlEditModel // ---------------------------------------------------- |