1 /************************************************************** 2 * 3 * Licensed to the Apache Software Foundation (ASF) under one 4 * or more contributor license agreements. See the NOTICE file 5 * distributed with this work for additional information 6 * regarding copyright ownership. The ASF licenses this file 7 * to you under the Apache License, Version 2.0 (the 8 * "License"); you may not use this file except in compliance 9 * with the License. You may obtain a copy of the License at 10 * 11 * http://www.apache.org/licenses/LICENSE-2.0 12 * 13 * Unless required by applicable law or agreed to in writing, 14 * software distributed under the License is distributed on an 15 * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 16 * KIND, either express or implied. See the License for the 17 * specific language governing permissions and limitations 18 * under the License. 19 * 20 *************************************************************/ 21 22 23 #ifndef _SFX_TEMPLDLG_HXX 24 #define _SFX_TEMPLDLG_HXX 25 26 #include "sal/config.h" 27 #include "sfx2/dllapi.h" 28 29 #include <rsc/rscsfx.hxx> 30 31 #include <sfx2/dockwin.hxx> 32 #include <sfx2/childwin.hxx> 33 #include <sfx2/basedlgs.hxx> 34 35 class SfxTemplateDialog_Impl; 36 class SfxTemplateCatalog_Impl; 37 38 // class ISfxTemplateCommon ---------------------------------------------- 39 40 class ISfxTemplateCommon 41 { 42 public: 43 virtual SfxStyleFamily GetActualFamily() const = 0; 44 virtual String GetSelectedEntry() const = 0; 45 }; 46 47 // class SfxTemplateDialog ----------------------------------------------- 48 49 class SfxTemplateDialog : public SfxDockingWindow 50 { 51 private: 52 friend class SfxTemplateDialogWrapper; 53 friend class SfxTemplateDialog_Impl; 54 55 SfxTemplateDialog_Impl* pImpl; 56 57 virtual void DataChanged( const DataChangedEvent& _rDCEvt ); 58 virtual void Resize(); 59 virtual SfxChildAlignment CheckAlignment( SfxChildAlignment, SfxChildAlignment ); 60 virtual void StateChanged( StateChangedType nStateChange ); 61 62 public: 63 SfxTemplateDialog( SfxBindings*, SfxChildWindow*, Window* ); 64 ~SfxTemplateDialog(); 65 66 virtual void Update(); 67 68 ISfxTemplateCommon* GetISfxTemplateCommon(); 69 void SetParagraphFamily(); 70 }; 71 72 // class SfxTemplateCatalog ---------------------------------------------- 73 74 class SfxTemplateCatalog : public SfxModalDialog 75 { 76 private: 77 SfxTemplateCatalog_Impl *pImpl; 78 79 public: 80 SfxTemplateCatalog(Window * pParent, SfxBindings *pBindings); 81 ~SfxTemplateCatalog(); 82 friend class SfxTemplateCatalog_Impl; 83 }; 84 85 // class SfxTemplateDialogWrapper ---------------------------------------- 86 87 class SFX2_DLLPUBLIC SfxTemplateDialogWrapper : public SfxChildWindow 88 { 89 public: 90 SfxTemplateDialogWrapper 91 (Window*,sal_uInt16,SfxBindings*,SfxChildWinInfo*); 92 SFX_DECL_CHILDWINDOW(SfxTemplateDialogWrapper); 93 94 void SetParagraphFamily(); 95 }; 96 97 #endif 98 99