1 /*************************************************************************
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
5 * Copyright 2008 by Sun Microsystems, Inc.
7 * OpenOffice.org - a multi-platform office productivity suite
9 * $RCSfile: docrecovery.hxx,v $
12 * This file is part of OpenOffice.org.
14 * OpenOffice.org is free software: you can redistribute it and/or modify
15 * it under the terms of the GNU Lesser General Public License version 3
16 * only, as published by the Free Software Foundation.
18 * OpenOffice.org is distributed in the hope that it will be useful,
19 * but WITHOUT ANY WARRANTY; without even the implied warranty of
20 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
21 * GNU Lesser General Public License version 3 for more details
22 * (a copy is included in the LICENSE file that accompanied this code).
24 * You should have received a copy of the GNU Lesser General Public License
25 * version 3 along with OpenOffice.org. If not, see
26 * <http://www.openoffice.org/license.html>
27 * for a copy of the LGPLv3 License.
29 ************************************************************************/
31 #ifndef _SVX_DOCRECOVERY_HXX
32 #define _SVX_DOCRECOVERY_HXX
34 #include <vcl/tabpage.hxx>
35 #ifndef _SV_TABDIALOG_HXX
36 #include <vcl/tabdlg.hxx>
38 #include <vcl/dialog.hxx>
39 #ifndef _SV_BUTTON_HXX
40 #include <vcl/button.hxx>
42 #include <vcl/fixed.hxx>
43 #include <svtools/svmedit2.hxx>
44 #include <svtools/svtreebx.hxx>
45 #include <svx/simptabl.hxx>
47 #include <cppuhelper/implbase1.hxx>
48 #include <cppuhelper/implbase2.hxx>
49 #include <com/sun/star/task/XStatusIndicatorFactory.hpp>
50 #include <com/sun/star/frame/XStatusListener.hpp>
51 #include <com/sun/star/frame/XDispatch.hpp>
52 #include <com/sun/star/lang/XComponent.hpp>
54 //===============================================
57 #define RECOVERY_CMDPART_PROTOCOL ::rtl::OUString::createFromAscii("vnd.sun.star.autorecovery:")
59 #define RECOVERY_CMDPART_DO_PREPARE_EMERGENCY_SAVE ::rtl::OUString::createFromAscii("/doPrepareEmergencySave" )
60 #define RECOVERY_CMDPART_DO_EMERGENCY_SAVE ::rtl::OUString::createFromAscii("/doEmergencySave" )
61 #define RECOVERY_CMDPART_DO_RECOVERY ::rtl::OUString::createFromAscii("/doAutoRecovery" )
62 #define RECOVERY_CMDPART_DO_CRASHREPORT ::rtl::OUString::createFromAscii("/doCrashReport" )
63 #define RECOVERY_CMDPART_DO_ENTRY_BACKUP ::rtl::OUString::createFromAscii("/doEntryBackup" )
64 #define RECOVERY_CMDPART_DO_ENTRY_CLEANUP ::rtl::OUString::createFromAscii("/doEntryCleanUp" )
66 #define RECOVERY_CMD_DO_PREPARE_EMERGENCY_SAVE ::rtl::OUString::createFromAscii("vnd.sun.star.autorecovery:/doPrepareEmergencySave")
67 #define RECOVERY_CMD_DO_EMERGENCY_SAVE ::rtl::OUString::createFromAscii("vnd.sun.star.autorecovery:/doEmergencySave" )
68 #define RECOVERY_CMD_DO_RECOVERY ::rtl::OUString::createFromAscii("vnd.sun.star.autorecovery:/doAutoRecovery" )
69 #define RECOVERY_CMD_DO_CRASHREPORT ::rtl::OUString::createFromAscii("vnd.sun.star.autorecovery:/doCrashReport" )
70 #define RECOVERY_CMD_DO_ENTRY_BACKUP ::rtl::OUString::createFromAscii("vnd.sun.star.autorecovery:/doEntryBackup" )
71 #define RECOVERY_CMD_DO_ENTRY_CLEANUP ::rtl::OUString::createFromAscii("vnd.sun.star.autorecovery:/doEntryCleanUp" )
73 #define SERVICENAME_PROGRESSFACTORY ::rtl::OUString::createFromAscii("com.sun.star.task.StatusIndicatorFactory")
74 #define SERVICENAME_URLTRANSFORMER ::rtl::OUString::createFromAscii("com.sun.star.util.URLTransformer" )
75 #define SERVICENAME_RECOVERYCORE ::rtl::OUString::createFromAscii("com.sun.star.frame.AutoRecovery" )
76 #define SERVICENAME_FOLDERPICKER ::rtl::OUString::createFromAscii("com.sun.star.ui.dialogs.FolderPicker" )
77 #define SERVICENAME_DESKTOP ::rtl::OUString::createFromAscii("com.sun.star.frame.Desktop" )
79 #define PROP_PARENTWINDOW ::rtl::OUString::createFromAscii("Window" )
80 #define PROP_STATUSINDICATOR ::rtl::OUString::createFromAscii("StatusIndicator" )
81 #define PROP_DISPATCHASYNCHRON ::rtl::OUString::createFromAscii("DispatchAsynchron")
82 #define PROP_SAVEPATH ::rtl::OUString::createFromAscii("SavePath" )
83 #define PROP_ENTRYID ::rtl::OUString::createFromAscii("EntryID" )
84 #define PROP_ALLOWPARENTSHOW ::rtl::OUString::createFromAscii("AllowParentShow" )
86 #define STATEPROP_ID ::rtl::OUString::createFromAscii("ID" )
87 #define STATEPROP_STATE ::rtl::OUString::createFromAscii("DocumentState")
88 #define STATEPROP_ORGURL ::rtl::OUString::createFromAscii("OriginalURL" )
89 #define STATEPROP_TEMPURL ::rtl::OUString::createFromAscii("TempURL" )
90 #define STATEPROP_FACTORYURL ::rtl::OUString::createFromAscii("FactoryURL" )
91 #define STATEPROP_TEMPLATEURL ::rtl::OUString::createFromAscii("TemplateURL" )
92 #define STATEPROP_TITLE ::rtl::OUString::createFromAscii("Title" )
93 #define STATEPROP_MODULE ::rtl::OUString::createFromAscii("Module" )
95 #define RECOVERY_OPERATIONSTATE_START ::rtl::OUString::createFromAscii("start" )
96 #define RECOVERY_OPERATIONSTATE_STOP ::rtl::OUString::createFromAscii("stop" )
97 #define RECOVERY_OPERATIONSTATE_UPDATE ::rtl::OUString::createFromAscii("update")
99 #define DLG_RET_UNKNOWN -1
101 #define DLG_RET_CANCEL 0
102 #define DLG_RET_BACK 100
103 #define DLG_RET_OK_AUTOLUNCH 101
105 //===============================================
109 namespace DocRecovery
{
112 # error "Who uses css? I need it as temp. namespace alias!"
114 # define css ::com::sun::star
117 //===============================================
122 /// default state, if a document was new created or loaded
124 /// modified against the original file
126 /// an active document can be postponed to be saved later.
128 /// was already handled during one AutoSave/Recovery session.
130 /** an action was started (saving/loading) ... Can be interesting later if the process may be was interrupted by an exception. */
132 E_TRY_LOAD_BACKUP
= 16,
133 E_TRY_LOAD_ORIGINAL
= 32,
137 /// the Auto/Emergency saved document isnt useable any longer
139 /// the Auto/Emergency saved document isnt realy up-to-date (some changes can be missing)
141 /// the Auto/Emergency saved document was processed successfully
145 //===============================================
148 E_SUCCESSFULLY_RECOVERED
,
149 E_ORIGINAL_DOCUMENT_RECOVERED
,
151 E_RECOVERY_IS_IN_PROGRESS
,
155 //===============================================
160 /// unique ID, which is specified by the underlying autorecovery core!
163 /// the full qualified document URL
164 ::rtl::OUString OrgURL
;
166 /// the full qualified URL of the temp. file (if it's exists)
167 ::rtl::OUString TempURL
;
169 /// a may be existing factory URL (e.g. for untitled documents)
170 ::rtl::OUString FactoryURL
;
172 /// may be the document base on a template file !?
173 ::rtl::OUString TemplateURL
;
175 /// the pure file name, without path, disc etcpp.
176 ::rtl::OUString DisplayName
;
178 /// the application module, where this document was loaded
179 ::rtl::OUString Module
;
181 /// state info as e.g. VALID, CORRUPTED, NON EXISTING ...
184 /// ui representation for DocState!
185 ERecoveryState RecoveryState
;
190 /// high contrast icon
197 , DocState (E_UNKNOWN
)
198 , RecoveryState(E_NOT_RECOVERED_YET
)
202 //===============================================
203 typedef ::std::vector
< TURLInfo
> TURLList
;
205 //===============================================
206 class IRecoveryUpdateListener
210 // inform listener about changed items, which should be refreshed
211 virtual void updateItems() = 0;
213 // inform listener about starting of the asynchronous recovery operation
214 virtual void start() = 0;
216 // inform listener about ending of the asynchronous recovery operation
217 virtual void end() = 0;
220 virtual void stepNext(TURLInfo
* pItem
) = 0;
223 //===============================================
224 class RecoveryCore
: public ::cppu::WeakImplHelper1
< css::frame::XStatusListener
>
226 //-------------------------------------------
230 //-------------------------------------------
235 css::uno::Reference
< css::lang::XMultiServiceFactory
> m_xSMGR
;
238 css::uno::Reference
< css::frame::XDispatch
> m_xRealCore
;
241 css::uno::Reference
< css::task::XStatusIndicator
> m_xProgress
;
247 IRecoveryUpdateListener
* m_pListener
;
249 /** @short knows the reason, why we listen on our internal m_xRealCore
252 @descr Because we listen for different operations
253 on the core dispatch implementation, we must know,
254 which URL we have to use for deregistration!
256 sal_Bool m_bListenForSaving
;
258 //-------------------------------------------
262 //---------------------------------------
264 RecoveryCore(const css::uno::Reference
< css::lang::XMultiServiceFactory
>& xSMGR
,
265 sal_Bool bUsedForSaving
);
267 //---------------------------------------
269 virtual ~RecoveryCore();
271 //---------------------------------------
273 virtual css::uno::Reference
< css::lang::XMultiServiceFactory
> getSMGR();
275 //---------------------------------------
277 virtual TURLList
* getURLListAccess();
279 //---------------------------------------
281 virtual sal_Bool
existsBrokenTempEntries();
282 virtual sal_Bool
existsNonRecoveredEntries();
283 static sal_Bool
isBrokenTempEntry(const TURLInfo
& rInfo
);
284 virtual void saveBrokenTempEntries(const ::rtl::OUString
& sSaveDir
);
285 virtual void saveAllTempEntries(const ::rtl::OUString
& sSaveDir
);
286 virtual void forgetBrokenTempEntries();
287 virtual void forgetAllRecoveryEntries();
288 void forgetBrokenRecoveryEntries();
290 //---------------------------------------
292 virtual void setProgressHandler(const css::uno::Reference
< css::task::XStatusIndicator
>& xProgress
);
294 //---------------------------------------
296 virtual void setUpdateListener(IRecoveryUpdateListener
* pListener
);
298 //---------------------------------------
300 virtual void doEmergencySavePrepare();
301 virtual void doEmergencySave();
302 virtual void doRecovery();
304 //---------------------------------------
306 static ERecoveryState
mapDocState2RecoverState(sal_Int32 eDocState
);
308 //-------------------------------------------
312 // css.frame.XStatusListener
313 virtual void SAL_CALL
statusChanged(const css::frame::FeatureStateEvent
& aEvent
)
314 throw(css::uno::RuntimeException
);
316 // css.lang.XEventListener
317 virtual void SAL_CALL
disposing(const css::lang::EventObject
& aEvent
)
318 throw(css::uno::RuntimeException
);
320 //-------------------------------------------
324 //---------------------------------------
325 /** @short starts listening on the internal EmergencySave/AutoRecovery core.
327 void impl_startListening();
329 //---------------------------------------
330 /** @short stop listening on the internal EmergencySave/AutoRecovery core.
332 void impl_stopListening();
334 //---------------------------------------
336 css::util::URL
impl_getParsedURL(const ::rtl::OUString
& sURL
);
339 //===============================================
340 class PluginProgressWindow
: public Window
344 css::uno::Reference
< css::lang::XComponent
> m_xProgress
;
348 PluginProgressWindow( Window
* pParent
,
349 const css::uno::Reference
< css::lang::XComponent
>& xProgress
);
350 ~PluginProgressWindow();
353 class PluginProgress
: public ::cppu::WeakImplHelper2
< css::task::XStatusIndicator
,
354 css::lang::XComponent
>
357 //-------------------------------------------
362 css::uno::Reference
< css::task::XStatusIndicatorFactory
> m_xProgressFactory
;
364 css::uno::Reference
< css::task::XStatusIndicator
> m_xProgress
;
366 PluginProgressWindow
* m_pPlugProgressWindow
;
368 //-------------------------------------------
372 //---------------------------------------
374 PluginProgress( Window
* pParent
,
375 const css::uno::Reference
< css::lang::XMultiServiceFactory
>& xSMGR
);
377 //---------------------------------------
379 virtual ~PluginProgress();
381 //---------------------------------------
383 Window
* getPlugWindow();
385 //-------------------------------------------
389 //---------------------------------------
391 virtual void SAL_CALL
start(const ::rtl::OUString
& sText
,
393 throw(css::uno::RuntimeException
);
395 virtual void SAL_CALL
end()
396 throw(css::uno::RuntimeException
);
398 virtual void SAL_CALL
setText(const ::rtl::OUString
& sText
)
399 throw(css::uno::RuntimeException
);
401 virtual void SAL_CALL
setValue(sal_Int32 nValue
)
402 throw(css::uno::RuntimeException
);
404 virtual void SAL_CALL
reset()
405 throw(css::uno::RuntimeException
);
407 //---------------------------------------
409 virtual void SAL_CALL
dispose()
410 throw(css::uno::RuntimeException
);
412 virtual void SAL_CALL
addEventListener(const css::uno::Reference
< css::lang::XEventListener
>& xListener
)
413 throw(css::uno::RuntimeException
);
415 virtual void SAL_CALL
removeEventListener( const css::uno::Reference
< css::lang::XEventListener
>& xListener
)
416 throw(css::uno::RuntimeException
);
419 //===============================================
420 class IExtendedTabPage
: public TabPage
422 //-------------------------------------------
428 //-------------------------------------------
432 IExtendedTabPage( Window
* pParent
, WinBits nStyle
= 0 )
433 : TabPage( pParent
, nStyle
)
434 , m_nResult(DLG_RET_UNKNOWN
)
437 IExtendedTabPage( Window
* pParent
, const ResId
& rResId
)
438 : TabPage( pParent
, rResId
)
439 , m_nResult(DLG_RET_UNKNOWN
)
442 virtual ~IExtendedTabPage()
445 virtual short execute() = 0;
446 virtual void setDefButton() = 0;
449 typedef ::std::vector
< IExtendedTabPage
* > TTabPageList
;
451 //===============================================
452 class TabDialog4Recovery
: public TabDialog
454 //-------------------------------------------
458 TTabPageList m_lTabPages
;
459 TTabPageList::iterator m_pActualPage
;
461 //-------------------------------------------
465 TabDialog4Recovery(Window
* pParent
);
466 virtual ~TabDialog4Recovery();
468 virtual void addTabPage(IExtendedTabPage
* pPage
);
469 virtual short Execute();
472 //===============================================
473 class SaveDialog
: public IExtendedTabPage
475 //-------------------------------------------
480 FixedText m_aTitleFT
;
481 FixedLine m_aTitleFL
;
482 FixedText m_aDescrFT
;
483 FixedText m_aFileListFT
;
484 ListBox m_aFileListLB
;
485 FixedLine m_aBottomFL
;
488 RecoveryCore
* m_pCore
;
490 //-------------------------------------------
494 //---------------------------------------
495 /** @short create all child controls of this dialog.
497 @descr The dialog isnt shown nor it starts any
501 can point to a parent window.
502 If its set to 0, the defmodal-dialog-parent
506 provides access to the recovery core service
507 and the current list of open documents,
508 which should be shown inside this dialog.
510 SaveDialog(Window
* pParent
,
511 RecoveryCore
* pCore
);
513 //---------------------------------------
514 /** @short free all controls and used memory. */
515 virtual ~SaveDialog();
517 //---------------------------------------
519 virtual short execute();
521 //---------------------------------------
523 virtual void setDefButton();
525 DECL_LINK(OKButtonHdl
, void*);
528 //===============================================
529 class SaveProgressDialog
: public ModalDialog
530 , public IRecoveryUpdateListener
532 //-------------------------------------------
537 FixedText m_aProgrFT
;
538 String m_aProgrBaseTxt
;
539 Window m_aProgrParent
;
542 RecoveryCore
* m_pCore
;
545 css::uno::Reference
< css::task::XStatusIndicator
> m_xProgress
;
547 //-------------------------------------------
551 //---------------------------------------
552 /** @short create all child controls of this dialog.
554 @descr The dialog isnt shown nor it starts any
558 can point to a parent window.
559 If its set to 0, the defmodal-dialog-parent
563 used to start emegrency save.
565 SaveProgressDialog(Window
* pParent
,
566 RecoveryCore
* pCore
);
568 //---------------------------------------
569 /** @short free all controls and used memory. */
570 virtual ~SaveProgressDialog();
572 //---------------------------------------
573 /** @short start the emergency save operation. */
574 virtual short Execute();
576 // IRecoveryUpdateListener
577 virtual void updateItems();
578 virtual void stepNext(TURLInfo
* pItem
);
579 virtual void start();
583 //===============================================
584 class RecovDocListEntry
: public SvLBoxString
586 //-------------------------------------------
590 //-------------------------------------------
594 //---------------------------------------
596 RecovDocListEntry( SvLBoxEntry
* pEntry
,
598 const String
& sText
);
600 //---------------------------------------
602 virtual void Paint(const Point
& aPos
,
605 SvLBoxEntry
* pEntry
);
608 //===============================================
609 class RecovDocList
: public SvxSimpleTable
611 //-------------------------------------------
615 Image m_aGreenCheckImg
;
616 Image m_aYellowCheckImg
;
617 Image m_aRedCrossImg
;
618 Image m_aGreenCheckImgHC
;
619 Image m_aYellowCheckImgHC
;
620 Image m_aRedCrossImgHC
;
622 String m_aSuccessRecovStr
;
623 String m_aOrigDocRecovStr
;
624 String m_aRecovFailedStr
;
625 String m_aRecovInProgrStr
;
626 String m_aNotRecovYetStr
;
628 //-------------------------------------------
632 //---------------------------------------
634 RecovDocList( Window
* pParent
,
635 const ResId
& rResId
);
637 //---------------------------------------
639 virtual ~RecovDocList();
641 //---------------------------------------
643 virtual void InitEntry( SvLBoxEntry
* pEntry
,
644 const XubString
& sText
,
645 const Image
& aImage1
,
646 const Image
& aImage2
,
647 SvLBoxButtonKind eButtonKind
);
650 //===============================================
651 class RecoveryDialog
: public IExtendedTabPage
652 , public IRecoveryUpdateListener
654 //-------------------------------------------
658 FixedText m_aTitleFT
;
659 FixedLine m_aTitleFL
;
660 FixedText m_aDescrFT
;
661 FixedText m_aProgressFT
;
662 Window m_aProgrParent
;
663 FixedText m_aFileListFT
;
664 RecovDocList m_aFileListLB
;
665 FixedLine m_aBottomFL
;
666 PushButton m_aNextBtn
;
667 CancelButton m_aCancelBtn
;
669 String m_aTitleRecoveryInProgress
;
670 String m_aTitleRecoveryReport
;
671 String m_aRecoveryOnlyFinish
;
672 String m_aRecoveryOnlyFinishDescr
;
674 PushButton
* m_pDefButton
;
675 RecoveryCore
* m_pCore
;
676 css::uno::Reference
< css::task::XStatusIndicator
> m_xProgress
;
677 enum EInternalRecoveryState
679 E_RECOVERY_PREPARED
, // dialog started ... recovery prepared
680 E_RECOVERY_IN_PROGRESS
, // recovery core still in progress
681 E_RECOVERY_CORE_DONE
, // recovery core finished it's task
682 E_RECOVERY_DONE
, // user clicked "next" button
683 E_RECOVERY_CANCELED
, // user clicked "cancel" button
684 E_RECOVERY_CANCELED_BEFORE
, // user clicked "cancel" button before recovery was started
685 E_RECOVERY_CANCELED_AFTERWARDS
, // user clicked "cancel" button after reovery was finished
686 E_RECOVERY_HANDLED
// the recovery wizard page was shown already ... and will be shown now again ...
688 sal_Int32 m_eRecoveryState
;
689 sal_Bool m_bWaitForUser
;
690 sal_Bool m_bWaitForCore
;
691 sal_Bool m_bUserDecideNext
;
692 sal_Bool m_bWasRecoveryStarted
;
693 sal_Bool m_bRecoveryOnly
;
695 //-------------------------------------------
699 //---------------------------------------
701 RecoveryDialog(Window
* pParent
,
702 RecoveryCore
* pCore
);
704 //---------------------------------------
706 virtual ~RecoveryDialog();
708 //---------------------------------------
709 // IRecoveryUpdateListener
710 virtual void updateItems();
711 virtual void stepNext(TURLInfo
* pItem
);
712 virtual void start();
715 //---------------------------------------
717 virtual short execute();
719 //---------------------------------------
721 virtual void setDefButton();
723 //-------------------------------------------
727 //---------------------------------------
729 DECL_LINK(NextButtonHdl
, void*);
730 DECL_LINK(CancelButtonHdl
, void*);
732 //---------------------------------------
734 void impl_refreshDocList();
736 //---------------------------------------
738 String
impl_getStatusString( const TURLInfo
& rInfo
) const;
741 //===============================================
742 class BrokenRecoveryDialog
: public ModalDialog
744 //-------------------------------------------
747 FixedText m_aDescrFT
;
748 FixedText m_aFileListFT
;
749 ListBox m_aFileListLB
;
750 FixedText m_aSaveDirFT
;
752 PushButton m_aSaveDirBtn
;
753 FixedLine m_aBottomFL
;
755 CancelButton m_aCancelBtn
;
757 ::rtl::OUString m_sSavePath
;
758 RecoveryCore
* m_pCore
;
759 sal_Bool m_bBeforeRecovery
;
760 sal_Bool m_bExecutionNeeded
;
762 //-------------------------------------------
766 //---------------------------------------
768 BrokenRecoveryDialog(Window
* pParent
,
769 RecoveryCore
* pCore
,
770 sal_Bool bBeforeRecovery
);
772 //---------------------------------------
774 virtual ~BrokenRecoveryDialog();
776 //---------------------------------------
778 virtual sal_Bool
isExecutionNeeded();
780 //---------------------------------------
782 virtual ::rtl::OUString
getSaveDirURL();
784 //-------------------------------------------
788 //---------------------------------------
792 //---------------------------------------
794 DECL_LINK(SaveButtonHdl
, void*);
796 //---------------------------------------
798 DECL_LINK(OkButtonHdl
, void*);
800 //---------------------------------------
802 DECL_LINK(CancelButtonHdl
, void*);
804 //---------------------------------------
806 void impl_askForSavePath();
811 class ErrorRepWelcomeDialog
: public IExtendedTabPage
819 FixedLine maBottomFL
;
820 PushButton maPrevBtn
;
822 CancelButton maCancelBtn
;
824 DECL_LINK( PrevBtnHdl
, void* );
825 DECL_LINK( NextBtnHdl
, void* );
826 DECL_LINK( CancelBtnHdl
, void* );
828 ErrorRepWelcomeDialog( Window
* _pParent
, sal_Bool _bAllowBack
= sal_True
);
829 virtual ~ErrorRepWelcomeDialog();
831 virtual short execute();
833 //---------------------------------------
835 virtual void setDefButton();
838 struct ErrorRepParams
842 : miHTTPConnectionType( 0 )
844 : miHTTPConnectionType( 1 )
846 , mbAllowContact( false )
849 String maHTTPProxyServer
;
850 String maHTTPProxyPort
;
851 int miHTTPConnectionType
;
853 String maReturnAddress
;
858 class ErrorDescriptionEdit
: public MultiLineEdit
861 DECL_LINK( ModifyHdl
, void* );
864 ErrorDescriptionEdit( Window
* pParent
, const ResId
& rResId
);
865 virtual ~ErrorDescriptionEdit();
868 class ErrorRepSendDialog
: public IExtendedTabPage
876 FixedText maDocTypeFT
;
879 ErrorDescriptionEdit maUsingML
;
880 PushButton maShowRepBtn
;
882 CheckBox maContactCB
;
883 FixedText maEMailAddrFT
;
886 FixedLine maBottomFL
;
887 PushButton maPrevBtn
;
889 CancelButton maCancelBtn
;
891 ErrorRepParams maParams
;
893 DECL_LINK( ShowRepBtnHdl
, void* );
894 DECL_LINK( OptBtnHdl
, void* );
895 DECL_LINK( ContactCBHdl
, void* );
896 DECL_LINK( PrevBtnHdl
, void* );
897 DECL_LINK( SendBtnHdl
, void* );
898 DECL_LINK( CancelBtnHdl
, void* );
903 ErrorRepSendDialog( Window
* _pParent
);
904 virtual ~ErrorRepSendDialog();
906 String
GetDocType( void ) const;
907 String
GetUsing( void ) const;
908 bool IsContactAllowed( void ) const;
909 String
GetEMailAddress( void ) const;
916 virtual short execute();
918 //---------------------------------------
920 virtual void setDefButton();
923 class ErrorRepOptionsDialog
: public ModalDialog
927 RadioButton maSystemBtn
;
928 RadioButton maDirectBtn
;
929 RadioButton maManualBtn
;
930 FixedText maProxyServerFT
;
931 Edit maProxyServerEd
;
932 FixedText maProxyPortFT
;
934 FixedText maDescriptionFT
;
935 FixedLine maButtonsFL
;
937 CancelButton maCancelBtn
;
939 ErrorRepParams
& mrParams
;
941 DECL_LINK( CancelBtnHdl
, void* );
942 DECL_LINK( OKBtnHdl
, void * );
943 DECL_LINK( ManualBtnHdl
, void * );
946 ErrorRepOptionsDialog( Window
* _pParent
, ErrorRepParams
& rParams
);
947 virtual ~ErrorRepOptionsDialog();
950 class ErrorRepEdit
: public ExtMultiLineEdit
953 ErrorRepEdit( Window
* pParent
, const ResId
& rResId
);
954 virtual ~ErrorRepEdit();
957 class ErrorRepPreviewDialog
: public ModalDialog
960 ErrorRepEdit maContentML
;
966 ErrorRepPreviewDialog( Window
* _pParent
);
967 virtual ~ErrorRepPreviewDialog();
969 virtual void Resize();
971 } // namespace DocRecovery