summaryrefslogtreecommitdiff
path: root/app/pebble.cpp
diff options
context:
space:
mode:
authorTomasz Sterna <tomek@xiaoka.com>2015-04-17 15:59:39 +0200
committerTomasz Sterna <tomek@xiaoka.com>2015-04-17 15:59:39 +0200
commit8bb7a35eedd431f707ca6fb9134c35bace8e4b24 (patch)
treeb9ee5787397604c198b5630197e995219203518d /app/pebble.cpp
parent453e9ea4ea8d56ad84c2329cb95f1dfed279be95 (diff)
Disclaimer page
Diffstat (limited to 'app/pebble.cpp')
-rw-r--r--app/pebble.cpp38
1 files changed, 7 insertions, 31 deletions
diff --git a/app/pebble.cpp b/app/pebble.cpp
index 04ff6a8..804a85e 100644
--- a/app/pebble.cpp
+++ b/app/pebble.cpp
@@ -1,35 +1,5 @@
-/*
- Copyright (C) 2014 Jouni Roivas
- Copyright (C) 2013 Jolla Ltd.
- Contact: Thomas Perl <thomas.perl@jollamobile.com>
- All rights reserved.
-
- You may use this file under the terms of BSD license as follows:
-
- Redistribution and use in source and binary forms, with or without
- modification, are permitted provided that the following conditions are met:
- * Redistributions of source code must retain the above copyright
- notice, this list of conditions and the following disclaimer.
- * Redistributions in binary form must reproduce the above copyright
- notice, this list of conditions and the following disclaimer in the
- documentation and/or other materials provided with the distribution.
- * Neither the name of the authors nor the
- names of its contributors may be used to endorse or promote products
- derived from this software without specific prior written permission.
-
- THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
- ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
- WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDERS OR CONTRIBUTORS BE LIABLE FOR
- ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
- (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
- LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
- SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-*/
-
#include <QtQuick>
+#include <QQmlPropertyMap>
#include <sailfishapp.h>
#include "pebbledinterface.h"
@@ -37,6 +7,8 @@
#include "pebblefirmware.h"
#include "pebblestoreview.h"
+const char DONATE_URL[] = "https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=MAGN86VCARBSA";
+
int main(int argc, char *argv[])
{
QScopedPointer<QGuiApplication> app(SailfishApp::application(argc, argv));
@@ -56,10 +28,14 @@ int main(int argc, char *argv[])
QScopedPointer<PebbledInterface> pebbled(new PebbledInterface);
QScopedPointer<PebbleAppIconProvider> appicons(new PebbleAppIconProvider(pebbled.data()));
QScopedPointer<PebbleFirmware> firmware(new PebbleFirmware);
+ QScopedPointer<QQmlPropertyMap> donate(new QQmlPropertyMap);
+
+ donate->insert("url", QString(DONATE_URL));
view->rootContext()->setContextProperty("APP_VERSION", APP_VERSION);
view->rootContext()->setContextProperty("pebbled", pebbled.data());
view->rootContext()->setContextProperty("pebbleFirmware", firmware.data());
+ view->rootContext()->setContextProperty("donate", donate.data());
view->engine()->addImageProvider("pebble-app-icon", appicons.data());
view->setSource(SailfishApp::pathTo("qml/pebble.qml"));
view->show();