mirror of
https://gitlab.linphone.org/BC/public/linphone-desktop.git
synced 2026-01-29 01:39:19 +00:00
feat(app): try to extract style from component (unstable)
This commit is contained in:
parent
6fceeeb12e
commit
ab21a4e5d9
5 changed files with 14 additions and 5 deletions
|
|
@ -33,6 +33,7 @@ lupdate_only{
|
|||
ui/components/scrollBar/*.qml \
|
||||
ui/components/select/*.qml \
|
||||
ui/components/timeline/*.qml \
|
||||
ui/style/collapse/*.qml \
|
||||
ui/views/*.qml \
|
||||
ui/views/mainWindow/*.qml
|
||||
}
|
||||
|
|
|
|||
|
|
@ -33,6 +33,8 @@
|
|||
<file>ui/components/form/DarkButton.qml</file>
|
||||
<file>ui/components/invertedMouseArea/InvertedMouseArea.qml</file>
|
||||
<file>ui/scripts/utils.js</file>
|
||||
<file>ui/style/qmldir</file>
|
||||
<file>ui/style/collapse/Style.qml</file>
|
||||
<file>ui/views/newCall.qml</file>
|
||||
<file>ui/views/manageAccounts.qml</file>
|
||||
<file>ui/views/mainWindow/mainWindow.qml</file>
|
||||
|
|
|
|||
|
|
@ -1,5 +1,6 @@
|
|||
#include <cstdlib>
|
||||
|
||||
#include <QQmlFileSelector>
|
||||
#include <QMenu>
|
||||
#include <QQmlApplicationEngine>
|
||||
#include <QQmlContext>
|
||||
|
|
@ -46,9 +47,15 @@ void setTrayIcon (QQmlApplicationEngine &engine) {
|
|||
}
|
||||
|
||||
int main (int argc, char *argv[]) {
|
||||
QGuiApplication::setAttribute(Qt::AA_EnableHighDpiScaling);
|
||||
App app(argc, argv);
|
||||
QQmlApplicationEngine engine(QUrl("qrc:/ui/views/mainWindow/mainWindow.qml"));
|
||||
QQmlApplicationEngine engine;
|
||||
|
||||
// Provide `+custom` folders for custom components.
|
||||
QQmlFileSelector *selector = new QQmlFileSelector(&engine);
|
||||
selector->setExtraSelectors(QStringList("custom"));
|
||||
|
||||
engine.load(QUrl("qrc:/ui/views/mainWindow/mainWindow.qml"));
|
||||
if (engine.rootObjects().isEmpty())
|
||||
return EXIT_FAILURE;
|
||||
|
||||
|
|
|
|||
|
|
@ -3,6 +3,8 @@ import QtQuick 2.7
|
|||
import 'qrc:/ui/components/form'
|
||||
import 'qrc:/ui/components/image'
|
||||
|
||||
import 'qrc:/ui/style' as Style
|
||||
|
||||
// ===================================================================
|
||||
|
||||
Item {
|
||||
|
|
@ -18,9 +20,7 @@ Item {
|
|||
|
||||
ActionButton {
|
||||
anchors.centerIn: parent
|
||||
background: Rectangle {
|
||||
color: 'transparent'
|
||||
}
|
||||
background: Style.CollapseStyle.background
|
||||
icon: 'collapse'
|
||||
iconSize: 32
|
||||
id: button
|
||||
|
|
|
|||
|
|
@ -17,7 +17,6 @@ Item {
|
|||
}
|
||||
|
||||
_mouseArea.parent = (function () {
|
||||
// Search root.
|
||||
var root = item
|
||||
|
||||
while (root.parent != null) {
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue