2007-06-05 12:10:51 +00:00
|
|
|
/////////////////////////////////////////////////////////////////////////////
|
|
|
|
// Name: dialog_build_BOM.h
|
|
|
|
// Copyright: GNU license
|
2008-03-20 01:50:21 +00:00
|
|
|
// Licence:
|
2007-06-05 12:10:51 +00:00
|
|
|
/////////////////////////////////////////////////////////////////////////////
|
|
|
|
|
|
|
|
#ifndef _DIALOG_BUILD_BOM_H_
|
|
|
|
#define _DIALOG_BUILD_BOM_H_
|
|
|
|
|
2009-03-12 15:24:52 +00:00
|
|
|
#include "dialog_build_BOM_base.h"
|
2007-06-05 12:10:51 +00:00
|
|
|
|
2010-07-30 21:41:55 +00:00
|
|
|
|
2010-03-19 20:15:30 +00:00
|
|
|
class DIALOG_BUILD_BOM : public DIALOG_BUILD_BOM_BASE
|
2008-03-20 01:50:21 +00:00
|
|
|
{
|
2009-03-12 15:24:52 +00:00
|
|
|
private:
|
2010-07-30 21:41:55 +00:00
|
|
|
WinEDA_DrawFrame * m_Parent;
|
|
|
|
wxConfig* m_Config;
|
|
|
|
wxString m_ListFileName;
|
2007-06-05 12:10:51 +00:00
|
|
|
|
2009-03-12 15:24:52 +00:00
|
|
|
private:
|
2007-07-02 12:48:10 +00:00
|
|
|
void OnRadioboxSelectFormatSelected( wxCommandEvent& event );
|
2007-06-05 12:10:51 +00:00
|
|
|
void OnOkClick( wxCommandEvent& event );
|
2007-10-13 05:56:37 +00:00
|
|
|
void OnCancelClick( wxCommandEvent& event );
|
|
|
|
|
2009-03-12 15:24:52 +00:00
|
|
|
void SavePreferences();
|
2010-07-30 21:41:55 +00:00
|
|
|
void Init();
|
2010-02-26 06:06:03 +00:00
|
|
|
void Create_BOM_Lists(int aTypeFile,
|
2008-05-15 13:29:59 +00:00
|
|
|
bool aIncludeSubComponents,
|
|
|
|
char aExportSeparatorSymbol,
|
|
|
|
bool aRunBrowser);
|
2010-07-30 21:41:55 +00:00
|
|
|
|
2008-05-15 13:29:59 +00:00
|
|
|
void GenereListeOfItems(const wxString & FullFileName, bool aIncludeSubComponents );
|
|
|
|
void CreateExportList(const wxString & FullFileName, bool aIncludeSubComponents);
|
2010-07-30 21:41:55 +00:00
|
|
|
|
|
|
|
/**
|
|
|
|
* Function CreateParstList
|
|
|
|
* prints a list of components, in a form which can be imported by a
|
|
|
|
* spreadsheet. Form is:
|
|
|
|
* cmp value; number of components; <footprint>; <field1>; ...;
|
|
|
|
* list of references having the same value
|
|
|
|
*/
|
|
|
|
void CreatePartsList( const wxString& aFullFileName, bool aIncludeSubComponents );
|
|
|
|
|
2008-12-10 18:00:15 +00:00
|
|
|
int PrintComponentsListByRef( FILE * f, std::vector <OBJ_CMP_TO_LIST>& aList,
|
2008-05-15 13:29:59 +00:00
|
|
|
bool CompactForm, bool aIncludeSubComponents );
|
2010-07-30 21:41:55 +00:00
|
|
|
|
2008-12-10 18:00:15 +00:00
|
|
|
int PrintComponentsListByVal( FILE *f, std::vector <OBJ_CMP_TO_LIST>& aList,
|
2008-05-15 13:29:59 +00:00
|
|
|
bool aIncludeSubComponents);
|
2010-07-30 21:41:55 +00:00
|
|
|
|
2010-04-24 09:03:35 +00:00
|
|
|
int PrintComponentsListByPart( FILE *f, std::vector <OBJ_CMP_TO_LIST>& aList,
|
|
|
|
bool aIncludeSubComponents);
|
2010-07-30 21:41:55 +00:00
|
|
|
|
2008-03-20 01:50:21 +00:00
|
|
|
void PrintFieldData(FILE * f, SCH_COMPONENT * DrawLibItem, bool CompactForm = FALSE);
|
2007-06-05 12:10:51 +00:00
|
|
|
|
2010-07-30 21:41:55 +00:00
|
|
|
bool IsFieldChecked(int aFieldId);
|
2007-06-05 12:10:51 +00:00
|
|
|
|
2009-03-12 15:24:52 +00:00
|
|
|
public:
|
|
|
|
DIALOG_BUILD_BOM( WinEDA_DrawFrame* parent );
|
2010-07-30 21:41:55 +00:00
|
|
|
// ~DIALOG_BUILD_BOM() {};
|
2007-06-05 12:10:51 +00:00
|
|
|
};
|
|
|
|
|
2010-07-30 21:41:55 +00:00
|
|
|
#endif // _DIALOG_BUILD_BOM_H_
|
2009-03-12 15:24:52 +00:00
|
|
|
|