KRename – powerful batch renamer
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

77 satır
2.2KB

  1. /***************************************************************************
  2. numberdialog.h - description
  3. -------------------
  4. begin : Don Apr 24 2003
  5. copyright : (C) 2003 by Dominik Seichter
  6. email : domseichter@web.de
  7. ***************************************************************************/
  8. /***************************************************************************
  9. * *
  10. * This program is free software; you can redistribute it and/or modify *
  11. * it under the terms of the GNU General Public License as published by *
  12. * the Free Software Foundation; either version 2 of the License, or *
  13. * (at your option) any later version. *
  14. * *
  15. ***************************************************************************/
  16. #ifndef NUMBERDIALOG_H
  17. #define NUMBERDIALOG_H
  18. #include <tqwidget.h>
  19. #include <kdialogbase.h>
  20. #include <tqvaluelist.h>
  21. // KDE includes
  22. #include <knuminput.h>
  23. class KMyIntSpinBox : public KIntSpinBox
  24. {
  25. Q_OBJECT
  26. public:
  27. KMyIntSpinBox( TQWidget* parent )
  28. : KIntSpinBox( parent )
  29. { };
  30. ~KMyIntSpinBox() { };
  31. private:
  32. void keyPressEvent( TQKeyEvent* e );
  33. signals:
  34. void returnPressed();
  35. };
  36. class TQCheckBox;
  37. class KIntNumInput;
  38. class TDEListBox;
  39. class KPushButton;
  40. class NumberDialog : public KDialogBase {
  41. Q_OBJECT
  42. public:
  43. NumberDialog(TQValueList<int> & n,TQWidget *parent=0);
  44. ~NumberDialog();
  45. // TODO: bad object oriented design!!!
  46. // make them accessible by members
  47. KIntNumInput* spinIndex;
  48. KIntNumInput* spinStep;
  49. TQCheckBox* checkResetCounter;
  50. TQValueList<int> getList();
  51. private slots:
  52. void addNumber();
  53. void removeNumber();
  54. private:
  55. void sort();
  56. TDEListBox* listNumbers;
  57. KPushButton* buttonAdd;
  58. KPushButton* buttonRemove;
  59. KMyIntSpinBox* spinNumber;
  60. };
  61. #endif