1*1d2dbeb0SAndrew Rist /************************************************************** 2cdf0e10cSrcweir * 3*1d2dbeb0SAndrew Rist * Licensed to the Apache Software Foundation (ASF) under one 4*1d2dbeb0SAndrew Rist * or more contributor license agreements. See the NOTICE file 5*1d2dbeb0SAndrew Rist * distributed with this work for additional information 6*1d2dbeb0SAndrew Rist * regarding copyright ownership. The ASF licenses this file 7*1d2dbeb0SAndrew Rist * to you under the Apache License, Version 2.0 (the 8*1d2dbeb0SAndrew Rist * "License"); you may not use this file except in compliance 9*1d2dbeb0SAndrew Rist * with the License. You may obtain a copy of the License at 10*1d2dbeb0SAndrew Rist * 11*1d2dbeb0SAndrew Rist * http://www.apache.org/licenses/LICENSE-2.0 12*1d2dbeb0SAndrew Rist * 13*1d2dbeb0SAndrew Rist * Unless required by applicable law or agreed to in writing, 14*1d2dbeb0SAndrew Rist * software distributed under the License is distributed on an 15*1d2dbeb0SAndrew Rist * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 16*1d2dbeb0SAndrew Rist * KIND, either express or implied. See the License for the 17*1d2dbeb0SAndrew Rist * specific language governing permissions and limitations 18*1d2dbeb0SAndrew Rist * under the License. 19*1d2dbeb0SAndrew Rist * 20*1d2dbeb0SAndrew Rist *************************************************************/ 21*1d2dbeb0SAndrew Rist 22*1d2dbeb0SAndrew Rist 23cdf0e10cSrcweir #ifndef _CREATEADDRESSLISTDIALOG_HXX 24cdf0e10cSrcweir #define _CREATEADDRESSLISTDIALOG_HXX 25cdf0e10cSrcweir 26cdf0e10cSrcweir #include <sfx2/basedlgs.hxx> 27cdf0e10cSrcweir 28cdf0e10cSrcweir #ifndef _SV_BUTTON_HXX 29cdf0e10cSrcweir #include <vcl/button.hxx> 30cdf0e10cSrcweir #endif 31cdf0e10cSrcweir #include <svtools/stdctrl.hxx> 32cdf0e10cSrcweir #include <vcl/field.hxx> 33cdf0e10cSrcweir #include <vcl/lstbox.hxx> 34cdf0e10cSrcweir #include <vector> 35cdf0e10cSrcweir 36cdf0e10cSrcweir class SwAddressControl_Impl; 37cdf0e10cSrcweir class SwMailMergeConfigItem; 38cdf0e10cSrcweir /*-- 19.04.2004 12:09:46--------------------------------------------------- 39cdf0e10cSrcweir container of the created database 40cdf0e10cSrcweir -----------------------------------------------------------------------*/ 41cdf0e10cSrcweir struct SwCSVData 42cdf0e10cSrcweir { 43cdf0e10cSrcweir ::std::vector< ::rtl::OUString > aDBColumnHeaders; 44cdf0e10cSrcweir ::std::vector< ::std::vector< ::rtl::OUString> > aDBData; 45cdf0e10cSrcweir }; 46cdf0e10cSrcweir /*-- 08.04.2004 14:04:39--------------------------------------------------- 47cdf0e10cSrcweir 48cdf0e10cSrcweir -----------------------------------------------------------------------*/ 49cdf0e10cSrcweir class SwFindEntryDialog; 50cdf0e10cSrcweir class SwCreateAddressListDialog : public SfxModalDialog 51cdf0e10cSrcweir { 52cdf0e10cSrcweir FixedInfo m_aAddressInformation; 53cdf0e10cSrcweir SwAddressControl_Impl* m_pAddressControl; 54cdf0e10cSrcweir 55cdf0e10cSrcweir PushButton m_aNewPB; 56cdf0e10cSrcweir PushButton m_aDeletePB; 57cdf0e10cSrcweir PushButton m_aFindPB; 58cdf0e10cSrcweir PushButton m_aCustomizePB; 59cdf0e10cSrcweir 60cdf0e10cSrcweir FixedInfo m_aViewEntriesFI; 61cdf0e10cSrcweir PushButton m_aStartPB; 62cdf0e10cSrcweir PushButton m_aPrevPB; 63cdf0e10cSrcweir NumericField m_aSetNoNF; 64cdf0e10cSrcweir PushButton m_aNextPB; 65cdf0e10cSrcweir PushButton m_aEndPB; 66cdf0e10cSrcweir 67cdf0e10cSrcweir FixedLine m_aSeparatorFL; 68cdf0e10cSrcweir 69cdf0e10cSrcweir OKButton m_aOK; 70cdf0e10cSrcweir CancelButton m_aCancel; 71cdf0e10cSrcweir HelpButton m_aHelp; 72cdf0e10cSrcweir 73cdf0e10cSrcweir String m_sAddressListFilterName; 74cdf0e10cSrcweir String m_sURL; 75cdf0e10cSrcweir 76cdf0e10cSrcweir SwCSVData* m_pCSVData; 77cdf0e10cSrcweir SwFindEntryDialog* m_pFindDlg; 78cdf0e10cSrcweir 79cdf0e10cSrcweir DECL_LINK(NewHdl_Impl, PushButton*); 80cdf0e10cSrcweir DECL_LINK(DeleteHdl_Impl, PushButton*); 81cdf0e10cSrcweir DECL_LINK(FindHdl_Impl, PushButton*); 82cdf0e10cSrcweir DECL_LINK(CustomizeHdl_Impl, PushButton*); 83cdf0e10cSrcweir DECL_LINK(OkHdl_Impl, PushButton*); 84cdf0e10cSrcweir DECL_LINK(DBCursorHdl_Impl, PushButton*); 85cdf0e10cSrcweir DECL_LINK(DBNumCursorHdl_Impl, NumericField*); 86cdf0e10cSrcweir 87cdf0e10cSrcweir void UpdateButtons(); 88cdf0e10cSrcweir 89cdf0e10cSrcweir public: 90cdf0e10cSrcweir SwCreateAddressListDialog( 91cdf0e10cSrcweir Window* pParent, const String& rURL, SwMailMergeConfigItem& rConfig); 92cdf0e10cSrcweir ~SwCreateAddressListDialog(); 93cdf0e10cSrcweir GetURL() const94cdf0e10cSrcweir const String& GetURL() const { return m_sURL; } 95cdf0e10cSrcweir void Find( const String& rSearch, sal_Int32 nColumn); 96cdf0e10cSrcweir }; 97cdf0e10cSrcweir /*-- 13.04.2004 13:30:21--------------------------------------------------- 98cdf0e10cSrcweir 99cdf0e10cSrcweir -----------------------------------------------------------------------*/ 100cdf0e10cSrcweir class SwFindEntryDialog : public ModelessDialog 101cdf0e10cSrcweir { 102cdf0e10cSrcweir FixedText m_aFindFT; 103cdf0e10cSrcweir Edit m_aFindED; 104cdf0e10cSrcweir CheckBox m_aFindOnlyCB; 105cdf0e10cSrcweir ListBox m_aFindOnlyLB; 106cdf0e10cSrcweir 107cdf0e10cSrcweir PushButton m_aFindPB; 108cdf0e10cSrcweir CancelButton m_aCancel; 109cdf0e10cSrcweir HelpButton m_aHelp; 110cdf0e10cSrcweir 111cdf0e10cSrcweir SwCreateAddressListDialog* m_pParent; 112cdf0e10cSrcweir 113cdf0e10cSrcweir DECL_LINK(FindHdl_Impl, PushButton*); 114cdf0e10cSrcweir DECL_LINK(FindEnableHdl_Impl, Edit*); 115cdf0e10cSrcweir DECL_LINK(CloseHdl_Impl, PushButton*); 116cdf0e10cSrcweir 117cdf0e10cSrcweir public: 118cdf0e10cSrcweir SwFindEntryDialog(SwCreateAddressListDialog* pParent); 119cdf0e10cSrcweir ~SwFindEntryDialog(); 120cdf0e10cSrcweir GetFieldsListBox()121cdf0e10cSrcweir ListBox& GetFieldsListBox(){return m_aFindOnlyLB;} GetFindString() const122cdf0e10cSrcweir String GetFindString() const {return m_aFindED.GetText();} 123cdf0e10cSrcweir }; 124cdf0e10cSrcweir 125cdf0e10cSrcweir #endif 126cdf0e10cSrcweir 127