News:

Accounts with zero posts and zero activity during the last months will be deleted periodically to fight SPAM!

Main Menu

Workspace loading and Active Project

Started by daniloz, October 27, 2011, 02:57:09 PM

Previous topic - Next topic

daniloz

#15
Quote from: Alpha on October 27, 2011, 11:49:07 PM
Quote from: MortenMacFly on October 27, 2011, 07:26:14 PM
Quote from: nausea on October 27, 2011, 05:45:14 PM
you mentioned a plugin you use for developement: "DisplayEvents-plugin". Where do I find this one to use it myself?
Search the forums. ;-)
I also indexed it in the plugins page about a month ago.

And here is the patch for the DisplayEvents plugin, so we also see the new event...
(sorry about the "hardcoded" paths, I don't know how to do it better - suggestions are welcome)

oBFusCATed

#16
You're mixing tabs and spaces, C::B source is all spaces and you've not increased the SDK version numbers,
but you've changed the API/ABI for the ProjectManager. The SDK version numbers are in cbplugin.h.


Edit:
For the patch generation, goto the root of the working copy and execute "svn diff > my.patch".
This is the most robust way to generate patches. I've seen tortoisesvn mess up the patches it creates.
(most of the time I ignore long posts)
[strangers don't send me private messages, I'll ignore them; post a topic in the forum, but first read the rules!]

MortenMacFly

If you do what I said here:

Quote from: MortenMacFly on October 27, 2011, 04:15:01 PM
If you really need an event for the case "workspace completely loaded", provide a patch accordingly. It should be really simple to implement. Create an event in sdk_events{.cpp/.h} and instrument the method "ProjectManager::LoadWorkspace" accordingly.

You wouldn't even need to change the API interface. I think putting this event in WorkspaceChanged is the wrong place.
Compiler logging: Settings->Compiler & Debugger->tab "Other"->Compiler logging="Full command line"
C::B Manual: [url="https://www.codeblocks.org/docs/main_codeblocks_en.html"]https://www.codeblocks.org/docs/main_codeblocks_en.html[/url]
C::B FAQ: [url="https://wiki.codeblocks.org/index.php?title=FAQ"]https://wiki.codeblocks.org/index.php?title=FAQ[/url]

daniloz

Quote from: MortenMacFly on October 28, 2011, 10:18:39 AM
If you do what I said here:

Quote from: MortenMacFly on October 27, 2011, 04:15:01 PM
If you really need an event for the case "workspace completely loaded", provide a patch accordingly. It should be really simple to implement. Create an event in sdk_events{.cpp/.h} and instrument the method "ProjectManager::LoadWorkspace" accordingly.

You wouldn't even need to change the API interface. I think putting this event in WorkspaceChanged is the wrong place.

Hey, Morten, sorry.... I haven't really understood what you've suggested. Now I do...
I'll change my implementation on Monday (hopefully) and provide a new patch as soon as available...
And maybe I'll change the event name to cbEVT_WORKSPACE_LOADING_COMPLETE, that would be more uniform with the other events names...

MortenMacFly

Quote from: daniloz on October 28, 2011, 04:37:10 PM
And maybe I'll change the event name to cbEVT_WORKSPACE_LOADING_COMPLETE, that would be more uniform with the other events names...
True... I'll wait patiently...
Compiler logging: Settings->Compiler & Debugger->tab "Other"->Compiler logging="Full command line"
C::B Manual: [url="https://www.codeblocks.org/docs/main_codeblocks_en.html"]https://www.codeblocks.org/docs/main_codeblocks_en.html[/url]
C::B FAQ: [url="https://wiki.codeblocks.org/index.php?title=FAQ"]https://wiki.codeblocks.org/index.php?title=FAQ[/url]

daniloz

#20
Quote from: MortenMacFly on October 28, 2011, 05:05:24 PM
Quote from: daniloz on October 28, 2011, 04:37:10 PM
And maybe I'll change the event name to cbEVT_WORKSPACE_LOADING_COMPLETE, that would be more uniform with the other events names...
True... I'll wait patiently...
I don't want to keep you wanting, so here it is...
The patch for cbEVT_WORKSPACE_LOADING_COMPLETE and for the DisplayEvents plugin.

@jens: any better way do do a patch for DisplayEvents than having a strange path for the original and patched versions?