Author Topic: Workspace loading and Active Project  (Read 10685 times)

Offline daniloz

  • Regular
  • ***
  • Posts: 268
Re: Workspace loading and Active Project
« Reply #15 on: October 28, 2011, 08:37:47 am »
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)
« Last Edit: October 28, 2011, 11:50:00 pm by daniloz »

Online oBFusCATed

  • Developer
  • Lives here!
  • *****
  • Posts: 12898
    • Travis build status
Re: Workspace loading and Active Project
« Reply #16 on: October 28, 2011, 10:16:12 am »
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.
« Last Edit: October 28, 2011, 10:17:56 am by oBFusCATed »
(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!]

Offline MortenMacFly

  • Administrator
  • Lives here!
  • *****
  • Posts: 9606
Re: Workspace loading and Active Project
« Reply #17 on: October 28, 2011, 10:18:39 am »
If you do what I said here:

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: http://www.codeblocks.org/docs/main_codeblocks_en.html
C::B FAQ: http://wiki.codeblocks.org/index.php?title=FAQ

Offline daniloz

  • Regular
  • ***
  • Posts: 268
Re: Workspace loading and Active Project
« Reply #18 on: October 28, 2011, 04:37:10 pm »
If you do what I said here:

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...

Offline MortenMacFly

  • Administrator
  • Lives here!
  • *****
  • Posts: 9606
Re: Workspace loading and Active Project
« Reply #19 on: October 28, 2011, 05:05:24 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: http://www.codeblocks.org/docs/main_codeblocks_en.html
C::B FAQ: http://wiki.codeblocks.org/index.php?title=FAQ

Offline daniloz

  • Regular
  • ***
  • Posts: 268
Re: Workspace loading and Active Project
« Reply #20 on: October 28, 2011, 11:52:56 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?
« Last Edit: October 31, 2011, 09:12:20 pm by daniloz »