-rw-r--r-- | korganizer/filteredit_base.cpp | 13 | ||||
-rw-r--r-- | korganizer/koeditordetails.cpp | 3 | ||||
-rw-r--r-- | korganizer/koeditorgeneral.cpp | 8 | ||||
-rw-r--r-- | korganizer/koprefsdialog.cpp | 6 |
4 files changed, 18 insertions, 12 deletions
diff --git a/korganizer/filteredit_base.cpp b/korganizer/filteredit_base.cpp index 15a4aaa..505edf6 100644 --- a/korganizer/filteredit_base.cpp +++ b/korganizer/filteredit_base.cpp | |||
@@ -1,39 +1,40 @@ | |||
1 | /**************************************************************************** | 1 | /**************************************************************************** |
2 | ** Form implementation generated from reading ui file 'filteredit_base.ui' | 2 | ** Form implementation generated from reading ui file 'filteredit_base.ui' |
3 | ** | 3 | ** |
4 | ** Created: Fr Jan 21 21:25:30 2005 | 4 | ** Created: Fr Jan 21 21:25:30 2005 |
5 | ** by: The User Interface Compiler ($Id$) | 5 | ** by: The User Interface Compiler ($Id$) |
6 | ** | 6 | ** |
7 | ** WARNING! All changes made in this file will be lost! | 7 | ** WARNING! All changes made in this file will be lost! |
8 | ****************************************************************************/ | 8 | ****************************************************************************/ |
9 | 9 | ||
10 | #include "filteredit_base.h" | 10 | #include "filteredit_base.h" |
11 | 11 | ||
12 | #include <qvariant.h> | 12 | #include <qvariant.h> |
13 | #include <qpushbutton.h> | 13 | #include <qpushbutton.h> |
14 | #include <qframe.h> | 14 | #include <qframe.h> |
15 | #include <qbuttongroup.h> | 15 | #include <qbuttongroup.h> |
16 | #include <qapplication.h> | ||
16 | #include <qradiobutton.h> | 17 | #include <qradiobutton.h> |
17 | #include <qlistbox.h> | 18 | #include <qlistbox.h> |
18 | #include <qlabel.h> | 19 | #include <qlabel.h> |
19 | #include <qcheckbox.h> | 20 | #include <qcheckbox.h> |
20 | #include <qlayout.h> | 21 | #include <qlayout.h> |
21 | #include <qtooltip.h> | 22 | #include <qtooltip.h> |
22 | #include <qwhatsthis.h> | 23 | #include <qwhatsthis.h> |
23 | #include "tr.h" | 24 | #include "tr.h" |
24 | 25 | ||
25 | /* | 26 | /* |
26 | * Constructs a FilterEdit_base as a child of 'parent', with the | 27 | * Constructs a FilterEdit_base as a child of 'parent', with the |
27 | * name 'name' and widget flags set to 'f'. | 28 | * name 'name' and widget flags set to 'f'. |
28 | */ | 29 | */ |
29 | FilterEdit_base::FilterEdit_base( QWidget* parent, const char* name, WFlags fl ) | 30 | FilterEdit_base::FilterEdit_base( QWidget* parent, const char* name, WFlags fl ) |
30 | : QWidget( parent, name, fl ) | 31 | : QWidget( parent, name, fl ) |
31 | { | 32 | { |
32 | if ( !name ) | 33 | if ( !name ) |
33 | setName( "FilterEdit_base" ); | 34 | setName( "FilterEdit_base" ); |
34 | FilterEdit_baseLayout = new QVBoxLayout( this, 0, 0, "FilterEdit_baseLayout"); | 35 | FilterEdit_baseLayout = new QVBoxLayout( this, 0, 0, "FilterEdit_baseLayout"); |
35 | 36 | ||
36 | mCriteriaFrame = new QFrame( this, "mCriteriaFrame" ); | 37 | mCriteriaFrame = new QFrame( this, "mCriteriaFrame" ); |
37 | mCriteriaFrame->setFrameShape( QFrame::StyledPanel ); | 38 | mCriteriaFrame->setFrameShape( QFrame::StyledPanel ); |
38 | mCriteriaFrame->setFrameShadow( QFrame::Raised ); | 39 | mCriteriaFrame->setFrameShadow( QFrame::Raised ); |
39 | mCriteriaFrameLayout = new QVBoxLayout( mCriteriaFrame, 3, 2, "mCriteriaFrameLayout"); | 40 | mCriteriaFrameLayout = new QVBoxLayout( mCriteriaFrame, 3, 2, "mCriteriaFrameLayout"); |
@@ -86,60 +87,66 @@ FilterEdit_base::FilterEdit_base( QWidget* parent, const char* name, WFlags fl ) | |||
86 | mTodoCheck = new QCheckBox( mCriteriaFrame, "mTodoCheck" ); | 87 | mTodoCheck = new QCheckBox( mCriteriaFrame, "mTodoCheck" ); |
87 | layout9->addWidget( mTodoCheck ); | 88 | layout9->addWidget( mTodoCheck ); |
88 | 89 | ||
89 | mJournalCheck = new QCheckBox( mCriteriaFrame, "mJournalCheck" ); | 90 | mJournalCheck = new QCheckBox( mCriteriaFrame, "mJournalCheck" ); |
90 | layout9->addWidget( mJournalCheck ); | 91 | layout9->addWidget( mJournalCheck ); |
91 | mCriteriaFrameLayout->addLayout( layout9 ); | 92 | mCriteriaFrameLayout->addLayout( layout9 ); |
92 | 93 | ||
93 | layout2 = new QHBoxLayout( 0, 0, 0, "layout2"); | 94 | layout2 = new QHBoxLayout( 0, 0, 0, "layout2"); |
94 | 95 | ||
95 | textLabel2 = new QLabel( mCriteriaFrame, "textLabel2" ); | 96 | textLabel2 = new QLabel( mCriteriaFrame, "textLabel2" ); |
96 | layout2->addWidget( textLabel2 ); | 97 | layout2->addWidget( textLabel2 ); |
97 | 98 | ||
98 | mPublicCheck = new QCheckBox( mCriteriaFrame, "mPublicCheck" ); | 99 | mPublicCheck = new QCheckBox( mCriteriaFrame, "mPublicCheck" ); |
99 | layout2->addWidget( mPublicCheck ); | 100 | layout2->addWidget( mPublicCheck ); |
100 | 101 | ||
101 | mPrivateCheck = new QCheckBox( mCriteriaFrame, "mPrivateCheck" ); | 102 | mPrivateCheck = new QCheckBox( mCriteriaFrame, "mPrivateCheck" ); |
102 | layout2->addWidget( mPrivateCheck ); | 103 | layout2->addWidget( mPrivateCheck ); |
103 | 104 | ||
104 | mConfidentialCheck = new QCheckBox( mCriteriaFrame, "mConfidentialCheck" ); | 105 | mConfidentialCheck = new QCheckBox( mCriteriaFrame, "mConfidentialCheck" ); |
105 | mConfidentialCheck->setChecked( FALSE ); | 106 | mConfidentialCheck->setChecked( FALSE ); |
106 | layout2->addWidget( mConfidentialCheck ); | 107 | layout2->addWidget( mConfidentialCheck ); |
107 | mCriteriaFrameLayout->addLayout( layout2 ); | 108 | mCriteriaFrameLayout->addLayout( layout2 ); |
108 | FilterEdit_baseLayout->addWidget( mCriteriaFrame ); | 109 | FilterEdit_baseLayout->addWidget( mCriteriaFrame ); |
109 | languageChange(); | 110 | languageChange(); |
110 | resize( QSize(324, 281).expandedTo(minimumSizeHint()) ); | 111 | resize( QSize(300, 200).expandedTo(minimumSizeHint()) ); |
111 | clearWState( WState_Polished ); | 112 | clearWState( WState_Polished ); |
112 | } | 113 | } |
113 | 114 | ||
114 | /* | 115 | /* |
115 | * Destroys the object and frees any allocated resources | 116 | * Destroys the object and frees any allocated resources |
116 | */ | 117 | */ |
117 | FilterEdit_base::~FilterEdit_base() | 118 | FilterEdit_base::~FilterEdit_base() |
118 | { | 119 | { |
119 | // no need to delete child widgets, Qt does it all for us | 120 | // no need to delete child widgets, Qt does it all for us |
120 | } | 121 | } |
121 | 122 | ||
122 | /* | 123 | /* |
123 | * Sets the strings of the subwidgets using the current | 124 | * Sets the strings of the subwidgets using the current |
124 | * language. | 125 | * language. |
125 | */ | 126 | */ |
126 | void FilterEdit_base::languageChange() | 127 | void FilterEdit_base::languageChange() |
127 | { | 128 | { |
128 | setCaption( tr( "FilterEditor" ) ); | 129 | setCaption( tr( "FilterEditor" ) ); |
129 | ButtonGroup1->setTitle( tr( "Categories" ) ); | 130 | ButtonGroup1->setTitle( tr( "Categories" ) ); |
130 | mCatShowCheck->setText( tr( "Include" ) ); | 131 | mCatShowCheck->setText( tr( "Include" ) ); |
131 | mCatHideCheck->setText( tr( "Exclude" ) ); | 132 | mCatHideCheck->setText( tr( "Exclude" ) ); |
132 | mCatEditButton->setText( tr( "Edit Selection..." ) ); | 133 | mCatEditButton->setText( tr( "Edit Selection..." ) ); |
133 | textLabel1->setText( tr( "Exclude" ) ); | 134 | textLabel1->setText( tr( "Exclude" ) ); |
134 | mRecurringCheck->setText( tr( "recurring events" ) ); | 135 | if (QApplication::desktop()->width() > 480 ) { |
135 | mCompletedCheck->setText( tr( "completed to-dos" ) ); | 136 | mCompletedCheck->setText( tr( "completed to-dos" ) ); |
137 | mRecurringCheck->setText( tr( "recurring events" ) ); | ||
138 | } | ||
139 | else { | ||
140 | mCompletedCheck->setText( tr( "compl.todos" ) ); | ||
141 | mRecurringCheck->setText( tr( "recurr. events" ) ); | ||
142 | } | ||
136 | textLabel1_2->setText( tr( "Exclude" ) ); | 143 | textLabel1_2->setText( tr( "Exclude" ) ); |
137 | mEventCheck->setText( tr( "events" ) ); | 144 | mEventCheck->setText( tr( "events" ) ); |
138 | mTodoCheck->setText( tr( "todos" ) ); | 145 | mTodoCheck->setText( tr( "todos" ) ); |
139 | mJournalCheck->setText( tr( "journals" ) ); | 146 | mJournalCheck->setText( tr( "journals" ) ); |
140 | textLabel2->setText( tr( "Include" ) ); | 147 | textLabel2->setText( tr( "Include" ) ); |
141 | mPublicCheck->setText( tr( "public" ) ); | 148 | mPublicCheck->setText( tr( "public" ) ); |
142 | mPrivateCheck->setText( tr( "private" ) ); | 149 | mPrivateCheck->setText( tr( "private" ) ); |
143 | mConfidentialCheck->setText( tr( "confidential" ) ); | 150 | mConfidentialCheck->setText( tr( "confidential" ) ); |
144 | } | 151 | } |
145 | 152 | ||
diff --git a/korganizer/koeditordetails.cpp b/korganizer/koeditordetails.cpp index b73d22f..cf0a458 100644 --- a/korganizer/koeditordetails.cpp +++ b/korganizer/koeditordetails.cpp | |||
@@ -123,49 +123,50 @@ KOEditorDetails::KOEditorDetails (int spacing,QWidget* parent,const char* name) | |||
123 | mStatusCombo->insertStringList(Attendee::statusList()); | 123 | mStatusCombo->insertStringList(Attendee::statusList()); |
124 | connect(mStatusCombo,SIGNAL(activated(int)),SLOT(updateAttendeeItem())); | 124 | connect(mStatusCombo,SIGNAL(activated(int)),SLOT(updateAttendeeItem())); |
125 | 125 | ||
126 | mRsvpButton = new QCheckBox(this); | 126 | mRsvpButton = new QCheckBox(this); |
127 | mRsvpButton->setText(i18n("Request response")); | 127 | mRsvpButton->setText(i18n("Request response")); |
128 | connect(mRsvpButton,SIGNAL(clicked()),SLOT(updateAttendeeItem())); | 128 | connect(mRsvpButton,SIGNAL(clicked()),SLOT(updateAttendeeItem())); |
129 | QWidget *buttonBox = new QWidget(this); | 129 | QWidget *buttonBox = new QWidget(this); |
130 | QVBoxLayout *buttonLayout = new QVBoxLayout(buttonBox); | 130 | QVBoxLayout *buttonLayout = new QVBoxLayout(buttonBox); |
131 | 131 | ||
132 | QPushButton *newButton = new QPushButton(i18n("&New"),buttonBox); | 132 | QPushButton *newButton = new QPushButton(i18n("&New"),buttonBox); |
133 | buttonLayout->addWidget(newButton); | 133 | buttonLayout->addWidget(newButton); |
134 | connect(newButton,SIGNAL(clicked()),SLOT(addNewAttendee())); | 134 | connect(newButton,SIGNAL(clicked()),SLOT(addNewAttendee())); |
135 | 135 | ||
136 | mRemoveButton = new QPushButton(i18n("&Remove"),buttonBox); | 136 | mRemoveButton = new QPushButton(i18n("&Remove"),buttonBox); |
137 | buttonLayout->addWidget(mRemoveButton); | 137 | buttonLayout->addWidget(mRemoveButton); |
138 | connect(mRemoveButton, SIGNAL(clicked()),SLOT(removeAttendee())); | 138 | connect(mRemoveButton, SIGNAL(clicked()),SLOT(removeAttendee())); |
139 | 139 | ||
140 | mAddressBookButton = new QPushButton(i18n("Address &Book..."),this); | 140 | mAddressBookButton = new QPushButton(i18n("Address &Book..."),this); |
141 | // buttonLayout->addWidget(mAddressBookButton); | 141 | // buttonLayout->addWidget(mAddressBookButton); |
142 | connect(mAddressBookButton,SIGNAL(clicked()),SLOT(openAddressBook())); | 142 | connect(mAddressBookButton,SIGNAL(clicked()),SLOT(openAddressBook())); |
143 | //mRoleCombo->setFixedSize( mRoleCombo->sizeHint () ); | 143 | //mRoleCombo->setFixedSize( mRoleCombo->sizeHint () ); |
144 | 144 | ||
145 | if (qApp->desktop()->width() < 640 ) { | 145 | if (qApp->desktop()->width() < 640 ) { |
146 | if ( qApp->desktop()->width() < 300 ) | 146 | if ( qApp->desktop()->width() < 300 ) |
147 | mListView->setFixedHeight(80); | 147 | topLayout->setSpacing(1); |
148 | ;//mListView->setFixedHeight(80); | ||
148 | topLayout->addMultiCellWidget(mOrganizerLabel,0,0,0,3); | 149 | topLayout->addMultiCellWidget(mOrganizerLabel,0,0,0,3); |
149 | topLayout->addMultiCellWidget(mListView,1,1,0,3); | 150 | topLayout->addMultiCellWidget(mListView,1,1,0,3); |
150 | topLayout->addWidget(attendeeLabel,3,0); | 151 | topLayout->addWidget(attendeeLabel,3,0); |
151 | topLayout->addMultiCellWidget(mNameEdit,3,3,1,2); | 152 | topLayout->addMultiCellWidget(mNameEdit,3,3,1,2); |
152 | topLayout->addWidget(emailLabel,4,0); | 153 | topLayout->addWidget(emailLabel,4,0); |
153 | topLayout->addMultiCellWidget(mEmailEdit,4,4,1,2); | 154 | topLayout->addMultiCellWidget(mEmailEdit,4,4,1,2); |
154 | topLayout->addWidget(attendeeRoleLabel,5,0); | 155 | topLayout->addWidget(attendeeRoleLabel,5,0); |
155 | topLayout->addMultiCellWidget(mRoleCombo,5,5,1,3); | 156 | topLayout->addMultiCellWidget(mRoleCombo,5,5,1,3); |
156 | topLayout->addWidget(statusLabel,6,0); | 157 | topLayout->addWidget(statusLabel,6,0); |
157 | topLayout->addMultiCellWidget(mStatusCombo,6,6,1,3); | 158 | topLayout->addMultiCellWidget(mStatusCombo,6,6,1,3); |
158 | topLayout->addMultiCellWidget(mAddressBookButton,2,2,2,3); | 159 | topLayout->addMultiCellWidget(mAddressBookButton,2,2,2,3); |
159 | topLayout->addMultiCellWidget(mRsvpButton,2,2,0,1); | 160 | topLayout->addMultiCellWidget(mRsvpButton,2,2,0,1); |
160 | topLayout->addMultiCellWidget(buttonBox,3,4,3,3); | 161 | topLayout->addMultiCellWidget(buttonBox,3,4,3,3); |
161 | topLayout->setRowStretch(1,2); | 162 | topLayout->setRowStretch(1,2); |
162 | topLayout->setColStretch(0,0); | 163 | topLayout->setColStretch(0,0); |
163 | topLayout->setColStretch(1,2); | 164 | topLayout->setColStretch(1,2); |
164 | topLayout->setColStretch(2,1); | 165 | topLayout->setColStretch(2,1); |
165 | topLayout->setColStretch(3,1); | 166 | topLayout->setColStretch(3,1); |
166 | 167 | ||
167 | } else { | 168 | } else { |
168 | topLayout->addMultiCellWidget(mOrganizerLabel,0,0,0,5); | 169 | topLayout->addMultiCellWidget(mOrganizerLabel,0,0,0,5); |
169 | topLayout->addMultiCellWidget(mListView,1,1,0,5); | 170 | topLayout->addMultiCellWidget(mListView,1,1,0,5); |
170 | topLayout->addWidget(attendeeLabel,3,0); | 171 | topLayout->addWidget(attendeeLabel,3,0); |
171 | topLayout->addMultiCellWidget(mNameEdit,3,3,1,4); | 172 | topLayout->addMultiCellWidget(mNameEdit,3,3,1,4); |
diff --git a/korganizer/koeditorgeneral.cpp b/korganizer/koeditorgeneral.cpp index b4fe965..f5eb52e 100644 --- a/korganizer/koeditorgeneral.cpp +++ b/korganizer/koeditorgeneral.cpp | |||
@@ -228,79 +228,79 @@ void KOEditorGeneral::pickAlarmSound() | |||
228 | if (!mAlarmSoundButton->isOn()) { | 228 | if (!mAlarmSoundButton->isOn()) { |
229 | //mAlarmSound = ""; | 229 | //mAlarmSound = ""; |
230 | QToolTip::remove(mAlarmSoundButton); | 230 | QToolTip::remove(mAlarmSoundButton); |
231 | QToolTip::add(mAlarmSoundButton, i18n("No sound set")); | 231 | QToolTip::add(mAlarmSoundButton, i18n("No sound set")); |
232 | mAlarmProgramButton->setOn(true); | 232 | mAlarmProgramButton->setOn(true); |
233 | mAlarmSoundButton->setOn(false); | 233 | mAlarmSoundButton->setOn(false); |
234 | } else { | 234 | } else { |
235 | QString fileName(KFileDialog::getOpenFileName(mAlarmSound, | 235 | QString fileName(KFileDialog::getOpenFileName(mAlarmSound, |
236 | i18n("*.wav|Wav Files"), 0)); | 236 | i18n("*.wav|Wav Files"), 0)); |
237 | if (!fileName.isEmpty()) { | 237 | if (!fileName.isEmpty()) { |
238 | mAlarmSound = fileName; | 238 | mAlarmSound = fileName; |
239 | QToolTip::remove(mAlarmSoundButton); | 239 | QToolTip::remove(mAlarmSoundButton); |
240 | QString dispStr = i18n("Playing '%1'").arg(fileName); | 240 | QString dispStr = i18n("Playing '%1'").arg(fileName); |
241 | QToolTip::add(mAlarmSoundButton, dispStr); | 241 | QToolTip::add(mAlarmSoundButton, dispStr); |
242 | mAlarmProgramButton->setOn(false); | 242 | mAlarmProgramButton->setOn(false); |
243 | mAlarmSoundButton->setOn(true); | 243 | mAlarmSoundButton->setOn(true); |
244 | } else { | 244 | } else { |
245 | mAlarmProgramButton->setOn(true); | 245 | mAlarmProgramButton->setOn(true); |
246 | mAlarmSoundButton->setOn(false); | 246 | mAlarmSoundButton->setOn(false); |
247 | 247 | ||
248 | } | 248 | } |
249 | } | 249 | } |
250 | 250 | ||
251 | if (mAlarmProgramButton->isOn()) | 251 | if (mAlarmProgramButton->isOn()) |
252 | ((QWidget*)parent())->topLevelWidget()->setCaption(i18n("Proc.Al.: ") + mAlarmProgram ); | 252 | ((QWidget*)parent())->topLevelWidget()->setCaption(i18n("Proc.Al.: ") + getFittingPath(mAlarmProgram) ); |
253 | if ( mAlarmSoundButton->isOn()) | 253 | if ( mAlarmSoundButton->isOn()) |
254 | ((QWidget*)parent())->topLevelWidget()->setCaption(i18n("Audio.Al.: ") + mAlarmSound ); | 254 | ((QWidget*)parent())->topLevelWidget()->setCaption(i18n("Audio.Al.: ") + getFittingPath(mAlarmSound) ); |
255 | } | 255 | } |
256 | 256 | ||
257 | void KOEditorGeneral::pickAlarmProgram() | 257 | void KOEditorGeneral::pickAlarmProgram() |
258 | { | 258 | { |
259 | if (!mAlarmProgramButton->isOn()) { | 259 | if (!mAlarmProgramButton->isOn()) { |
260 | //mAlarmProgram = ""; | 260 | //mAlarmProgram = ""; |
261 | QToolTip::remove(mAlarmProgramButton); | 261 | QToolTip::remove(mAlarmProgramButton); |
262 | QToolTip::add(mAlarmProgramButton, i18n("No program set")); | 262 | QToolTip::add(mAlarmProgramButton, i18n("No program set")); |
263 | mAlarmProgramButton->setOn(false); | 263 | mAlarmProgramButton->setOn(false); |
264 | mAlarmSoundButton->setOn(true); | 264 | mAlarmSoundButton->setOn(true); |
265 | } else { | 265 | } else { |
266 | QString fileName(KFileDialog::getOpenFileName(mAlarmProgram,i18n("Procedure Alarm.: ") , 0)); | 266 | QString fileName(KFileDialog::getOpenFileName(mAlarmProgram,i18n("Procedure Alarm.: ") , 0)); |
267 | if (!fileName.isEmpty()) { | 267 | if (!fileName.isEmpty()) { |
268 | mAlarmProgram = fileName; | 268 | mAlarmProgram = fileName; |
269 | QToolTip::remove(mAlarmProgramButton); | 269 | QToolTip::remove(mAlarmProgramButton); |
270 | QString dispStr = i18n("Running '%1'").arg(fileName); | 270 | QString dispStr = i18n("Running '%1'").arg(fileName); |
271 | QToolTip::add(mAlarmProgramButton, dispStr); | 271 | QToolTip::add(mAlarmProgramButton, dispStr); |
272 | mAlarmSoundButton->setOn(false); | 272 | mAlarmSoundButton->setOn(false); |
273 | mAlarmProgramButton->setOn(true); | 273 | mAlarmProgramButton->setOn(true); |
274 | } else { | 274 | } else { |
275 | mAlarmProgramButton->setOn(false); | 275 | mAlarmProgramButton->setOn(false); |
276 | mAlarmSoundButton->setOn(true); | 276 | mAlarmSoundButton->setOn(true); |
277 | } | 277 | } |
278 | } | 278 | } |
279 | if (mAlarmProgramButton->isOn()) | 279 | if (mAlarmProgramButton->isOn()) |
280 | ((QWidget*)parent())->topLevelWidget()->setCaption(i18n("Proc.Al.: ") + mAlarmProgram ); | 280 | ((QWidget*)parent())->topLevelWidget()->setCaption(i18n("Proc.Al.: ") + getFittingPath(mAlarmProgram) ); |
281 | if ( mAlarmSoundButton->isOn()) | 281 | if ( mAlarmSoundButton->isOn()) |
282 | ((QWidget*)parent())->topLevelWidget()->setCaption(i18n("Sound.Al.: ") + mAlarmSound ); | 282 | ((QWidget*)parent())->topLevelWidget()->setCaption(i18n("Sound.Al.: ") + getFittingPath(mAlarmSound) ); |
283 | } | 283 | } |
284 | 284 | ||
285 | 285 | ||
286 | QString KOEditorGeneral::getFittingPath( const QString s ) | 286 | QString KOEditorGeneral::getFittingPath( const QString s ) |
287 | { | 287 | { |
288 | int maxlen = 50; | 288 | int maxlen = 50; |
289 | if ( QApplication::desktop()->width() < 640 ) { | 289 | if ( QApplication::desktop()->width() < 640 ) { |
290 | if ( QApplication::desktop()->width() < 320 ) | 290 | if ( QApplication::desktop()->width() < 320 ) |
291 | maxlen = 22; | 291 | maxlen = 22; |
292 | else | 292 | else |
293 | maxlen = 35; | 293 | maxlen = 35; |
294 | } | 294 | } |
295 | if ( s.length() > maxlen ) { | 295 | if ( s.length() > maxlen ) { |
296 | return "..."+s.right(maxlen -3); | 296 | return "..."+s.right(maxlen -3); |
297 | } | 297 | } |
298 | return s; | 298 | return s; |
299 | } | 299 | } |
300 | 300 | ||
301 | void KOEditorGeneral::enableAlarmEdit(bool enable) | 301 | void KOEditorGeneral::enableAlarmEdit(bool enable) |
302 | { | 302 | { |
303 | if ( enable ) { | 303 | if ( enable ) { |
304 | if (!mAlarmProgramButton->isOn() && !mAlarmSoundButton->isOn()) { | 304 | if (!mAlarmProgramButton->isOn() && !mAlarmSoundButton->isOn()) { |
305 | mAlarmSoundButton->setOn( true ); | 305 | mAlarmSoundButton->setOn( true ); |
306 | if ( mAlarmSound.isEmpty() ) | 306 | if ( mAlarmSound.isEmpty() ) |
diff --git a/korganizer/koprefsdialog.cpp b/korganizer/koprefsdialog.cpp index ea73fd0..1b24f56 100644 --- a/korganizer/koprefsdialog.cpp +++ b/korganizer/koprefsdialog.cpp | |||
@@ -695,71 +695,69 @@ void KOPrefsDialog::setupViewsTab() | |||
695 | topLayout->addWidget(dummy->checkBox(),ii++,0); | 695 | topLayout->addWidget(dummy->checkBox(),ii++,0); |
696 | 696 | ||
697 | dummy = | 697 | dummy = |
698 | addWidBool(i18n("Listview uses monthly timespan"), | 698 | addWidBool(i18n("Listview uses monthly timespan"), |
699 | &(KOPrefs::instance()->mListViewMonthTimespan),topFrame); | 699 | &(KOPrefs::instance()->mListViewMonthTimespan),topFrame); |
700 | topLayout->addWidget(dummy->checkBox(),ii++,0); | 700 | topLayout->addWidget(dummy->checkBox(),ii++,0); |
701 | dummy = | 701 | dummy = |
702 | addWidBool(i18n("Highlight selection in Time Edit"), | 702 | addWidBool(i18n("Highlight selection in Time Edit"), |
703 | &(KOPrefs::instance()->mHightlightDateTimeEdit),topFrame); | 703 | &(KOPrefs::instance()->mHightlightDateTimeEdit),topFrame); |
704 | topLayout->addWidget( dummy->checkBox(), ii++,0); | 704 | topLayout->addWidget( dummy->checkBox(), ii++,0); |
705 | 705 | ||
706 | 706 | ||
707 | 707 | ||
708 | 708 | ||
709 | 709 | ||
710 | topFrame = addPage(i18n("Month View"),0,0); | 710 | topFrame = addPage(i18n("Month View"),0,0); |
711 | // DesktopIcon("viewmag",KIcon::SizeMedium)); | 711 | // DesktopIcon("viewmag",KIcon::SizeMedium)); |
712 | 712 | ||
713 | topLayout = new QGridLayout(topFrame,5,1); | 713 | topLayout = new QGridLayout(topFrame,5,1); |
714 | topLayout->setSpacing(spacingHint()); | 714 | topLayout->setSpacing(spacingHint()); |
715 | topLayout->setMargin(marginHint()); | 715 | topLayout->setMargin(marginHint()); |
716 | ii = 0; | 716 | ii = 0; |
717 | QLabel *lab; | 717 | QLabel *lab; |
718 | QHBox *habo = new QHBox( topFrame ); | 718 | QHBox *habo = new QHBox( topFrame ); |
719 | if ( QApplication::desktop()->width() < 320 ) { | 719 | if ( QApplication::desktop()->width() <= 480 ) { |
720 | lab = new QLabel ( i18n("Show events that recur "), topFrame ); | 720 | lab = new QLabel ( i18n("Show events that recur "), topFrame ); |
721 | topLayout->addMultiCellWidget(lab,ii, ii,0,1); | 721 | topLayout->addMultiCellWidget(lab,ii, ii,0,1); |
722 | ii++; | 722 | ii++; |
723 | |||
724 | } else { | 723 | } else { |
725 | new QLabel ( i18n("Show events that recur "), habo ); | 724 | new QLabel ( i18n("Show events that recur "), habo ); |
726 | |||
727 | } | 725 | } |
728 | dailyRecur = | 726 | dailyRecur = |
729 | addWidBool(i18n("daily"), | 727 | addWidBool(i18n("daily"), |
730 | &(KOPrefs::instance()->mMonthDailyRecur),habo); | 728 | &(KOPrefs::instance()->mMonthDailyRecur),habo); |
731 | // topLayout->addWidget(dailyRecur->checkBox(),ii++,0); | 729 | // topLayout->addWidget(dailyRecur->checkBox(),ii++,0); |
732 | 730 | ||
733 | weeklyRecur = | 731 | weeklyRecur = |
734 | addWidBool(i18n("weekly"), | 732 | addWidBool(i18n("weekly"), |
735 | &(KOPrefs::instance()->mMonthWeeklyRecur),habo); | 733 | &(KOPrefs::instance()->mMonthWeeklyRecur),habo); |
736 | topLayout->addMultiCellWidget(habo,ii, ii,0,1); | 734 | topLayout->addMultiCellWidget(habo,ii, ii,0,1); |
737 | ii++; | 735 | ii++; |
738 | 736 | ||
739 | 737 | ||
740 | habo = new QHBox( topFrame ); | 738 | habo = new QHBox( topFrame ); |
741 | if ( QApplication::desktop()->width() < 320 ) { | 739 | if ( QApplication::desktop()->width() <= 480 ) { |
742 | lab = new QLabel (i18n("Show in every cell ") , topFrame ); | 740 | lab = new QLabel (i18n("Show in every cell ") , topFrame ); |
743 | topLayout->addMultiCellWidget(lab,ii, ii,0,1); | 741 | topLayout->addMultiCellWidget(lab,ii, ii,0,1); |
744 | ii++; | 742 | ii++; |
745 | 743 | ||
746 | } else { | 744 | } else { |
747 | new QLabel ( i18n("Show in every cell "), habo ); | 745 | new QLabel ( i18n("Show in every cell "), habo ); |
748 | } | 746 | } |
749 | weeklyRecur = | 747 | weeklyRecur = |
750 | addWidBool(i18n("short month"), | 748 | addWidBool(i18n("short month"), |
751 | &(KOPrefs::instance()->mMonthShowShort),habo); | 749 | &(KOPrefs::instance()->mMonthShowShort),habo); |
752 | weeklyRecur = | 750 | weeklyRecur = |
753 | addWidBool(i18n("icons"), | 751 | addWidBool(i18n("icons"), |
754 | &(KOPrefs::instance()->mMonthShowIcons),habo); | 752 | &(KOPrefs::instance()->mMonthShowIcons),habo); |
755 | 753 | ||
756 | topLayout->addMultiCellWidget(habo,ii, ii,0,1); | 754 | topLayout->addMultiCellWidget(habo,ii, ii,0,1); |
757 | ii++; | 755 | ii++; |
758 | #ifdef DESKTOP_VERSION | 756 | #ifdef DESKTOP_VERSION |
759 | KPrefsDialogWidBool *enableMonthScroll = | 757 | KPrefsDialogWidBool *enableMonthScroll = |
760 | addWidBool(i18n("Enable scrollbars in month view cells"), | 758 | addWidBool(i18n("Enable scrollbars in month view cells"), |
761 | &(KOPrefs::instance()->mEnableMonthScroll),topFrame); | 759 | &(KOPrefs::instance()->mEnableMonthScroll),topFrame); |
762 | topLayout->addWidget(enableMonthScroll->checkBox(),ii++,0); | 760 | topLayout->addWidget(enableMonthScroll->checkBox(),ii++,0); |
763 | #endif | 761 | #endif |
764 | 762 | ||
765 | dummy = | 763 | dummy = |