bitcoin-core / gui-qml

Bitcoin GUI (experimental QML-based fork)
MIT License
111 stars 40 forks source link

DRAFT: Custom data directory support #273

Closed jarolrod closed 1 week ago

jarolrod commented 1 year ago

Opened to showcase initial support. Lacks system settings wiring.

Dark Light
Screen Shot 2023-02-22 at 3 37 32 AM Screen Shot 2023-02-22 at 3 36 54 AM

Windows Intel macOS Apple Silicon macOS ARM64 Android

hebasto commented 1 year ago

Here is the error output for the android apk

...libbitcoin-qt_arm64-v8a.so: qrc:/qt-project.org/imports/QtQuick/Dialogs/DefaultFileDialog.qml:45:1: module "QtQuick.Dialogs.Private" is not installed                             

It looks like expected considering https://github.com/bitcoin-core/gui-qml/blob/1e9981df75b559596e8f9386858ec3f147124634/src/qml/bitcoin.cpp#L55-L57

hebasto commented 1 year ago

Maybe

diff --git a/build-aux/m4/bitcoin_qt.m4 b/build-aux/m4/bitcoin_qt.m4
index e12d2efa6..5b1a133c1 100644
--- a/build-aux/m4/bitcoin_qt.m4
+++ b/build-aux/m4/bitcoin_qt.m4
@@ -236,6 +236,7 @@ AC_DEFUN([BITCOIN_QT_CONFIGURE],[
         _BITCOIN_QT_CHECK_STATIC_PLUGIN([QtQuickLayoutsPlugin], [-lqml_QtQuick_Layouts_qquicklayoutsplugin])
         dnl qtquickcontrols module plugins
         _BITCOIN_QT_CHECK_STATIC_PLUGIN([QtQuick2DialogsPlugin], [-lqml_QtQuick_Dialogs_dialogplugin])
+        _BITCOIN_QT_CHECK_STATIC_PLUGIN([QtQuick2DialogsPrivatePlugin], [-lqml_QtQuick_Dialogs_Private_dialogsprivateplugin])
         _BITCOIN_QT_CHECK_STATIC_PLUGIN([QtQuickControls1Plugin], [-lqml_QtQuick_Controls_qtquickcontrolsplugin])
         _BITCOIN_QT_CHECK_STATIC_PLUGIN([QmlFolderListModelPlugin], [-lqml_Qt_labs_folderlistmodel_qmlfolderlistmodelplugin])
         _BITCOIN_QT_CHECK_STATIC_PLUGIN([QmlSettingsPlugin], [-lqml_Qt_labs_settings_qmlsettingsplugin])
diff --git a/src/qml/bitcoin.cpp b/src/qml/bitcoin.cpp
index 55a1e152d..288a88b42 100644
--- a/src/qml/bitcoin.cpp
+++ b/src/qml/bitcoin.cpp
@@ -52,9 +52,7 @@ QT_END_NAMESPACE
 Q_IMPORT_PLUGIN(QtQmlPlugin)
 Q_IMPORT_PLUGIN(QtQmlModelsPlugin)
 Q_IMPORT_PLUGIN(QtQuick2DialogsPlugin)
-#ifndef QT_QPA_PLATFORM_ANDROID
 Q_IMPORT_PLUGIN(QtQuick2DialogsPrivatePlugin)
-#endif
 Q_IMPORT_PLUGIN(QtQuick2Plugin)
 Q_IMPORT_PLUGIN(QtQuick2WindowPlugin)
 Q_IMPORT_PLUGIN(QtQuickControls1Plugin)

?

hebasto commented 1 year ago

Need rebase.

When undraft? :)

jarolrod commented 1 year ago

rebased over main

pablomartin4btc commented 6 months ago

Since we have already #390, do still we need this PR? Does @D33r-Gee need to incorporate anything from here?

jarolrod commented 1 week ago

replaced by https://github.com/bitcoin-core/gui-qml/pull/408