LCOV - code coverage report
Current view: top level - sw/source/ui/dbui - mmoutputpage.hxx (source / functions) Hit Total Coverage
Test: libreoffice_filtered.info Lines: 0 2 0.0 %
Date: 2012-08-25 Functions: 0 4 0.0 %
Legend: Lines: hit not hit | Branches: + taken - not taken # not executed Branches: 0 0 -

           Branch data     Line data    Source code
       1                 :            : /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
       2                 :            : /*************************************************************************
       3                 :            :  *
       4                 :            :  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
       5                 :            :  *
       6                 :            :  * Copyright 2000, 2010 Oracle and/or its affiliates.
       7                 :            :  *
       8                 :            :  * OpenOffice.org - a multi-platform office productivity suite
       9                 :            :  *
      10                 :            :  * This file is part of OpenOffice.org.
      11                 :            :  *
      12                 :            :  * OpenOffice.org is free software: you can redistribute it and/or modify
      13                 :            :  * it under the terms of the GNU Lesser General Public License version 3
      14                 :            :  * only, as published by the Free Software Foundation.
      15                 :            :  *
      16                 :            :  * OpenOffice.org is distributed in the hope that it will be useful,
      17                 :            :  * but WITHOUT ANY WARRANTY; without even the implied warranty of
      18                 :            :  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
      19                 :            :  * GNU Lesser General Public License version 3 for more details
      20                 :            :  * (a copy is included in the LICENSE file that accompanied this code).
      21                 :            :  *
      22                 :            :  * You should have received a copy of the GNU Lesser General Public License
      23                 :            :  * version 3 along with OpenOffice.org.  If not, see
      24                 :            :  * <http://www.openoffice.org/license.html>
      25                 :            :  * for a copy of the LGPLv3 License.
      26                 :            :  *
      27                 :            :  ************************************************************************/
      28                 :            : #ifndef _MAILMERGEOUTPUTPAGE_HXX
      29                 :            : #define _MAILMERGEOUTPUTPAGE_HXX
      30                 :            : #include <svtools/wizardmachine.hxx>
      31                 :            : #include <vcl/button.hxx>
      32                 :            : #include <svtools/stdctrl.hxx>
      33                 :            : #include <vcl/combobox.hxx>
      34                 :            : #include <vcl/field.hxx>
      35                 :            : #include <vcl/lstbox.hxx>
      36                 :            : #include <sfx2/objsh.hxx>
      37                 :            : #include <sfx2/basedlgs.hxx>
      38                 :            : #include <svtools/svtabbx.hxx>
      39                 :            : #include <svtools/headbar.hxx>
      40                 :            : #include <svtools/prgsbar.hxx>
      41                 :            : #include "swdllapi.h"
      42                 :            : #include "mailmergehelper.hxx"
      43                 :            : 
      44                 :            : class SwMailMergeWizard;
      45                 :            : class SfxPrinter;
      46                 :            : class SwSendMailDialog;
      47                 :            : 
      48                 :            : namespace com{ namespace sun{ namespace star{
      49                 :            :     namespace mail{
      50                 :            :         class XMailMessage;
      51                 :            :     }
      52                 :            : }}}
      53                 :            : 
      54                 :            : class SwMailMergeOutputPage : public svt::OWizardPage
      55                 :            : {
      56                 :            :     SwBoldFixedInfo m_aHeaderFI;
      57                 :            :     FixedInfo       m_aOptionsFI;
      58                 :            :     RadioButton     m_aSaveStartDocRB;
      59                 :            :     RadioButton     m_aSaveMergedDocRB;
      60                 :            :     RadioButton     m_aPrintRB;
      61                 :            :     RadioButton     m_aSendMailRB;
      62                 :            : 
      63                 :            :     FixedLine       m_aSeparatorFL;
      64                 :            : 
      65                 :            :     PushButton      m_aSaveStartDocPB;
      66                 :            : 
      67                 :            :     RadioButton     m_aSaveAsOneRB;
      68                 :            :     RadioButton     m_aSaveIndividualRB;
      69                 :            :     RadioButton     m_aPrintAllRB; //has to be here for tab control reasons
      70                 :            :     RadioButton     m_aSendAllRB;  //has to be here for tab control reasons
      71                 :            :     //this group is used in save and print
      72                 :            :     RadioButton     m_aFromRB;
      73                 :            :     NumericField    m_aFromNF;
      74                 :            :     FixedText       m_aToFT;
      75                 :            :     NumericField    m_aToNF;
      76                 :            :     PushButton      m_aSaveNowPB;
      77                 :            : 
      78                 :            :     FixedText       m_aPrinterFT;
      79                 :            :     ListBox         m_aPrinterLB;
      80                 :            :     PushButton      m_aPrinterSettingsPB;
      81                 :            :     PushButton      m_aPrintNowPB;
      82                 :            : 
      83                 :            :     FixedText       m_aMailToFT;
      84                 :            :     ListBox         m_aMailToLB;
      85                 :            :     PushButton      m_aCopyToPB;
      86                 :            :     FixedText       m_aSubjectFT;
      87                 :            :     Edit            m_aSubjectED;
      88                 :            :     FixedText       m_aSendAsFT;
      89                 :            :     ListBox         m_aSendAsLB;
      90                 :            :     FixedText       m_aAttachmentFT;
      91                 :            :     Edit            m_aAttachmentED;
      92                 :            :     PushButton      m_aSendAsPB;
      93                 :            :     PushButton      m_aSendDocumentsPB;
      94                 :            : 
      95                 :            :     //some FixedLine labels
      96                 :            :     String          m_sSaveStartST;
      97                 :            :     String          m_sSaveMergedST;
      98                 :            :     String          m_sPrintST;
      99                 :            :     String          m_sSendMailST;
     100                 :            : 
     101                 :            :     //misc strings
     102                 :            :     String          m_sDefaultAttachmentST;
     103                 :            :     String          m_sNoSubjectQueryST;
     104                 :            :     String          m_sNoSubjectST;
     105                 :            :     String          m_sNoAttachmentNameST;
     106                 :            :     String          m_sConfigureMail;
     107                 :            : 
     108                 :            :     String          m_sBody;
     109                 :            : 
     110                 :            :     long            m_nFromToRBPos;
     111                 :            :     long            m_nFromToFTPos;
     112                 :            :     long            m_nFromToNFPos;
     113                 :            :     long            m_nRBOffset;
     114                 :            : 
     115                 :            :     bool            m_bCancelSaving;
     116                 :            : 
     117                 :            :     SwMailMergeWizard*  m_pWizard;
     118                 :            : 
     119                 :            :     //some dialog data
     120                 :            :     Printer*        m_pTempPrinter;
     121                 :            :     SfxPrinter*     m_pDocumentPrinterCopy;
     122                 :            :     String          m_sCC;
     123                 :            :     String          m_sBCC;
     124                 :            : 
     125                 :            : 
     126                 :            :     DECL_LINK(OutputTypeHdl_Impl, RadioButton*);
     127                 :            :     DECL_LINK(CopyToHdl_Impl, PushButton*);
     128                 :            :     DECL_LINK(SaveStartHdl_Impl, PushButton* );
     129                 :            :     DECL_LINK(SaveOutputHdl_Impl, PushButton* );
     130                 :            :     DECL_LINK(PrinterChangeHdl_Impl, ListBox* );
     131                 :            :     DECL_LINK(PrintHdl_Impl, void *);
     132                 :            :     DECL_LINK(PrinterSetupHdl_Impl, PushButton* );
     133                 :            :     DECL_LINK(SendTypeHdl_Impl, ListBox*);
     134                 :            :     DECL_LINK(SendAsHdl_Impl, PushButton*);
     135                 :            :     DECL_LINK(SendDocumentsHdl_Impl, PushButton*);
     136                 :            :     DECL_LINK(DocumentSelectionHdl_Impl, RadioButton*);
     137                 :            :     DECL_LINK(SaveCancelHdl_Impl, void *);
     138                 :            : protected:
     139                 :            :         virtual bool    canAdvance() const;
     140                 :            :         virtual void    ActivatePage();
     141                 :            : public:
     142                 :            :         SwMailMergeOutputPage( SwMailMergeWizard* _pParent);
     143                 :            :         ~SwMailMergeOutputPage();
     144                 :            : 
     145                 :            : };
     146                 :            : 
     147                 :          0 : struct SwMailDescriptor
     148                 :            : {
     149                 :            :     ::rtl::OUString                             sEMail;
     150                 :            :     ::rtl::OUString                             sAttachmentURL;
     151                 :            :     ::rtl::OUString                             sAttachmentName;
     152                 :            :     ::rtl::OUString                             sMimeType;
     153                 :            :     ::rtl::OUString                             sSubject;
     154                 :            :     ::rtl::OUString                             sBodyMimeType;
     155                 :            :     ::rtl::OUString                             sBodyContent;
     156                 :            : 
     157                 :            : 
     158                 :            :     ::rtl::OUString                             sCC;
     159                 :            :     ::rtl::OUString                             sBCC;
     160                 :            : };
     161                 :            : struct SwSendMailDialog_Impl;
     162                 :            : class SwMailMergeConfigItem;
     163                 :            : class SW_DLLPUBLIC SwSendMailDialog : public ModelessDialog //SfxModalDialog
     164                 :            : {
     165                 :            :     FixedLine               m_aStatusFL;
     166                 :            :     FixedText               m_aStatusFT;
     167                 :            : 
     168                 :            :     FixedLine               m_aTransferStatusFL;
     169                 :            :     FixedText               m_aTransferStatusFT;
     170                 :            :     FixedInfo               m_PausedFI;
     171                 :            :     ProgressBar             m_aProgressBar;
     172                 :            :     FixedText               m_aErrorStatusFT;
     173                 :            : 
     174                 :            :     PushButton              m_aDetailsPB;
     175                 :            :     HeaderBar               m_aStatusHB;
     176                 :            :     SvTabListBox            m_aStatusLB;
     177                 :            : 
     178                 :            :     FixedLine               m_aSeparatorFL;
     179                 :            : 
     180                 :            :     PushButton              m_aStopPB;
     181                 :            :     PushButton              m_aClosePB;
     182                 :            : 
     183                 :            :     String                  m_sMore;
     184                 :            :     String                  m_sLess;
     185                 :            :     String                  m_sContinue;
     186                 :            :     String                  m_sStop;
     187                 :            :     String                  m_sSend;
     188                 :            :     String                  m_sTransferStatus;
     189                 :            :     String                  m_sErrorStatus;
     190                 :            :     String                  m_sSendingTo;
     191                 :            :     String                  m_sCompleted;
     192                 :            :     String                  m_sFailed;
     193                 :            :     String                  m_sTerminateQuery;
     194                 :            : 
     195                 :            :     bool                    m_bCancel;
     196                 :            :     bool                    m_bDesctructionEnabled;
     197                 :            : 
     198                 :            :     ImageList               m_aImageList;
     199                 :            : 
     200                 :            :     SwSendMailDialog_Impl*  m_pImpl;
     201                 :            :     SwMailMergeConfigItem*  m_pConfigItem;
     202                 :            :     sal_Int32               m_nStatusHeight;
     203                 :            :     sal_Int32               m_nSendCount;
     204                 :            :     sal_Int32               m_nErrorCount;
     205                 :            : 
     206                 :            :     SW_DLLPRIVATE DECL_LINK( DetailsHdl_Impl, void* );
     207                 :            :     SW_DLLPRIVATE DECL_LINK( StopHdl_Impl, PushButton* );
     208                 :            :     SW_DLLPRIVATE DECL_LINK( CloseHdl_Impl, void* );
     209                 :            :     SW_DLLPRIVATE DECL_STATIC_LINK( SwSendMailDialog, StartSendMails, SwSendMailDialog* );
     210                 :            :     SW_DLLPRIVATE DECL_STATIC_LINK( SwSendMailDialog, StopSendMails, SwSendMailDialog* );
     211                 :            :     SW_DLLPRIVATE DECL_STATIC_LINK( SwSendMailDialog, RemoveThis, Timer* );
     212                 :            : 
     213                 :            :     SW_DLLPRIVATE void        IterateMails();
     214                 :            :     SW_DLLPRIVATE void        SendMails();
     215                 :            :     SW_DLLPRIVATE void        UpdateTransferStatus();
     216                 :            : 
     217                 :            :     virtual void        StateChanged( StateChangedType nStateChange );
     218                 :            : 
     219                 :            : public:
     220                 :            :     SwSendMailDialog( Window* pParent, SwMailMergeConfigItem& );
     221                 :            :     ~SwSendMailDialog();
     222                 :            : 
     223                 :            :     void                AddDocument( SwMailDescriptor& rDesc );
     224                 :            :     void                SetDocumentCount( sal_Int32 nAllDocuments );
     225                 :          0 :     void                EnableDesctruction() {m_bDesctructionEnabled = true;}
     226                 :            :     void                ShowDialog();
     227                 :            : 
     228                 :            :     void                DocumentSent( ::com::sun::star::uno::Reference< ::com::sun::star::mail::XMailMessage>,
     229                 :            :                                         bool bResult,
     230                 :            :                                         const ::rtl::OUString* pError );
     231                 :            :     void                AllMailsSent();
     232                 :            : 
     233                 :            : };
     234                 :            : #endif
     235                 :            : 
     236                 :            : 
     237                 :            : /* vim:set shiftwidth=4 softtabstop=4 expandtab: */

Generated by: LCOV version 1.10