Developer forums (C::B DEVELOPMENT STRICTLY!) > Plugins development
Editor event information
fenixk19:
Hello. I'm writing a session management plugin, like in kate editor - it manages opened files, without using a project. First, i'm not sure that i'm not inventing a bicycle. Tell me please, if there is some way to save and restore information on opened files. And my main question is:
how to get name of just opened file, when i catch cbEVT_EDITOR_OPEN event?
MortenMacFly:
--- Quote from: fenixk19 on January 28, 2010, 12:31:25 am ---how to get name of just opened file, when i catch cbEVT_EDITOR_OPEN event?
--- End quote ---
--- Code: --- cbEditor* ed = Manager::Get()->GetEditorManager()->GetBuiltinEditor(event.GetEditor());
if (ed)
wxString filename = ed->GetFilename();
--- End code ---
Please have a look at how it's done in other plugins. Also we have a SDK reference which is very helpful here. You can even build yourself using doxygen from the sources in SVN.
fenixk19:
Thanks. I didn't know what plugin to look at.
--- Quote ---we have a SDK reference
--- End quote ---
You mean SDK reference in wiki?
Jenna:
--- Quote from: fenixk19 on January 28, 2010, 08:01:28 am ---Thanks. I didn't know what plugin to look at.
--- End quote ---
The easiest way in such a case is to use ThreadSearch plugin and search for the keyword, either in the project (it's enough in this case) or in C::B's source-directory.
MortenMacFly:
--- Quote from: fenixk19 on January 28, 2010, 08:01:28 am ---You mean SDK reference in wiki?
--- End quote ---
No, I meant the CHM file on BerliOS here:
http://developer.berlios.de/project/showfiles.php?group_id=5358
Namely "codeblocks_sdk_doc_r6117.chm", this link:
http://prdownload.berlios.de/codeblocks/codeblocks_sdk_doc_r6117.chm
Navigation
[0] Message Index
[#] Next page
Go to full version