这篇教程C++ wxDELETE函数代码示例写得很实用,希望能帮到您。
本文整理汇总了C++中wxDELETE函数的典型用法代码示例。如果您正苦于以下问题:C++ wxDELETE函数的具体用法?C++ wxDELETE怎么用?C++ wxDELETE使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。 在下文中一共展示了wxDELETE函数的28个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的C++代码示例。 示例1: wxDELETEvoid wxArchiveFSCacheDataImpl::CloseStreams(){ wxDELETE(m_archive); wxDELETE(m_stream);}
开发者ID:CyberIntelMafia,项目名称:clamav-devel,代码行数:5,
示例2: wxDELETEFbImportBook::~FbImportBook(){ wxDELETE(m_parser);}
开发者ID:EvgeniiFrolov,项目名称:myrulib,代码行数:4,
示例3: wxDynamicCastbool wxStandardDialogLayoutAdapter::DoLayoutAdaptation(wxDialog* dialog){ if (dialog->GetSizer()) {#if wxUSE_BOOKCTRL wxBookCtrlBase* bookContentWindow = wxDynamicCast(dialog->GetContentWindow(), wxBookCtrlBase); if (bookContentWindow) { // If we have a book control, make all the pages (that use sizers) scrollable wxWindowList windows; for (size_t i = 0; i < bookContentWindow->GetPageCount(); i++) { wxWindow* page = bookContentWindow->GetPage(i); wxScrolledWindow* scrolledWindow = wxDynamicCast(page, wxScrolledWindow); if (scrolledWindow) windows.Append(scrolledWindow); else if (!scrolledWindow && page->GetSizer()) { // Create a scrolled window and reparent scrolledWindow = CreateScrolledWindow(page); wxSizer* oldSizer = page->GetSizer(); wxSizer* newSizer = new wxBoxSizer(wxVERTICAL); newSizer->Add(scrolledWindow,1, wxEXPAND, 0); page->SetSizer(newSizer, false /* don't delete the old sizer */); scrolledWindow->SetSizer(oldSizer); ReparentControls(page, scrolledWindow); windows.Append(scrolledWindow); } } FitWithScrolling(dialog, windows); } else#endif // wxUSE_BOOKCTRL {#if wxUSE_BUTTON // If we have an arbitrary dialog, create a scrolling area for the main content, and a button sizer // for the main buttons. wxScrolledWindow* scrolledWindow = CreateScrolledWindow(dialog); int buttonSizerBorder = 0; // First try to find a wxStdDialogButtonSizer wxSizer* buttonSizer = FindButtonSizer(true /* find std button sizer */, dialog, dialog->GetSizer(), buttonSizerBorder); // Next try to find a wxBoxSizer containing the controls if (!buttonSizer && dialog->GetLayoutAdaptationLevel() > wxDIALOG_ADAPTATION_STANDARD_SIZER) buttonSizer = FindButtonSizer(false /* find ordinary sizer */, dialog, dialog->GetSizer(), buttonSizerBorder); // If we still don't have a button sizer, collect any 'loose' buttons in the layout if (!buttonSizer && dialog->GetLayoutAdaptationLevel() > wxDIALOG_ADAPTATION_ANY_SIZER) { int count = 0; wxStdDialogButtonSizer* stdButtonSizer = new wxStdDialogButtonSizer; buttonSizer = stdButtonSizer; FindLooseButtons(dialog, stdButtonSizer, dialog->GetSizer(), count); if (count > 0) stdButtonSizer->Realize(); else { wxDELETE(buttonSizer); } } if (buttonSizerBorder == 0) buttonSizerBorder = 5; ReparentControls(dialog, scrolledWindow, buttonSizer); wxBoxSizer* newTopSizer = new wxBoxSizer(wxVERTICAL); wxSizer* oldSizer = dialog->GetSizer(); dialog->SetSizer(newTopSizer, false /* don't delete old sizer */); newTopSizer->Add(scrolledWindow, 1, wxEXPAND|wxALL, 0); if (buttonSizer) newTopSizer->Add(buttonSizer, 0, wxEXPAND|wxALL, buttonSizerBorder); scrolledWindow->SetSizer(oldSizer); FitWithScrolling(dialog, scrolledWindow);#endif // wxUSE_BUTTON } } dialog->SetLayoutAdaptationDone(true); return true;}
开发者ID:beanhome,项目名称:dev,代码行数:96,
示例4: wxDELETEvoid wxPlatform::ClearPlatforms(){ wxDELETE(sm_customPlatforms);}
开发者ID:vdm113,项目名称:wxWidgets-ICC-patch,代码行数:4,
示例5: wxDELETEAdvancedDlg::~AdvancedDlg(){ wxDELETE(m_rightclickMenu); }
开发者ID:GaganJotSingh,项目名称:codelite,代码行数:5,
示例6: wxDynamicCastvoid FbAuthListModel::Append(FbModelData * data){ FbAuthListData * item = wxDynamicCast(data, FbAuthListData); if (item && m_position > 0) m_items.Insert(item->GetCode(), m_position - 1); wxDELETE(data);}
开发者ID:EvgeniiFrolov,项目名称:myrulib,代码行数:6,
示例7: wxDELETEwxTopLevelWindowMSW::ButtonMenu::~ButtonMenu(){ wxDELETE(m_menu);}
开发者ID:Jasonudoo,项目名称:wxWidgets,代码行数:4,
示例8: wxDELETEvoid SpinCtrlTestCase::tearDown(){ wxDELETE(m_spin);}
开发者ID:mael15,项目名称:wxWidgets,代码行数:4,
示例9: wxDELETECompDateAxis::~CompDateAxis(){ wxDELETE(m_spanDraw);}
开发者ID:lukecian,项目名称:wxfreechart,代码行数:4,
示例10: wxDELETEvoid wxSound::Free(){ wxDELETE(m_data);}
开发者ID:madnessw,项目名称:thesnow,代码行数:4,
示例11: wxDELETEvoid wxAppConsoleBase::CleanUp(){ wxDELETE(m_mainLoop);}
开发者ID:czxxjtu,项目名称:wxPython-1,代码行数:4,
示例12: wxDELETEvoid ListBoxTestCase::tearDown(){ wxDELETE(m_list);}
开发者ID:enachb,项目名称:freetel-code,代码行数:4,
示例13: wxDELETEvoid RearrangeListTestCase::tearDown(){ wxDELETE(m_rearrange);}
开发者ID:beanhome,项目名称:dev,代码行数:4,
示例14: wxCreateSoundBackendSDL/*static*/ void wxSound::EnsureBackend(){ if (!ms_backend) { // FIXME -- make this fully dynamic when plugins architecture is in // place#if wxUSE_LIBSDL //if (!ms_backend) {#if !wxUSE_PLUGINS ms_backend = wxCreateSoundBackendSDL();#else wxString dllname; dllname.Printf(wxT("%s/%s"), wxDynamicLibrary::GetPluginsDirectory().c_str(), wxDynamicLibrary::CanonicalizePluginName( wxT("sound_sdl"), wxDL_PLUGIN_BASE).c_str()); wxLogTrace(wxT("sound"), wxT("trying to load SDL plugin from '%s'..."), dllname.c_str()); wxLogNull null; ms_backendSDL = new wxDynamicLibrary(dllname, wxDL_NOW); if (!ms_backendSDL->IsLoaded()) { wxDELETE(ms_backendSDL); } else { typedef wxSoundBackend *(*wxCreateSoundBackend_t)(); wxDYNLIB_FUNCTION(wxCreateSoundBackend_t, wxCreateSoundBackendSDL, *ms_backendSDL); if (pfnwxCreateSoundBackendSDL) { ms_backend = (*pfnwxCreateSoundBackendSDL)(); } }#endif if (ms_backend && !ms_backend->IsAvailable()) { wxDELETE(ms_backend); } }#endif#ifdef HAVE_SYS_SOUNDCARD_H if (!ms_backend) { ms_backend = new wxSoundBackendOSS(); if (!ms_backend->IsAvailable()) { wxDELETE(ms_backend); } }#endif if (!ms_backend) ms_backend = new wxSoundBackendNull(); if (!ms_backend->HasNativeAsyncPlayback()) ms_backend = new wxSoundSyncOnlyAdaptor(ms_backend); wxLogTrace(wxT("sound"), wxT("using backend '%s'"), ms_backend->GetName().c_str()); }}
开发者ID:CyberIntelMafia,项目名称:clamav-devel,代码行数:65,
示例15: OnExit virtual void OnExit() { wxDELETE(ms_buffer); }
开发者ID:chromylei,项目名称:third_party,代码行数:1,
示例16: PostEvent//.........这里部分代码省略......... unsigned errorCount = clang_codeCompleteGetNumDiagnostics(reply->results); // Collect all errors / fatal errors and report them back to user for(unsigned i = 0; i < errorCount; i++) { CXDiagnostic diag = clang_codeCompleteGetDiagnostic(reply->results, i); CXDiagnosticSeverity severity = clang_getDiagnosticSeverity(diag); if(!hasErrors) { hasErrors = (severity == CXDiagnostic_Error || severity == CXDiagnostic_Fatal); } if(severity == CXDiagnostic_Error || severity == CXDiagnostic_Fatal || severity == CXDiagnostic_Note) { CXString diagStr = clang_getDiagnosticSpelling(diag); wxString wxDiagString = wxString(clang_getCString(diagStr), wxConvUTF8); // Collect up to 10 error messages // and dont collect the same error twice if(errorMessages.find(wxDiagString) == errorMessages.end() && errorMessages.size() <= maxErrorToDisplay) { errorMessages.insert(wxDiagString); displayTip << wxDiagString.c_str() << wxT("/n"); } clang_disposeString(diagStr); } clang_disposeDiagnostic(diag); } CL_DEBUG(wxT("Found %u matches"), reply->results->NumResults); ClangUtils::printCompletionDiagnostics(reply->results); } if(!displayTip.IsEmpty() && hasErrors) { // Send back the error messages reply->errorMessage << "clang: " << displayTip; reply->errorMessage.RemoveLast(); // Free the results clang_disposeCodeCompleteResults(reply->results); reply->results = NULL; } // Send the event eEnd.SetClientData(reply); EventNotifier::Get()->AddPendingEvent(eEnd); } else if(task->GetContext() == CTX_GotoDecl || task->GetContext() == CTX_GotoImpl) { // Check to see if the file was modified since it was last reparsed // If it does, we need to re-parse it again wxFileName fnSource(cacheEntry.sourceFile); time_t fileModificationTime = fnSource.GetModificationTime().GetTicks(); time_t lastReparseTime = cacheEntry.lastReparse; if(fileModificationTime > lastReparseTime) { // The file needs to be re-parsed DoSetStatusMsg(wxString::Format(wxT("clang: re-parsing file %s.../n"), cacheEntry.sourceFile)); // Try reparsing the TU ClangThreadRequest::List_t usList = task->GetModifiedBuffers(); usList.push_back(std::make_pair(task->GetFileName(), task->GetDirtyBuffer())); ClangUnsavedFiles usf(usList); if(clang_reparseTranslationUnit(TU, usf.GetCount(), usf.GetUnsavedFiles(), clang_defaultReparseOptions(TU)) != 0) { // Failed to reparse cr.SetCancelled(true); // cancel the re-caching of the TU DoSetStatusMsg( wxString::Format("clang: clang_reparseTranslationUnit '%s' failed/n", cacheEntry.sourceFile)); clang_disposeTranslationUnit(TU); wxDELETE(reply); PostEvent(wxEVT_CLANG_TU_CREATE_ERROR, task->GetFileName()); return; } DoSetStatusMsg( wxString::Format("clang: clang_reparseTranslationUnit '%s' - done/n", cacheEntry.sourceFile)); // Update the 'lastReparse' field cacheEntry.lastReparse = time(NULL); } bool success = DoGotoDefinition(TU, task, reply); if(success) { eEnd.SetClientData(reply); EventNotifier::Get()->AddPendingEvent(eEnd); } else { DoSetStatusMsg(wxT("clang: no matches were found")); CL_DEBUG(wxT("Clang Goto Decl/Impl: could not find a cursor matching for position %s:%d:%d"), task->GetFileName().c_str(), (int)task->GetLine(), (int)task->GetColumn()); // Failed, delete the 'reply' allocatd earlier wxDELETE(reply); PostEvent(wxEVT_CLANG_TU_CREATE_ERROR, task->GetFileName()); } } else { wxDELETE(reply); PostEvent(wxEVT_CLANG_PCH_CACHE_ENDED, task->GetFileName()); }}
开发者ID:jiapei100,项目名称:codelite,代码行数:101,
示例17: wxDELETE/* static */void wxFontsManagerBase::CleanUp(){ wxDELETE(ms_instance);}
开发者ID:DumaGit,项目名称:winsparkle,代码行数:5,
示例18: wxDELETEclCommandProcessor::~clCommandProcessor() { wxDELETE(m_process); }
开发者ID:05storm26,项目名称:codelite,代码行数:1,
示例19: wxDELETEint HunspellInterface::UninitializeSpellCheckEngine(){ wxDELETE(m_pHunspell); m_bEngineInitialized = false; return true;}
开发者ID:stahta01,项目名称:EmBlocks,代码行数:6,
示例20: wxDELETEvoid ListbookTestCase::tearDown(){ wxDELETE(m_listbook);}
开发者ID:CustomCardsOnline,项目名称:wxWidgets,代码行数:4,
示例21: wxDELETEvoid Localization::Destroy() { wxDELETE(Localization::instance_);}
开发者ID:DocWhoChat,项目名称:appetizer,代码行数:3,
示例22: DoStopvoid wxSoundData::Stop(){ DoStop(); wxDELETE(m_pTimer);}
开发者ID:beanhome,项目名称:dev,代码行数:5,
示例23: wxDELETEvoid CodeCompletionManager::Release(){ wxDELETE(ms_CodeCompletionManager);}
开发者ID:05storm26,项目名称:codelite,代码行数:4,
示例24: wxDELETEvoid HtmlWindowTestCase::tearDown(){ wxDELETE(m_win);}
开发者ID:3v1n0,项目名称:wxWidgets,代码行数:4,
示例25: InvalidateItem // invalidate a single item, used by Clear() and InvalidateRange() void InvalidateItem(size_t n) { m_items[n] = (size_t)-1; wxDELETE(m_cells[n]); }
开发者ID:Zombiebest,项目名称:Dolphin,代码行数:6,
示例26: wxDELETEwxToolBar::~wxToolBar(){ wxDELETE(m_pToolTip);} // end of wxToolBar::~wxToolBar
开发者ID:CyberIntelMafia,项目名称:clamav-devel,代码行数:4,
示例27: wxDELETELuaHostTable::~LuaHostTable() { for (LuaHostTable::iterator i = this->begin(); i != this->end(); ++i) { LuaHostTableItem* item = i->second; wxDELETE(item); }}
开发者ID:DocWhoChat,项目名称:appetizer,代码行数:6,
示例28: wxDELETESlideShow::~SlideShow(){ for (int i=0; i<m_size; i++) wxDELETE(m_images[i]); wxDELETE(m_next);}
开发者ID:andrejv,项目名称:wxmaxima,代码行数:6,
注:本文中的wxDELETE函数示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。 C++ wxDataViewEventHandler函数代码示例 C++ wxCursor函数代码示例 |