--- /dev/null
+--- a/QtADB.pro 2018-03-17 12:44:50.933918102 -0400
++++ b/QtADB.pro 2018-03-17 12:46:04.896502772 -0400
+@@ -14,11 +14,13 @@
+ # limitations under the License.\r
+ #\r
+ # @author Jakub Motyczko\r
+ # -------------------------------------------------\r
+ QT += network\r
+-QT += declarative\r
++QT += widgets\r
++QT += qml\r
++QT += quick\r
+ TARGET = QtADB\r
+ \r
+ TEMPLATE = app\r
+ SOURCES += main.cpp \\r
+ ./dialogs/mainwindow.cpp \\r
+--- a/widgets/messagewidget.h 2018-03-17 12:48:28.691864775 -0400
++++ b/widgets/messagewidget.h 2018-03-17 12:49:55.190870634 -0400
+@@ -21,12 +21,13 @@
+ #ifndef MESSAGEWIDGET_H\r
+ #define MESSAGEWIDGET_H\r
+ \r
+ #include <QtGui>\r
+ #include <QtNetwork>\r
++#include <QtWidgets>\r
++#include <QQmlContext>\r
++#include <QQuickView>\r
+-#include <QDeclarativeView>\r
+-#include <QDeclarativeContext>\r
+ \r
+ #include "../classes/models/messagethreadmodel.h"\r
+ #include "../classes/models/contactmodel.h"\r
+ \r
+ \r
+@@ -46,12 +49,12 @@
+ protected:\r
+ void changeEvent(QEvent *e);\r
+ \r
+ private:\r
+ Ui::MessageWidget *ui;\r
+- QDeclarativeView *qmlView;\r
+- QDeclarativeContext *qmlViewCtx;\r
++ QQuickView *qmlView;\r
++ QQmlContext *qmlViewCtx;\r
+ \r
+ MessageModel messageModel;\r
+ MessageThreadModel messageThreadModel;\r
+ ContactModel contactModel;\r
+ QSortFilterProxyModel sortModel;\r
+--- a/widgets/appwidget.h 2018-03-17 12:58:56.731870593 -0400
++++ b/widgets/appwidget.h 2018-03-17 13:03:39.366822784 -0400
+@@ -20,10 +20,11 @@
+ \r
+ #ifndef APPWIDGET_H\r
+ #define APPWIDGET_H\r
+ \r
+ #include <QtGui>\r
++#include <QtWidgets>\r
+ \r
+ #include "../classes/phone.h"\r
+ #include "../classes/computer.h"\r
+ #include "../dialogs/appinfo.h"\r
+ #include "../dialogs/appdialog.h"\r
+--- a/widgets/messagewidget.cpp 2018-03-17 16:34:54.003310530 -0400
++++ b/widgets/messagewidget.cpp 2018-03-17 16:34:14.545124690 -0400
+@@ -51,11 +51,11 @@
+ this->sortContactModel.setSortRole(ContactModel::NameRole);\r
+ this->sortContactModel.sort(0, Qt::AscendingOrder);\r
+ \r
+ this->messageCount=0;\r
+ \r
+- this->qmlView = new QDeclarativeView;\r
++ this->qmlView = new QQuickView;\r
+ this->qmlViewCtx = this->qmlView->rootContext();\r
+ if (QFile::exists("qml/messageView.qml"))\r
+ this->qmlView->setSource(QUrl::fromLocalFile("qml/messageView.qml"));\r
+ else\r
+ //this->qmlView->setSource(QUrl::fromLocalFile("../messages/qml/messageView.qml"));\r
+@@ -63,15 +63,17 @@
+ this->qmlViewCtx->setContextProperty("threadModel", &sortThreadModel);\r
+ this->qmlViewCtx->setContextProperty("contactModel", &sortContactModel);\r
+ this->qmlViewCtx->setContextProperty("messageModel", &sortModel);\r
+ this->qmlViewCtx->setContextProperty("myNickname", "Me");\r
+ this->qmlViewCtx->setContextProperty("contactDefault", "qrc:/icons/contactDefault.png");\r
+- qmlView->setResizeMode(QDeclarativeView::SizeRootObjectToView);\r
+-\r
++ qmlView->setResizeMode(QQuickView::SizeRootObjectToView);\r
++ \r
+ this->qmlViewCtx->setContextProperty("messageWidget", this);\r
++ QWidget *container = QWidget::createWindowContainer(qmlView, this);\r
++ container->setFocusPolicy(Qt::TabFocus);\r
+ \r
+- ui->layoutMessages->addWidget(this->qmlView,1,1);\r
++ ui->layoutMessages->addWidget(container);\r
+ \r
+ //QSettings settings;\r
+ //this->sdk = settings.value("sdkPath").toString();\r
+ this->tcpServer.listen(QHostAddress::Any,4445);\r
+ \r
--- /dev/null
+# Copyright 1999-2018 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=6
+
+COMMIT=ccbb0c86c9eb
+inherit desktop qmake-utils readme.gentoo-r1
+
+DESCRIPTION="Android phone manager via ADB"
+HOMEPAGE="https://qtadb.wordpress.com"
+SRC_URI="https://bitbucket.org/michalmotyczko/${PN}/get/${COMMIT}.zip -> ${P}.zip"
+
+LICENSE="Apache-2.0"
+SLOT="0"
+KEYWORDS="~amd64 ~x86"
+IUSE=""
+
+RDEPEND="
+ dev-qt/qtcore:5
+ dev-qt/qtdeclarative:5
+ dev-qt/qtgui:5
+ dev-qt/qtnetwork:5
+ dev-qt/qtwidgets:5
+"
+DEPEND="${RDEPEND}
+ app-arch/unzip
+"
+
+PATCHES=( "${FILESDIR}"/${P}-qt5.patch )
+
+S="${WORKDIR}/michalmotyczko-${PN}-${COMMIT}"
+
+src_configure() {
+ eqmake5
+}
+
+src_install() {
+ newicon images/android.png ${PN}.png
+ make_desktop_entry QtADB QtADB ${PN} \
+ "Qt;PDA;Utility;" || ewarn "Desktop entry creation failed"
+ dobin QtADB
+
+ local DOC_CONTENTS="
+You will need a working Android SDK installation (adb and aapt executables)
+You can install Android SDK a) through portage (emerge android-sdk-update-manager
+and run android to download the actual sdk), b) manually from
+http://developer.android.com/sdk/index.html or c) just grab the adb, aapt linux
+binaries from http://qtadb.wordpress.com/download/
+adb and aapt executables are in the platform-tools subdir of Android SDK. You
+must run QtADB from this directory as a user able to write a log file in this
+directory.
+
+Also you will need to have ROOT access to your phone along with busybox
+The latter can be found in the Android market
+
+Last, if you want to use the SMS manager of QtADB, you have to install
+QtADB.apk to your device, available here: http://qtadb.wordpress.com/download/
+
+If you have trouble getting your phone connected through usb (driver problem),
+try adbWireless from Android market to get connected through WiFi
+"
+ readme.gentoo_create_doc
+}