Changeset 1825f82 in confclerk_git for src


Ignore:
Timestamp:
09/21/11 23:49:43 (11 years ago)
Author:
Philipp Spitzer <philipp@…>
Branches:
master, qt5
Children:
6d48bb2
Parents:
bf6be88
Message:

Implemented "unset dates" in the date navigator.

Location:
src/gui
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • src/gui/daynavigatorwidget.cpp

    rbf6be88 r1825f82  
    7272
    7373
     74void DayNavigatorWidget::unsetDates() {
     75    mStartDate= QDate();
     76    mEndDate = QDate();
     77    mCurDate = QDate();
     78
     79    configureNavigation();
     80    emit(dateChanged(mCurDate));
     81    this->update();
     82}
     83
     84
    7485void DayNavigatorWidget::configureNavigation() {
    7586    prevDayButton->setDisabled(!mStartDate.isValid() || mCurDate == mStartDate);
  • src/gui/daynavigatorwidget.h

    rbf6be88 r1825f82  
    3636        void setCurDate(const QDate& curDate);
    3737        QDate curDate() const {return mCurDate;}
     38        void unsetDates();
    3839    protected:
    3940        void paintEvent(QPaintEvent *);
  • src/gui/mainwindow.cpp

    rbf6be88 r1825f82  
    113113    }
    114114
    115     // TODO: open conferences at startup?
    116     #if 0
    117     if(!confCount)
    118         tabWidget->setCurrentIndex(6); // 6 - conference tab
    119     }
    120     #endif
    121 
    122115    // open dialog for given Event ID
    123116    // this is used in case Alarm Dialog request application to start
     
    215208        searchTabContainer->searchAgainClicked();
    216209        nowTabContainer->updateTreeView(QDate::currentDate());
     210        dayNavigator->setDates(startDate, endDate);
    217211    }
    218212}
     
    232226{
    233227    clearTabs();
     228    dayNavigator->unsetDates();
    234229    setWindowTitle(saved_title);
    235230}
  • src/gui/tabcontainer.cpp

    rbf6be88 r1825f82  
    4545    treeView->setItemDelegate(new Delegate(treeView));
    4646
    47     connect(dayNavigator, SIGNAL(dateChanged(const QDate &)), SLOT(updateTreeView(const QDate &)));
     47    // connect(dayNavigator, SIGNAL(dateChanged(const QDate &)), SLOT(updateTreeView(const QDate &)));
    4848
    4949    connect(treeView, SIGNAL(eventHasChanged(int,bool)), SIGNAL(eventHasChanged(int,bool)));
Note: See TracChangeset for help on using the changeset viewer.