author | Michael Krelin <hacker@klever.net> | 2007-07-04 11:23:42 (UTC) |
---|---|---|
committer | Michael Krelin <hacker@klever.net> | 2007-07-04 11:23:42 (UTC) |
commit | a08aff328d4393031d5ba7d622c2b05705a89d73 (patch) (unidiff) | |
tree | 8ee90d686081c52e7c69b5ce946e9b1a7d690001 /libkdepim/categoryeditdialog_base.cpp | |
parent | 11edc920afe4f274c0964436633aa632c8288a40 (diff) | |
download | kdepimpi-p1.zip kdepimpi-p1.tar.gz kdepimpi-p1.tar.bz2 |
initial public commit of qt4 portp1
Diffstat (limited to 'libkdepim/categoryeditdialog_base.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r-- | libkdepim/categoryeditdialog_base.cpp | 20 |
1 files changed, 12 insertions, 8 deletions
diff --git a/libkdepim/categoryeditdialog_base.cpp b/libkdepim/categoryeditdialog_base.cpp index 1908576..c85f6e5 100644 --- a/libkdepim/categoryeditdialog_base.cpp +++ b/libkdepim/categoryeditdialog_base.cpp | |||
@@ -1,155 +1,159 @@ | |||
1 | #include <klocale.h> | 1 | #include <klocale.h> |
2 | /**************************************************************************** | 2 | /**************************************************************************** |
3 | ** Form implementation generated from reading ui file '/build/kde/cvs/korge/kdepim/libkdepim/categoryeditdialog_base.ui' | 3 | ** Form implementation generated from reading ui file '/build/kde/cvs/korge/kdepim/libkdepim/categoryeditdialog_base.ui' |
4 | ** | 4 | ** |
5 | ** Created: Sat Mar 29 21:46:09 2003 | 5 | ** Created: Sat Mar 29 21:46:09 2003 |
6 | ** by: The User Interface Compiler () | 6 | ** by: The User Interface Compiler () |
7 | ** | 7 | ** |
8 | ** WARNING! All changes made in this file will be lost! | 8 | ** WARNING! All changes made in this file will be lost! |
9 | ****************************************************************************/ | 9 | ****************************************************************************/ |
10 | 10 | ||
11 | #include "categoryeditdialog_base.h" | 11 | #include "categoryeditdialog_base.h" |
12 | 12 | ||
13 | #include <qvariant.h> | 13 | #include <qvariant.h> |
14 | #include <qheader.h> | 14 | #include <q3header.h> |
15 | #include <qlineedit.h> | 15 | #include <qlineedit.h> |
16 | #include <qlistview.h> | 16 | #include <q3listview.h> |
17 | #include <qpushbutton.h> | 17 | #include <qpushbutton.h> |
18 | #include <qlayout.h> | 18 | #include <qlayout.h> |
19 | #include <qtooltip.h> | 19 | #include <qtooltip.h> |
20 | #include <qwhatsthis.h> | 20 | #include <q3whatsthis.h> |
21 | //Added by qt3to4: | ||
22 | #include <Q3GridLayout> | ||
23 | #include <Q3HBoxLayout> | ||
24 | #include <Q3VBoxLayout> | ||
21 | 25 | ||
22 | /* | 26 | /* |
23 | * Constructs a CategoryEditDialog_base as a child of 'parent', with the | 27 | * Constructs a CategoryEditDialog_base as a child of 'parent', with the |
24 | * name 'name' and widget flags set to 'f'. | 28 | * name 'name' and widget flags set to 'f'. |
25 | * | 29 | * |
26 | * The dialog will by default be modeless, unless you set 'modal' to | 30 | * The dialog will by default be modeless, unless you set 'modal' to |
27 | * TRUE to construct a modal dialog. | 31 | * TRUE to construct a modal dialog. |
28 | */ | 32 | */ |
29 | CategoryEditDialog_base::CategoryEditDialog_base( QWidget* parent, const char* name, bool modal, WFlags fl ) | 33 | CategoryEditDialog_base::CategoryEditDialog_base( QWidget* parent, const char* name, bool modal, Qt::WFlags fl ) |
30 | : QDialog( parent, name, true, fl ) | 34 | : QDialog( parent, name, true, fl ) |
31 | 35 | ||
32 | { | 36 | { |
33 | if ( !name ) | 37 | if ( !name ) |
34 | setName( "CategoryEditDialog_base" ); | 38 | setName( "CategoryEditDialog_base" ); |
35 | CategoryEditDialog_baseLayout = new QGridLayout( this, 1, 1, 11, 6, "CategoryEditDialog_baseLayout"); | 39 | CategoryEditDialog_baseLayout = new Q3GridLayout( this, 1, 1, 11, 6, "CategoryEditDialog_baseLayout"); |
36 | 40 | ||
37 | mEdit = new QLineEdit( this, "mEdit" ); | 41 | mEdit = new QLineEdit( this, "mEdit" ); |
38 | 42 | ||
39 | CategoryEditDialog_baseLayout->addMultiCellWidget( mEdit, 1, 1, 0, 0 ); | 43 | CategoryEditDialog_baseLayout->addMultiCellWidget( mEdit, 1, 1, 0, 0 ); |
40 | 44 | ||
41 | Layout13 = new QHBoxLayout( 0, 0, 6, "Layout13"); | 45 | Layout13 = new Q3HBoxLayout( 0, 0, 6, "Layout13"); |
42 | 46 | ||
43 | // mButtonHelp = new QPushButton( this, "mButtonHelp" ); | 47 | // mButtonHelp = new QPushButton( this, "mButtonHelp" ); |
44 | //mButtonHelp->setAutoDefault( TRUE ); | 48 | //mButtonHelp->setAutoDefault( TRUE ); |
45 | //Layout13->addWidget( mButtonHelp ); | 49 | //Layout13->addWidget( mButtonHelp ); |
46 | //QSpacerItem* spacer = new QSpacerItem( 20, 20, QSizePolicy::Expanding, QSizePolicy::Minimum ); | 50 | //QSpacerItem* spacer = new QSpacerItem( 20, 20, QSizePolicy::Expanding, QSizePolicy::Minimum ); |
47 | //Layout13->addItem( spacer ); | 51 | //Layout13->addItem( spacer ); |
48 | 52 | ||
49 | //mApply = new QPushButton( this, "mApply" ); | 53 | //mApply = new QPushButton( this, "mApply" ); |
50 | // Layout13->addWidget( mApply ); | 54 | // Layout13->addWidget( mApply ); |
51 | 55 | ||
52 | mButtonOk = new QPushButton( this, "mButtonOk" ); | 56 | mButtonOk = new QPushButton( this, "mButtonOk" ); |
53 | mButtonOk->setAutoDefault( TRUE ); | 57 | mButtonOk->setAutoDefault( TRUE ); |
54 | mButtonOk->setDefault( TRUE ); | 58 | mButtonOk->setDefault( TRUE ); |
55 | Layout13->addWidget( mButtonOk ); | 59 | Layout13->addWidget( mButtonOk ); |
56 | 60 | ||
57 | mButtonCancel = new QPushButton( this, "mButtonCancel" ); | 61 | mButtonCancel = new QPushButton( this, "mButtonCancel" ); |
58 | mButtonCancel->setAutoDefault( TRUE ); | 62 | mButtonCancel->setAutoDefault( TRUE ); |
59 | Layout13->addWidget( mButtonCancel ); | 63 | Layout13->addWidget( mButtonCancel ); |
60 | 64 | ||
61 | CategoryEditDialog_baseLayout->addMultiCellLayout( Layout13, 2, 2, 0, 1 ); | 65 | CategoryEditDialog_baseLayout->addMultiCellLayout( Layout13, 2, 2, 0, 1 ); |
62 | 66 | ||
63 | mCategories = new QListView( this, "mCategories" ); | 67 | mCategories = new Q3ListView( this, "mCategories" ); |
64 | mCategories->addColumn( tr2i18n( "Category" ) ); | 68 | mCategories->addColumn( tr2i18n( "Category" ) ); |
65 | 69 | ||
66 | CategoryEditDialog_baseLayout->addWidget( mCategories, 0, 0 ); | 70 | CategoryEditDialog_baseLayout->addWidget( mCategories, 0, 0 ); |
67 | 71 | ||
68 | layout103 = new QVBoxLayout( 0, 0, 6, "layout103"); | 72 | layout103 = new Q3VBoxLayout( 0, 0, 6, "layout103"); |
69 | 73 | ||
70 | mButtonAdd = new QPushButton( this, "mButtonAdd" ); | 74 | mButtonAdd = new QPushButton( this, "mButtonAdd" ); |
71 | CategoryEditDialog_baseLayout->addMultiCellWidget(mButtonAdd , 1, 1, 1, 1 ); | 75 | CategoryEditDialog_baseLayout->addMultiCellWidget(mButtonAdd , 1, 1, 1, 1 ); |
72 | //layout103->addWidget( mButtonAdd ); | 76 | //layout103->addWidget( mButtonAdd ); |
73 | 77 | ||
74 | mButtonModify = new QPushButton( this, "mButtonModify" ); | 78 | mButtonModify = new QPushButton( this, "mButtonModify" ); |
75 | layout103->addWidget( mButtonModify ); | 79 | layout103->addWidget( mButtonModify ); |
76 | 80 | ||
77 | mButtonRemove = new QPushButton( this, "mButtonRemove" ); | 81 | mButtonRemove = new QPushButton( this, "mButtonRemove" ); |
78 | layout103->addWidget( mButtonRemove ); | 82 | layout103->addWidget( mButtonRemove ); |
79 | QSpacerItem* spacer_2 = new QSpacerItem( 20, 20, QSizePolicy::Minimum, QSizePolicy::Expanding ); | 83 | QSpacerItem* spacer_2 = new QSpacerItem( 20, 20, QSizePolicy::Minimum, QSizePolicy::Expanding ); |
80 | layout103->addItem( spacer_2 ); | 84 | layout103->addItem( spacer_2 ); |
81 | 85 | ||
82 | CategoryEditDialog_baseLayout->addLayout( layout103, 0, 1 ); | 86 | CategoryEditDialog_baseLayout->addLayout( layout103, 0, 1 ); |
83 | languageChange(); | 87 | languageChange(); |
84 | resize( sizeHint() ); | 88 | resize( sizeHint() ); |
85 | 89 | ||
86 | // signals and slots connections | 90 | // signals and slots connections |
87 | connect( mButtonCancel, SIGNAL( clicked() ), this, SLOT( reject() ) ); | 91 | connect( mButtonCancel, SIGNAL( clicked() ), this, SLOT( reject() ) ); |
88 | connect( mButtonAdd, SIGNAL( clicked() ), this, SLOT( add() ) ); | 92 | connect( mButtonAdd, SIGNAL( clicked() ), this, SLOT( add() ) ); |
89 | connect( mButtonModify, SIGNAL( clicked() ), this, SLOT( modify() ) ); | 93 | connect( mButtonModify, SIGNAL( clicked() ), this, SLOT( modify() ) ); |
90 | connect( mButtonRemove, SIGNAL( clicked() ), this, SLOT( remove() ) ); | 94 | connect( mButtonRemove, SIGNAL( clicked() ), this, SLOT( remove() ) ); |
91 | connect( mButtonOk, SIGNAL( clicked() ), this, SLOT( slotOk() ) ); | 95 | connect( mButtonOk, SIGNAL( clicked() ), this, SLOT( slotOk() ) ); |
92 | //connect( mApply, SIGNAL( clicked() ), this, SLOT( slotApply() ) ); | 96 | //connect( mApply, SIGNAL( clicked() ), this, SLOT( slotApply() ) ); |
93 | 97 | ||
94 | // tab order | 98 | // tab order |
95 | // setTabOrder( mCategories, mEdit ); | 99 | // setTabOrder( mCategories, mEdit ); |
96 | // setTabOrder( mEdit, mButtonAdd ); | 100 | // setTabOrder( mEdit, mButtonAdd ); |
97 | // setTabOrder( mButtonAdd, mButtonModify ); | 101 | // setTabOrder( mButtonAdd, mButtonModify ); |
98 | // setTabOrder( mButtonModify, mButtonRemove ); | 102 | // setTabOrder( mButtonModify, mButtonRemove ); |
99 | // setTabOrder( mButtonRemove, mButtonHelp ); | 103 | // setTabOrder( mButtonRemove, mButtonHelp ); |
100 | // setTabOrder( mButtonHelp, mApply ); | 104 | // setTabOrder( mButtonHelp, mApply ); |
101 | // setTabOrder( mApply, mButtonOk ); | 105 | // setTabOrder( mApply, mButtonOk ); |
102 | // setTabOrder( mButtonOk, mButtonCancel ); | 106 | // setTabOrder( mButtonOk, mButtonCancel ); |
103 | } | 107 | } |
104 | 108 | ||
105 | /* | 109 | /* |
106 | * Destroys the object and frees any allocated resources | 110 | * Destroys the object and frees any allocated resources |
107 | */ | 111 | */ |
108 | CategoryEditDialog_base::~CategoryEditDialog_base() | 112 | CategoryEditDialog_base::~CategoryEditDialog_base() |
109 | { | 113 | { |
110 | // no need to delete child widgets, Qt does it all for us | 114 | // no need to delete child widgets, Qt does it all for us |
111 | } | 115 | } |
112 | 116 | ||
113 | /* | 117 | /* |
114 | * Sets the strings of the subwidgets using the current | 118 | * Sets the strings of the subwidgets using the current |
115 | * language. | 119 | * language. |
116 | */ | 120 | */ |
117 | void CategoryEditDialog_base::languageChange() | 121 | void CategoryEditDialog_base::languageChange() |
118 | { | 122 | { |
119 | setCaption( tr2i18n( "Edit Categories" ) ); | 123 | setCaption( tr2i18n( "Edit Categories" ) ); |
120 | // mButtonHelp->setText( tr2i18n( "&Help" ) ); | 124 | // mButtonHelp->setText( tr2i18n( "&Help" ) ); |
121 | // mApply->setText( tr2i18n( "&Apply" ) ); | 125 | // mApply->setText( tr2i18n( "&Apply" ) ); |
122 | mButtonOk->setText( tr2i18n( "&OK" ) ); | 126 | mButtonOk->setText( tr2i18n( "&OK" ) ); |
123 | mButtonCancel->setText( tr2i18n( "&Cancel" ) ); | 127 | mButtonCancel->setText( tr2i18n( "&Cancel" ) ); |
124 | mCategories->header()->setLabel( 0, tr2i18n( "Category" ) ); | 128 | mCategories->header()->setLabel( 0, tr2i18n( "Category" ) ); |
125 | mButtonAdd->setText( tr2i18n( "A&dd" ) ); | 129 | mButtonAdd->setText( tr2i18n( "A&dd" ) ); |
126 | mButtonModify->setText( tr2i18n( "&Modify" ) ); | 130 | mButtonModify->setText( tr2i18n( "&Modify" ) ); |
127 | mButtonRemove->setText( tr2i18n( "&Remove" ) ); | 131 | mButtonRemove->setText( tr2i18n( "&Remove" ) ); |
128 | } | 132 | } |
129 | 133 | ||
130 | void CategoryEditDialog_base::add() | 134 | void CategoryEditDialog_base::add() |
131 | { | 135 | { |
132 | qWarning( "CategoryEditDialog_base::add(): Not implemented yet" ); | 136 | qWarning( "CategoryEditDialog_base::add(): Not implemented yet" ); |
133 | } | 137 | } |
134 | 138 | ||
135 | void CategoryEditDialog_base::modify() | 139 | void CategoryEditDialog_base::modify() |
136 | { | 140 | { |
137 | qWarning( "CategoryEditDialog_base::modify(): Not implemented yet" ); | 141 | qWarning( "CategoryEditDialog_base::modify(): Not implemented yet" ); |
138 | } | 142 | } |
139 | 143 | ||
140 | void CategoryEditDialog_base::slotApply() | 144 | void CategoryEditDialog_base::slotApply() |
141 | { | 145 | { |
142 | qWarning( "CategoryEditDialog_base::slotApply(): Not implemented yet" ); | 146 | qWarning( "CategoryEditDialog_base::slotApply(): Not implemented yet" ); |
143 | } | 147 | } |
144 | 148 | ||
145 | void CategoryEditDialog_base::remove() | 149 | void CategoryEditDialog_base::remove() |
146 | { | 150 | { |
147 | qWarning( "CategoryEditDialog_base::remove(): Not implemented yet" ); | 151 | qWarning( "CategoryEditDialog_base::remove(): Not implemented yet" ); |
148 | } | 152 | } |
149 | 153 | ||
150 | void CategoryEditDialog_base::slotOk() | 154 | void CategoryEditDialog_base::slotOk() |
151 | { | 155 | { |
152 | qWarning( "CategoryEditDialog_base::slotOk(): Not implemented yet" ); | 156 | qWarning( "CategoryEditDialog_base::slotOk(): Not implemented yet" ); |
153 | } | 157 | } |
154 | 158 | ||
155 | //US #include "categoryeditdialog_base.moc" | 159 | //US #include "categoryeditdialog_base.moc" |