summaryrefslogtreecommitdiffabout
path: root/korganizer
authorzautrix <zautrix>2005-04-30 07:32:03 (UTC)
committer zautrix <zautrix>2005-04-30 07:32:03 (UTC)
commit7c31102a00920834ab8e3778f0f459b96b2fb309 (patch) (unidiff)
tree9f238caaaab4ba150e4f14708d85162af0ea5092 /korganizer
parentbdaded2da25b0ccef80d6e638fa12f92a4f8744d (diff)
downloadkdepimpi-7c31102a00920834ab8e3778f0f459b96b2fb309.zip
kdepimpi-7c31102a00920834ab8e3778f0f459b96b2fb309.tar.gz
kdepimpi-7c31102a00920834ab8e3778f0f459b96b2fb309.tar.bz2
fixes
Diffstat (limited to 'korganizer') (more/less context) (show whitespace changes)
-rw-r--r--korganizer/koeditordetails.cpp28
-rw-r--r--korganizer/koeditorgeneral.cpp10
-rw-r--r--korganizer/koeventeditor.cpp4
-rw-r--r--korganizer/kotodoeditor.cpp2
-rw-r--r--korganizer/searchdialog.cpp4
5 files changed, 42 insertions, 6 deletions
diff --git a/korganizer/koeditordetails.cpp b/korganizer/koeditordetails.cpp
index 802261c..bdfc637 100644
--- a/korganizer/koeditordetails.cpp
+++ b/korganizer/koeditordetails.cpp
@@ -85,14 +85,16 @@ KOEditorDetails::KOEditorDetails (int spacing,QWidget* parent,const char* name)
85 mListView->addColumn(i18n("Name"),180); 85 mListView->addColumn(i18n("Name"),180);
86 mListView->addColumn(i18n("Email"),180); 86 mListView->addColumn(i18n("Email"),180);
87 mListView->addColumn(i18n("Role"),60); 87 mListView->addColumn(i18n("Role"),60);
88 mListView->addColumn(i18n("Status"),100); 88 mListView->addColumn(i18n("Status"),100);
89 mListView->addColumn(i18n("RSVP"),35); 89 mListView->addColumn(i18n("RSVP"),35);
90 if ( QApplication::desktop()->width() <= 320 ) { 90 if ( QApplication::desktop()->width() <= 320 ) {
91 //mListView->setSizePolicy( QSizePolicy( QSizePolicy::Expanding, QSizePolicy::Expanding) ); 91 int hei = 80;
92 mListView->setFixedHeight(80); 92 if ( QApplication::desktop()->height() <= 240 )
93 hei = 60;
94 mListView->setFixedHeight(hei);
93 } 95 }
94 mListView->setAllColumnsShowFocus (true ); 96 mListView->setAllColumnsShowFocus (true );
95 //mListView->setSingleClick( true ); 97 //mListView->setSingleClick( true );
96 connect(mListView,SIGNAL(selectionChanged(QListViewItem *)), 98 connect(mListView,SIGNAL(selectionChanged(QListViewItem *)),
97 SLOT(updateAttendeeInput())); 99 SLOT(updateAttendeeInput()));
98 100
@@ -144,13 +146,31 @@ KOEditorDetails::KOEditorDetails (int spacing,QWidget* parent,const char* name)
144 buttonLayout->addWidget(mRemoveButton); 146 buttonLayout->addWidget(mRemoveButton);
145 connect(mRemoveButton, SIGNAL(clicked()),SLOT(removeAttendee())); 147 connect(mRemoveButton, SIGNAL(clicked()),SLOT(removeAttendee()));
146 148
147 // buttonLayout->addWidget(mAddressBookButton); 149 // buttonLayout->addWidget(mAddressBookButton);
148 connect(mAddressBookButton,SIGNAL(clicked()),SLOT(openAddressBook())); 150 connect(mAddressBookButton,SIGNAL(clicked()),SLOT(openAddressBook()));
149 //mRoleCombo->setFixedSize( mRoleCombo->sizeHint () ); 151 //mRoleCombo->setFixedSize( mRoleCombo->sizeHint () );
150 152 if ( QApplication::desktop()->height() <= 240 ) {
153 mRoleCombo->setSizePolicy( QSizePolicy( QSizePolicy::Preferred ,QSizePolicy::Minimum ,FALSE) );
154 mStatusCombo->setSizePolicy( QSizePolicy( QSizePolicy::Preferred ,QSizePolicy::Minimum ,FALSE) );
155 topLayout->addMultiCellWidget(mOrganizerLabel,0,0,0,5);
156 topLayout->addMultiCellWidget(mListView,1,1,0,5);
157 topLayout->addWidget(attendeeLabel,3,0);
158 topLayout->addMultiCellWidget(mNameEdit,3,3,1,4);
159 topLayout->addWidget(emailLabel,4,0);
160 topLayout->addMultiCellWidget(mEmailEdit,4,4,1,4);
161 topLayout->addWidget(attendeeRoleLabel,5,0);
162 topLayout->addMultiCellWidget(mRoleCombo,5,5,1,2);
163 topLayout->addWidget(statusLabel,5,3);
164 topLayout->addMultiCellWidget(mStatusCombo,5,5,4,5);
165 topLayout->addMultiCellWidget(mAddressBookButton,2,2,2,5);
166 topLayout->addMultiCellWidget(mRsvpButton,2,2,0,1);
167 topLayout->addMultiCellWidget(buttonBox,3,4,5,5);
168 topLayout->setRowStretch(1,5);
169 topLayout->setColStretch(0,0);
170 } else {
151 if (qApp->desktop()->width() < 640 ) { 171 if (qApp->desktop()->width() < 640 ) {
152 if ( qApp->desktop()->width() < 300 ) 172 if ( qApp->desktop()->width() < 300 )
153 topLayout->setSpacing(1); 173 topLayout->setSpacing(1);
154 ;//mListView->setFixedHeight(80); 174 ;//mListView->setFixedHeight(80);
155 topLayout->addMultiCellWidget(mOrganizerLabel,0,0,0,3); 175 topLayout->addMultiCellWidget(mOrganizerLabel,0,0,0,3);
156 topLayout->addMultiCellWidget(mListView,1,1,0,3); 176 topLayout->addMultiCellWidget(mListView,1,1,0,3);
@@ -167,13 +187,12 @@ KOEditorDetails::KOEditorDetails (int spacing,QWidget* parent,const char* name)
167 topLayout->addMultiCellWidget(buttonBox,3,4,3,3); 187 topLayout->addMultiCellWidget(buttonBox,3,4,3,3);
168 topLayout->setRowStretch(1,2); 188 topLayout->setRowStretch(1,2);
169 topLayout->setColStretch(0,0); 189 topLayout->setColStretch(0,0);
170 topLayout->setColStretch(1,2); 190 topLayout->setColStretch(1,2);
171 topLayout->setColStretch(2,1); 191 topLayout->setColStretch(2,1);
172 topLayout->setColStretch(3,1); 192 topLayout->setColStretch(3,1);
173
174 } else { 193 } else {
175 topLayout->addMultiCellWidget(mOrganizerLabel,0,0,0,5); 194 topLayout->addMultiCellWidget(mOrganizerLabel,0,0,0,5);
176 topLayout->addMultiCellWidget(mListView,1,1,0,5); 195 topLayout->addMultiCellWidget(mListView,1,1,0,5);
177 topLayout->addWidget(attendeeLabel,3,0); 196 topLayout->addWidget(attendeeLabel,3,0);
178 topLayout->addMultiCellWidget(mNameEdit,3,3,1,4); 197 topLayout->addMultiCellWidget(mNameEdit,3,3,1,4);
179 topLayout->addWidget(emailLabel,4,0); 198 topLayout->addWidget(emailLabel,4,0);
@@ -185,12 +204,13 @@ KOEditorDetails::KOEditorDetails (int spacing,QWidget* parent,const char* name)
185 topLayout->addMultiCellWidget(mAddressBookButton,2,2,4,5); 204 topLayout->addMultiCellWidget(mAddressBookButton,2,2,4,5);
186 topLayout->addMultiCellWidget(mRsvpButton,2,2,0,1); 205 topLayout->addMultiCellWidget(mRsvpButton,2,2,0,1);
187 topLayout->addMultiCellWidget(buttonBox,3,4,5,5); 206 topLayout->addMultiCellWidget(buttonBox,3,4,5,5);
188 topLayout->setRowStretch(1,5); 207 topLayout->setRowStretch(1,5);
189 topLayout->setColStretch(0,0); 208 topLayout->setColStretch(0,0);
190 } 209 }
210 }
191// #if 0 211// #if 0
192// topLayout->setColStretch(2,1); 212// topLayout->setColStretch(2,1);
193// topLayout->addWidget(statusLabel,3,3); 213// topLayout->addWidget(statusLabel,3,3);
194// topLayout->addWidget(mStatusCombo,3,4); 214// topLayout->addWidget(mStatusCombo,3,4);
195// #else 215// #else
196// topLayout->addWidget(statusLabel,4,3); 216// topLayout->addWidget(statusLabel,4,3);
diff --git a/korganizer/koeditorgeneral.cpp b/korganizer/koeditorgeneral.cpp
index 0045b7f..bfe0aec 100644
--- a/korganizer/koeditorgeneral.cpp
+++ b/korganizer/koeditorgeneral.cpp
@@ -90,24 +90,34 @@ void KOEditorGeneral::initHeader(QWidget *parent,QBoxLayout *topLayout)
90 // SizeType { Fixed = 0, Minimum = MayGrow, Maximum = MayShrink, Preferred = MayGrow|MayShrink, MinimumExpanding = Minimum|ExpMask, Expanding = MinimumExpanding|MayShrink } 90 // SizeType { Fixed = 0, Minimum = MayGrow, Maximum = MayShrink, Preferred = MayGrow|MayShrink, MinimumExpanding = Minimum|ExpMask, Expanding = MinimumExpanding|MayShrink }
91 // mSummaryEdit = new QLineEdit(parent); 91 // mSummaryEdit = new QLineEdit(parent);
92 headerLayout->addWidget(mSummaryEdit,1,1); 92 headerLayout->addWidget(mSummaryEdit,1,1);
93 connect ( mSummaryEdit->lineEdit(), SIGNAL ( returnPressed() ), this, SIGNAL (allAccepted () ) ); 93 connect ( mSummaryEdit->lineEdit(), SIGNAL ( returnPressed() ), this, SIGNAL (allAccepted () ) );
94 94
95 QLabel *locationLabel = new QLabel(i18n("Location:"),parent); 95 QLabel *locationLabel = new QLabel(i18n("Location:"),parent);
96 if ( QApplication::desktop()->height() < 320 )
97 headerLayout->addWidget(locationLabel,1,2);
98 else
96 headerLayout->addWidget(locationLabel,2,0); 99 headerLayout->addWidget(locationLabel,2,0);
97 100
98 mLocationEdit = new KOLocationBox(TRUE,parent,10); 101 mLocationEdit = new KOLocationBox(TRUE,parent,10);
99 mLocationEdit->setSizePolicy( QSizePolicy( QSizePolicy::Preferred ,QSizePolicy::MinimumExpanding ,FALSE) ); 102 mLocationEdit->setSizePolicy( QSizePolicy( QSizePolicy::Preferred ,QSizePolicy::MinimumExpanding ,FALSE) );
100 if ( QApplication::desktop()->width() > 320 ) 103 if ( QApplication::desktop()->width() > 320 )
101 mLocationEdit->setMaximumHeight( hei + 6); 104 mLocationEdit->setMaximumHeight( hei + 6);
102 105
103 // mLocationEdit = new QLineEdit(parent); 106 // mLocationEdit = new QLineEdit(parent);
104 connect ( mLocationEdit->lineEdit(), SIGNAL ( returnPressed() ), this, SIGNAL (allAccepted () ) ); 107 connect ( mLocationEdit->lineEdit(), SIGNAL ( returnPressed() ), this, SIGNAL (allAccepted () ) );
108 if ( QApplication::desktop()->height() < 320 ) {
109 headerLayout->addWidget(mLocationEdit,1,3);
110 headerLayout->setColStretch( 1, 10);
111 headerLayout->setColStretch( 3, 10);
112 }
113 else {
105 headerLayout->addWidget(mLocationEdit,2,1); 114 headerLayout->addWidget(mLocationEdit,2,1);
106 headerLayout->setColStretch( 1, 10); 115 headerLayout->setColStretch( 1, 10);
107} 116}
117}
108void KOEditorGeneral::setFocusOn( int i ) 118void KOEditorGeneral::setFocusOn( int i )
109{ 119{
110 mNextFocus = i; 120 mNextFocus = i;
111 QTimer::singleShot( 0, this, SLOT ( slotSetFocusOn() )); 121 QTimer::singleShot( 0, this, SLOT ( slotSetFocusOn() ));
112} 122}
113void KOEditorGeneral::slotSetFocusOn() 123void KOEditorGeneral::slotSetFocusOn()
diff --git a/korganizer/koeventeditor.cpp b/korganizer/koeventeditor.cpp
index e23e680..02d4a78 100644
--- a/korganizer/koeventeditor.cpp
+++ b/korganizer/koeventeditor.cpp
@@ -51,12 +51,14 @@ extern int globalFlagBlockAgenda;
51 51
52KOEventEditor::KOEventEditor( Calendar *calendar, QWidget *parent ) : 52KOEventEditor::KOEventEditor( Calendar *calendar, QWidget *parent ) :
53 KOIncidenceEditor( i18n("Edit Event"), calendar, parent ) 53 KOIncidenceEditor( i18n("Edit Event"), calendar, parent )
54{ 54{
55 mEvent = 0; 55 mEvent = 0;
56 init(); 56 init();
57 if ( QApplication::desktop()->height() <= 240 )
58 hideButtons();
57} 59}
58 60
59KOEventEditor::~KOEventEditor() 61KOEventEditor::~KOEventEditor()
60{ 62{
61 //emit dialogClose( mEvent ); 63 //emit dialogClose( mEvent );
62} 64}
@@ -110,13 +112,13 @@ void KOEventEditor::setupGeneral()
110 mGeneral->initTime(topFrame,topLayout); 112 mGeneral->initTime(topFrame,topLayout);
111// QBoxLayout *alarmLineLayout = new QHBoxLayout(topLayout); 113// QBoxLayout *alarmLineLayout = new QHBoxLayout(topLayout);
112 mGeneral->initAlarm(topFrame,topLayout); 114 mGeneral->initAlarm(topFrame,topLayout);
113 mGeneral->enableAlarm( false ); 115 mGeneral->enableAlarm( false );
114 116
115 QBoxLayout *buttonLayout; 117 QBoxLayout *buttonLayout;
116 if ( QApplication::desktop()->width() < 500 ) 118 if ( QApplication::desktop()->width() < 500 && QApplication::desktop()->height() > 240 )
117 buttonLayout = new QVBoxLayout( topLayout ); 119 buttonLayout = new QVBoxLayout( topLayout );
118 else 120 else
119 buttonLayout = new QHBoxLayout( topLayout ); 121 buttonLayout = new QHBoxLayout( topLayout );
120 QHBox* buttonWidget = new QHBox (topFrame); 122 QHBox* buttonWidget = new QHBox (topFrame);
121 QIconSet icon; 123 QIconSet icon;
122 if ( QApplication::desktop()->width() < 321 ) 124 if ( QApplication::desktop()->width() < 321 )
diff --git a/korganizer/kotodoeditor.cpp b/korganizer/kotodoeditor.cpp
index 5513e8b..9073bca 100644
--- a/korganizer/kotodoeditor.cpp
+++ b/korganizer/kotodoeditor.cpp
@@ -56,12 +56,14 @@ KOTodoEditor::KOTodoEditor( Calendar *calendar, QWidget *parent ) :
56 KOIncidenceEditor( i18n("Edit To-Do"), calendar, parent ) 56 KOIncidenceEditor( i18n("Edit To-Do"), calendar, parent )
57{ 57{
58 mTodo = 0; 58 mTodo = 0;
59 mRelatedTodo = 0; 59 mRelatedTodo = 0;
60 findButton(User1)->hide(); 60 findButton(User1)->hide();
61 init(); 61 init();
62 if ( QApplication::desktop()->height() <= 240 )
63 hideButtons();
62} 64}
63 65
64KOTodoEditor::~KOTodoEditor() 66KOTodoEditor::~KOTodoEditor()
65{ 67{
66 emit dialogClose( mTodo ); 68 emit dialogClose( mTodo );
67} 69}
diff --git a/korganizer/searchdialog.cpp b/korganizer/searchdialog.cpp
index 007d1f3..59bf1a2 100644
--- a/korganizer/searchdialog.cpp
+++ b/korganizer/searchdialog.cpp
@@ -111,13 +111,15 @@ SearchDialog::SearchDialog(Calendar *calendar,CalendarView *parent)
111 QToolButton *wt = QWhatsThis::whatsThisButton ( rangeWidget ); 111 QToolButton *wt = QWhatsThis::whatsThisButton ( rangeWidget );
112 rangeLayout->addWidget( (QWidget*)wt ); 112 rangeLayout->addWidget( (QWidget*)wt );
113 layout->addWidget(rangeWidget); 113 layout->addWidget(rangeWidget);
114 // Results list view 114 // Results list view
115 listView = new KOListView(mCalendar,topFrame); 115 listView = new KOListView(mCalendar,topFrame);
116 layout->addWidget(listView); 116 layout->addWidget(listView);
117 117 //layout->setStretchFactor( listView, 333 );
118 //listView->setSizePolicy( QSizePolicy( QSizePolicy::Preferred ,QSizePolicy::Expanding) );
119 //listView->setMaximumHeight( 50 );
118 listView->readSettings(KOGlobals::config(),"SearchListView Layout"); 120 listView->readSettings(KOGlobals::config(),"SearchListView Layout");
119 connect(searchEdit,SIGNAL(scrollDOWN()),SLOT(setFocusToList())); 121 connect(searchEdit,SIGNAL(scrollDOWN()),SLOT(setFocusToList()));
120 122
121 setCaption( i18n("KO/Pi Find: ")); 123 setCaption( i18n("KO/Pi Find: "));
122#ifdef DESKTOP_VERSION 124#ifdef DESKTOP_VERSION
123 OkButton = new QPushButton( i18n("Close"), this ); 125 OkButton = new QPushButton( i18n("Close"), this );