summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCaolán McNamara <caolanm@redhat.com>2013-09-16 20:25:59 +0100
committerCaolán McNamara <caolanm@redhat.com>2013-09-16 20:32:02 +0100
commitbc01ebe47c04228cf729a8f87af3efeab213dc3a (patch)
tree86d9cd358c6dc5740b03202b973522b8846e348e
parent902d4ded3b276ca3c0b4965bebede7c1efdc1a02 (diff)
convert copy to (cc) dialog to .ui
Change-Id: I1d5ef0410a0e3d325fb6cf42dad2c07eeb89a87a
-rw-r--r--sw/UIConfig_swriter.mk1
-rw-r--r--sw/inc/dbui.hrc2
-rw-r--r--sw/inc/helpid.h1
-rw-r--r--sw/source/ui/dbui/mmoutputpage.cxx57
-rw-r--r--sw/source/ui/dbui/mmoutputpage.hrc4
-rw-r--r--sw/source/ui/dbui/mmoutputpage.src72
-rw-r--r--sw/uiconfig/swriter/ui/ccdialog.ui197
7 files changed, 212 insertions, 122 deletions
diff --git a/sw/UIConfig_swriter.mk b/sw/UIConfig_swriter.mk
index b118f47a5f8d..9df802142a39 100644
--- a/sw/UIConfig_swriter.mk
+++ b/sw/UIConfig_swriter.mk
@@ -75,6 +75,7 @@ $(eval $(call gb_UIConfig_add_uifiles,modules/swriter,\
sw/uiconfig/swriter/ui/captionoptions \
sw/uiconfig/swriter/ui/cardformatpage \
sw/uiconfig/swriter/ui/cardmediumpage \
+ sw/uiconfig/swriter/ui/ccdialog \
sw/uiconfig/swriter/ui/characterproperties \
sw/uiconfig/swriter/ui/charurlpage \
sw/uiconfig/swriter/ui/columndialog \
diff --git a/sw/inc/dbui.hrc b/sw/inc/dbui.hrc
index 361b7dae14c3..0ced6d16925f 100644
--- a/sw/inc/dbui.hrc
+++ b/sw/inc/dbui.hrc
@@ -42,7 +42,7 @@
#define DLG_MM_ASSIGNFIELDS (RC_DBUI_BEGIN + 20)
#define DLG_MM_LAYOUT_PAGE (RC_DBUI_BEGIN + 22)
-#define DLG_MM_COPYTO (RC_DBUI_BEGIN + 23)
+
#define DLG_MM_MAILBODY (RC_DBUI_BEGIN + 24)
#define DLG_MM_SENDMAILS (RC_DBUI_BEGIN + 25)
#define DLG_MAILMERGECHILD (RC_DBUI_BEGIN + 26)
diff --git a/sw/inc/helpid.h b/sw/inc/helpid.h
index 34f861eb8909..344a790c83d9 100644
--- a/sw/inc/helpid.h
+++ b/sw/inc/helpid.h
@@ -381,7 +381,6 @@
#define HID_MM_CREATEADDRESSLIST "SW_HID_MM_CREATEADDRESSLIST"
#define HID_MM_ASSIGNFIELDS "SW_HID_MM_ASSIGNFIELDS"
#define HID_MM_LAYOUT_PAGE "SW_HID_MM_LAYOUT_PAGE"
-#define HID_MM_COPYTO "SW_HID_MM_COPYTO"
#define HID_MM_ADDRESSLIST_HB "SW_HID_MM_ADDRESSLIST_HB"
#define HID_MM_TESTACCOUNTSETTINGS "SW_HID_MM_TESTACCOUNTSETTINGS"
#define HID_MM_TESTACCOUNTSETTINGS_TLB "SW_HID_MM_TESTACCOUNTSETTINGS_TLB"
diff --git a/sw/source/ui/dbui/mmoutputpage.cxx b/sw/source/ui/dbui/mmoutputpage.cxx
index 2a5de59450fc..bf1ec91fdc57 100644
--- a/sw/source/ui/dbui/mmoutputpage.cxx
+++ b/sw/source/ui/dbui/mmoutputpage.cxx
@@ -213,56 +213,25 @@ IMPL_LINK( SwSendQueryBox_Impl, ModifyHdl, Edit*, pEdit)
class SwCopyToDialog : public SfxModalDialog
{
- FixedInfo m_aDescriptionFI;
- FixedText m_aCCFT;
- Edit m_aCCED;
- FixedText m_aBCCFT;
- Edit m_aBCCED;
-
- FixedInfo m_aNoteFI;
- FixedLine m_aSeparatorFL;
-
- OKButton m_aOK;
- CancelButton m_aCancel;
- HelpButton m_aHelp;
+ Edit* m_pCCED;
+ Edit* m_pBCCED;
public:
- SwCopyToDialog(Window* pParent);
- ~SwCopyToDialog();
+ SwCopyToDialog(Window* pParent)
+ : SfxModalDialog(pParent, "CCDialog",
+ "modules/swriter/ui/ccdialog.ui")
+ {
+ get(m_pCCED, "cc");
+ get(m_pBCCED, "bcc");
+ }
- String GetCC() {return m_aCCED.GetText();}
- void SetCC(const String& rSet) {m_aCCED.SetText(rSet);}
+ OUString GetCC() {return m_pCCED->GetText();}
+ void SetCC(const OUString& rSet) {m_pCCED->SetText(rSet);}
- String GetBCC() {return m_aBCCED.GetText();}
- void SetBCC(const String& rSet) {m_aBCCED.SetText(rSet);}
+ OUString GetBCC() {return m_pBCCED->GetText();}
+ void SetBCC(const OUString& rSet) {m_pBCCED->SetText(rSet);}
};
-SwCopyToDialog::SwCopyToDialog(Window* pParent) :
- SfxModalDialog(pParent, SW_RES(DLG_MM_COPYTO)),
-#ifdef _MSC_VER
-#pragma warning (disable : 4355)
-#endif
- m_aDescriptionFI( this, SW_RES( FI_DESCRIPTION )),
- m_aCCFT( this, SW_RES( FT_CC )),
- m_aCCED( this, SW_RES( ED_CC )),
- m_aBCCFT( this, SW_RES( FT_BCC )),
- m_aBCCED( this, SW_RES( ED_BCC )),
- m_aNoteFI( this, SW_RES( FI_NOTE )),
- m_aSeparatorFL( this, SW_RES( FL_SEPARATOR )),
- m_aOK( this, SW_RES( PB_OK )),
- m_aCancel( this, SW_RES( PB_CANCEL )),
- m_aHelp( this, SW_RES( PB_HELP ))
-#ifdef _MSC_VER
-#pragma warning (default : 4355)
-#endif
-{
- FreeResource();
-}
-
-SwCopyToDialog::~SwCopyToDialog()
-{
-}
-
SwMailMergeOutputPage::SwMailMergeOutputPage( SwMailMergeWizard* _pParent) :
svt::OWizardPage( _pParent, SW_RES(DLG_MM_OUTPUT_PAGE)),
#ifdef _MSC_VER
diff --git a/sw/source/ui/dbui/mmoutputpage.hrc b/sw/source/ui/dbui/mmoutputpage.hrc
index 94825ee82457..8a06731ff4cb 100644
--- a/sw/source/ui/dbui/mmoutputpage.hrc
+++ b/sw/source/ui/dbui/mmoutputpage.hrc
@@ -58,10 +58,6 @@
#define PB_SENDDOCUMENTS 40
#define FI_DESCRIPTION 41
-#define FT_CC 42
-#define ED_CC 43
-#define FT_BCC 44
-#define ED_BCC 45
#define PB_OK 47
#define PB_CANCEL 48
#define PB_HELP 49
diff --git a/sw/source/ui/dbui/mmoutputpage.src b/sw/source/ui/dbui/mmoutputpage.src
index d9fa4e3ada0b..8426048d8719 100644
--- a/sw/source/ui/dbui/mmoutputpage.src
+++ b/sw/source/ui/dbui/mmoutputpage.src
@@ -312,78 +312,6 @@ TabPage DLG_MM_OUTPUT_PAGE
};
};
-ModalDialog DLG_MM_COPYTO
-{
- OutputSize = TRUE ;
- SVLook = TRUE ;
- HelpID = HID_MM_COPYTO;
- Size = MAP_APPFONT ( 250 , 100 ) ;
- Moveable = TRUE ;
-
- Text [ en-US ] = "Copy To";
-
- FixedText FI_DESCRIPTION
- {
- Pos = MAP_APPFONT ( 6 , 3 ) ;
- Size = MAP_APPFONT ( 238 , 8 ) ;
- Text[ en-US ] = "Send a copy of this mail to:";
- };
- FixedText FT_CC
- {
- Pos = MAP_APPFONT ( 6 , 17 ) ;
- Size = MAP_APPFONT ( 30 , 8 ) ;
- Text[ en-US ] = "~Cc";
- };
- Edit ED_CC
- {
- HelpID = "sw:Edit:DLG_MM_COPYTO:ED_CC";
- Pos = MAP_APPFONT ( 40 , 15 ) ;
- Size = MAP_APPFONT ( 204 , 12 ) ;
- Border = TRUE;
- };
- FixedText FT_BCC
- {
- Pos = MAP_APPFONT ( 6 , 33 ) ;
- Size = MAP_APPFONT ( 30 , 8 ) ;
- Text[ en-US ] = "~Bcc";
- };
- Edit ED_BCC
- {
- HelpID = "sw:Edit:DLG_MM_COPYTO:ED_BCC";
- Pos = MAP_APPFONT ( 40 , 31 ) ;
- Size = MAP_APPFONT ( 204 , 12 ) ;
- Border = TRUE;
- };
- FixedText FI_NOTE
- {
- Pos = MAP_APPFONT ( 6 , 47 ) ;
- Size = MAP_APPFONT ( 204 , 20 ) ;
- WordBreak = TRUE;
- Text[ en-US ] = "Note:\nSeparate e-mail addresses with a semicolon (;).";
- };
- FixedLine FL_SEPARATOR
- {
- Pos = MAP_APPFONT ( 0 , 66 ) ;
- Size = MAP_APPFONT ( 250 , 8 ) ;
- };
- OKButton PB_OK
- {
- Pos = MAP_APPFONT ( 85 , 80 ) ;
- Size = MAP_APPFONT ( 50 , 14 ) ;
- DefButton = TRUE ;
- };
- CancelButton PB_CANCEL
- {
- Pos = MAP_APPFONT ( 138 , 80 ) ;
- Size = MAP_APPFONT ( 50 , 14 ) ;
- };
- HelpButton PB_HELP
- {
- Pos = MAP_APPFONT ( 194 , 80 ) ;
- Size = MAP_APPFONT ( 50 , 14 ) ;
- };
-};
-
ModalDialog DLG_MM_QUERY
{
OutputSize = TRUE ;
diff --git a/sw/uiconfig/swriter/ui/ccdialog.ui b/sw/uiconfig/swriter/ui/ccdialog.ui
new file mode 100644
index 000000000000..0c8c7544f419
--- /dev/null
+++ b/sw/uiconfig/swriter/ui/ccdialog.ui
@@ -0,0 +1,197 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<interface>
+ <!-- interface-requires gtk+ 3.0 -->
+ <object class="GtkDialog" id="CCDialog">
+ <property name="can_focus">False</property>
+ <property name="border_width">6</property>
+ <property name="title" translatable="yes">Copy To</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="orientation">vertical</property>
+ <property name="spacing">12</property>
+ <child internal-child="action_area">
+ <object class="GtkButtonBox" id="dialog-action_area1">
+ <property name="can_focus">False</property>
+ <property name="layout_style">end</property>
+ <child>
+ <object class="GtkButton" id="ok">
+ <property name="label">gtk-ok</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_stock">True</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="cancel">
+ <property name="label">gtk-cancel</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">True</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="help">
+ <property name="label">gtk-help</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">True</property>
+ <property name="use_stock">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">True</property>
+ <property name="position">2</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="frame1">
+ <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="alignment1">
+ <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="GtkGrid" id="grid1">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="hexpand">True</property>
+ <property name="row_spacing">6</property>
+ <property name="column_spacing">12</property>
+ <child>
+ <object class="GtkLabel" id="label2">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">_Cc</property>
+ <property name="use_underline">True</property>
+ <property name="mnemonic_widget">cc</property>
+ </object>
+ <packing>
+ <property name="left_attach">0</property>
+ <property name="top_attach">0</property>
+ <property name="width">1</property>
+ <property name="height">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="label3">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">_Bcc</property>
+ <property name="use_underline">True</property>
+ <property name="mnemonic_widget">bcc</property>
+ </object>
+ <packing>
+ <property name="left_attach">0</property>
+ <property name="top_attach">1</property>
+ <property name="width">1</property>
+ <property name="height">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="label4">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">Note: Separate e-mail addresses with a semicolon (;).</property>
+ <property name="use_underline">True</property>
+ </object>
+ <packing>
+ <property name="left_attach">0</property>
+ <property name="top_attach">2</property>
+ <property name="width">2</property>
+ <property name="height">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkEntry" id="cc">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="hexpand">True</property>
+ <property name="invisible_char">●</property>
+ </object>
+ <packing>
+ <property name="left_attach">1</property>
+ <property name="top_attach">0</property>
+ <property name="width">1</property>
+ <property name="height">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkEntry" id="bcc">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="hexpand">True</property>
+ <property name="invisible_char">●</property>
+ </object>
+ <packing>
+ <property name="left_attach">1</property>
+ <property name="top_attach">1</property>
+ <property name="width">1</property>
+ <property name="height">1</property>
+ </packing>
+ </child>
+ </object>
+ </child>
+ </object>
+ </child>
+ <child type="label">
+ <object class="GtkLabel" id="label1">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="label">Send a copy of this mail to...</property>
+ <attributes>
+ <attribute name="weight" value="bold"/>
+ </attributes>
+ </object>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">True</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ </child>
+ <action-widgets>
+ <action-widget response="0">ok</action-widget>
+ <action-widget response="0">cancel</action-widget>
+ <action-widget response="0">help</action-widget>
+ </action-widgets>
+ </object>
+</interface>