17#ifndef ATTRIBUTION_OBJ_TYPE_H
18#define ATTRIBUTION_OBJ_TYPE_H
28#include <wx/choicebk.h>
29#include <wx/datectrl.h>
30#include <wx/dateevt.h>
31#include <wx/notebook.h>
32#include <wx/srchctrl.h>
34#include "../core/projectdefmemory.h"
35#include "managed_aui_wnd.h"
36#include "tmchecklistboxrank.h"
44DECLARE_EVENT_TYPE(tmEVT_INFO_BTN_PRESSED, -1)
45DECLARE_EVENT_TYPE(tmEVT_ADD_BTN_PRESSED, -1)
46DECLARE_EVENT_TYPE(tmEVT_REMOVE_BTN_PRESSED, -1)
48#define ID_DLG_OBJ_ATTRIBUTION 10039
49#define ID_PANEL8 10058
50#define ID_CHECKLISTBOX1 10059
51#define ID_PANEL23 10139
52#define ID_CHOICE13 10203
53#define ID_TEXTCTRL19 10204
54#define ID_CHOICE14 10205
55#define ID_DATEPICKERCTRL 10214
56#define ID_TEXTCTRL21 10206
57#define ID_CHECKBOX7 10209
58#define ID_SEARCHCTRL1 10053
59#define ID_CHECKBOX9 10054
60#define ID_DLG_OBJ_ATTRIBUTION_BTN_INFO 10055
61#define ID_DLG_OBJ_ATTRIBUTION_BTN_ATTRIBUTE 10056
62#define ID_CHECKBOX5 10136
63#define SYMBOL_ATTRIBOBJTYPE_PANEL_STYLE wxCAPTION | wxRESIZE_BORDER | wxSYSTEM_MENU | wxCLOSE_BOX
64#define SYMBOL_ATTRIBOBJTYPE_PANEL_TITLE _("Object Kind")
65#define SYMBOL_ATTRIBOBJTYPE_PANEL_IDNAME ID_DLG_OBJ_ATTRIBUTION
66#define SYMBOL_ATTRIBOBJTYPE_PANEL_SIZE wxSize(230, 150)
67#define SYMBOL_ATTRIBOBJTYPE_PANEL_POSITION wxDefaultPosition
68const int ID_DLG_OBJ_ATTRIBUTION_BTN_ADD = wxWindow::NewControlId();
69const int ID_DLG_OBJ_ATTRIBUTION_BTN_REMOVE = wxWindow::NewControlId();
72 wxSizer* CreateControls(wxWindow* parent,
bool call_fit = TRUE,
bool set_sizer = TRUE);
74 wxAuiPaneInfo mPaneInfo;
78 wxWindow* m_ParentEvt;
79 int m_NbFeaturesSelected;
84 wxChoicebook* m_AttribNotebook;
85 wxStaticText* m_WarningMultiFeatureCtrl;
86 bool m_AutoDisplayAttributes;
87 bool m_EmptyListAfterAttributes;
88 bool m_EnableFullAttribution;
89 wxBoxSizer* m_ButtonSizer;
90 wxBoxSizer* m_AttribSizer;
91 wxSearchCtrl* m_textCtrlLines;
92 wxSearchCtrl* m_textCtrlPoints;
93 wxSearchCtrl* m_textCtrlPoly;
97 void OnAddBtn(wxCommandEvent& event);
99 void OnRemoveBtn(wxCommandEvent& event);
101 void OnInfoBtn(wxCommandEvent& event);
103 void OnEditStart(wxCommandEvent& event);
105 void OnEditStop(wxCommandEvent& event);
107 void SetFocusTextCtrl(wxFocusEvent& event);
109 void KillFocusTextCtrl(wxFocusEvent& event);
111 void FilterPointList(wxCommandEvent& event);
113 void FilterPolyList(wxCommandEvent& event);
115 void FilterLineList(wxCommandEvent& event);
117 DECLARE_EVENT_TABLE()
144 int GetSelectedValues(TOC_GENERIC_NAME panel_name, wxArrayLong& values,
bool panel_freq =
false);
146 void SetSelectedValues(TOC_GENERIC_NAME panel_name,
const wxArrayLong& values,
bool panel_freq =
false);
150 bool IsEmptyListValuesRequired() {
151 return m_EmptyListAfterAttributes;
154 bool IsFullAttributionEnabled() {
155 return m_EnableFullAttribution;
160 void ResetFilterFields();
167 void OnFullAttribution(wxCommandEvent& event);
Definition attribution_obj_type.h:71
void SetVisibleNotebook(TOC_GENERIC_NAME notebooktype)
Set visible notebook.
Definition attribution_obj_type.cpp:604
bool UpdateObjectLineList(DataBaseTM *pDB)
Update items in the object line list.
Definition attribution_obj_type.cpp:468
void OnDisplayAttributesAuto(wxCommandEvent &event)
Called when Auto Display Attributes is enabled.
Definition attribution_obj_type.cpp:330
void SetDataBaseToList(DataBaseTM *pDB)
Pass database to check box list.
Definition attribution_obj_type.cpp:532
TOC_GENERIC_NAME GetVisibleNotebook()
Get visible notebook page.
Definition attribution_obj_type.cpp:639
bool UpdateObjectPointList(DataBaseTM *pDB)
Update items in the object point list.
Definition attribution_obj_type.cpp:427
bool IsAutoDisplayAttributeChecked()
Get Status of Auto display attributes checkbox.
Definition attribution_obj_type.cpp:827
void SetInfoBtn(int nbfeatures)
Enable or disable the Info button.
Definition attribution_obj_type.cpp:583
void SetSelectedValues(TOC_GENERIC_NAME panel_name, const wxArrayLong &values, bool panel_freq=false)
Set checked values to the lists.
Definition attribution_obj_type.cpp:770
bool UpdateObjectPolyList(DataBaseTM *pDB)
Update items in the object polygon list.
Definition attribution_obj_type.cpp:448
int GetSelectedValues(TOC_GENERIC_NAME panel_name, wxArrayLong &values, bool panel_freq=false)
Get checked values from lists.
Definition attribution_obj_type.cpp:713
void SetAttributeBtn(int nbfeatures, bool editmode)
Set the text for the button.
Definition attribution_obj_type.cpp:556
void EmptyListValues()
Clear all attributes set when called.
Definition attribution_obj_type.cpp:408
void OnEmptyListAffterAttributes(wxCommandEvent &event)
Switch status of cleaning attribution each time called.
Definition attribution_obj_type.cpp:342
Definition database_tm.h:80
Definition managed_aui_wnd.h:32
Enhance the tmCheckListBox class.
Definition tmchecklistboxrank.h:45
Deals with checkbox list.
Definition tmchecklistbox.h:56