Author Topic: another patch for the todo plugin  (Read 6614 times)

Offline frithjofh

  • Regular
  • ***
  • Posts: 376
another patch for the todo plugin
« on: November 20, 2015, 01:46:11 pm »
updated a dialogue to be more user friendly. refactored. added some security checks

changes to the asktypedlg gui :

- replaced the combobox with a list of radiobuttons

changes to the asktypedlg.h :

- changed base class to wxDialog
- changed constructor to take argumnts by const&
- made destructor virtual

changes to the asktypedlg.cpp :

- changed base class to wxDialog
- changed constructor to take arguments by const&
- in constructor added some checks for the XRC system
- moved empty destructor to header
- did the according changes caused by change of gui
- some clean up
« Last Edit: November 22, 2015, 09:40:19 am by frithjofh »
architect with some spare time  -  c::b compiled from last svn  -   openSuSE leap x86_64  -  AMD FX-4100

Offline frithjofh

  • Regular
  • ***
  • Posts: 376
Re: another patch for the todo plugin
« Reply #1 on: November 22, 2015, 09:40:44 am »
included the list of changes made in the previous post
architect with some spare time  -  c::b compiled from last svn  -   openSuSE leap x86_64  -  AMD FX-4100

Offline ollydbg

  • Developer
  • Lives here!
  • *****
  • Posts: 5910
  • OpenCV and Robotics
    • Chinese OpenCV forum moderator
Re: another patch for the todo plugin
« Reply #2 on: November 24, 2015, 03:47:41 pm »

changes to the asktypedlg.h :

- changed base class to wxDialog
...
- changed base class to wxDialog
...
I haven't test your patch, but looked a the patch file, I see the above changes. My question is why you change to wxDialog?
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.

Offline frithjofh

  • Regular
  • ***
  • Posts: 376
Re: another patch for the todo plugin
« Reply #3 on: November 24, 2015, 08:15:22 pm »
let me return the question: why should it be a wxScrolledDialog?

is that needed by anybody or by anything? I couldn't tell, so I chose the more simple alternative.

if there is a reason for wxScrolledDialog here, please tell me, and I'll switch back.

thx for the feedback  :)
architect with some spare time  -  c::b compiled from last svn  -   openSuSE leap x86_64  -  AMD FX-4100

Offline Jenna

  • Administrator
  • Lives here!
  • *****
  • Posts: 7255
Re: another patch for the todo plugin
« Reply #4 on: November 24, 2015, 10:13:53 pm »
let me return the question: why should it be a wxScrolledDialog?

is that needed by anybody or by anything? I couldn't tell, so I chose the more simple alternative.

if there is a reason for wxScrolledDialog here, please tell me, and I'll switch back.

thx for the feedback  :)
wxScrollDialog automatically uses scrollbars, if the dialog does not fit on screen.

Offline frithjofh

  • Regular
  • ***
  • Posts: 376
Re: another patch for the todo plugin
« Reply #5 on: November 24, 2015, 10:26:55 pm »
yes, I know that much, but the dialog is really tiny...

maybe on a mobile phone...
architect with some spare time  -  c::b compiled from last svn  -   openSuSE leap x86_64  -  AMD FX-4100