-rw-r--r-- | korganizer/mainwindow.cpp | 16 |
1 files changed, 13 insertions, 3 deletions
diff --git a/korganizer/mainwindow.cpp b/korganizer/mainwindow.cpp index c6ae868..a4e0834 100644 --- a/korganizer/mainwindow.cpp +++ b/korganizer/mainwindow.cpp @@ -193,9 +193,12 @@ MainWindow::MainWindow( QWidget *parent, const char *name, QString msg) : filterToolBar = 0; filterMenubar = 0; filterPopupMenu = 0; } - + if ( p->mShowIconOnetoolbar ) { + viewToolBar = iconToolBar ; + navigatorToolBar = iconToolBar ; + } else { if ( p->mToolBarHorV ) { if ( p->mToolBarUpV ) tbd = Bottom; else @@ -222,9 +225,9 @@ MainWindow::MainWindow( QWidget *parent, const char *name, QString msg) : tbd = Left; } navigatorToolBar = new QPEToolBar( this ); addToolBar (navigatorToolBar , tbd ); - + } mCalendarModifiedFlag = false; @@ -692,8 +695,9 @@ void MainWindow::initActions() actionMenu->insertSeparator(); icon = loadPixmap( pathString + "newevent" ); configureToolBarMenu->insertItem(i18n("Stretched TB"), 5 ); + configureToolBarMenu->insertItem(i18n("Only one toolbar"), 6 ); configureToolBarMenu->insertSeparator(); configureToolBarMenu->insertItem(i18n("Filtermenu"), 7 ); configureToolBarMenu->insertSeparator(); configureToolBarMenu->insertItem(i18n("Week Number"), 400); @@ -1192,8 +1196,10 @@ void MainWindow::initActions() configureToolBarMenu->setItemChecked( 5, true ); } if (p-> mShowIconFilter) configureToolBarMenu->setItemChecked( 7, true ); + if (p-> mShowIconOnetoolbar) + configureToolBarMenu->setItemChecked( 6, true ); if ( filterMenubar ) connect( mView->filterView(), SIGNAL( filterChanged() ), SLOT( updateFilterToolbar() ) ); @@ -1953,10 +1959,13 @@ void MainWindow::selectFilter( int fil ) } else if ( fil == 1 ){ if ( mView->filterView()->filtersEnabled() ) mView->toggleFilerEnabled( ); } else { - if ( !mView->filterView()->filtersEnabled() ) + if ( !mView->filterView()->filtersEnabled() ) { + mView->filterView()->blockSignals( true ); mView->toggleFilerEnabled( ); + mView->filterView()->blockSignals( false ); + } mView->selectFilter( fil-2 ); } } void MainWindow::updateFilterToolbar() @@ -1982,8 +1991,9 @@ void MainWindow::configureToolBar( int item ) configureToolBarMenu->setItemChecked( item, !configureToolBarMenu-> isItemChecked ( item ) ); KOPrefs *p = KOPrefs::instance(); p-> mShowIconStretch= configureToolBarMenu->isItemChecked( 5 ); + p-> mShowIconOnetoolbar = configureToolBarMenu->isItemChecked( 6 ); p-> mShowIconFilter = configureToolBarMenu->isItemChecked( 7 ); p-> mShowIconNewEvent= configureToolBarMenu->isItemChecked( 10 ); p->mShowIconNewTodo = configureToolBarMenu->isItemChecked( 20 ); p-> mShowIconSearch= configureToolBarMenu->isItemChecked( 120 ); |