summaryrefslogtreecommitdiffabout
Side-by-side diff
Diffstat (more/less context) (ignore whitespace changes)
-rw-r--r--bin/kdepim/kaddressbook/germantranslation.txt10
-rw-r--r--kaddressbook/views/contactlistview.cpp2
-rw-r--r--kaddressbook/xxportselectdialog.cpp8
-rw-r--r--korganizer/calendarview.cpp14
-rw-r--r--korganizer/koeditordetails.cpp7
-rw-r--r--korganizer/mainwindow.cpp5
6 files changed, 36 insertions, 10 deletions
diff --git a/bin/kdepim/kaddressbook/germantranslation.txt b/bin/kdepim/kaddressbook/germantranslation.txt
index b5ad650..08efcf6 100644
--- a/bin/kdepim/kaddressbook/germantranslation.txt
+++ b/bin/kdepim/kaddressbook/germantranslation.txt
@@ -498,55 +498,65 @@
{ "Change Email...","Ändere Email..." },
{ "Remove Contact","Entferne Kontakt" },
{ "Use Preferred","Nutze Preferred" },
{ "Distribution List Editor","Distribution List Editor" },
{ "Choose which contacts to export","Wähle Kontakte zum Exportieren" },
{ "Which contacts do you want to export?","Welche Kontakte sollen exportiert werden?" },
{ "Contact Selection","Kontaktauswahl" },
{ "&All","&Alle" },
{ "Export the entire address book","Exportiere das komplette Addressbuch" },
{ "&Selected","Au&sgewählte" },
{ "Only export contacts selected in KAddressBook.\nThis option is disabled if no contacts are selected.","###Only export contacts selected in KAddressBook.\nThis option is disabled if no contacts are selected." },
{ "By matching &filter","Zutreffender &Filter" },
{ "Only export contacts matching the selected filter.\nThis option is disabled if you haven't defined any filters","###Only export contacts matching the selected filter.\nThis option is disabled if you haven't defined any filters" },
{ "By Cate&gories","Kategorien" },
{ "Only export contacts who are members of a category that is checked on the list to the left.\nThis option is disabled if you have no categories.","###Only export contacts who are members of a category that is checked on the list to the left.\nThis option is disabled if you have no categories." },
{ "Select a filter to decide which contacts to export.","Wähle Filter zum Export aus." },
{ "Check the categories whose members you want to export.","Wähle die Kategorien zum Export aus." },
{ "Sorting","Sortieren" },
{ "Criterion:","Merkmal:" },
{ "Order:","Reihenfolge:" },
{ "Ascending","Aufsteigend" },
{ "Descending","Absteigend" },
{ "Save file","Datei speichern" },
{ "Error","Fehler" },
{ "Unable to export contacts.","Exportieren der Kontakte geht nicht." },
{ "\nNo unsaved changes detected!\nNothing will be saved!","\nKeine ungespeicherten\nÄnderungen erkannt!\nNichts wird gespeichert!" },
{ "Manage new categories...","Verwalte neue Kategorien..." },
{ "&File","Datei" },
{ "&Edit","Bearbeite" },
{ "&View","Ansichten" },
{ "&Settings","Konfiguration" },
{ "&Change selected","Ändere Selekt." },
{ "&Help","Hilfe" },
{ "Remove sync info","Entferne Sync Info" },
{ "For all profiles","Für alle Profile" },
{ "&Change","Ändere" },
{ "Import xml (Qtopia)...","Importiere xml (Qtopia)..." },
{ "Export xml (Qtopia)...","Exportiere xml (Qtopia)..." },
{ "Export to phone","Exportiere aufs Handy..." },
{ "Which contacts do you want to select?","Welche Kontakte möchten Sie wählen?" },
{ "&Modify","Ändere" },
{ "Choose which contacts to select","Bitte Kontakte auswählen!" },
{ "After importing/loading/syncing\nthere may be new categories in\naddressees\nwhich are not in the category list.\nPlease choose what to do:\n ","Nach dem Importieren/Laden/Syncen\nkann es neue Kategorien in den \nKontakten geben, die nicht\nin der Kategorieliste enthalten sind.\nBitte wählen Sie, was passieren soll:\n " },
{ "Manage new Categories","Verwalte neue Kategorien" },
{ "Add to category list","Füge zur Kategorieliste hinzu" },
{ "Remove from addressees","Entferne von den Kontakten" },
{ "New categories not in list:","Kategorien, die nicht in der Liste sind:" },
{ "A&dd","Hinzufügen" },
+{ "Please read Help-Sync Howto\nto know what settings to use.","Bitte lese Hilfe-Sync Howto\num zu erfahren welche Einstellungen\ndie richtigen sind." },
+{ "NOTE: This will remove all old\ncontact data on phone!","ACHTUNG: Das löscht alle alten\nKontakt Daten auf dem Handy!" },
+{ "Export to mobile phone!","Exportiere auf das Handy!" },
+{ "Export to phone options","Export ans Handy Optionen" },
+{ "Writing to phone...","Sende Daten ans Handy..." },
+{ " This may take 1-3 minutes!"," Das kann 1-3 Minuten dauern!" },
+{ "Retry","Nochmal versuchen" },
+{ "KDE/Pim phone access","KDE/Pim Handy Zugriff" },
+{ "Error accessing device!\nPlease turn on connection\nand retry!","Fehler beim Zugriff auf das Gerät!\nBitte die Verbindung aktivieren\nund nochmal versuchen!" },
+{ "Error exporting to phone!","Fehler beim Export auf das Handy!" },
{ "","" },
{ "","" },
{ "","" },
{ "","" },
{ "","" },
{ "","" },
{ "","" }, \ No newline at end of file
diff --git a/kaddressbook/views/contactlistview.cpp b/kaddressbook/views/contactlistview.cpp
index ad43970..23b091c 100644
--- a/kaddressbook/views/contactlistview.cpp
+++ b/kaddressbook/views/contactlistview.cpp
@@ -144,97 +144,97 @@ void DynamicTip::maybeTip( const QPoint &pos )
++i;
}
}
tip( r, s );
}
else
hide();
ishidden = !ishidden;
}
///////////////////////////
// ContactListViewItem Methods
ContactListViewItem::ContactListViewItem(const KABC::Addressee &a,
ContactListView *parent,
KABC::AddressBook *doc,
const KABC::Field::List &fields )
: KListViewItem(parent), mAddressee(a), mFields( fields ),
parentListView( parent ), mDocument(doc)
{
refresh();
}
QString ContactListViewItem::key(int column, bool ascending) const
{
#ifndef DESKTOP_VERSION
int lan = KGlobal::locale()->language();
//qDebug("language %d ", lan);
if ( lan == 1 ) { //GERMAN
QString ret = QListViewItem::key(column, ascending).lower().utf8();
int start = -1;
while ( (start = ret.find( 'ä', start+1)) > 0 ) {
ret.at(start-1) = 'a';
}
start = -1;
while ( (start = ret.find( 'ö', start+1)) > 0 ) {
ret.at(start-1) = 'o';
}
start = -1;
while ( (start = ret.find( 'ü', start+1)) > 0 ) {
ret.at(start-1) = 'o';
}
start = -1;
while ( (start = ret.find( 'ß', start+1)) > 0 ) {
ret.at(start-1) = 's';
}
- qDebug("conv string %s ", ret.latin1());
+ //qDebug("conv string %s ", ret.latin1());
return ret;
}
else
#endif
return QListViewItem::key(column, ascending).lower();
}
void ContactListViewItem::paintCell(QPainter * p,
const QColorGroup & cg,
int column,
int width,
int align)
{
KListViewItem::paintCell(p, cg, column, width, align);
if ( !p )
return;
if (parentListView->singleLine()) {
p->setPen( parentListView->alternateColor() );
p->drawLine( 0, height() - 1, width, height() - 1 );
}
}
ContactListView *ContactListViewItem::parent()
{
return parentListView;
}
void ContactListViewItem::refresh()
{
// Update our addressee, since it may have changed else were
mAddressee = mDocument->findByUid(mAddressee.uid());
if (mAddressee.isEmpty())
return;
int i = 0;
KABC::Field::List::ConstIterator it;
for( it = mFields.begin(); it != mFields.end(); ++it ) {
setText( i++, (*it)->value( mAddressee ) );
}
}
///////////////////////////////
diff --git a/kaddressbook/xxportselectdialog.cpp b/kaddressbook/xxportselectdialog.cpp
index ab95d5f..6282453 100644
--- a/kaddressbook/xxportselectdialog.cpp
+++ b/kaddressbook/xxportselectdialog.cpp
@@ -1,85 +1,86 @@
/*
This file is part of KAddressBook.
Copyright (c) 2002 Anders Lund <anders.lund@lund.tdcadsl.dk>
Tobias Koenig <tokoe@kde.org>
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software
Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
As a special exception, permission is given to link this program
with any edition of Qt, and distribute the resulting executable,
without including the source code for Qt in the source distribution.
*/
/*
Enhanced Version of the file for platform independent KDE tools.
Copyright (c) 2004 Ulf Schenk
$Id$
*/
#include <kabc/addressbook.h>
#include <kapplication.h>
#include <kcombobox.h>
#include <klocale.h>
#include <kglobal.h>
+#include <qapplication.h>
#include <qbuttongroup.h>
#include <qcombobox.h>
#include <qheader.h>
#include <qlabel.h>
#include <qlayout.h>
#include <qlistview.h>
#include <qpushbutton.h>
#include <qradiobutton.h>
#include <qstringlist.h>
#include <qwhatsthis.h>
#include "kabcore.h"
#include "kabprefs.h"
#include "xxportselectdialog.h"
XXPortSelectDialog::XXPortSelectDialog( KABCore *core, bool sort,
QWidget* parent, const char* name )
: KDialogBase( Plain, i18n( "Choose which contacts to select" ), Help | Ok | Cancel,
Ok, parent, name, true, true ), mCore( core ),
mUseSorting( sort )
{
initGUI();
connect( mFiltersCombo, SIGNAL( activated( int ) ),
SLOT( filterChanged( int ) ) );
connect( mCategoriesView, SIGNAL( clicked( QListViewItem* ) ),
SLOT( categoryClicked( QListViewItem* ) ) );
// setup filters
#ifndef KAB_EMBEDDED
mFilters = Filter::restore( kapp->config(), "Filter" );
Filter::List::iterator filterIt;
#else //KAB_EMBEDDED
mFilters = Filter::restore( KGlobal::config(), "Filter" );
Filter::List::Iterator filterIt;
#endif //KAB_EMBEDDED
QStringList filters;
for ( filterIt = mFilters.begin(); filterIt != mFilters.end(); ++filterIt )
filters.append( (*filterIt).name() );
mFiltersCombo->insertStringList( filters );
mUseFilters->setEnabled( filters.count() > 0 );
// setup categories
QStringList categories = KABPrefs::instance()->mCustomCategories;
QStringList::Iterator it;
for ( it = categories.begin(); it != categories.end(); ++it )
@@ -200,89 +201,94 @@ void XXPortSelectDialog::slotHelp()
void XXPortSelectDialog::initGUI()
{
QFrame *page = plainPage();
QVBoxLayout *topLayout = new QVBoxLayout( page, KDialog::marginHint(),
KDialog::spacingHint() );
QLabel *label = new QLabel( i18n( "Which contacts do you want to select?" ), page );
topLayout->addWidget( label );
mButtonGroup = new QButtonGroup( i18n( "Contact Selection" ), page );
mButtonGroup->setColumnLayout( 0, Qt::Vertical );
mButtonGroup->layout()->setSpacing( KDialog::spacingHint() );
mButtonGroup->layout()->setMargin( KDialog::marginHint() );
QGridLayout *groupLayout = new QGridLayout( mButtonGroup->layout() );
groupLayout->setAlignment( Qt::AlignTop );
mUseWholeBook = new QRadioButton( i18n( "&All" ), mButtonGroup );
mUseWholeBook->setChecked( true );
QWhatsThis::add( mUseWholeBook, i18n( "Select the entire address book" ) );
groupLayout->addWidget( mUseWholeBook, 0, 0 );
mUseSelection = new QRadioButton( i18n( "&Selected" ), mButtonGroup );
QWhatsThis::add( mUseSelection, i18n( "Only contacts selected in KAddressBook.\n"
"This option is disabled if no contacts are selected." ) );
groupLayout->addWidget( mUseSelection, 1, 0 );
mUseFilters = new QRadioButton( i18n( "By matching &filter" ), mButtonGroup );
QWhatsThis::add( mUseFilters, i18n( "Only contacts matching the selected filter.\n"
"This option is disabled if you haven't defined any filters" ) );
groupLayout->addWidget( mUseFilters, 2, 0 );
mUseCategories = new QRadioButton( i18n( "By Cate&gories" ), mButtonGroup );
QWhatsThis::add( mUseCategories, i18n( "Only contacts who are members of a category that is checked on the list to the left.\n"
"This option is disabled if you have no categories." ) );
groupLayout->addWidget( mUseCategories, 3, 0 );
mFiltersCombo = new QComboBox( false, mButtonGroup );
QWhatsThis::add( mFiltersCombo, i18n( "Select a filter to decide which contacts to select." ) );
groupLayout->addWidget( mFiltersCombo, 2, 1 );
mCategoriesView = new QListView( mButtonGroup );
mCategoriesView->addColumn( "" );
mCategoriesView->header()->hide();
QWhatsThis::add( mCategoriesView, i18n( "Check the categories whose members you want to select." ) );
groupLayout->addWidget( mCategoriesView, 3, 1 );
+ // if (QApplication::desktop()->height() == 480 )
+ // mCategoriesView->setMaximumHeight( 240 );
topLayout->addWidget( mButtonGroup );
QButtonGroup *sortingGroup = new QButtonGroup( i18n( "Sorting" ), page );
sortingGroup->setColumnLayout( 0, Qt::Vertical );
QGridLayout *sortLayout = new QGridLayout( sortingGroup->layout(), 2, 2,
KDialog::spacingHint() );
sortLayout->setAlignment( Qt::AlignTop );
label = new QLabel( i18n( "Criterion:" ), sortingGroup );
sortLayout->addWidget( label, 0, 0 );
#ifndef KAB_EMBEDDED
mFieldCombo = new KComboBox( false, sortingGroup );
#else //KAB_EMBEDDED
//US Combobox is not editable anyway
mFieldCombo = new KComboBox( sortingGroup );
#endif //KAB_EMBEDDED
sortLayout->addWidget( mFieldCombo, 0, 1 );
label = new QLabel( i18n( "Order:" ), sortingGroup );
sortLayout->addWidget( label, 1, 0 );
#ifndef KAB_EMBEDDED
mSortTypeCombo = new KComboBox( false, sortingGroup );
#else //KAB_EMBEDDED
//US Combobox is not editable anyway
mSortTypeCombo = new KComboBox( sortingGroup );
#endif //KAB_EMBEDDED
sortLayout->addWidget( mSortTypeCombo, 1, 1 );
topLayout->addWidget( sortingGroup );
if ( !mUseSorting )
- sortingGroup->hide();
+ sortingGroup->hide();
+#ifndef DESKTOP_VERSION
+ hideButtons();
+#endif
}
#ifndef KAB_EMBEDDED
#include "xxportselectdialog.moc"
#endif //KAB_EMBEDDED
diff --git a/korganizer/calendarview.cpp b/korganizer/calendarview.cpp
index 47cd488..543897a 100644
--- a/korganizer/calendarview.cpp
+++ b/korganizer/calendarview.cpp
@@ -2405,108 +2405,114 @@ void CalendarView::moveIncidence(Incidence * inc )
if ( !inc ) return;
// qDebug("showDatePickerForIncidence( ) ");
if ( mDateFrame->isVisible() )
mDateFrame->hide();
else {
int w =mDatePicker->sizeHint().width()+2*mDateFrame->lineWidth() ;
int h = mDatePicker->sizeHint().height()+2*mDateFrame->lineWidth() ;
int dw = QApplication::desktop()->width();
int dh = QApplication::desktop()->height();
mDateFrame->setGeometry( (dw-w)/2, (dh - h )/2 ,w,h );
mDateFrame->show();
}
mDatePickerMode = 2;
mMoveIncidence = inc ;
QDate da;
if ( mMoveIncidence->type() == "Todo" ) {
Todo * to = (Todo *) mMoveIncidence;
if ( to->hasDueDate() )
da = to->dtDue().date();
else
da = QDate::currentDate();
} else {
da = mMoveIncidence->dtStart().date();
}
mDatePicker->setDate( da );
}
void CalendarView::showDatePicker( )
{
//qDebug("CalendarView::showDatePicker( ) ");
if ( mDateFrame->isVisible() )
mDateFrame->hide();
else {
int w =mDatePicker->sizeHint().width() ;
int h = mDatePicker->sizeHint().height() ;
int dw = QApplication::desktop()->width();
int dh = QApplication::desktop()->height();
mDateFrame->setGeometry( (dw-w)/2, (dh - h )/2 ,w,h );
mDateFrame->show();
}
mDatePickerMode = 1;
mDatePicker->setDate( mNavigator->selectedDates().first() );
}
void CalendarView::showEventEditor()
{
#ifdef DESKTOP_VERSION
mEventEditor->show();
#else
- if ( mEventEditor->width() != QApplication::desktop()->width() )
- mEventEditor->hide();
+ if ( mEventEditor->width() != QApplication::desktop()->width() ) {
+ qDebug("CalendarView: recreate mEventEditor ");
+ delete mEventEditor;
+ mEventEditor = mDialogManager->getEventEditor();
+ }
mEventEditor->showMaximized();
#endif
}
void CalendarView::showTodoEditor()
{
#ifdef DESKTOP_VERSION
mTodoEditor->show();
#else
- if ( mTodoEditor->width() != QApplication::desktop()->width() )
- mTodoEditor->hide();
+ if ( mTodoEditor->width() != QApplication::desktop()->width() ) {
+ qDebug("CalendarView: recreate mTodoEditor ");
+ delete mTodoEditor;
+ mTodoEditor = mDialogManager->getTodoEditor();
+ }
mTodoEditor->showMaximized();
#endif
}
void CalendarView::cloneIncidence()
{
Incidence *incidence = currentSelection();
if ( !incidence ) incidence = mTodoList->selectedIncidences().first();
if ( incidence ) {
cloneIncidence(incidence);
}
}
void CalendarView::moveIncidence()
{
Incidence *incidence = currentSelection();
if ( !incidence ) incidence = mTodoList->selectedIncidences().first();
if ( incidence ) {
moveIncidence(incidence);
}
}
void CalendarView::beamIncidence()
{
Incidence *incidence = currentSelection();
if ( !incidence ) incidence = mTodoList->selectedIncidences().first();
if ( incidence ) {
beamIncidence(incidence);
}
}
void CalendarView::toggleCancelIncidence()
{
Incidence *incidence = currentSelection();
if ( !incidence ) incidence = mTodoList->selectedIncidences().first();
if ( incidence ) {
cancelIncidence(incidence);
}
}
void CalendarView::cancelIncidence(Incidence * inc )
{
inc->setCancelled( ! inc->cancelled() );
changeIncidenceDisplay( inc,KOGlobals::EVENTEDITED );
updateView();
}
void CalendarView::cloneIncidence(Incidence * orgInc )
{
Incidence * newInc = orgInc->clone();
newInc->recreate();
diff --git a/korganizer/koeditordetails.cpp b/korganizer/koeditordetails.cpp
index 66f6977..b73d22f 100644
--- a/korganizer/koeditordetails.cpp
+++ b/korganizer/koeditordetails.cpp
@@ -97,108 +97,109 @@ KOEditorDetails::KOEditorDetails (int spacing,QWidget* parent,const char* name)
QLabel *attendeeLabel = new QLabel(this);
attendeeLabel->setText(i18n("Name:"));
attendeeLabel->setFixedSize( attendeeLabel->sizeHint() );
mNameEdit = new QLineEdit(this);
connect(mNameEdit,SIGNAL(textChanged(const QString &)),
SLOT(updateAttendeeItem()));
mUidEdit = new QLineEdit(0);
mUidEdit->setText("");
QLabel *emailLabel = new QLabel(this);
emailLabel->setText(i18n("Email:"));
mEmailEdit = new QLineEdit(this);
connect(mEmailEdit,SIGNAL(textChanged(const QString &)),
SLOT(updateAttendeeItem()));
QLabel *attendeeRoleLabel = new QLabel(this);
attendeeRoleLabel->setText(i18n("Role:"));
mRoleCombo = new QComboBox(false,this);
mRoleCombo->insertStringList(Attendee::roleList());
connect(mRoleCombo,SIGNAL(activated(int)),SLOT(updateAttendeeItem()));
QLabel *statusLabel = new QLabel(this);
statusLabel->setText( i18n("Status:") );
mStatusCombo = new QComboBox(false,this);
mStatusCombo->insertStringList(Attendee::statusList());
connect(mStatusCombo,SIGNAL(activated(int)),SLOT(updateAttendeeItem()));
mRsvpButton = new QCheckBox(this);
mRsvpButton->setText(i18n("Request response"));
connect(mRsvpButton,SIGNAL(clicked()),SLOT(updateAttendeeItem()));
QWidget *buttonBox = new QWidget(this);
QVBoxLayout *buttonLayout = new QVBoxLayout(buttonBox);
QPushButton *newButton = new QPushButton(i18n("&New"),buttonBox);
buttonLayout->addWidget(newButton);
connect(newButton,SIGNAL(clicked()),SLOT(addNewAttendee()));
mRemoveButton = new QPushButton(i18n("&Remove"),buttonBox);
buttonLayout->addWidget(mRemoveButton);
connect(mRemoveButton, SIGNAL(clicked()),SLOT(removeAttendee()));
mAddressBookButton = new QPushButton(i18n("Address &Book..."),this);
// buttonLayout->addWidget(mAddressBookButton);
connect(mAddressBookButton,SIGNAL(clicked()),SLOT(openAddressBook()));
//mRoleCombo->setFixedSize( mRoleCombo->sizeHint () );
- if (qApp->desktop()->width() < 300 ) {
+ if (qApp->desktop()->width() < 640 ) {
+ if ( qApp->desktop()->width() < 300 )
mListView->setFixedHeight(80);
topLayout->addMultiCellWidget(mOrganizerLabel,0,0,0,3);
topLayout->addMultiCellWidget(mListView,1,1,0,3);
topLayout->addWidget(attendeeLabel,3,0);
topLayout->addMultiCellWidget(mNameEdit,3,3,1,2);
topLayout->addWidget(emailLabel,4,0);
topLayout->addMultiCellWidget(mEmailEdit,4,4,1,2);
topLayout->addWidget(attendeeRoleLabel,5,0);
- topLayout->addMultiCellWidget(mRoleCombo,5,5,1,2);
+ topLayout->addMultiCellWidget(mRoleCombo,5,5,1,3);
topLayout->addWidget(statusLabel,6,0);
- topLayout->addMultiCellWidget(mStatusCombo,6,6,1,2);
+ topLayout->addMultiCellWidget(mStatusCombo,6,6,1,3);
topLayout->addMultiCellWidget(mAddressBookButton,2,2,2,3);
topLayout->addMultiCellWidget(mRsvpButton,2,2,0,1);
topLayout->addMultiCellWidget(buttonBox,3,4,3,3);
topLayout->setRowStretch(1,2);
topLayout->setColStretch(0,0);
topLayout->setColStretch(1,2);
topLayout->setColStretch(2,1);
topLayout->setColStretch(3,1);
} else {
topLayout->addMultiCellWidget(mOrganizerLabel,0,0,0,5);
topLayout->addMultiCellWidget(mListView,1,1,0,5);
topLayout->addWidget(attendeeLabel,3,0);
topLayout->addMultiCellWidget(mNameEdit,3,3,1,4);
topLayout->addWidget(emailLabel,4,0);
topLayout->addMultiCellWidget(mEmailEdit,4,4,1,4);
topLayout->addWidget(attendeeRoleLabel,5,0);
topLayout->addMultiCellWidget(mRoleCombo,5,5,1,2);
topLayout->addWidget(statusLabel,5,3);
topLayout->addMultiCellWidget(mStatusCombo,5,5,4,5);
topLayout->addMultiCellWidget(mAddressBookButton,2,2,4,5);
topLayout->addMultiCellWidget(mRsvpButton,2,2,0,1);
topLayout->addMultiCellWidget(buttonBox,3,4,5,5);
topLayout->setRowStretch(1,5);
topLayout->setColStretch(0,0);
}
// #if 0
// topLayout->setColStretch(2,1);
// topLayout->addWidget(statusLabel,3,3);
// topLayout->addWidget(mStatusCombo,3,4);
// #else
// topLayout->addWidget(statusLabel,4,3);
// // topLayout->addWidget(mStatusCombo,4,3);
// topLayout->addMultiCellWidget(mStatusCombo,4,4,4,5);
// #endif
// // topLayout->setRowStretch(5,1);
// topLayout->addMultiCellWidget(mRsvpButton,5,5,0,1);
// topLayout->addMultiCellWidget(buttonBox,2,3,5,5);
// topLayout->setRowStretch(1,5);
// topLayout->setColStretch(0,0);
#ifdef KORG_NOKABC
mAddressBookButton->hide();
#endif
updateAttendeeInput();
#ifndef DESKTOP_VERSION
diff --git a/korganizer/mainwindow.cpp b/korganizer/mainwindow.cpp
index 65566b5..46ae6a0 100644
--- a/korganizer/mainwindow.cpp
+++ b/korganizer/mainwindow.cpp
@@ -68,97 +68,100 @@ using namespace KCal;
#else
#include "koimportoldialog.h"
#endif
#include "mainwindow.h"
class KOex2phonePrefs : public QDialog
{
public:
KOex2phonePrefs( QWidget *parent=0, const char *name=0 ) :
QDialog( parent, name, true )
{
setCaption( i18n("Export to phone options") );
QVBoxLayout* lay = new QVBoxLayout( this );
lay->setSpacing( 3 );
lay->setMargin( 3 );
QLabel *lab;
lay->addWidget(lab = new QLabel( i18n("Please read Help-Sync Howto\nto know what settings to use."), this ) );
lab->setAlignment (AlignHCenter );
QHBox* temphb;
temphb = new QHBox( this );
new QLabel( i18n("I/O device: "), temphb );
mPhoneDevice = new QLineEdit( temphb);
lay->addWidget( temphb );
temphb = new QHBox( this );
new QLabel( i18n("Connection: "), temphb );
mPhoneConnection = new QLineEdit( temphb);
lay->addWidget( temphb );
temphb = new QHBox( this );
new QLabel( i18n("Model(opt.): "), temphb );
mPhoneModel = new QLineEdit( temphb);
lay->addWidget( temphb );
mWriteBackFuture= new QCheckBox( i18n("Write back events in future only"), this );
mWriteBackFuture->setChecked( true );
lay->addWidget( mWriteBackFuture );
temphb = new QHBox( this );
new QLabel( i18n("Max. weeks in future: ") , temphb );
mWriteBackFutureWeeks= new QSpinBox(1,104, 1, temphb);
mWriteBackFutureWeeks->setValue( 8 );
lay->addWidget( temphb );
lay->addWidget(lab = new QLabel( i18n("NOTE: This will remove all old\ntodo/calendar data on phone!"), this ) );
lab->setAlignment (AlignHCenter );
QPushButton * ok = new QPushButton( i18n("Export to mobile phone!"), this );
lay->addWidget( ok );
QPushButton * cancel = new QPushButton( i18n("Cancel"), this );
lay->addWidget( cancel );
connect ( ok,SIGNAL(clicked() ),this , SLOT ( accept() ) );
connect (cancel, SIGNAL(clicked() ), this, SLOT ( reject()) );
resize( 220, 240 );
-
+ qApp->processEvents();
+ int dw = QApplication::desktop()->width();
+ int dh = QApplication::desktop()->height();
+ move( (dw-width())/2, (dh - height() )/2 );
}
public:
QLineEdit* mPhoneConnection, *mPhoneDevice, *mPhoneModel;
QCheckBox* mWriteBackFuture;
QSpinBox* mWriteBackFutureWeeks;
};
int globalFlagBlockStartup;
MainWindow::MainWindow( QWidget *parent, const char *name, QString msg) :
QMainWindow( parent, name )
{
#ifdef DESKTOP_VERSION
setFont( QFont("Arial"), 14 );
#endif
mClosed = false;
//QString confFile = KStandardDirs::appDir() + "config/korganizerrc";
QString confFile = locateLocal("config","korganizerrc");
QFileInfo finf ( confFile );
bool showWarning = !finf.exists();
setIcon(SmallIcon( "ko24" ) );
mBlockAtStartup = true;
mFlagKeyPressed = false;
setCaption("KOrganizer/Pi");
KOPrefs *p = KOPrefs::instance();
KPimGlobalPrefs::instance()->setGlobalConfig();
if ( p->mHourSize > 18 )
p->mHourSize = 18;
QMainWindow::ToolBarDock tbd;
if ( p->mToolBarHor ) {
if ( p->mToolBarUp )
tbd = Bottom;
else
tbd = Top;
}
else {
if ( p->mToolBarUp )
tbd = Right;
else
tbd = Left;
}
if ( KOPrefs::instance()->mUseAppColors )
QApplication::setPalette( QPalette (KOPrefs::instance()->mAppColor1, KOPrefs::instance()->mAppColor2), true );
globalFlagBlockStartup = 1;
iconToolBar = new QPEToolBar( this );
addToolBar (iconToolBar , tbd );
mCalendarModifiedFlag = false;