Ignore:
Timestamp:
06/12/12 22:26:48 (10 years ago)
Author:
Philipp Spitzer <philipp@…>
Branches:
master, qt5
Children:
56307f8
Parents:
6bf226b
Message:

The groups starts at full hours again.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/mvc/eventmodel.cpp

    r6bf226b r8f15208  
    4949    if (mEvents.empty()) return;
    5050
    51     const int minTimeSpan = 3600; // one hour // minimum duration of a group
     51    const int minTimeSpan = 3600; // one hour // minimum duration of a group in seconds
    5252    const int minChildCount = 3;  // minimum number of events in one group
    5353
    54     // Create the first time group. The events have to be sorted by start time at this point!
    55     //    Remarks for the following non-comment line:
    56     //    * As it is right now it could be written as
    57     //      QDateTime groupStartDateTime = mEvents.first().start();
    58     //    * Before r1444 the minutes were set to zero so that the time groups started at
    59     //      whole hours.
    60 
    61     // QDateTime groupStartDateTime(mEvents.first().start().date(), QTime(mEvents.first().start().time().hour(), 0));
    62     QDateTime groupStartDateTime = mEvents.first().start();
     54    QDateTime groupStartDateTime(mEvents.first().start().date(), QTime(mEvents.first().start().time().hour(), 0), mEvents.first().start().timeSpec());
    6355    QDateTime groupEndDateTime = groupStartDateTime.addSecs(mEvents.first().duration());
    6456    mGroups << EventModel::Group("", 0);
Note: See TracChangeset for help on using the changeset viewer.