author | zautrix <zautrix> | 2004-06-29 11:59:46 (UTC) |
---|---|---|
committer | zautrix <zautrix> | 2004-06-29 11:59:46 (UTC) |
commit | da43dbdc6c82453228f34766fc74585615cba938 (patch) (unidiff) | |
tree | 16576932cea08bf117b2d0320b0d5f66ee8ad093 /kaddressbook | |
parent | 627489ea2669d3997676bc3cee0f5d0d0c16c4d4 (diff) | |
download | kdepimpi-da43dbdc6c82453228f34766fc74585615cba938.zip kdepimpi-da43dbdc6c82453228f34766fc74585615cba938.tar.gz kdepimpi-da43dbdc6c82453228f34766fc74585615cba938.tar.bz2 |
New lib ical.Some minor changes as well.
-rw-r--r-- | kaddressbook/kabcore.cpp | 46 | ||||
-rw-r--r-- | kaddressbook/kabcore.h | 2 | ||||
-rw-r--r-- | kaddressbook/kaddressbookmain.cpp | 19 | ||||
-rw-r--r-- | kaddressbook/kaddressbookmain.h | 4 | ||||
-rw-r--r-- | kaddressbook/mainembedded.cpp | 8 |
5 files changed, 41 insertions, 38 deletions
diff --git a/kaddressbook/kabcore.cpp b/kaddressbook/kabcore.cpp index 3e578bc..70ab6b7 100644 --- a/kaddressbook/kabcore.cpp +++ b/kaddressbook/kabcore.cpp | |||
@@ -128,3 +128,3 @@ KABCore::KABCore( KXMLGUIClient *client, bool readWrite, QWidget *parent, const | |||
128 | #endif //KAB_EMBEDDED | 128 | #endif //KAB_EMBEDDED |
129 | 129 | mExtensionBarSplitter = 0; | |
130 | mIsPart = !parent->inherits( "KAddressBookMain" ); | 130 | mIsPart = !parent->inherits( "KAddressBookMain" ); |
@@ -225,3 +225,3 @@ void KABCore::restoreSettings() | |||
225 | setDetailsVisible( state ); | 225 | setDetailsVisible( state ); |
226 | QValueList<int> splitterSize = KABPrefs::instance()->mExtensionsSplitter; | 226 | QValueList<int> splitterSize = KABPrefs::instance()->mDetailsSplitter; |
227 | if ( splitterSize.count() == 0 ) { | 227 | if ( splitterSize.count() == 0 ) { |
@@ -231,2 +231,11 @@ void KABCore::restoreSettings() | |||
231 | mMiniSplitter->setSizes( splitterSize ); | 231 | mMiniSplitter->setSizes( splitterSize ); |
232 | if ( mExtensionBarSplitter ) { | ||
233 | splitterSize = KABPrefs::instance()->mExtensionsSplitter; | ||
234 | if ( splitterSize.count() == 0 ) { | ||
235 | splitterSize.append( width() / 2 ); | ||
236 | splitterSize.append( width() / 2 ); | ||
237 | } | ||
238 | mExtensionBarSplitter->setSizes( splitterSize ); | ||
239 | |||
240 | } | ||
232 | #ifndef KAB_EMBEDDED | 241 | #ifndef KAB_EMBEDDED |
@@ -259,5 +268,6 @@ void KABCore::saveSettings() | |||
259 | KABPrefs::instance()->mJumpButtonBarVisible = mActionJumpBar->isChecked(); | 268 | KABPrefs::instance()->mJumpButtonBarVisible = mActionJumpBar->isChecked(); |
260 | KABPrefs::instance()->mExtensionsSplitter = mMiniSplitter->sizes(); | 269 | if ( mExtensionBarSplitter ) |
270 | KABPrefs::instance()->mExtensionsSplitter = mExtensionBarSplitter->sizes(); | ||
261 | KABPrefs::instance()->mDetailsPageVisible = mActionDetails->isChecked(); | 271 | KABPrefs::instance()->mDetailsPageVisible = mActionDetails->isChecked(); |
262 | 272 | KABPrefs::instance()->mDetailsSplitter = mMiniSplitter->sizes(); | |
263 | #ifndef KAB_EMBEDDED | 273 | #ifndef KAB_EMBEDDED |
@@ -1145,3 +1155,17 @@ void KABCore::initGUI() | |||
1145 | 1155 | ||
1146 | 1156 | #ifdef DESKTOP_VERSION | |
1157 | topLayout = new QHBoxLayout( this ); | ||
1158 | |||
1159 | |||
1160 | mMiniSplitter = new KDGanttMinimizeSplitter( Qt::Horizontal, this); | ||
1161 | mMiniSplitter->setMinimizeDirection ( KDGanttMinimizeSplitter::Right ); | ||
1162 | |||
1163 | topLayout->addWidget(mMiniSplitter ); | ||
1164 | |||
1165 | mExtensionBarSplitter = new KDGanttMinimizeSplitter( Qt::Vertical,mMiniSplitter ); | ||
1166 | mExtensionBarSplitter->setMinimizeDirection ( KDGanttMinimizeSplitter::Down ); | ||
1167 | mViewManager = new ViewManager( this, mExtensionBarSplitter ); | ||
1168 | mDetails = new ViewContainer( mMiniSplitter ); | ||
1169 | mExtensionManager = new ExtensionManager( this, mExtensionBarSplitter ); | ||
1170 | #else | ||
1147 | if ( QApplication::desktop()->width() > 480 ) { | 1171 | if ( QApplication::desktop()->width() > 480 ) { |
@@ -1163,3 +1187,3 @@ void KABCore::initGUI() | |||
1163 | mExtensionManager = new ExtensionManager( this, mMiniSplitter ); | 1187 | mExtensionManager = new ExtensionManager( this, mMiniSplitter ); |
1164 | 1188 | #endif | |
1165 | //eh->hide(); | 1189 | //eh->hide(); |
@@ -1488,2 +1512,3 @@ void KABCore::addActionsManually() | |||
1488 | 1512 | ||
1513 | |||
1489 | if (QApplication::desktop()->width() > 320 ) { | 1514 | if (QApplication::desktop()->width() > 320 ) { |
@@ -1493,6 +1518,9 @@ void KABCore::addActionsManually() | |||
1493 | mViewManager->getFilterAction()->plug ( tb); | 1518 | mViewManager->getFilterAction()->plug ( tb); |
1494 | if (QApplication::desktop()->width() > 480 ) | 1519 | if (QApplication::desktop()->width() > 480 ) { |
1495 | mActionDelete->plug( tb ); | 1520 | mActionUndo->plug( tb ); |
1521 | mActionDelete->plug( tb ); | ||
1522 | mActionRedo->plug( tb ); | ||
1523 | } | ||
1496 | } | 1524 | } |
1497 | mActionQuit->plug ( tb ); | 1525 | //mActionQuit->plug ( tb ); |
1498 | // tb->insertWidget(-1, 0, mIncSearchWidget, 6); | 1526 | // tb->insertWidget(-1, 0, mIncSearchWidget, 6); |
diff --git a/kaddressbook/kabcore.h b/kaddressbook/kabcore.h index edf98c2..b84ec22 100644 --- a/kaddressbook/kabcore.h +++ b/kaddressbook/kabcore.h | |||
@@ -346,3 +346,3 @@ class KABCore : public QWidget | |||
346 | // QSplitter *mDetailsSplitter; | 346 | // QSplitter *mDetailsSplitter; |
347 | //QSplitter *mExtensionBarSplitter; | 347 | KDGanttMinimizeSplitter *mExtensionBarSplitter; |
348 | ViewContainer *mDetails; | 348 | ViewContainer *mDetails; |
diff --git a/kaddressbook/kaddressbookmain.cpp b/kaddressbook/kaddressbookmain.cpp index 92c32ca..8ebb93a 100644 --- a/kaddressbook/kaddressbookmain.cpp +++ b/kaddressbook/kaddressbookmain.cpp | |||
@@ -94,20 +94,3 @@ KAddressBookMain::~KAddressBookMain() | |||
94 | } | 94 | } |
95 | #ifndef DESKTOP_VERSION | 95 | |
96 | void KAddressBookMain::show () | ||
97 | { | ||
98 | static bool block = false; | ||
99 | if( block ) { | ||
100 | QWidget::show(); | ||
101 | return; | ||
102 | } else { | ||
103 | block = true ; | ||
104 | QWidget::showFullScreen(); | ||
105 | } | ||
106 | int min = 20; | ||
107 | if ( QApplication::desktop()->width() > 320 ) | ||
108 | min += 20; | ||
109 | setGeometry( 0,0,QApplication::desktop()->width(), QApplication::desktop()->height() - min ); | ||
110 | block = false; | ||
111 | } | ||
112 | #endif | ||
113 | void KAddressBookMain::showMinimized () | 96 | void KAddressBookMain::showMinimized () |
diff --git a/kaddressbook/kaddressbookmain.h b/kaddressbook/kaddressbookmain.h index 81ae09c..cf6f899 100644 --- a/kaddressbook/kaddressbookmain.h +++ b/kaddressbook/kaddressbookmain.h | |||
@@ -72,6 +72,2 @@ class KAddressBookMain : public KMainWindow, virtual public KAddressBookIface | |||
72 | public slots: | 72 | public slots: |
73 | #ifndef DESKTOP_VERSION | ||
74 | void show(); | ||
75 | #endif | ||
76 | |||
77 | void showMinimized () ; | 73 | void showMinimized () ; |
diff --git a/kaddressbook/mainembedded.cpp b/kaddressbook/mainembedded.cpp index ffa37a5..3f6f69d 100644 --- a/kaddressbook/mainembedded.cpp +++ b/kaddressbook/mainembedded.cpp | |||
@@ -70,8 +70,4 @@ int main( int argc, char **argv ) | |||
70 | a.showMainWidget(m ); | 70 | a.showMainWidget(m ); |
71 | m->showFullScreen(); | 71 | m->showMaximized(); |
72 | int min = 20; | 72 | |
73 | if ( QApplication::desktop()->width() > 320 ) | ||
74 | min += 20; | ||
75 | m->setGeometry( 0,0,QApplication::desktop()->width(), QApplication::desktop()->height() - min ); | ||
76 | |||
77 | #else | 73 | #else |