~ubuntu-clock-dev/ubuntu-clock-app/reboot-packaging

« back to all changes in this revision

Viewing changes to backend/modules/DateTime/backend.cpp

  • Committer: Nekhelesh Ramananthan
  • Date: 2014-07-26 09:34:15 UTC
  • mto: (37.1.1 reboot)
  • mto: This revision was merged to the branch mainline in revision 37.
  • Revision ID: krnekhelesh@gmail.com-20140726093415-67r3x357o0fnq08n
Initial working version

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
/*
 
2
 * Copyright (C) 2014 Canonical Ltd
 
3
 *
 
4
 * This file is part of Ubuntu Clock App
 
5
 *
 
6
 * Ubuntu Clock App is free software: you can redistribute it and/or modify
 
7
 * it under the terms of the GNU General Public License version 3 as
 
8
 * published by the Free Software Foundation.
 
9
 *
 
10
 * Ubuntu Clock App is distributed in the hope that it will be useful,
 
11
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 
12
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 
13
 * GNU General Public License for more details.
 
14
 *
 
15
 * You should have received a copy of the GNU General Public License
 
16
 * along with this program.  If not, see <http://www.gnu.org/licenses/>.
 
17
 */
 
18
 
 
19
#include <QtQml>
 
20
#include <QtQml/QQmlContext>
 
21
#include "backend.h"
 
22
#include "datetime.h"
 
23
 
 
24
void BackendPlugin::registerTypes(const char *uri)
 
25
{
 
26
    Q_ASSERT(uri == QLatin1String("DateTime"));
 
27
 
 
28
    qmlRegisterType<DateTime>(uri, 1, 0, "DateTime");
 
29
}
 
30
 
 
31
void BackendPlugin::initializeEngine(QQmlEngine *engine, const char *uri)
 
32
{
 
33
    QQmlExtensionPlugin::initializeEngine(engine, uri);
 
34
}