本文整理汇总了C++中wxTreeEvent::Skip方法的典型用法代码示例。如果您正苦于以下问题:C++ wxTreeEvent::Skip方法的具体用法?C++ wxTreeEvent::Skip怎么用?C++ wxTreeEvent::Skip使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类wxTreeEvent
的用法示例。
在下文中一共展示了wxTreeEvent::Skip方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: OnTreeItemSelectionChanged
void ProjectExplorerWindow::OnTreeItemSelectionChanged(wxTreeEvent& event)
{
// HATE: So when windows deletes a treeview item it sends a ItemSelectionChange
// event which in this code will cause the SelectItem function to be called
// this will cause the DeleteAllItems function to bail but will not unfreeze
// the tree when we rebuild the list which will then cause it to crash when
// when we try to change focus to the list. So we just ignore these events if
// the tree is frozen. This would not happen if Microsoft did not LIE in its
// documentation.
if (m_tree->IsFrozen()) {
event.Skip();
return;
}
Project::File* file = NULL;
wxTreeItemId item = event.GetItem();
if (item.IsOk())
{
m_tree->SelectItem(item);
ItemData* itemData = GetDataForItem(item);
if (itemData != NULL && itemData->file != NULL && itemData->isFile)
{
file = (Project::File *)itemData->file;
}
}
else
{
int a = 0;
}
m_infoBox->SetFile(file);
}
示例2: OnTreeSelectionChange
void wxTreebook::OnTreeSelectionChange(wxTreeEvent& event)
{
if ( event.GetEventObject() != m_bookctrl )
{
event.Skip();
return;
}
wxTreeItemId newId = event.GetItem();
if ( (m_selection == wxNOT_FOUND &&
(!newId.IsOk() || newId == GetTreeCtrl()->GetRootItem())) ||
(m_selection != wxNOT_FOUND && newId == m_treeIds[m_selection]) )
{
// this event can only come when we modify the tree selection ourselves
// so we should simply ignore it
return;
}
int newPos = DoInternalFindPageById(newId);
if ( newPos != wxNOT_FOUND )
SetSelection( newPos );
}
示例3: OnTree
void wxExGenericDirCtrl::OnTree(wxTreeEvent& event)
{
wxArrayString files;
GetPaths(files);
if (files.empty())
{
event.Skip();
return;
}
if (event.GetEventType() == wxEVT_COMMAND_TREE_ITEM_MENU)
{
const wxExFileName filename(files[0]);
wxExMenu menu; // uses AppendVCS
if (filename.FileExists())
{
menu.Append(ID_TREE_OPEN, _("&Open"));
menu.AppendSeparator();
}
menu.Append(ID_TREE_COPY,
wxGetStockLabel(wxID_COPY), wxEmptyString, wxART_COPY);
if (wxExVCS::DirExists(filename))
{
menu.AppendSeparator();
menu.AppendVCS(filename);
}
if (filename.GetLexer().GetScintillaLexer() == "makefile")
{
menu.AppendSeparator();
menu.Append(ID_TREE_RUN_MAKE, "&Make");
}
menu.AppendSeparator();
menu.Append(ID_TOOL_REPORT_FIND,
wxExEllipsed(m_Frame->GetFindInCaption(ID_TOOL_REPORT_FIND)));
menu.Append(ID_TOOL_REPORT_REPLACE,
wxExEllipsed(m_Frame->GetFindInCaption(ID_TOOL_REPORT_REPLACE)));
PopupMenu(&menu);
}
else if (event.GetEventType() == wxEVT_COMMAND_TREE_ITEM_ACTIVATED)
{
const wxFileName fn(files[0]);
if (!fn.FileExists() && fn.DirExists())
{
if (!GetTreeCtrl()->IsExpanded(event.GetItem()))
{
ExpandAndSelectPath(files[0]);
}
else
{
CollapsePath(files[0]);
}
}
else
{
wxExOpenFiles(m_Frame, files, 0, wxDIR_FILES); // only files in this dir
}
}
else if (event.GetEventType() == wxEVT_COMMAND_TREE_SEL_CHANGED)
{
wxExLogStatus(wxFileName(files[0]), STAT_FULLPATH);
}
else
{
wxFAIL;
}
}
示例4: onTreeItemGetTooltip
void BookmarkView::onTreeItemGetTooltip( wxTreeEvent& event ) {
event.Skip();
}
示例5: OnTreeKeyDown
void BulletTree::OnTreeKeyDown(wxTreeEvent& event)
{
event.Skip();
}
示例6: OnItemActivated
void coreWorkflowManagerWidgetUI::OnItemActivated(wxTreeEvent &event)
{
event.Skip();
wxLogDebug(wxT("Event handler (coreWorkflowManagerWidgetUI::OnItemActivated) not implemented yet")); //notify the user that he hasn't implemented the event handler yet
}
示例7: OnItemExpanded
void DisplayVariableDlg::OnItemExpanded(wxTreeEvent& event)
{
event.Skip();
}
示例8: OnDeleteItem
void SDRDevicesDialog::OnDeleteItem( wxTreeEvent& event ) {
event.Skip();
}
示例9: OnSelectionChanged
void SDRDevicesDialog::OnSelectionChanged( wxTreeEvent& event ) {
SDRDeviceInfo *selDev = getSelectedDevice(devTree->GetSelection());
if (selDev && selDev->isAvailable()) {
dev = selDev;
selId = devTree->GetSelection();
DeviceConfig *devConfig = wxGetApp().getConfig()->getDevice(dev->getName());
m_propertyGrid->Clear();
SoapySDR::ArgInfoList args = dev->getSettingsArgInfo();
SoapySDR::ArgInfoList::const_iterator args_i;
m_propertyGrid->Append(new wxPropertyCategory("General Settings"));
devSettings.erase(devSettings.begin(),devSettings.end());
devSettings["name"] = m_propertyGrid->Append( new wxStringProperty("Name", wxPG_LABEL, devConfig->getDeviceName()) );
devSettings["offset"] = m_propertyGrid->Append( new wxIntProperty("Offset (Hz)", wxPG_LABEL, devConfig->getOffset()) );
props.erase(props.begin(), props.end());
if (args.size()) {
m_propertyGrid->Append(new wxPropertyCategory("Run-time Settings"));
for (args_i = args.begin(); args_i != args.end(); args_i++) {
SoapySDR::ArgInfo arg = (*args_i);
props.push_back(addArgInfoProperty(m_propertyGrid, arg));
}
}
if (dev->getRxChannel()) {
args = dev->getRxChannel()->getStreamArgsInfo();
DeviceConfig *devConfig = wxGetApp().getConfig()->getDevice(dev->getDeviceId());
ConfigSettings devStreamOpts = devConfig->getStreamOpts();
if (devStreamOpts.size()) {
for (int j = 0, jMax = args.size(); j < jMax; j++) {
if (devStreamOpts.find(args[j].key) != devStreamOpts.end()) {
args[j].value = devStreamOpts[args[j].key];
}
}
}
if (args.size()) {
m_propertyGrid->Append(new wxPropertyCategory("Stream Settings"));
for (args_i = args.begin(); args_i != args.end(); args_i++) {
SoapySDR::ArgInfo arg = (*args_i);
props.push_back(addArgInfoProperty(m_propertyGrid, arg));
}
}
}
if (selDev->isManual()) {
m_addRemoteButton->SetLabel("Remove");
removeId = selId;
} else {
m_addRemoteButton->SetLabel("Add");
removeId = nullptr;
}
} else if (selDev && !selDev->isAvailable() && selDev->isManual()) {
m_propertyGrid->Clear();
devSettings.erase(devSettings.begin(),devSettings.end());
props.erase(props.begin(), props.end());
removeId = devTree->GetSelection();
dev = nullptr;
selId = nullptr;
editId = nullptr;
m_addRemoteButton->SetLabel("Remove");
} else if (!selDev) {
m_addRemoteButton->SetLabel("Add");
removeId = nullptr;
}
event.Skip();
}
示例10: OnLinksExpanding
void HTMLButcherFileLinkDialog::OnLinksExpanding(wxTreeEvent &event)
{
//wxTreeCtrl *linksctrl=(wxTreeCtrl*)FindWindow(ID_LINKS);
ExpandItem(event.GetItem());
event.Skip();
}
示例11: On_Item_RClick
//---------------------------------------------------------
void CData_Source_PgSQL::On_Item_RClick(wxTreeEvent &event)
{
SelectItem(event.GetItem());
event.Skip();
}
示例12: OnKeyDown
void WatchWindow::OnKeyDown(wxTreeEvent& event)
{
if (event.GetKeyCode() == WXK_DELETE ||
event.GetKeyCode() == WXK_BACK)
{
wxTreeItemId item = GetSelection();
if (item.IsOk() && GetItemParent(item) == m_root)
{
wxTreeItemId next = GetNextSibling(item);
Delete(item);
CreateEmptySlotIfNeeded();
// Select the next item.
if (!next.IsOk())
{
wxTreeItemIdValue cookie;
next = GetLastChild(GetRootItem(), cookie);
}
SelectItem(next);
}
}
else
{
// If we're not currently editing a field, begin editing. This
// eliminates the need to double click to begin editing.
int code = event.GetKeyCode();
if (!m_editing && code < 256 && (isgraph(code) || IsSpace(code)))
{
// Get the currently selected item in the list.
wxTreeItemId item = GetSelection();
if (item.IsOk())
{
if (IsSpace(code))
{
EditLabel(item, "");
}
else
{
EditLabel(item, wxString(static_cast<char>(code)));
}
event.Skip(false);
}
}
else
{
event.Skip(true);
}
}
}
示例13: OnItemSelected
void WatchWindow::OnItemSelected(wxTreeEvent& event)
{
// Initiate the label editing.
EditLabel(event.GetItem());
event.Skip();
}
示例14: OnDatasetSelChanged
//----------------------------------------
void CDatasetTreeCtrl::OnDatasetSelChanged( wxTreeEvent &event )
{
event.Skip();
}
示例15: OnEndDrag
//----------------------------------------
void CFieldsTreeCtrl::OnEndDrag( wxTreeEvent &event )
{
event.Skip();
}