Kaydet (Commit) 3f7f957e authored tarafından Caolán McNamara's avatar Caolán McNamara

convert macro dialog to .ui format

Change-Id: I5c832f3eaa6aefe2d652173289ef306e8743d4e0
üst daccedee
...@@ -17,6 +17,7 @@ $(eval $(call gb_UI_add_uifiles,cui,\ ...@@ -17,6 +17,7 @@ $(eval $(call gb_UI_add_uifiles,cui,\
cui/uiconfig/ui/insertoleobject \ cui/uiconfig/ui/insertoleobject \
cui/uiconfig/ui/insertplugin \ cui/uiconfig/ui/insertplugin \
cui/uiconfig/ui/insertrowcolumn \ cui/uiconfig/ui/insertrowcolumn \
cui/uiconfig/ui/scriptorganizer \
cui/uiconfig/ui/macroselectordialog \ cui/uiconfig/ui/macroselectordialog \
cui/uiconfig/ui/positionpage \ cui/uiconfig/ui/positionpage \
cui/uiconfig/ui/specialcharacters \ cui/uiconfig/ui/specialcharacters \
......
...@@ -36,12 +36,6 @@ ...@@ -36,12 +36,6 @@
#define STR_LOADACCELCONFIG 46 #define STR_LOADACCELCONFIG 46
#define STR_SAVEACCELCONFIG 47 #define STR_SAVEACCELCONFIG 47
#define IMG_HARDDISK 48
#define STR_PRODMACROS 50
#define STR_MYMACROS 51
#define IMG_LIB 52
#define IMG_MACRO 54
#define IMG_DOC 56
#define STR_GROUP_STYLES 58 #define STR_GROUP_STYLES 58
#define STR_PDF_EXPORT_SEND 59 #define STR_PDF_EXPORT_SEND 59
#define IMG_INFO 61 #define IMG_INFO 61
...@@ -49,6 +43,5 @@ ...@@ -49,6 +43,5 @@
#define BMP_COLLAPSED 63 #define BMP_COLLAPSED 63
#define BMP_EXPANDED 64 #define BMP_EXPANDED 64
#define STR_BASICMACROS 67 #define STR_BASICMACROS 67
#define STR_DLG_MACROS 68
#define STR_HUMAN_APPNAME 69 #define STR_HUMAN_APPNAME 69
#define STR_FILTERNAME_CFG 70 #define STR_FILTERNAME_CFG 70
...@@ -198,22 +198,10 @@ TabPage RID_SVXPAGE_KEYBOARD ...@@ -198,22 +198,10 @@ TabPage RID_SVXPAGE_KEYBOARD
Resource RID_SVXPAGE_CONFIGGROUPBOX Resource RID_SVXPAGE_CONFIGGROUPBOX
{ {
String STR_MYMACROS
{
Text [ en-US ] = "My Macros";
};
String STR_PRODMACROS
{
Text [ en-US ] = "%PRODUCTNAME Macros";
};
String STR_BASICMACROS String STR_BASICMACROS
{ {
Text [ en-US ] = "BASIC Macros" ; Text [ en-US ] = "BASIC Macros" ;
}; };
String STR_DLG_MACROS
{
Text [ en-US ] = "%PRODUCTNAME Macros" ;
};
String STR_HUMAN_APPNAME String STR_HUMAN_APPNAME
{ {
TEXT = "%PRODUCTNAME" ; TEXT = "%PRODUCTNAME" ;
...@@ -222,26 +210,6 @@ Resource RID_SVXPAGE_CONFIGGROUPBOX ...@@ -222,26 +210,6 @@ Resource RID_SVXPAGE_CONFIGGROUPBOX
{ {
Text [ en-US ] = "Styles" ; Text [ en-US ] = "Styles" ;
}; };
Image IMG_HARDDISK
{
ImageBitmap = Bitmap { File = "harddisk_16.bmp" ; };
MASKCOLOR
};
Image IMG_LIB
{
ImageBitmap = Bitmap { File = "im30820.png"; };
MASKCOLOR
};
Image IMG_MACRO
{
ImageBitmap = Bitmap { File = "im30821.png"; };
MASKCOLOR
};
Image IMG_DOC
{
ImageBitmap = Bitmap { File = "im30826.png"; };
MASKCOLOR
};
Image BMP_COLLAPSED Image BMP_COLLAPSED
{ {
ImageBitmap = Bitmap ImageBitmap = Bitmap
......
...@@ -387,16 +387,16 @@ struct SvxConfigGroupBoxResource_Impl : public Resource ...@@ -387,16 +387,16 @@ struct SvxConfigGroupBoxResource_Impl : public Resource
SvxConfigGroupBoxResource_Impl::SvxConfigGroupBoxResource_Impl() : SvxConfigGroupBoxResource_Impl::SvxConfigGroupBoxResource_Impl() :
Resource(CUI_RES(RID_SVXPAGE_CONFIGGROUPBOX)), Resource(CUI_RES(RID_SVXPAGE_CONFIGGROUPBOX)),
m_hdImage(CUI_RES(IMG_HARDDISK)), m_hdImage(CUI_RES(RID_CUIIMG_HARDDISK)),
m_libImage(CUI_RES(IMG_LIB)), m_libImage(CUI_RES(RID_CUIIMG_LIB)),
m_macImage(CUI_RES(IMG_MACRO)), m_macImage(CUI_RES(RID_CUIIMG_MACRO)),
m_docImage(CUI_RES(IMG_DOC)), m_docImage(CUI_RES(RID_CUIIMG_DOC)),
m_sMyMacros(String(CUI_RES(STR_MYMACROS))), m_sMyMacros(CUI_RESSTR(RID_SVXSTR_MYMACROS)),
m_sProdMacros(String(CUI_RES(STR_PRODMACROS))), m_sProdMacros(CUI_RESSTR(RID_SVXSTR_PRODMACROS)),
m_sMacros(String(CUI_RES(STR_BASICMACROS))), m_sMacros(CUI_RESSTR(STR_BASICMACROS)),
m_sDlgMacros(String(CUI_RES(STR_DLG_MACROS))), m_sDlgMacros(CUI_RESSTR(RID_SVXSTR_PRODMACROS)),
m_aHumanAppName(String(CUI_RES(STR_HUMAN_APPNAME))), m_aHumanAppName(CUI_RESSTR(STR_HUMAN_APPNAME)),
m_aStrGroupStyles(String(CUI_RES(STR_GROUP_STYLES))), m_aStrGroupStyles(CUI_RESSTR(STR_GROUP_STYLES)),
m_collapsedImage(CUI_RES(BMP_COLLAPSED)), m_collapsedImage(CUI_RES(BMP_COLLAPSED)),
m_expandedImage(CUI_RES(BMP_EXPANDED)) m_expandedImage(CUI_RES(BMP_EXPANDED))
{ {
......
...@@ -21,22 +21,6 @@ ...@@ -21,22 +21,6 @@
#include <svl/solar.hrc> #include <svl/solar.hrc>
// ScriptOrgDialog
#define SF_TXT_SCRIPTS 1
#define SF_CTRL_SCRIPTSBOX 2
#define SF_PB_RUN 3
#define SF_PB_CLOSE 4
#define SF_PB_CREATE 5
#define SF_PB_EDIT 6
#define SF_PB_RENAME 7
#define SF_PB_DEL 8
#define SF_PB_HELP 9
#define IMG_HARDDISK 1
#define IMG_LIB 3
#define IMG_MACRO 5
#define IMG_DOCUMENT 7
// NewObjectDialog // NewObjectDialog
#define FT_NEWLIB 10 #define FT_NEWLIB 10
#define STR_FT_NEWMACRO 11 #define STR_FT_NEWMACRO 11
...@@ -48,15 +32,4 @@ ...@@ -48,15 +32,4 @@
#define STR_FT_RENAME 18 #define STR_FT_RENAME 18
#define STR_RENAME 19 #define STR_RENAME 19
// Others #endif
/*
Please be aware that these strings are global resources, don't use self-defined values!
You have to use the RID_SVXSTART macro do avoid ID clashes with other resource files. Sfx2 delivers
some of its own resource files to svx - where they are added to svx resource file!!
*/
#define STR_MYMACROS 32
#define STR_PRODMACROS 33
#endif // _SCRIPTDLG_HRC
...@@ -20,116 +20,6 @@ ...@@ -20,116 +20,6 @@
#include "scriptdlg.hrc" #include "scriptdlg.hrc"
#include "helpid.hrc" #include "helpid.hrc"
#define MASKCOLOR MaskColor = \
Color { Red = 0xFFFF ; Green = 0x0000 ; Blue = 0xFFFF ; };
ModalDialog RID_DLG_SCRIPTORGANIZER
{
OutputSize = TRUE ;
Size = MAP_APPFONT ( 210 , 165 ) ;
Moveable = TRUE ;
Text [ en-US ] = "%MACROLANG Macros";
Closeable = TRUE ;
HelpId = HID_SCRIPTORG_DIALOG;
FixedText SF_TXT_SCRIPTS
{
Pos = MAP_APPFONT ( 6 , 3 ) ;
Size = MAP_APPFONT ( 100 , 10 ) ;
Text [ en-US ] = "~Macros" ;
};
Control SF_CTRL_SCRIPTSBOX
{
HelpId = HID_SCRIPTSBOX ;
Border = TRUE ;
Pos = MAP_APPFONT ( 6 , 16 ) ;
Size = MAP_APPFONT ( 130 , 144 ) ;
TabStop = TRUE ;
Image IMG_HARDDISK
{
ImageBitmap = Bitmap { File = "harddisk_16.bmp" ; };
MASKCOLOR
};
Image IMG_LIB
{
ImageBitmap = Bitmap { File = "im30820.png"; };
MASKCOLOR
};
Image IMG_MACRO
{
ImageBitmap = Bitmap { File = "im30821.png"; };
MASKCOLOR
};
Image IMG_DOCUMENT
{
ImageBitmap = Bitmap { File = "im30826.png"; };
MASKCOLOR
};
String STR_MYMACROS
{
Text [ en-US ] = "My Macros";
};
String STR_PRODMACROS
{
Text [ en-US ] = "%PRODUCTNAME Macros";
};
};
PushButton SF_PB_RUN
{
HelpID = "cui:PushButton:RID_DLG_SCRIPTORGANIZER:SF_PB_RUN";
Pos = MAP_APPFONT ( 144 , 6 ) ;
Size = MAP_APPFONT ( 60 , 14 ) ;
DefButton = TRUE;
Text [ en-US ] = "R~un" ;
};
CancelButton SF_PB_CLOSE
{
Pos = MAP_APPFONT ( 144 , 23 ) ;
Size = MAP_APPFONT ( 60 , 14 ) ;
TabStop = TRUE ;
Text [ en-US ] = "Close" ;
};
PushButton SF_PB_CREATE
{
HelpID = "cui:PushButton:RID_DLG_SCRIPTORGANIZER:SF_PB_CREATE";
Size = MAP_APPFONT ( 60 , 14 ) ;
Pos = MAP_APPFONT ( 144 , 60 ) ;
Text [ en-US ] = "~Create..." ;
TabStop = TRUE ;
};
PushButton SF_PB_EDIT
{
HelpID = "cui:PushButton:RID_DLG_SCRIPTORGANIZER:SF_PB_EDIT";
Size = MAP_APPFONT ( 60 , 14 ) ;
Pos = MAP_APPFONT ( 144 , 77 ) ;
Text [ en-US ] = "~Edit" ;
TabStop = TRUE ;
};
PushButton SF_PB_RENAME
{
HelpID = "cui:PushButton:RID_DLG_SCRIPTORGANIZER:SF_PB_RENAME";
Pos = MAP_APPFONT ( 144 , 94 ) ;
Size = MAP_APPFONT ( 60 , 14 ) ;
Text [ en-US ] = "Rename..." ;
};
PushButton SF_PB_DEL
{
HelpID = "cui:PushButton:RID_DLG_SCRIPTORGANIZER:SF_PB_DEL";
Pos = MAP_APPFONT ( 144 , 114 ) ;
Size = MAP_APPFONT ( 60 , 14 ) ;
Text [ en-US ] = "~Delete..." ;
TabStop = TRUE ;
};
HelpButton SF_PB_HELP
{
Pos = MAP_APPFONT ( 144 , 131 ) ;
Size = MAP_APPFONT ( 60 , 14 ) ;
TabStop = TRUE ;
};
};
ModalDialog RID_DLG_NEWLIB ModalDialog RID_DLG_NEWLIB
{ {
HelpID = "cui:ModalDialog:RID_DLG_NEWLIB"; HelpID = "cui:ModalDialog:RID_DLG_NEWLIB";
......
...@@ -250,8 +250,6 @@ ...@@ -250,8 +250,6 @@
#define HID_HANGULHANJA_EDIT_DLG "CUI_HID_HANGULHANJA_EDIT_DLG" #define HID_HANGULHANJA_EDIT_DLG "CUI_HID_HANGULHANJA_EDIT_DLG"
#define HID_HANGULHANJA_OPT_DICTS_LB "CUI_HID_HANGULHANJA_OPT_DICTS_LB" #define HID_HANGULHANJA_OPT_DICTS_LB "CUI_HID_HANGULHANJA_OPT_DICTS_LB"
#define HID_MULTIPATH "CUI_HID_MULTIPATH" #define HID_MULTIPATH "CUI_HID_MULTIPATH"
#define HID_SCRIPTORG_DIALOG "CUI_HID_SCRIPTORG_DIALOG"
#define HID_SCRIPTSBOX "CUI_HID_SCRIPTSBOX"
#define HID_SPELLCHECK "CUI_HID_SPELLCHECK" #define HID_SPELLCHECK "CUI_HID_SPELLCHECK"
#define HID_TPSIZE_CTRL "CUI_HID_TPSIZE_CTRL" #define HID_TPSIZE_CTRL "CUI_HID_TPSIZE_CTRL"
#define HID_TPROTATION_CTRL1 "CUI_HID_TPROTATION_CTRL1" #define HID_TPROTATION_CTRL1 "CUI_HID_TPROTATION_CTRL1"
......
...@@ -69,6 +69,8 @@ private: ...@@ -69,6 +69,8 @@ private:
::com::sun::star::uno::Reference< ::com::sun::star::uno::XInterface > getDocumentModel( ::com::sun::star::uno::Reference< ::com::sun::star::uno::XComponentContext >& xCtx, ::rtl::OUString& docName ); ::com::sun::star::uno::Reference< ::com::sun::star::uno::XInterface > getDocumentModel( ::com::sun::star::uno::Reference< ::com::sun::star::uno::XComponentContext >& xCtx, ::rtl::OUString& docName );
void Init();
protected: protected:
void ExpandTree( SvTreeListEntry* pRootEntry ); void ExpandTree( SvTreeListEntry* pRootEntry );
virtual void RequestingChildren( SvTreeListEntry* pParent ); virtual void RequestingChildren( SvTreeListEntry* pParent );
...@@ -78,7 +80,8 @@ public: ...@@ -78,7 +80,8 @@ public:
void Init( const ::rtl::OUString& language ); void Init( const ::rtl::OUString& language );
void RequestSubEntries( SvTreeListEntry* pRootEntry, ::com::sun::star::uno::Reference< ::com::sun::star::script::browse::XBrowseNode >& node, void RequestSubEntries( SvTreeListEntry* pRootEntry, ::com::sun::star::uno::Reference< ::com::sun::star::script::browse::XBrowseNode >& node,
::com::sun::star::uno::Reference< com::sun::star::frame::XModel>& model ); ::com::sun::star::uno::Reference< com::sun::star::frame::XModel>& model );
SFTreeListBox( Window* pParent, const ResId& rRes ); SFTreeListBox(Window* pParent, const ResId& rRes);
SFTreeListBox(Window* pParent);
~SFTreeListBox(); ~SFTreeListBox();
void ExpandAllTrees(); void ExpandAllTrees();
...@@ -139,16 +142,14 @@ public: ...@@ -139,16 +142,14 @@ public:
class SvxScriptOrgDialog : public SfxModalDialog class SvxScriptOrgDialog : public SfxModalDialog
{ {
protected: protected:
FixedText aScriptsTxt; SFTreeListBox* m_pScriptsBox;
SFTreeListBox aScriptsBox;
PushButton* m_pRunButton;
PushButton aRunButton; PushButton* m_pCloseButton;
CancelButton aCloseButton; PushButton* m_pCreateButton;
PushButton aCreateButton; PushButton* m_pEditButton;
PushButton aEditButton; PushButton* m_pRenameButton;
PushButton aRenameButton; PushButton* m_pDelButton;
PushButton aDelButton;
HelpButton aHelpButton;
::rtl::OUString m_sLanguage; ::rtl::OUString m_sLanguage;
static Selection_hash m_lastSelection; static Selection_hash m_lastSelection;
......
<?xml version="1.0" encoding="UTF-8"?>
<interface>
<!-- interface-requires gtk+ 3.0 -->
<object class="GtkDialog" id="ScriptOrganizerDialog">
<property name="can_focus">False</property>
<property name="border_width">5</property>
<property name="title" translatable="yes">%MACROLANG Macros</property>
<property name="type_hint">dialog</property>
<child internal-child="vbox">
<object class="GtkBox" id="dialog-vbox1">
<property name="can_focus">False</property>
<property name="spacing">2</property>
<child internal-child="action_area">
<object class="GtkButtonBox" id="dialog-action_area1">
<property name="can_focus">False</property>
<property name="orientation">vertical</property>
<property name="layout_style">start</property>
<child>
<object class="GtkButton" id="run">
<property name="label">Run</property>
<property name="use_action_appearance">False</property>
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="can_default">True</property>
<property name="has_default">True</property>
<property name="receives_default">True</property>
<property name="use_action_appearance">False</property>
</object>
<packing>
<property name="expand">False</property>
<property name="fill">True</property>
<property name="position">0</property>
</packing>
</child>
<child>
<object class="GtkButton" id="close">
<property name="label">gtk-close</property>
<property name="use_action_appearance">False</property>
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="receives_default">True</property>
<property name="use_action_appearance">False</property>
<property name="use_stock">True</property>
</object>
<packing>
<property name="expand">False</property>
<property name="fill">True</property>
<property name="position">1</property>
</packing>
</child>
<child>
<object class="GtkButton" id="create">
<property name="label">Create...</property>
<property name="use_action_appearance">False</property>
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="receives_default">True</property>
<property name="use_action_appearance">False</property>
</object>
<packing>
<property name="expand">False</property>
<property name="fill">True</property>
<property name="position">2</property>
<property name="secondary">True</property>
</packing>
</child>
<child>
<object class="GtkButton" id="edit">
<property name="label">gtk-edit</property>
<property name="use_action_appearance">False</property>
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="receives_default">True</property>
<property name="use_action_appearance">False</property>
<property name="use_stock">True</property>
<property name="image_position">bottom</property>
</object>
<packing>
<property name="expand">False</property>
<property name="fill">True</property>
<property name="position">3</property>
<property name="secondary">True</property>
</packing>
</child>
<child>
<object class="GtkButton" id="rename">
<property name="label">Rename...</property>
<property name="use_action_appearance">False</property>
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="receives_default">True</property>
<property name="use_action_appearance">False</property>
</object>
<packing>
<property name="expand">False</property>
<property name="fill">True</property>
<property name="position">4</property>
<property name="secondary">True</property>
</packing>
</child>
<child>
<object class="GtkButton" id="delete">
<property name="label">Delete...</property>
<property name="use_action_appearance">False</property>
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="receives_default">True</property>
<property name="use_action_appearance">False</property>
</object>
<packing>
<property name="expand">False</property>
<property name="fill">True</property>
<property name="position">5</property>
<property name="secondary">True</property>
</packing>
</child>
<child>
<object class="GtkButton" id="help">
<property name="label">gtk-help</property>
<property name="use_action_appearance">False</property>
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="receives_default">True</property>
<property name="use_action_appearance">False</property>
<property name="use_stock">True</property>
</object>
<packing>
<property name="expand">False</property>
<property name="fill">True</property>
<property name="position">6</property>
<property name="secondary">True</property>
</packing>
</child>
</object>
<packing>
<property name="expand">False</property>
<property name="fill">True</property>
<property name="pack_type">end</property>
<property name="position">0</property>
</packing>
</child>
<child>
<object class="GtkFrame" id="frame2">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="hexpand">True</property>
<property name="vexpand">True</property>
<property name="label_xalign">0</property>
<property name="shadow_type">none</property>
<child>
<object class="GtkAlignment" id="alignment2">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="hexpand">True</property>
<property name="vexpand">True</property>
<property name="top_padding">6</property>
<property name="left_padding">12</property>
<child>
<object class="cuilo:SFTreeListBox" id="scripts">
<property name="height_request">300</property>
<property name="width_request">280</property>
<property name="hexpand">True</property>
<property name="vexpand">True</property>
<property name="visible">True</property>
<property name="can_focus">True</property>
</object>
</child>
</object>
</child>
<child type="label">
<object class="GtkLabel" id="macrosft">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="label" translatable="yes">Macros</property>
<attributes>
<attribute name="weight" value="bold"/>
</attributes>
</object>
</child>
</object>
<packing>
<property name="expand">True</property>
<property name="fill">True</property>
<property name="position">1</property>
</packing>
</child>
</object>
</child>
<action-widgets>
<action-widget response="0">run</action-widget>
<action-widget response="0">close</action-widget>
<action-widget response="0">create</action-widget>
<action-widget response="0">edit</action-widget>
<action-widget response="0">rename</action-widget>
<action-widget response="0">delete</action-widget>
<action-widget response="0">help</action-widget>
</action-widgets>
</object>
</interface>
...@@ -148,7 +148,6 @@ hidspecial HID_REDLINING_DLG { HelpID = HID_REDLINING_DLG; }; ...@@ -148,7 +148,6 @@ hidspecial HID_REDLINING_DLG { HelpID = HID_REDLINING_DLG; };
hidspecial HID_REDLINING_EDIT { HelpID = HID_REDLINING_EDIT; }; hidspecial HID_REDLINING_EDIT { HelpID = HID_REDLINING_EDIT; };
hidspecial HID_REDLINING_NEXT { HelpID = HID_REDLINING_NEXT; }; hidspecial HID_REDLINING_NEXT { HelpID = HID_REDLINING_NEXT; };
hidspecial HID_REDLINING_PREV { HelpID = HID_REDLINING_PREV; }; hidspecial HID_REDLINING_PREV { HelpID = HID_REDLINING_PREV; };
hidspecial HID_SCRIPTSBOX { HelpId = HID_SCRIPTSBOX; };
hidspecial HID_SPLDLG_BUTTON_CHANGE { HelpID = HID_SPLDLG_BUTTON_CHANGE ; }; hidspecial HID_SPLDLG_BUTTON_CHANGE { HelpID = HID_SPLDLG_BUTTON_CHANGE ; };
hidspecial HID_SPLDLG_BUTTON_CHANGEALL { HelpID = HID_SPLDLG_BUTTON_CHANGEALL ; }; hidspecial HID_SPLDLG_BUTTON_CHANGEALL { HelpID = HID_SPLDLG_BUTTON_CHANGEALL ; };
hidspecial HID_SPLDLG_BUTTON_CLOSE { HelpID = HID_SPLDLG_BUTTON_CLOSE ; }; hidspecial HID_SPLDLG_BUTTON_CLOSE { HelpID = HID_SPLDLG_BUTTON_CLOSE ; };
......
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