Kaydet (Commit) 0f00751a authored tarafından Caolán McNamara's avatar Caolán McNamara

unwind RID_STYLE_DESIGNER_IMAGELIST ImageList

Change-Id: I8fd69aa8acc8aa2bb1705b3819cf089e618464b5
üst a15bdfa3
...@@ -57,11 +57,14 @@ ...@@ -57,11 +57,14 @@
#define STR_PDF_EXPORT_SEND ( RC_DIALOG_BEGIN + 120 ) #define STR_PDF_EXPORT_SEND ( RC_DIALOG_BEGIN + 120 )
#define IMG_INFO ( RC_DIALOG_BEGIN + 122 ) #define IMG_INFO ( RC_DIALOG_BEGIN + 122 )
#define RID_STYLE_DESIGNER_IMAGELIST ( RC_DIALOG_BEGIN + 123 ) //free
#define SFX_ST_EDIT ( RC_DIALOG_BEGIN + 124 ) #define SFX_ST_EDIT ( RC_DIALOG_BEGIN + 124 )
#define STR_STYLE_ELEMTLIST ( RC_DIALOG_BEGIN + 125 ) #define STR_STYLE_ELEMTLIST ( RC_DIALOG_BEGIN + 125 )
#define STR_FONT_TABPAGE ( RC_DIALOG_BEGIN + 126 ) #define STR_FONT_TABPAGE ( RC_DIALOG_BEGIN + 126 )
#define STR_PREVIEW_CHECKBOX ( RC_DIALOG_BEGIN + 127 ) #define STR_PREVIEW_CHECKBOX ( RC_DIALOG_BEGIN + 127 )
#define RID_SFXBMP_WATERCAN ( RC_DIALOG_BEGIN + 128 )
#define RID_SFXBMP_NEW_BY_EXAMPLE ( RC_DIALOG_BEGIN + 129 )
#define RID_SFXBMP_UPDATE_BY_EXAMPLE ( RC_DIALOG_BEGIN + 130 )
#endif #endif
......
...@@ -343,8 +343,6 @@ SfxTemplatePanelControl::SfxTemplatePanelControl(SfxBindings* pBindings, vcl::Wi ...@@ -343,8 +343,6 @@ SfxTemplatePanelControl::SfxTemplatePanelControl(SfxBindings* pBindings, vcl::Wi
{ {
OSL_ASSERT(mpBindings!=nullptr); OSL_ASSERT(mpBindings!=nullptr);
pImpl->setNonFamilyImages();
SetStyle(GetStyle() & ~WB_DOCKABLE); SetStyle(GetStyle() & ~WB_DOCKABLE);
} }
...@@ -2176,26 +2174,26 @@ SfxTemplateDialog_Impl::SfxTemplateDialog_Impl(SfxBindings* pB, SfxTemplatePanel ...@@ -2176,26 +2174,26 @@ SfxTemplateDialog_Impl::SfxTemplateDialog_Impl(SfxBindings* pB, SfxTemplatePanel
::comphelper::getProcessComponentContext()) ); ::comphelper::getProcessComponentContext()) );
uno::Reference< container::XNameAccess > xUICommands; uno::Reference< container::XNameAccess > xUICommands;
OUString sTextDoc("com.sun.star.text.TextDocument"); OUString sTextDoc("com.sun.star.text.TextDocument");
if(xNameAccess->hasByName(sTextDoc)) if (xNameAccess->hasByName(sTextDoc))
{ {
uno::Any a = xNameAccess->getByName( sTextDoc ); uno::Any a = xNameAccess->getByName(sTextDoc);
a >>= xUICommands; a >>= xUICommands;
} }
if (xUICommands.is()) if (xUICommands.is())
{ {
uno::Any aCommand = xUICommands->getByName(".uno:StyleApply"); uno::Any aCommand = xUICommands->getByName(".uno:StyleApply");
OUString sLabel = lcl_GetLabel( aCommand ); OUString sLabel = lcl_GetLabel( aCommand );
m_aActionTbR->InsertItem( SID_STYLE_WATERCAN, sLabel ); m_aActionTbR->InsertItem(SID_STYLE_WATERCAN, Image(BitmapEx(SfxResId(RID_SFXBMP_WATERCAN))), sLabel);
m_aActionTbR->SetHelpId(SID_STYLE_WATERCAN, HID_TEMPLDLG_WATERCAN); m_aActionTbR->SetHelpId(SID_STYLE_WATERCAN, HID_TEMPLDLG_WATERCAN);
aCommand = xUICommands->getByName(".uno:StyleNewByExample"); aCommand = xUICommands->getByName(".uno:StyleNewByExample");
sLabel = lcl_GetLabel( aCommand ); sLabel = lcl_GetLabel( aCommand );
m_aActionTbR->InsertItem( SID_STYLE_NEW_BY_EXAMPLE, sLabel ); m_aActionTbR->InsertItem(SID_STYLE_NEW_BY_EXAMPLE, Image(BitmapEx(SfxResId(RID_SFXBMP_NEW_BY_EXAMPLE))), sLabel);
m_aActionTbR->SetHelpId(SID_STYLE_NEW_BY_EXAMPLE, HID_TEMPLDLG_NEWBYEXAMPLE); m_aActionTbR->SetHelpId(SID_STYLE_NEW_BY_EXAMPLE, HID_TEMPLDLG_NEWBYEXAMPLE);
aCommand = xUICommands->getByName(".uno:StyleUpdateByExample"); aCommand = xUICommands->getByName(".uno:StyleUpdateByExample");
sLabel = lcl_GetLabel( aCommand ); sLabel = lcl_GetLabel( aCommand );
m_aActionTbR->InsertItem( SID_STYLE_UPDATE_BY_EXAMPLE, sLabel ); m_aActionTbR->InsertItem(SID_STYLE_UPDATE_BY_EXAMPLE, Image(BitmapEx(SfxResId(RID_SFXBMP_UPDATE_BY_EXAMPLE))), sLabel);
m_aActionTbR->SetHelpId(SID_STYLE_UPDATE_BY_EXAMPLE, HID_TEMPLDLG_UPDATEBYEXAMPLE); m_aActionTbR->SetHelpId(SID_STYLE_UPDATE_BY_EXAMPLE, HID_TEMPLDLG_UPDATEBYEXAMPLE);
} }
} }
...@@ -2251,11 +2249,6 @@ void SfxTemplateDialog_Impl::ReplaceUpdateButtonByMenu() ...@@ -2251,11 +2249,6 @@ void SfxTemplateDialog_Impl::ReplaceUpdateButtonByMenu()
ToolBoxItemBits::DROPDOWNONLY|m_aActionTbR->GetItemBits( SID_STYLE_NEW_BY_EXAMPLE )); ToolBoxItemBits::DROPDOWNONLY|m_aActionTbR->GetItemBits( SID_STYLE_NEW_BY_EXAMPLE ));
} }
void SfxTemplateDialog_Impl::setNonFamilyImages()
{
m_aActionTbR->SetImageList(ImageList(SfxResId(RID_STYLE_DESIGNER_IMAGELIST)));
}
void SfxTemplateDialog_Impl::ClearFamilyList() void SfxTemplateDialog_Impl::ClearFamilyList()
{ {
m_aActionTbL->Clear(); m_aActionTbL->Clear();
......
...@@ -21,16 +21,19 @@ ...@@ -21,16 +21,19 @@
#include "dialog.hrc" #include "dialog.hrc"
#include "helpid.hrc" #include "helpid.hrc"
ImageList RID_STYLE_DESIGNER_IMAGELIST Bitmap RID_SFXBMP_WATERCAN
{ {
Prefix = "sc"; File = "sc05554.png";
IdList = };
{
SID_STYLE_WATERCAN ; Bitmap RID_SFXBMP_NEW_BY_EXAMPLE
SID_STYLE_NEW_BY_EXAMPLE ; {
SID_STYLE_UPDATE_BY_EXAMPLE ; File = "sc05555.png";
}; };
IdCount = { 3 ; };
Bitmap RID_SFXBMP_UPDATE_BY_EXAMPLE
{
File = "sc05556.png";
}; };
// Strings --------------------------------------------------------------- // Strings ---------------------------------------------------------------
......
...@@ -367,8 +367,6 @@ protected: ...@@ -367,8 +367,6 @@ protected:
void Resize(); void Resize();
Size GetMinOutputSizePixel(); Size GetMinOutputSizePixel();
void setNonFamilyImages();
public: public:
friend class SfxTemplateDialog; friend class SfxTemplateDialog;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment