LCOV - code coverage report
Current view: top level - sw/source/ui/dbui - mmoutputpage.hxx (source / functions) Hit Total Coverage
Test: commit c8344322a7af75b84dd3ca8f78b05543a976dfd5 Lines: 0 2 0.0 %
Date: 2015-06-13 12:38:46 Functions: 0 4 0.0 %
Legend: Lines: hit not hit

          Line data    Source code
       1             : /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
       2             : /*
       3             :  * This file is part of the LibreOffice project.
       4             :  *
       5             :  * This Source Code Form is subject to the terms of the Mozilla Public
       6             :  * License, v. 2.0. If a copy of the MPL was not distributed with this
       7             :  * file, You can obtain one at http://mozilla.org/MPL/2.0/.
       8             :  *
       9             :  * This file incorporates work covered by the following license notice:
      10             :  *
      11             :  *   Licensed to the Apache Software Foundation (ASF) under one or more
      12             :  *   contributor license agreements. See the NOTICE file distributed
      13             :  *   with this work for additional information regarding copyright
      14             :  *   ownership. The ASF licenses this file to you under the Apache
      15             :  *   License, Version 2.0 (the "License"); you may not use this file
      16             :  *   except in compliance with the License. You may obtain a copy of
      17             :  *   the License at http://www.apache.org/licenses/LICENSE-2.0 .
      18             :  */
      19             : #ifndef INCLUDED_SW_SOURCE_UI_DBUI_MMOUTPUTPAGE_HXX
      20             : #define INCLUDED_SW_SOURCE_UI_DBUI_MMOUTPUTPAGE_HXX
      21             : #include <svtools/wizardmachine.hxx>
      22             : #include <vcl/button.hxx>
      23             : #include <vcl/layout.hxx>
      24             : #include <svtools/stdctrl.hxx>
      25             : #include <vcl/combobox.hxx>
      26             : #include <vcl/field.hxx>
      27             : #include <vcl/lstbox.hxx>
      28             : #include <vcl/prgsbar.hxx>
      29             : #include <sfx2/objsh.hxx>
      30             : #include <sfx2/basedlgs.hxx>
      31             : #include <svtools/simptabl.hxx>
      32             : #include <svtools/svtabbx.hxx>
      33             : #include <svtools/headbar.hxx>
      34             : #include "mailmergehelper.hxx"
      35             : 
      36             : class SwMailMergeWizard;
      37             : class SfxPrinter;
      38             : class SwSendMailDialog;
      39             : 
      40             : namespace com{ namespace sun{ namespace star{
      41             :     namespace mail{
      42             :         class XMailMessage;
      43             :     }
      44             : }}}
      45             : 
      46             : class SwMailMergeOutputPage : public svt::OWizardPage
      47             : {
      48             :     VclPtr<RadioButton>    m_pSaveStartDocRB;
      49             :     VclPtr<RadioButton>    m_pSaveMergedDocRB;
      50             :     VclPtr<RadioButton>    m_pPrintRB;
      51             :     VclPtr<RadioButton>    m_pSendMailRB;
      52             : 
      53             :     VclPtr<VclFrame>       m_pSeparator;
      54             : 
      55             :     VclPtr<PushButton>     m_pSaveStartDocPB;
      56             : 
      57             :     VclPtr<RadioButton>    m_pSaveAsOneRB;
      58             :     VclPtr<RadioButton>    m_pSaveIndividualRB;
      59             :     VclPtr<RadioButton>    m_pPrintAllRB; //has to be here for tab control reasons
      60             :     VclPtr<RadioButton>    m_pSendAllRB;  //has to be here for tab control reasons
      61             :     //this group is used in save and print
      62             :     VclPtr<RadioButton>    m_pFromRB;
      63             :     VclPtr<NumericField>   m_pFromNF;
      64             :     VclPtr<FixedText>      m_pToFT;
      65             :     VclPtr<NumericField>   m_pToNF;
      66             :     VclPtr<PushButton>     m_pSaveNowPB;
      67             : 
      68             :     VclPtr<FixedText>      m_pPrinterFT;
      69             :     VclPtr<ListBox>        m_pPrinterLB;
      70             :     VclPtr<PushButton>     m_pPrinterSettingsPB;
      71             :     VclPtr<PushButton>     m_pPrintNowPB;
      72             : 
      73             :     VclPtr<FixedText>      m_pMailToFT;
      74             :     VclPtr<ListBox>        m_pMailToLB;
      75             :     VclPtr<PushButton>     m_pCopyToPB;
      76             :     VclPtr<FixedText>      m_pSubjectFT;
      77             :     VclPtr<Edit>           m_pSubjectED;
      78             :     VclPtr<FixedText>      m_pSendAsFT;
      79             :     VclPtr<ListBox>        m_pSendAsLB;
      80             :     VclPtr<VclContainer>   m_pAttachmentGroup;
      81             :     VclPtr<Edit>           m_pAttachmentED;
      82             :     VclPtr<PushButton>     m_pSendAsPB;
      83             :     VclPtr<PushButton>     m_pSendDocumentsPB;
      84             : 
      85             :     //some FixedLine labels
      86             :     OUString        m_sSaveStartST;
      87             :     OUString        m_sSaveMergedST;
      88             :     OUString        m_sPrintST;
      89             :     OUString        m_sSendMailST;
      90             : 
      91             :     //misc strings
      92             :     OUString        m_sDefaultAttachmentST;
      93             :     OUString        m_sNoSubjectST;
      94             :     OUString        m_sConfigureMail;
      95             : 
      96             :     OUString        m_sBody;
      97             : 
      98             :     bool            m_bCancelSaving;
      99             : 
     100             :     VclPtr<SwMailMergeWizard>  m_pWizard;
     101             : 
     102             :     //some dialog data
     103             :     VclPtr<Printer> m_pTempPrinter;
     104             :     OUString        m_sCC;
     105             :     OUString        m_sBCC;
     106             : 
     107             :     DECL_LINK(OutputTypeHdl_Impl, RadioButton*);
     108             :     DECL_LINK(CopyToHdl_Impl, PushButton*);
     109             :     DECL_LINK(SaveStartHdl_Impl, PushButton* );
     110             :     DECL_LINK(SaveOutputHdl_Impl, PushButton* );
     111             :     DECL_LINK(PrinterChangeHdl_Impl, ListBox* );
     112             :     DECL_LINK(PrintHdl_Impl, void *);
     113             :     DECL_LINK(PrinterSetupHdl_Impl, PushButton* );
     114             :     DECL_LINK(SendTypeHdl_Impl, ListBox*);
     115             :     DECL_LINK(SendAsHdl_Impl, PushButton*);
     116             :     DECL_LINK(SendDocumentsHdl_Impl, PushButton*);
     117             :     DECL_LINK(DocumentSelectionHdl_Impl, RadioButton*);
     118             :     DECL_LINK(SaveCancelHdl_Impl, void *);
     119             : 
     120             :     int documentStartPageNumber( int document ) const;
     121             :     int documentEndPageNumber( int document ) const;
     122             : 
     123             : protected:
     124             :         virtual bool    canAdvance() const SAL_OVERRIDE;
     125             :         virtual void    ActivatePage() SAL_OVERRIDE;
     126             : public:
     127             :         SwMailMergeOutputPage( SwMailMergeWizard* _pParent);
     128             :         virtual ~SwMailMergeOutputPage();
     129             :     virtual void dispose() SAL_OVERRIDE;
     130             : 
     131             : };
     132             : 
     133           0 : struct SwMailDescriptor
     134             : {
     135             :     OUString                             sEMail;
     136             :     OUString                             sAttachmentURL;
     137             :     OUString                             sAttachmentName;
     138             :     OUString                             sMimeType;
     139             :     OUString                             sSubject;
     140             :     OUString                             sBodyMimeType;
     141             :     OUString                             sBodyContent;
     142             : 
     143             :     OUString                             sCC;
     144             :     OUString                             sBCC;
     145             : };
     146             : struct SwSendMailDialog_Impl;
     147             : class SwMailMergeConfigItem;
     148             : class SwSendMailDialog : public ModelessDialog //SfxModalDialog
     149             : {
     150             :     VclPtr<FixedText>               m_pTransferStatus;
     151             :     VclPtr<FixedText>               m_pPaused;
     152             :     VclPtr<ProgressBar>             m_pProgressBar;
     153             :     VclPtr<FixedText>               m_pErrorStatus;
     154             : 
     155             :     VclPtr<SvSimpleTableContainer>  m_pContainer;
     156             :     VclPtr<HeaderBar>               m_pStatusHB;
     157             :     VclPtr<SvSimpleTable>           m_pStatus;
     158             : 
     159             :     VclPtr<PushButton>              m_pStop;
     160             :     VclPtr<PushButton>              m_pClose;
     161             : 
     162             :     OUString                m_sContinue;
     163             :     OUString                m_sStop;
     164             :     OUString                m_sTransferStatus;
     165             :     OUString                m_sErrorStatus;
     166             :     OUString                m_sSendingTo;
     167             :     OUString                m_sCompleted;
     168             :     OUString                m_sFailed;
     169             : 
     170             :     bool                    m_bCancel;
     171             :     bool                    m_bDesctructionEnabled;
     172             : 
     173             :     ImageList               m_aImageList;
     174             : 
     175             :     SwSendMailDialog_Impl*  m_pImpl;
     176             :     SwMailMergeConfigItem*  m_pConfigItem;
     177             :     sal_Int32               m_nStatusHeight;
     178             :     sal_Int32               m_nSendCount;
     179             :     sal_Int32               m_nErrorCount;
     180             : 
     181             :     DECL_DLLPRIVATE_LINK( StopHdl_Impl, PushButton* );
     182             :     DECL_DLLPRIVATE_LINK( CloseHdl_Impl, void* );
     183             :     DECL_DLLPRIVATE_STATIC_LINK( SwSendMailDialog, StartSendMails, SwSendMailDialog* );
     184             :     DECL_DLLPRIVATE_STATIC_LINK( SwSendMailDialog, StopSendMails, SwSendMailDialog* );
     185             :     DECL_DLLPRIVATE_LINK_TYPED( RemoveThis, Idle*, void );
     186             : 
     187             :     SAL_DLLPRIVATE void        IterateMails();
     188             :     SAL_DLLPRIVATE void        SendMails();
     189             :     SAL_DLLPRIVATE void        UpdateTransferStatus();
     190             : 
     191             :     virtual void        StateChanged( StateChangedType nStateChange ) SAL_OVERRIDE;
     192             : 
     193             : public:
     194             :     SwSendMailDialog( vcl::Window* pParent, SwMailMergeConfigItem& );
     195             :     virtual ~SwSendMailDialog();
     196             :     virtual void        dispose() SAL_OVERRIDE;
     197             : 
     198             :     void                AddDocument( SwMailDescriptor& rDesc );
     199             :     void                SetDocumentCount( sal_Int32 nAllDocuments );
     200           0 :     void                EnableDesctruction() {m_bDesctructionEnabled = true;}
     201             :     void                ShowDialog();
     202             : 
     203             :     void                DocumentSent( ::com::sun::star::uno::Reference< ::com::sun::star::mail::XMailMessage>,
     204             :                                         bool bResult,
     205             :                                         const OUString* pError );
     206             :     void                AllMailsSent();
     207             : 
     208             : };
     209             : #endif
     210             : 
     211             : /* vim:set shiftwidth=4 softtabstop=4 expandtab: */

Generated by: LCOV version 1.11