Author Topic: What is Simplest CB Plugin that does logging correctly?  (Read 5810 times)

Offline stahta01

  • Lives here!
  • ****
  • Posts: 7588
    • My Best Post
What is Simplest CB Plugin that does logging correctly?
« on: April 16, 2023, 12:11:10 am »
What is Simplest CB Plugin that does logging correctly?

GitBlocks is not doing the logging correctly to "Log & others" window; it keeps adding new tags.

Edit: I picked CppCheck plugin as one to try copying how it is done.
Edit2: GitBlocks seems to now attach and release correctly.

Tim S.
« Last Edit: April 16, 2023, 05:32:36 pm by stahta01 »
C Programmer working to learn more about C++ and Git.
On Windows 7 64 bit and Windows 10 64 bit.
--
When in doubt, read the CB WiKi FAQ. http://wiki.codeblocks.org

Offline ollydbg

  • Developer
  • Lives here!
  • *****
  • Posts: 5913
  • OpenCV and Robotics
    • Chinese OpenCV forum moderator
Re: What is Simplest CB Plugin that does logging correctly?
« Reply #1 on: April 17, 2023, 02:26:40 am »
A plugin named "cccc" which only contains one source file would be simple to understand, it just add a single log panel once attached, and remove it when released.

Luckily you have solved your issue.
If some piece of memory should be reused, turn them to variables (or const variables).
If some piece of operations should be reused, turn them to functions.
If they happened together, then turn them to classes.