[Kde-pim] Review Request: Signal changes in KDateEdit and KTimeEdit (the first of two related review requests)

Anselmo Melo anselmolsm at gmail.com
Thu Sep 23 22:09:27 BST 2010


-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
http://svn.reviewboard.kde.org/r/5432/
-----------------------------------------------------------

Review request for KDE PIM and David Faure.


Summary
-------

This is the first of two review requests about changing widgets in incidenceeditor-ng for korganizer-mobile.

In this review request, we introduce changes in KTimeEdit and KDateEdit, both from kdepim/libkdepim.

As part of our current task in korganizer-mobile, we want to use KTimeEdit and KDateEdit instead of QTimeEdit and QDateEdit in incidenceeditor-ng.

Why?
With the new Time and Date selector widgets designed by Nuno, we do not need the spin buttons anymore (QDateEdit and QTimeEdit inherits from QAbstractSpinBox).

To complete the integration of the new widgets, we need signals emitted when the widgets are set using either setTime() or setDate(), i.e., change their values programmatically.
In the current code, KTimeEdit has a signal timeChanged() and KDateEdit has dateChanged(), both emitted only when the user edits the widgets, but not when they are set programmatically.

So, last Wednesday dfaure suggested the following:

1 - Rename the current timeChanged() to timeEdited() and dateChanged() to dateEdited();
2 - Update the uses of these signals across kdepim
3 - Add the new timeChanged() and dateChanged() and emit them in setTime and setDate, respectively.

With the listed changes, KTimeEdit and KDateEdit signals will follow what happens in Qt Edit classes (e.g. QLineEdit): a Changed signal whenever the content changes and an Edit signal emitted when the user edits the content.

The diff adds these new signals, document them and updates the current uses of {time,date}Changed() signals to {time,date}Edited().

Comments are welcome, as always =)


Diffs
-----

  /trunk/KDE/kdepim/incidenceeditor-ng/schedulingdialog.cpp 1178629 
  /trunk/KDE/kdepim/kalarm/recurrenceedit.cpp 1178629 
  /trunk/KDE/kdepim/libkdepim/kdateedit.h 1178629 
  /trunk/KDE/kdepim/libkdepim/kdateedit.cpp 1178629 
  /trunk/KDE/kdepim/libkdepim/kprefsdialog.cpp 1178629 
  /trunk/KDE/kdepim/libkdepim/ktimeedit.h 1178629 
  /trunk/KDE/kdepim/libkdepim/ktimeedit.cpp 1178629 

Diff: http://svn.reviewboard.kde.org/r/5432/diff


Testing
-------

KDEPIM builds successfully with the patch applied on top of r1178629. Applications affected by the changes working in the same way they did without the patch.


Thanks,

Anselmo

_______________________________________________
KDE PIM mailing list kde-pim at kde.org
https://mail.kde.org/mailman/listinfo/kde-pim
KDE PIM home page at http://pim.kde.org/



More information about the kde-pim mailing list