~ubuntu-branches/ubuntu/natty/knemo/natty

« back to all changes in this revision

Viewing changes to src/knemod/syncstats/externalstats.cpp

  • Committer: Bazaar Package Importer
  • Author(s): Felix Geyer
  • Date: 2011-02-22 16:36:22 UTC
  • mfrom: (1.1.13 upstream)
  • Revision ID: james.westby@ubuntu.com-20110222163622-d8i62gy1stn7tydv
Tags: 0.7.0-0ubuntu1
* New upstream release.
* Switch to source format 3.0 (quilt).
* Make knemo depend on libqt4-sql-sqlite.

Show diffs side-by-side

added added

removed removed

Lines of Context:
21
21
#include "statisticsmodel.h"
22
22
#include "interface.h"
23
23
 
24
 
ExternalStats::ExternalStats( Interface * interface, QObject * parent )
 
24
#include <KCalendarSystem>
 
25
 
 
26
ExternalStats::ExternalStats( Interface * interface, KCalendarSystem * calendar, QObject * parent )
25
27
    : QObject( parent ),
26
28
      mInterface( interface ),
27
29
      mExternalDays( 0 ),
28
30
      mExternalHours( 0 )
29
31
{
30
 
    mExternalHours = new StatisticsModel( StatisticsModel::Hour );
 
32
    mExternalHours = new StatisticsModel( KNemoStats::Hour );
31
33
    mExternalHours->setSortRole( StatisticsModel::DataRole );
32
 
    mExternalDays = new StatisticsModel( StatisticsModel::Day );
 
34
    mExternalDays = new StatisticsModel( KNemoStats::Day );
33
35
    mExternalDays->setSortRole( StatisticsModel::DataRole );
34
 
    KCalendarSystem * calendar = KCalendarSystem::create( mInterface->getSettings().calendar );
35
36
    mExternalHours->setCalendar( calendar );
36
37
    mExternalDays->setCalendar( calendar );
37
38
}