From 041eda0d7482d60cd67731b81fd36104fcd3120f Mon Sep 17 00:00:00 2001 From: zecke Date: Sun, 23 Feb 2003 21:27:08 +0000 Subject: Implement some of the new framework --- (limited to 'core/pim/datebook2/view.cpp') diff --git a/core/pim/datebook2/view.cpp b/core/pim/datebook2/view.cpp new file mode 100644 index 0000000..b07c89a --- a/dev/null +++ b/core/pim/datebook2/view.cpp @@ -0,0 +1,62 @@ + +#include + +#include "bookmanager.h" +#include "mainwindow.h" +#include "view.h" + +using namespace Datebook; + +View::View( MainWindow* window, QWidget* ) { + m_win = window; +} +View::~View() { +} +QDate View::dateFromWeek( int week, int year, bool startOnMon ) { + +} +bool View::calcWeek( const QDate& d, int & week, int & year, bool ) { + +} +void View::loadConfig( Config* conf ) { + doLoadConfig( conf ); +} +void View::saveConfig( Config* conf ) { + doSaveConfig( conf ); +} +void View::popup( int uid ) { + m_win->viewPopup( uid ); +} +void View::add( const QDate& start ) { + m_win->viewAdd( start ); +} +void View::add( const QDateTime& start, const QDateTime& end ) { + m_win->viewAdd( start, end ); +} +void View::edit( int uid ) { + m_win->edit( uid ); +} +void View::remove( int uid ) { + m_win->remove( uid ); +} +ODateBookAccess::List View::allEvents() const{ + return m_win->manager()->allRecords(); +} +OEffectiveEvent::ValueList View::events( const QDate& from, const QDate& to ) { + return m_win->manager()->list( from, to ); +} +OEvent View::event( int uid ) const{ + return m_win->manager()->event( uid ); +} +bool View::isAP()const { + return m_win->viewAP(); +} +bool View::weekStartOnMonday()const { + return m_win->viewStartMonday(); +} +QList View::records( const QDate& on ) { + return m_win->manager()->records( on, on ); +} +QList View::records( const QDate& on, const QDate& to ) { + return m_win->manager()->records( on, to ); +} -- cgit v0.9.0.2