Code::Blocks Forums
Developer forums (C::B DEVELOPMENT STRICTLY!) => Development => CodeCompletion redesign => Topic started by: Loaden on August 20, 2010, 05:49:18 pm
-
void NativeParser::CreateClassBrowser()
{
ConfigManager* cfg = Manager::Get()->GetConfigManager(_T("code_completion"));
if (!m_pClassBrowser && cfg->ReadBool(_T("/use_symbols_browser"), true))
{
bool isFloating = cfg->ReadBool(_T("/as_floating_window"), false);
if (!isFloating)
{
// make this a tab in projectmanager notebook
m_pClassBrowser = new ClassBrowser(Manager::Get()->GetProjectManager()->GetNotebook(), this);
Manager::Get()->GetProjectManager()->GetNotebook()->AddPage(m_pClassBrowser, _("Symbols"));
m_pClassBrowser->UpdateSash();
}
else
{
m_pClassBrowser = new ClassBrowser(Manager::Get()->GetAppWindow(), this);
// make this a free floating/docking window
CodeBlocksDockEvent evt(cbEVT_ADD_DOCK_WINDOW);
evt.name = _T("SymbolsBrowser");
evt.title = _("Symbols browser");
evt.pWindow = m_pClassBrowser;
evt.dockSide = CodeBlocksDockEvent::dsRight;
evt.desiredSize.Set(200, 250);
evt.floatingSize.Set(200, 250);
evt.minimumSize.Set(150, 150);
evt.shown = true;
evt.hideable = true;
Manager::Get()->ProcessEvent(evt);
m_pClassBrowser->UpdateSash();
}
m_ClassBrowserIsFloating = isFloating;
// Dreaded DDE-open bug related: do not touch unless for a good reason
// m_pClassBrowser->SetParser(m_pParser);
}
}
What is the 'DDE-open bug' ?
If i uncomment the line "m_pClassBrowser->SetParser(m_pParser);", CC also works fine, include open file through DDE.
-
What is the 'DDE-open bug' ?
IIRC it was the following:
Windows reserves just about 5 secs for a DDE call to succeed. If parsing takes longer the return event comes too late, so the calling application using DDE "hangs".
However, you can also try to use SVN blame to find out when this was commented.
-
What is the 'DDE-open bug' ?
...
However, you can also try to use SVN blame to find out when this was commented.
mandrav 2008-2-23 22:14:40
* Seemingly fixed dreaded DDE bug on windows.
* Parse project(s) for symbols when opening through the command-line.
But even if I do not comment this line, through the command line to open the project is parsing correct, include class browser.
-
Of course, I have rewritten SetParser function, and added a temporary Parser, So, I think do not have this problem now.
-
Of course, I have rewritten SetParser function, and added a temporary Parser, So, I think do not have this problem now.
So - it *might* work now. In fact, since so many things have changed it may have become obsolete.
I can try my self to use it again on large workspaces / projects. I'll report back.