Hugintrunk
0.1
|
the main images tree control, used on images and optimizer tabs More...
#include <ImagesTree.h>
Public Types | |
enum | GroupMode { GROUP_NONE =0, GROUP_LENS =1, GROUP_STACK =2, GROUP_OUTPUTLAYERS =3, GROUP_OUTPUTSTACK =4 } |
enumeration for grouping mode More... | |
enum | DisplayMode { DISPLAY_GENERAL =0, DISPLAY_EXIF =1, DISPLAY_POSITION =2, DISPLAY_LENS =3, DISPLAY_PHOTOMETRICS =4, DISPLAY_PHOTOMETRICS_IMAGES =32, DISPLAY_PHOTOMETRICS_LENSES =33 } |
enumeration for display mode, limits the displayed columns More... | |
Public Member Functions | |
ImagesTreeCtrl () | |
general constructor More... | |
bool | Create (wxWindow *parent, wxWindowID id=wxID_ANY, const wxPoint &pos=wxDefaultPosition, const wxSize &size=wxDefaultSize, long style=wxTAB_TRAVERSAL, const wxString &name=wxT("panel")) |
creates the control More... | |
void | Init (HuginBase::Panorama *pano) |
initialization, connects all control with Panorama, register observer More... | |
virtual | ~ImagesTreeCtrl (void) |
destructor More... | |
void | SetGroupMode (GroupMode newMode) |
sets the group mode to given mode More... | |
void | SetDisplayMode (DisplayMode newMode) |
sets the display mode to given mode More... | |
void | SetGuiLevel (GuiLevel newSetting) |
sets the GuiLevel of the control More... | |
void | SetOptimizerMode () |
sets to control into optimizer mode More... | |
virtual void | panoramaChanged (HuginBase::Panorama &pano) |
receives notification about panorama changes More... | |
void | panoramaImagesChanged (HuginBase::Panorama &pano, const HuginBase::UIntSet &imgNr) |
receive the update signal and update display accordingly More... | |
HuginBase::UIntSet | GetSelectedImages () |
returns the selected images More... | |
void | MarkActiveImages (const bool markActive) |
sets the flag, if active/disabled image should be marked with different colour More... | |
Public Member Functions inherited from wxcode::wxTreeListCtrl | |
wxTreeListCtrl () | |
wxTreeListCtrl (wxWindow *parent, wxWindowID id=-1, const wxPoint &pos=wxDefaultPosition, const wxSize &size=wxDefaultSize, long style=wxTR_DEFAULT_STYLE, const wxValidator &validator=wxDefaultValidator, const wxString &name=wxTreeListCtrlNameStr) | |
virtual | ~wxTreeListCtrl () |
bool | Create (wxWindow *parent, wxWindowID id=-1, const wxPoint &pos=wxDefaultPosition, const wxSize &size=wxDefaultSize, long style=wxTR_DEFAULT_STYLE, const wxValidator &validator=wxDefaultValidator, const wxString &name=wxTreeListCtrlNameStr) |
void | Refresh (bool erase=TRUE, const wxRect *rect=NULL) |
void | SetFocus () |
size_t | GetCount () const |
unsigned int | GetIndent () const |
void | SetIndent (unsigned int indent) |
unsigned int | GetLineSpacing () const |
void | SetLineSpacing (unsigned int spacing) |
wxImageList * | GetImageList () const |
wxImageList * | GetStateImageList () const |
wxImageList * | GetButtonsImageList () const |
void | SetImageList (wxImageList *imageList) |
void | SetStateImageList (wxImageList *imageList) |
void | SetButtonsImageList (wxImageList *imageList) |
void | AssignImageList (wxImageList *imageList) |
void | AssignStateImageList (wxImageList *imageList) |
void | AssignButtonsImageList (wxImageList *imageList) |
void | SetToolTip (const wxString &tip) |
void | SetToolTip (wxToolTip *tip) |
void | SetItemToolTip (const wxTreeItemId &item, const wxString &tip) |
void | AddColumn (const wxString &text, int width=DEFAULT_COL_WIDTH, int flag=wxALIGN_LEFT, int image=-1, bool shown=true, bool edit=false, const wxString &tooltip=wxEmptyString) |
void | AddColumn (const wxTreeListColumnInfo &colInfo) |
void | InsertColumn (int before, const wxString &text, int width=DEFAULT_COL_WIDTH, int flag=wxALIGN_LEFT, int image=-1, bool shown=true, bool edit=false, const wxString &tooltip=wxEmptyString) |
void | InsertColumn (int before, const wxTreeListColumnInfo &colInfo) |
void | RemoveColumn (int column) |
int | GetColumnCount () const |
void | SetMainColumn (int column) |
int | GetMainColumn () const |
void | SetColumn (int column, const wxTreeListColumnInfo &colInfo) |
wxTreeListColumnInfo | GetColumn (int column) |
const wxTreeListColumnInfo & | GetColumn (int column) const |
void | SetColumnText (int column, const wxString &text) |
wxString | GetColumnText (int column) const |
void | SetColumnWidth (int column, int width) |
int | GetColumnWidth (int column) const |
void | SetColumnAlignment (int column, int flag) |
int | GetColumnAlignment (int column) const |
void | SetColumnImage (int column, int image) |
int | GetColumnImage (int column) const |
void | SetColumnShown (int column, bool shown=true) |
bool | IsColumnShown (int column) const |
void | SetColumnEditable (int column, bool edit=true) |
bool | IsColumnEditable (int column) const |
wxString | GetItemText (const wxTreeItemId &item) const |
wxString | GetItemText (const wxTreeItemId &item, int column) const |
int | GetItemImage (const wxTreeItemId &item, wxTreeItemIcon which=wxTreeItemIcon_Normal) const |
int | GetItemImage (const wxTreeItemId &item, int column) const |
wxTreeItemData * | GetItemData (const wxTreeItemId &item) const |
wxTreeItemData * | GetItemData (const wxTreeItemId &item, int column) const |
bool | GetItemBold (const wxTreeItemId &item) const |
bool | GetItemBold (const wxTreeItemId &item, int column) const |
wxColour | GetItemTextColour (const wxTreeItemId &item) const |
wxColour | GetItemTextColour (const wxTreeItemId &item, int column) const |
wxColour | GetItemBackgroundColour (const wxTreeItemId &item) const |
wxColour | GetItemBackgroundColour (const wxTreeItemId &item, int column) const |
wxFont | GetItemFont (const wxTreeItemId &item) const |
wxFont | GetItemFont (const wxTreeItemId &item, int column) const |
void | SetItemText (const wxTreeItemId &item, const wxString &text) |
void | SetItemText (const wxTreeItemId &item, int column, const wxString &text) |
void | SetItemImage (const wxTreeItemId &item, int image, wxTreeItemIcon which=wxTreeItemIcon_Normal) |
void | SetItemImage (const wxTreeItemId &item, int column, int image) |
void | SetItemData (const wxTreeItemId &item, wxTreeItemData *data) |
void | SetItemData (const wxTreeItemId &item, int column, wxTreeItemData *data) |
void | SetItemBold (const wxTreeItemId &item, bool bold=true) |
void | SetItemBold (const wxTreeItemId &item, int column, bool bold=true) |
void | SetItemTextColour (const wxTreeItemId &item, const wxColour &colour) |
void | SetItemTextColour (const wxTreeItemId &item, int column, const wxColour &colour) |
void | SetItemBackgroundColour (const wxTreeItemId &item, const wxColour &colour) |
void | SetItemBackgroundColour (const wxTreeItemId &item, int column, const wxColour &colour) |
void | SetItemFont (const wxTreeItemId &item, const wxFont &font) |
void | SetItemFont (const wxTreeItemId &item, int column, const wxFont &font) |
void | SetItemHasChildren (const wxTreeItemId &item, bool has=true) |
bool | IsVisible (const wxTreeItemId &item, bool fullRow=false, bool within=true) const |
bool | HasChildren (const wxTreeItemId &item) const |
bool | IsExpanded (const wxTreeItemId &item) const |
bool | IsSelected (const wxTreeItemId &item) const |
bool | IsBold (const wxTreeItemId &item) const |
bool | IsBold (const wxTreeItemId &item, int column) const |
virtual bool | SetFont (const wxFont &font) |
virtual void | SetWindowStyleFlag (long styles) |
virtual long | GetWindowStyleFlag () const |
size_t | GetChildrenCount (const wxTreeItemId &item, bool recursively=true) |
wxTreeItemId | GetRootItem () const |
wxTreeItemId | GetSelection () const |
size_t | GetSelections (wxArrayTreeItemIds &) const |
wxTreeItemId | GetItemParent (const wxTreeItemId &item) const |
wxTreeItemId | GetFirstChild (const wxTreeItemId &item, wxTreeItemIdValue &cookie) const |
wxTreeItemId | GetNextChild (const wxTreeItemId &item, wxTreeItemIdValue &cookie) const |
wxTreeItemId | GetPrevChild (const wxTreeItemId &item, wxTreeItemIdValue &cookie) const |
wxTreeItemId | GetLastChild (const wxTreeItemId &item, wxTreeItemIdValue &cookie) const |
wxTreeItemId | GetNextSibling (const wxTreeItemId &item) const |
wxTreeItemId | GetPrevSibling (const wxTreeItemId &item) const |
wxTreeItemId | GetNext (const wxTreeItemId &item) const |
wxTreeItemId | GetPrev (const wxTreeItemId &item) const |
wxTreeItemId | GetFirstExpandedItem () const |
wxTreeItemId | GetNextExpanded (const wxTreeItemId &item) const |
wxTreeItemId | GetPrevExpanded (const wxTreeItemId &item) const |
wxTreeItemId | GetFirstVisibleItem (bool fullRow=false) const |
wxTreeItemId | GetFirstVisible (bool fullRow=false, bool within=true) const |
wxTreeItemId | GetNextVisible (const wxTreeItemId &item, bool fullRow=false, bool within=true) const |
wxTreeItemId | GetPrevVisible (const wxTreeItemId &item, bool fullRow=false, bool within=true) const |
wxTreeItemId | GetLastVisible (bool fullRow=false, bool within=true) const |
wxTreeItemId | AddRoot (const wxString &text, int image=-1, int selectedImage=-1, wxTreeItemData *data=NULL) |
wxTreeItemId | PrependItem (const wxTreeItemId &parent, const wxString &text, int image=-1, int selectedImage=-1, wxTreeItemData *data=NULL) |
wxTreeItemId | InsertItem (const wxTreeItemId &parent, const wxTreeItemId &idPrevious, const wxString &text, int image=-1, int selectedImage=-1, wxTreeItemData *data=NULL) |
wxTreeItemId | InsertItem (const wxTreeItemId &parent, size_t index, const wxString &text, int image=-1, int selectedImage=-1, wxTreeItemData *data=NULL) |
wxTreeItemId | AppendItem (const wxTreeItemId &parent, const wxString &text, int image=-1, int selectedImage=-1, wxTreeItemData *data=NULL) |
void | Delete (const wxTreeItemId &item) |
void | DeleteChildren (const wxTreeItemId &item) |
void | DeleteRoot () |
void | SetItemParent (const wxTreeItemId &parent, const wxTreeItemId &item) |
void | Expand (const wxTreeItemId &item) |
void | ExpandAll (const wxTreeItemId &item) |
void | Collapse (const wxTreeItemId &item) |
void | CollapseAndReset (const wxTreeItemId &item) |
void | Toggle (const wxTreeItemId &item) |
void | SetCurrentItem (const wxTreeItemId &item=(wxTreeItemId *) NULL) |
void | Unselect () |
void | UnselectAll () |
bool | SelectItem (const wxTreeItemId &item, const wxTreeItemId &last=(wxTreeItemId *) NULL, bool unselect_others=true) |
void | SelectAll () |
void | EnsureVisible (const wxTreeItemId &item) |
void | ScrollTo (const wxTreeItemId &item) |
wxTreeItemId | HitTest (const wxPoint &point) |
wxTreeItemId | HitTest (const wxPoint &point, int &flags) |
wxTreeItemId | HitTest (const wxPoint &point, int &flags, int &column) |
bool | GetBoundingRect (const wxTreeItemId &item, wxRect &rect, bool textOnly=false) const |
void | EditLabel (const wxTreeItemId &item) |
void | EditLabel (const wxTreeItemId &item, int column) |
void | EndEdit (bool isCancelled) |
virtual wxString | OnGetItemText (wxTreeItemData *item, long column) const |
virtual int | OnCompareItems (const wxTreeItemId &item1, const wxTreeItemId &item2) |
virtual int | OnCompareItems (const wxTreeItemId &item1, const wxTreeItemId &item2, int column) |
void | SortChildren (const wxTreeItemId &item, int column=-1, bool reverseOrder=false) |
wxTreeItemId | FindItem (const wxTreeItemId &item, const wxString &str, int mode=0) |
wxTreeItemId | FindItem (const wxTreeItemId &item, int column, const wxString &str, int mode=0) |
virtual bool | SetBackgroundColour (const wxColour &colour) |
virtual bool | SetForegroundColour (const wxColour &colour) |
void | SetDragItem (const wxTreeItemId &item=(wxTreeItemId *) NULL) |
virtual wxSize | DoGetBestSize () const |
Public Member Functions inherited from HuginBase::PanoramaObserver | |
virtual | ~PanoramaObserver () |
Protected Member Functions | |
void | UpdateImageText (wxTreeItemId item) |
updates the information for the given image in tree More... | |
void | UpdateGroupText (wxTreeItemId item) |
updates the information fot the given lens/stack in the tree More... | |
void | UpdateGroup (wxTreeItemId parent, const HuginBase::UIntSet imgs, HuginBase::UIntSet &changed) |
updates the given group, updates number of images and the images itself More... | |
void | OnColumnWidthChange (wxListEvent &e) |
event handler, when column width was changed, save into wxConfig More... | |
void | OnLinkImageVariables (wxCommandEvent &e) |
event handler for linking image variables More... | |
void | OnUnlinkImageVariables (wxCommandEvent &e) |
event handler for unlinking image variables More... | |
void | OnEditImageVariables (wxCommandEvent &e) |
event handler for showing image variables editing dialog More... | |
void | OnBeginDrag (wxTreeEvent &e) |
event handler when dragging begins, veto if dragging is not possible More... | |
void | OnLeftUp (wxMouseEvent &e) |
event handler for left up, handles end of dragging and updates of optimizer variables states More... | |
void | OnLeftDown (wxMouseEvent &e) |
event handler for left mouse down, handles toggle of optimizer variables More... | |
void | OnMouseMove (wxMouseEvent &e) |
event handler for mouse motion, handles focussing of check boxes More... | |
void | OnLeftDblClick (wxMouseEvent &e) |
event handler for left double click More... | |
void | OnSelectAll (wxCommandEvent &e) |
event handler for select all optimizer variables More... | |
void | OnUnselectAll (wxCommandEvent &e) |
event handler for unselect all optimizer variables More... | |
void | OnSelectLensStack (wxCommandEvent &e) |
event handler for select all optimizer variables for selected lens/stack More... | |
void | OnUnselectLensStack (wxCommandEvent &e) |
event handler for unselect all optimizer variables for selected lens/stack More... | |
void | OnChar (wxTreeEvent &e) |
event handler for key events More... | |
void | OnBeginEdit (wxTreeEvent &e) |
event handler for beginning editing More... | |
void | OnEndEdit (wxTreeEvent &e) |
event handler for ending editing, updates the Panorama with modified value More... | |
void | OnExecuteOperation (wxCommandEvent &e) |
menu event handler for PanoOperation (context menu items) More... | |
void | OnContextMenu (wxTreeEvent &e) |
event handler to display context menu More... | |
void | OnHeaderContextMenu (wxListEvent &e) |
event handler for context menu on header More... | |
void | OnActivateImage (wxCommandEvent &e) |
event handler for activate image More... | |
void | OnDeactivateImage (wxCommandEvent &e) |
event handler for deactivate image More... | |
Protected Member Functions inherited from wxcode::wxTreeListCtrl | |
wxTreeListHeaderWindow * | GetHeaderWindow () const |
wxTreeListMainWindow * | GetMainWindow () const |
int | GetHeaderHeight () const |
void | CalculateAndSetHeaderHeight () |
void | DoHeaderLayout () |
void | OnSize (wxSizeEvent &event) |
Private Member Functions | |
void | CreateColumns () |
creates all columns and stores information in m_columnMap, m_columnVector, m_editableColumns and m_variableVector More... | |
void | UnLinkImageVariables (bool linked) |
helper procedure for link/unlink image variables More... | |
void | SelectAllParameters (bool select, bool allImages) |
select/unselect all variables in the active column true selects all, false unselect all true works on all images, false only on images of current lens or stack More... | |
void | UpdateOptimizerVariables () |
updates the display of the optimizer variables (set font) More... | |
void | GenerateSubMenu (wxMenu *menu, PanoOperation::PanoOperationVector *operations, int &id) |
generates submenu for given PanoOperationVector More... | |
void | UpdateItemFont () |
update the font colour for all items More... | |
void | CreateCheckboxImages () |
create image list with necessary images of checkboxes More... | |
Private Attributes | |
HuginBase::Panorama * | m_pano |
GroupMode | m_groupMode |
the active group mode More... | |
HuginBase::StandardImageVariableGroups * | m_variable_groups |
int | m_degDigits |
int | m_distDigits |
int | m_pixelDigits |
GuiLevel | m_guiLevel |
stores the active GuiLevel More... | |
bool | m_optimizerMode |
true, if in optimizer mode More... | |
bool | m_markDisabledImages |
true, if disabled images should be marked with other font color More... | |
DisplayMode | m_displayMode |
the active display mode More... | |
std::map< std::string, size_t > | m_columnMap |
map for easier access to column information More... | |
std::vector< std::string > | m_columnVector |
vector for easier access to column information More... | |
HuginBase::UIntSet | m_editableColumns |
set, which contains editable columns (all column which contains numeric image variables More... | |
std::vector < HuginBase::ImageVariableGroup::ImageVariableEnum > | m_variableVector |
vector for easier access to linking information More... | |
std::map< int, PanoOperation::PanoOperation * > | m_menuOperation |
map with current active context menu PanoOperation More... | |
size_t | m_selectedColumn |
selected column More... | |
HuginBase::UIntSet | m_draggingImages |
UIntSet of dragging images. More... | |
bool | m_dragging |
true, if dragging More... | |
double | m_editVal |
value, which is currently edited More... | |
wxString | m_editOldString |
wxString, as shown before editing started More... | |
bool | m_needsUpdate |
helper variable for update of output stacks/layers More... | |
wxTreeItemId | m_root |
pointer to root item, not shown More... | |
wxTreeItemId | m_lastCurrentItem |
stores last item on which the mouse was hovering More... | |
long | m_lastCurrentCol |
wxTreeItemId | m_leftDownItem |
stores where left mouse click happend More... | |
long | m_leftDownColumn |
wxString | m_configClassName |
Additional Inherited Members | |
Protected Attributes inherited from wxcode::wxTreeListCtrl | |
wxTreeListHeaderWindow * | m_header_win |
wxTreeListMainWindow * | m_main_win |
the main images tree control, used on images and optimizer tabs
Definition at line 36 of file ImagesTree.h.
enumeration for display mode, limits the displayed columns
Enumerator | |
---|---|
DISPLAY_GENERAL | |
DISPLAY_EXIF | |
DISPLAY_POSITION | |
DISPLAY_LENS | |
DISPLAY_PHOTOMETRICS | |
DISPLAY_PHOTOMETRICS_IMAGES | |
DISPLAY_PHOTOMETRICS_LENSES |
Definition at line 49 of file ImagesTree.h.
enumeration for grouping mode
Enumerator | |
---|---|
GROUP_NONE | |
GROUP_LENS | |
GROUP_STACK | |
GROUP_OUTPUTLAYERS | |
GROUP_OUTPUTSTACK |
Definition at line 40 of file ImagesTree.h.
ImagesTreeCtrl::ImagesTreeCtrl | ( | ) |
general constructor
Definition at line 100 of file ImagesTree.cpp.
References DISPLAY_GENERAL, GROUP_NONE, GUI_SIMPLE, m_displayMode, m_dragging, m_groupMode, m_guiLevel, m_markDisabledImages, m_needsUpdate, m_optimizerMode, and m_pano.
|
virtual |
destructor
Definition at line 229 of file ImagesTree.cpp.
References DEBUG_TRACE, m_pano, m_variable_groups, and HuginBase::Panorama::removeObserver().
bool ImagesTreeCtrl::Create | ( | wxWindow * | parent, |
wxWindowID | id = wxID_ANY , |
||
const wxPoint & | pos = wxDefaultPosition , |
||
const wxSize & | size = wxDefaultSize , |
||
long | style = wxTAB_TRAVERSAL , |
||
const wxString & | name = wxT("panel") |
||
) |
creates the control
Definition at line 112 of file ImagesTree.cpp.
References wxcode::wxTreeListCtrl::AddRoot(), CreateColumns(), DEBUG_TRACE, m_configClassName, m_degDigits, m_distDigits, m_pixelDigits, and m_root.
|
private |
create image list with necessary images of checkboxes
Definition at line 961 of file ImagesTree.cpp.
References wxcode::wxTreeListCtrl::AssignImageList().
Referenced by SetOptimizerMode().
|
private |
creates all columns and stores information in m_columnMap, m_columnVector, m_editableColumns and m_variableVector
Definition at line 136 of file ImagesTree.cpp.
References ADDCOLUMN, wxcode::wxTreeListCtrl::AddColumn(), wxcode::wxTreeListCtrl::GetColumnCount(), m_configClassName, and wxcode::wxTreeListCtrl::SetColumnWidth().
Referenced by Create().
|
private |
generates submenu for given PanoOperationVector
Definition at line 1278 of file ImagesTree.cpp.
References GetSelectedImages(), m_guiLevel, m_menuOperation, and m_pano.
Referenced by OnContextMenu().
HuginBase::UIntSet ImagesTreeCtrl::GetSelectedImages | ( | ) |
returns the selected images
if a lens or stack is selected it returns all images of the selected lens/stack
Definition at line 910 of file ImagesTree.cpp.
References data, wxcode::wxTreeListCtrl::GetFirstChild(), ImagesTreeData::GetImgNr(), wxcode::wxTreeListCtrl::GetItemData(), wxcode::wxTreeListCtrl::GetNextChild(), wxcode::wxTreeListCtrl::GetSelections(), and ImagesTreeData::IsGroup().
Referenced by ImagesPanel::CPGenerate(), GenerateSubMenu(), OnActivateImage(), OnBeginDrag(), OnChar(), OnContextMenu(), ImagesPanel::OnCropFactorChanged(), OnDeactivateImage(), OnEditImageVariables(), OnExecuteOperation(), ImagesPanel::OnFocalLengthChanged(), OnLeftUp(), ImagesPanel::OnLensTypeChanged(), OptimizePhotometricPanel::OnReset(), OptimizePanel::OnReset(), ImagesPanel::OnSelectionChanged(), ImagesPanel::panoramaImagesChanged(), and UnLinkImageVariables().
void ImagesTreeCtrl::Init | ( | HuginBase::Panorama * | pano | ) |
initialization, connects all control with Panorama, register observer
Definition at line 215 of file ImagesTree.cpp.
References HuginBase::Panorama::addObserver(), DEBUG_ASSERT, m_pano, and m_variable_groups.
Referenced by OptimizePhotometricPanel::Init(), ImagesPanel::Init(), and OptimizePanel::Init().
void ImagesTreeCtrl::MarkActiveImages | ( | const bool | markActive | ) |
sets the flag, if active/disabled image should be marked with different colour
Definition at line 939 of file ImagesTree.cpp.
References m_markDisabledImages, and UpdateItemFont().
Referenced by OptimizePhotometricPanel::SetOnlyActiveImages(), and OptimizePanel::SetOnlyActiveImages().
|
protected |
event handler for activate image
Definition at line 1387 of file ImagesTree.cpp.
References PanoCommand::CommandHistory::addCommand(), HuginBase::Panorama::getActiveImages(), PanoCommand::GlobalCmdHist::getInstance(), GetSelectedImages(), and m_pano.
|
protected |
event handler when dragging begins, veto if dragging is not possible
Definition at line 1486 of file ImagesTree.cpp.
References HuginBase::Panorama::getNrOfImages(), GetSelectedImages(), GROUP_LENS, GROUP_NONE, GROUP_STACK, m_dragging, m_draggingImages, m_groupMode, and m_pano.
|
protected |
event handler for beginning editing
Definition at line 2010 of file ImagesTree.cpp.
References data, hugin_utils::doubleTowxString(), wxcode::wxTreeListCtrl::GetFirstChild(), HuginBase::Panorama::getImage(), ImagesTreeData::GetImgNr(), wxcode::wxTreeListCtrl::GetItemData(), wxcode::wxTreeListCtrl::GetItemText(), ImagesTreeData::IsGroup(), m_columnVector, m_editOldString, m_editVal, m_pano, and wxcode::wxTreeListCtrl::SetItemText().
|
protected |
event handler for key events
Definition at line 1963 of file ImagesTree.cpp.
References PanoCommand::CommandHistory::addCommand(), MainFrame::Get(), HuginBase::Panorama::getImage(), PanoCommand::GlobalCmdHist::getInstance(), GetSelectedImages(), m_pano, and wxcode::wxTreeListCtrl::SelectAll().
|
protected |
event handler, when column width was changed, save into wxConfig
Definition at line 945 of file ImagesTree.cpp.
References wxcode::wxTreeListCtrl::GetColumnWidth(), and m_configClassName.
|
protected |
event handler to display context menu
Definition at line 1110 of file ImagesTree.cpp.
References data, GenerateSubMenu(), PanoOperation::GetControlPointsOperationVector(), HuginBase::Panorama::getImage(), PanoOperation::GetImagesOperationVector(), wxcode::wxTreeListCtrl::GetItemData(), wxcode::wxTreeListCtrl::GetItemText(), PanoOperation::GetLensesOperationVector(), HuginBase::ConstStandardImageVariableGroups::getLensVariables(), PanoOperation::GetResetOperationVector(), GetSelectedImages(), PanoOperation::GetStacksOperationVector(), GROUP_LENS, GROUP_STACK, GUI_SIMPLE, ID_OPERATION_START, ImagesTreeData::IsGroup(), m_columnVector, m_editableColumns, m_groupMode, m_guiLevel, m_markDisabledImages, m_menuOperation, m_optimizerMode, m_pano, m_selectedColumn, m_variableVector, and set_contains().
|
protected |
event handler for deactivate image
Definition at line 1397 of file ImagesTree.cpp.
References PanoCommand::CommandHistory::addCommand(), HuginBase::Panorama::getActiveImages(), PanoCommand::GlobalCmdHist::getInstance(), GetSelectedImages(), and m_pano.
|
protected |
event handler for showing image variables editing dialog
Definition at line 1450 of file ImagesTree.cpp.
References DISPLAY_LENS, DISPLAY_PHOTOMETRICS, DISPLAY_PHOTOMETRICS_IMAGES, DISPLAY_PHOTOMETRICS_LENSES, GetSelectedImages(), m_columnMap, m_displayMode, m_guiLevel, m_pano, m_selectedColumn, ImageVariableDialog::SelectTab(), and ImageVariableDialog::SetGuiLevel().
|
protected |
event handler for ending editing, updates the Panorama with modified value
Definition at line 2032 of file ImagesTree.cpp.
References PanoCommand::CommandHistory::addCommand(), data, HuginBase::BaseSrcPanoImage::FISHEYE_ORTHOGRAPHIC, wxcode::wxTreeListCtrl::GetFirstChild(), HuginBase::Panorama::getImage(), ImagesTreeData::GetImgNr(), PanoCommand::GlobalCmdHist::getInstance(), wxcode::wxTreeListCtrl::GetItemData(), ImagesTreeData::IsGroup(), m_columnVector, m_editOldString, m_editVal, m_pano, wxcode::wxTreeListCtrl::Refresh(), wxcode::wxTreeListCtrl::SetItemText(), and hugin_utils::str2double().
|
protected |
menu event handler for PanoOperation (context menu items)
Definition at line 2105 of file ImagesTree.cpp.
References PanoCommand::CommandHistory::addCommand(), PanoOperation::PanoOperation::GetCommand(), PanoCommand::GlobalCmdHist::getInstance(), GetSelectedImages(), m_guiLevel, m_menuOperation, and m_pano.
|
protected |
event handler for context menu on header
Definition at line 1375 of file ImagesTree.cpp.
References m_editableColumns, m_optimizerMode, m_selectedColumn, and set_contains().
|
protected |
event handler for left double click
Definition at line 2115 of file ImagesTree.cpp.
References flags, wxcode::wxTreeListCtrl::HitTest(), m_optimizerMode, and m_selectedColumn.
|
protected |
event handler for left mouse down, handles toggle of optimizer variables
Definition at line 1768 of file ImagesTree.cpp.
References wxcode::wxTreeListCtrl::EndEdit(), flags, wxcode::wxTreeListCtrl::GetItemText(), wxcode::wxTreeListCtrl::HitTest(), m_dragging, m_editableColumns, m_leftDownColumn, m_leftDownItem, and set_contains().
Referenced by SetOptimizerMode().
|
protected |
event handler for left up, handles end of dragging and updates of optimizer variables states
Definition at line 1505 of file ImagesTree.cpp.
References PanoCommand::CommandHistory::addCommand(), data, flags, MainFrame::Get(), GLPreviewFrame::GetDragGroupImages(), wxcode::wxTreeListCtrl::GetFirstChild(), MainFrame::getGLPreview(), ImagesTreeData::GetGroupNr(), ImagesTreeData::GetImgNr(), PanoCommand::GlobalCmdHist::getInstance(), wxcode::wxTreeListCtrl::GetItemData(), wxcode::wxTreeListCtrl::GetItemImage(), wxcode::wxTreeListCtrl::GetItemParent(), HuginBase::ConstStandardImageVariableGroups::getLensVariables(), wxcode::wxTreeListCtrl::GetNextChild(), HuginBase::Panorama::getNrOfImages(), HuginBase::Panorama::getOptimizeVector(), GetSelectedImages(), HuginBase::ConstStandardImageVariableGroups::getStackVariables(), GROUP_LENS, GROUP_NONE, wxcode::wxTreeListCtrl::HitTest(), ImagesTreeData::IsGroup(), wxcode::wxTreeListCtrl::IsSelected(), m_columnVector, m_dragging, m_draggingImages, m_groupMode, m_leftDownColumn, m_leftDownItem, m_optimizerMode, m_pano, set_contains(), and GLPreviewFrame::SetDragGroupImages().
|
protected |
event handler for linking image variables
Definition at line 1440 of file ImagesTree.cpp.
References UnLinkImageVariables().
|
protected |
event handler for mouse motion, handles focussing of check boxes
Definition at line 1798 of file ImagesTree.cpp.
References flags, wxcode::wxTreeListCtrl::GetItemImage(), wxcode::wxTreeListCtrl::HitTest(), m_lastCurrentCol, m_lastCurrentItem, and wxcode::wxTreeListCtrl::SetItemImage().
Referenced by SetOptimizerMode().
|
protected |
event handler for select all optimizer variables
Definition at line 1943 of file ImagesTree.cpp.
References SelectAllParameters().
|
protected |
event handler for select all optimizer variables for selected lens/stack
Definition at line 1953 of file ImagesTree.cpp.
References SelectAllParameters().
|
protected |
event handler for unlinking image variables
Definition at line 1445 of file ImagesTree.cpp.
References UnLinkImageVariables().
|
protected |
event handler for unselect all optimizer variables
Definition at line 1948 of file ImagesTree.cpp.
References SelectAllParameters().
|
protected |
event handler for unselect all optimizer variables for selected lens/stack
Definition at line 1958 of file ImagesTree.cpp.
References SelectAllParameters().
|
virtual |
receives notification about panorama changes
Implements HuginBase::PanoramaObserver.
Definition at line 236 of file ImagesTree.cpp.
References fill_set(), HuginBase::Panorama::getNrOfImages(), GROUP_OUTPUTLAYERS, GROUP_OUTPUTSTACK, m_groupMode, m_needsUpdate, m_optimizerMode, panoramaImagesChanged(), wxcode::wxTreeListCtrl::Refresh(), and UpdateOptimizerVariables().
|
virtual |
receive the update signal and update display accordingly
Implements HuginBase::PanoramaObserver.
Definition at line 256 of file ImagesTree.cpp.
References wxcode::wxTreeListCtrl::AppendItem(), DEBUG_TRACE, wxcode::wxTreeListCtrl::Delete(), fill_set(), HuginBase::Panorama::getActiveImages(), wxcode::wxTreeListCtrl::GetChildrenCount(), HuginBase::getExposureLayers(), wxcode::wxTreeListCtrl::GetFirstChild(), HuginBase::getHDRStacks(), wxcode::wxTreeListCtrl::GetLastChild(), HuginBase::StandardImageVariableGroups::getLenses(), wxcode::wxTreeListCtrl::GetNextChild(), HuginBase::Panorama::getNrOfImages(), HuginBase::ConstImageVariableGroup::getNumberOfParts(), HuginBase::Panorama::getOptions(), HuginBase::ConstImageVariableGroup::getPartsSet(), HuginBase::StandardImageVariableGroups::getStacks(), GROUP_LENS, GROUP_NONE, GROUP_OUTPUTLAYERS, GROUP_OUTPUTSTACK, GROUP_STACK, m_groupMode, m_markDisabledImages, m_needsUpdate, m_optimizerMode, m_pano, m_root, m_variable_groups, SetGroupMode(), HuginBase::StandardImageVariableGroups::update(), UpdateGroup(), UpdateGroupText(), UpdateItemFont(), and UpdateOptimizerVariables().
Referenced by panoramaChanged(), and SetGroupMode().
|
private |
select/unselect all variables in the active column true selects all, false unselect all true works on all images, false only on images of current lens or stack
Definition at line 1831 of file ImagesTree.cpp.
References PanoCommand::CommandHistory::addCommand(), HuginBase::PanoramaOptions::colorReferenceImage, data, fill_set(), wxcode::wxTreeListCtrl::GetFirstChild(), HuginBase::Panorama::getImage(), ImagesTreeData::GetImgNr(), PanoCommand::GlobalCmdHist::getInstance(), wxcode::wxTreeListCtrl::GetItemData(), wxcode::wxTreeListCtrl::GetItemParent(), wxcode::wxTreeListCtrl::GetNextChild(), HuginBase::Panorama::getNrOfImages(), HuginBase::Panorama::getOptimizeVector(), HuginBase::Panorama::getOptions(), wxcode::wxTreeListCtrl::GetSelections(), ImagesTreeData::IsGroup(), m_columnVector, m_pano, m_selectedColumn, and HuginBase::PanoramaOptions::optimizeReferenceImage.
Referenced by OnSelectAll(), OnSelectLensStack(), OnUnselectAll(), and OnUnselectLensStack().
void ImagesTreeCtrl::SetDisplayMode | ( | DisplayMode | newMode | ) |
sets the display mode to given mode
Definition at line 1052 of file ImagesTree.cpp.
References DISPLAY_EXIF, DISPLAY_GENERAL, DISPLAY_LENS, DISPLAY_PHOTOMETRICS, DISPLAY_PHOTOMETRICS_IMAGES, DISPLAY_PHOTOMETRICS_LENSES, DISPLAY_POSITION, GUI_ADVANCED, GUI_EXPERT, m_columnMap, m_displayMode, m_guiLevel, wxcode::wxTreeListCtrl::Refresh(), and wxcode::wxTreeListCtrl::SetColumnShown().
Referenced by OptimizePhotometricPanel::Init(), OptimizePanel::Init(), ImagesPanel::OnDisplayModeChanged(), and SetGuiLevel().
void ImagesTreeCtrl::SetGroupMode | ( | GroupMode | newMode | ) |
sets the group mode to given mode
Definition at line 1026 of file ImagesTree.cpp.
References wxcode::wxTreeListCtrl::DeleteChildren(), wxcode::wxTreeListCtrl::ExpandAll(), fill_set(), HuginBase::Panorama::getNrOfImages(), GROUP_NONE, m_groupMode, m_needsUpdate, m_pano, m_root, and panoramaImagesChanged().
Referenced by OptimizePhotometricPanel::Init(), OptimizePanel::Init(), ImagesPanel::OnGroupModeChanged(), and panoramaImagesChanged().
void ImagesTreeCtrl::SetGuiLevel | ( | GuiLevel | newSetting | ) |
sets the GuiLevel of the control
Definition at line 954 of file ImagesTree.cpp.
References m_displayMode, m_guiLevel, and SetDisplayMode().
Referenced by OptimizePhotometricPanel::SetGuiLevel(), OptimizePanel::SetGuiLevel(), and ImagesPanel::SetGuiLevel().
void ImagesTreeCtrl::SetOptimizerMode | ( | ) |
sets to control into optimizer mode
this marks the variables, which should be optimized, bold and underlined, also activates the context menu for optimizer
Definition at line 996 of file ImagesTree.cpp.
References CreateCheckboxImages(), m_columnVector, m_editableColumns, m_optimizerMode, OnLeftDown(), OnMouseMove(), and wxcode::wxTreeListCtrl::SetColumnEditable().
Referenced by OptimizePhotometricPanel::Init(), and OptimizePanel::Init().
|
private |
helper procedure for link/unlink image variables
Definition at line 1408 of file ImagesTree.cpp.
References PanoCommand::CommandHistory::addCommand(), PanoCommand::GlobalCmdHist::getInstance(), HuginBase::ConstStandardImageVariableGroups::getLensVariables(), GetSelectedImages(), HuginBase::ConstStandardImageVariableGroups::getStackVariables(), GROUP_LENS, m_groupMode, m_pano, m_selectedColumn, and m_variableVector.
Referenced by OnLinkImageVariables(), and OnUnlinkImageVariables().
|
protected |
updates the given group, updates number of images and the images itself
Definition at line 789 of file ImagesTree.cpp.
References wxcode::wxTreeListCtrl::AppendItem(), data, wxcode::wxTreeListCtrl::Delete(), wxcode::wxTreeListCtrl::GetChildrenCount(), wxcode::wxTreeListCtrl::GetFirstChild(), ImagesTreeData::GetImgNr(), wxcode::wxTreeListCtrl::GetItemData(), wxcode::wxTreeListCtrl::GetLastChild(), wxcode::wxTreeListCtrl::GetNextChild(), set_contains(), ImagesTreeData::SetImgNr(), and UpdateImageText().
Referenced by panoramaImagesChanged().
|
protected |
updates the information fot the given lens/stack in the tree
Definition at line 594 of file ImagesTree.cpp.
References data, hugin_utils::doubleTowxString(), wxcode::wxTreeListCtrl::GetChildrenCount(), wxcode::wxTreeListCtrl::GetFirstChild(), ImagesTreeData::GetGroupNr(), HuginBase::Panorama::getImage(), ImagesTreeData::GetImgNr(), wxcode::wxTreeListCtrl::GetItemData(), getProjectionString(), getResponseString(), GROUP_LENS, GROUP_NONE, GROUP_OUTPUTLAYERS, GROUP_OUTPUTSTACK, GROUP_STACK, m_columnMap, m_degDigits, m_distDigits, m_groupMode, m_pano, m_pixelDigits, HuginBase::BaseSrcPanoImage::RESPONSE_EMOR, wxcode::wxTreeListCtrl::SetItemBold(), wxcode::wxTreeListCtrl::SetItemText(), hugin_utils::TDiff2D< T >::x, and hugin_utils::TDiff2D< T >::y.
Referenced by panoramaImagesChanged().
|
protected |
updates the information for the given image in tree
Definition at line 370 of file ImagesTree.cpp.
References HuginBase::PanoramaOptions::colorReferenceImage, hugin_utils::doubleTowxString(), flags, FormatString::GetAperture(), wxcode::wxTreeListCtrl::GetChildrenCount(), HuginBase::Panorama::getCtrlPointsForImage(), FormatString::GetExifDateTime(), FormatString::GetExposureTime(), FormatString::GetFocalLength(), HuginBase::Panorama::getImage(), ImagesTreeData::GetImgNr(), FormatString::GetIso(), wxcode::wxTreeListCtrl::GetItemData(), wxcode::wxTreeListCtrl::GetItemParent(), HuginBase::StandardImageVariableGroups::getLenses(), HuginBase::Panorama::getOptions(), HuginBase::ConstImageVariableGroup::getPartNumber(), getProjectionString(), getResponseString(), HuginBase::StandardImageVariableGroups::getStacks(), GROUP_LENS, GROUP_NONE, GROUP_STACK, HUGIN_CONV_FILENAME, m_columnMap, m_degDigits, m_distDigits, m_groupMode, m_pano, m_pixelDigits, m_variable_groups, HuginBase::PanoramaOptions::optimizeReferenceImage, HuginBase::BaseSrcPanoImage::RESPONSE_EMOR, wxcode::wxTreeListCtrl::SetItemText(), hugin_utils::TDiff2D< T >::x, and hugin_utils::TDiff2D< T >::y.
Referenced by UpdateGroup().
|
private |
update the font colour for all items
Definition at line 1292 of file ImagesTree.cpp.
References wxcode::wxTreeListCtrl::GetFirstChild(), HuginBase::Panorama::getImage(), ImagesTreeData::GetImgNr(), wxcode::wxTreeListCtrl::GetItemData(), wxcode::wxTreeListCtrl::GetNextChild(), ImagesTreeData::IsGroup(), m_markDisabledImages, m_pano, m_root, and wxcode::wxTreeListCtrl::SetItemTextColour().
Referenced by MarkActiveImages(), and panoramaImagesChanged().
|
private |
updates the display of the optimizer variables (set font)
Definition at line 847 of file ImagesTree.cpp.
References data, wxcode::wxTreeListCtrl::GetColumnCount(), wxcode::wxTreeListCtrl::GetFirstChild(), ImagesTreeData::GetImgNr(), wxcode::wxTreeListCtrl::GetItemData(), wxcode::wxTreeListCtrl::GetItemText(), wxcode::wxTreeListCtrl::GetNext(), wxcode::wxTreeListCtrl::GetNextChild(), HuginBase::Panorama::getOptimizeVector(), ImagesTreeData::IsGroup(), m_columnVector, m_editableColumns, m_pano, m_root, set_contains(), and wxcode::wxTreeListCtrl::SetItemImage().
Referenced by panoramaChanged(), and panoramaImagesChanged().
|
private |
map for easier access to column information
Definition at line 190 of file ImagesTree.h.
Referenced by OnEditImageVariables(), SetDisplayMode(), UpdateGroupText(), and UpdateImageText().
|
private |
vector for easier access to column information
Definition at line 192 of file ImagesTree.h.
Referenced by OnBeginEdit(), OnContextMenu(), OnEndEdit(), OnLeftUp(), SelectAllParameters(), SetOptimizerMode(), and UpdateOptimizerVariables().
|
private |
Definition at line 223 of file ImagesTree.h.
Referenced by Create(), CreateColumns(), and OnColumnWidthChange().
|
private |
Definition at line 178 of file ImagesTree.h.
Referenced by Create(), UpdateGroupText(), and UpdateImageText().
|
private |
the active display mode
Definition at line 188 of file ImagesTree.h.
Referenced by ImagesTreeCtrl(), OnEditImageVariables(), SetDisplayMode(), and SetGuiLevel().
|
private |
Definition at line 179 of file ImagesTree.h.
Referenced by Create(), UpdateGroupText(), and UpdateImageText().
|
private |
true, if dragging
Definition at line 204 of file ImagesTree.h.
Referenced by ImagesTreeCtrl(), OnBeginDrag(), OnLeftDown(), and OnLeftUp().
|
private |
UIntSet of dragging images.
Definition at line 202 of file ImagesTree.h.
Referenced by OnBeginDrag(), and OnLeftUp().
|
private |
set, which contains editable columns (all column which contains numeric image variables
Definition at line 194 of file ImagesTree.h.
Referenced by OnContextMenu(), OnHeaderContextMenu(), OnLeftDown(), SetOptimizerMode(), and UpdateOptimizerVariables().
|
private |
wxString, as shown before editing started
Definition at line 208 of file ImagesTree.h.
Referenced by OnBeginEdit(), and OnEndEdit().
|
private |
value, which is currently edited
Definition at line 206 of file ImagesTree.h.
Referenced by OnBeginEdit(), and OnEndEdit().
|
private |
the active group mode
Definition at line 172 of file ImagesTree.h.
Referenced by ImagesTreeCtrl(), OnBeginDrag(), OnContextMenu(), OnLeftUp(), panoramaChanged(), panoramaImagesChanged(), SetGroupMode(), UnLinkImageVariables(), UpdateGroupText(), and UpdateImageText().
|
private |
stores the active GuiLevel
Definition at line 182 of file ImagesTree.h.
Referenced by GenerateSubMenu(), ImagesTreeCtrl(), OnContextMenu(), OnEditImageVariables(), OnExecuteOperation(), SetDisplayMode(), and SetGuiLevel().
|
private |
Definition at line 217 of file ImagesTree.h.
Referenced by OnMouseMove().
|
private |
stores last item on which the mouse was hovering
Definition at line 216 of file ImagesTree.h.
Referenced by OnMouseMove().
|
private |
Definition at line 220 of file ImagesTree.h.
Referenced by OnLeftDown(), and OnLeftUp().
|
private |
stores where left mouse click happend
Definition at line 219 of file ImagesTree.h.
Referenced by OnLeftDown(), and OnLeftUp().
|
private |
true, if disabled images should be marked with other font color
Definition at line 186 of file ImagesTree.h.
Referenced by ImagesTreeCtrl(), MarkActiveImages(), OnContextMenu(), panoramaImagesChanged(), and UpdateItemFont().
|
private |
map with current active context menu PanoOperation
Definition at line 198 of file ImagesTree.h.
Referenced by GenerateSubMenu(), OnContextMenu(), and OnExecuteOperation().
|
private |
helper variable for update of output stacks/layers
Definition at line 210 of file ImagesTree.h.
Referenced by ImagesTreeCtrl(), panoramaChanged(), panoramaImagesChanged(), and SetGroupMode().
|
private |
true, if in optimizer mode
Definition at line 184 of file ImagesTree.h.
Referenced by ImagesTreeCtrl(), OnContextMenu(), OnHeaderContextMenu(), OnLeftDblClick(), OnLeftUp(), panoramaChanged(), panoramaImagesChanged(), and SetOptimizerMode().
|
private |
Definition at line 170 of file ImagesTree.h.
Referenced by GenerateSubMenu(), ImagesTreeCtrl(), Init(), OnActivateImage(), OnBeginDrag(), OnBeginEdit(), OnChar(), OnContextMenu(), OnDeactivateImage(), OnEditImageVariables(), OnEndEdit(), OnExecuteOperation(), OnLeftUp(), panoramaImagesChanged(), SelectAllParameters(), SetGroupMode(), UnLinkImageVariables(), UpdateGroupText(), UpdateImageText(), UpdateItemFont(), UpdateOptimizerVariables(), and ~ImagesTreeCtrl().
|
private |
Definition at line 180 of file ImagesTree.h.
Referenced by Create(), UpdateGroupText(), and UpdateImageText().
|
private |
pointer to root item, not shown
Definition at line 213 of file ImagesTree.h.
Referenced by Create(), panoramaImagesChanged(), SetGroupMode(), UpdateItemFont(), and UpdateOptimizerVariables().
|
private |
selected column
Definition at line 200 of file ImagesTree.h.
Referenced by OnContextMenu(), OnEditImageVariables(), OnHeaderContextMenu(), OnLeftDblClick(), SelectAllParameters(), and UnLinkImageVariables().
|
private |
Definition at line 175 of file ImagesTree.h.
Referenced by Init(), panoramaImagesChanged(), UpdateImageText(), and ~ImagesTreeCtrl().
|
private |
vector for easier access to linking information
Definition at line 196 of file ImagesTree.h.
Referenced by OnContextMenu(), and UnLinkImageVariables().