mirror of
https://github.com/monero-project/monero-gui.git
synced 2025-04-03 12:49:04 +00:00
Merge e19934a799
into 47f0047c9f
This commit is contained in:
commit
87ddfd1962
107 changed files with 771 additions and 667 deletions
.github
CMakeLists.txtDockerfile.androidDockerfile.linuxDockerfile.windowsLeftPanel.qmlMakefileMiddlePanel.qmlREADME.mdcmake
components
CMakeLists.txtCheckBox2.qmlDaemonManagerDialog.qmlDatePicker.qmlInlineButton.qmlInputDialog.qmlLanguageSidebar.qmlLineEdit.qmlMenuButton.qmlPasswordDialog.qmlProcessingSplash.qmlRemoteNodeDialog.qmlRemoteNodeEdit.qmlStandardDialog.qmlStandardDropdown.qmlSuccessfulTxDialog.qmlTitleBar.qmlTxConfirmationDialog.qml
effects
fonts
images
installers/windows
js
main.qmlpages
Account.qmlAddressBook.qmlAdvanced.qmlCMakeLists.txtHistory.qmlKeys.qmlMining.qmlReceive.qmlSharedRingDB.qmlSign.qmlTransfer.qmlTxKey.qml
qtquickcontrols2.confmerchant
settings
src
translations
wizard
CMakeLists.txtWizardAskPassword.qmlWizardController.qmlWizardCreateDevice1.qmlWizardCreateWallet1.qmlWizardCreateWallet2.qmlWizardCreateWallet3.qmlWizardCreateWallet4.qmlWizardCreateWallet5.qmlWizardDaemonSettings.qmlWizardHeader.qmlWizardHome.qmlWizardLanguage.qmlWizardMenuItem.qmlWizardModeBootstrap.qmlWizardModeRemoteNodeWarning.qmlWizardModeSelection.qmlWizardNav.qmlWizardOpenWallet1.qml
10
.github/qt_helper.py
vendored
10
.github/qt_helper.py
vendored
|
@ -14,7 +14,7 @@ MAX_TRIES = 32
|
|||
def fetch_links_to_archives(os, target, major, minor, patch, toolchain):
|
||||
MAX_XML_SIZE = 1024 * 1024 * 1024
|
||||
MIRROR = 'download.qt.io'
|
||||
base_url = f'https://{MIRROR}/online/qtsdkrepository/{os}/{target}/qt{major}_{major}{minor}{patch}'
|
||||
base_url = f'https://{MIRROR}/online/qtsdkrepository/{os}/{target}/qt{major}_{major}{minor}{patch}/qt{major}_{major}{minor}{patch}'
|
||||
url = f'{base_url}/Updates.xml'
|
||||
for _ in range(MAX_TRIES):
|
||||
try:
|
||||
|
@ -31,7 +31,11 @@ def fetch_links_to_archives(os, target, major, minor, patch, toolchain):
|
|||
name = pkg.find('.//Name')
|
||||
if name == None:
|
||||
continue
|
||||
if name.text != f'qt.qt{major}.{major}{minor}{patch}.{toolchain}':
|
||||
if name.text not in [
|
||||
f'qt.qt{major}.{major}{minor}{patch}.{toolchain}',
|
||||
f"qt.qt{major}.{major}{minor}{patch}.addons.qt5compat.{toolchain}",
|
||||
f"qt.qt{major}.{major}{minor}{patch}.addons.qtshadertools.{toolchain}"
|
||||
]:
|
||||
continue
|
||||
version = pkg.find('.//Version')
|
||||
if version == None:
|
||||
|
@ -100,7 +104,7 @@ def main():
|
|||
result = calc_hash_sum([l['name'] for l in links])
|
||||
print('result', result, 'expect', expect, flush=True)
|
||||
assert result == expect
|
||||
assert extract_archives([l['name'] for l in links], '.', ['{}.{}.{}'.format(major, minor, patch)])
|
||||
assert extract_archives([l['name'] for l in links], '{}.{}.{}'.format(major, minor, patch))
|
||||
[pathlib.Path(l['name']).unlink() for l in links]
|
||||
|
||||
if __name__ == '__main__':
|
||||
|
|
18
.github/workflows/build.yml
vendored
18
.github/workflows/build.yml
vendored
|
@ -4,7 +4,7 @@ on: [push, pull_request]
|
|||
|
||||
env:
|
||||
FREE_DISKSPACE: |
|
||||
sudo rm -rf /usr/local/.ghcup /usr/share/dotnet /usr/share/swift /usr/share/miniconda
|
||||
sudo rm -rf /usr/local/.ghcup /usr/share/dotnet /usr/share/swift /usr/share/miniconda /usr/local/lib/android /opt/hostedtoolcache
|
||||
|
||||
jobs:
|
||||
build-macos:
|
||||
|
@ -14,7 +14,7 @@ jobs:
|
|||
with:
|
||||
submodules: recursive
|
||||
- name: install dependencies
|
||||
run: HOMEBREW_NO_AUTO_UPDATE=1 brew install boost hidapi openssl zmq libpgm libsodium miniupnpc expat libunwind-headers protobuf qt5 pkg-config
|
||||
run: HOMEBREW_NO_AUTO_UPDATE=1 brew install boost hidapi openssl zmq libpgm libsodium miniupnpc expat libunwind-headers protobuf qt6 pkg-config
|
||||
- name: build
|
||||
run: DEV_MODE=ON make release -j3
|
||||
- name: test qml
|
||||
|
@ -38,7 +38,7 @@ jobs:
|
|||
- name: install monero dependencies
|
||||
run: sudo apt -y install build-essential cmake libboost-all-dev miniupnpc libunbound-dev graphviz doxygen libunwind8-dev pkg-config libssl-dev libzmq3-dev libsodium-dev libhidapi-dev libnorm-dev libusb-1.0-0-dev libpgm-dev libprotobuf-dev protobuf-compiler
|
||||
- name: install monero gui dependencies
|
||||
run: sudo apt -y install qtbase5-dev qtdeclarative5-dev qml-module-qtqml-models2 qml-module-qtquick-controls qml-module-qtquick-controls2 qml-module-qtquick-dialogs qml-module-qtquick-xmllistmodel qml-module-qt-labs-settings qml-module-qt-labs-platform qml-module-qt-labs-folderlistmodel qttools5-dev-tools qml-module-qtquick-templates2 libqt5svg5-dev libgcrypt20-dev xvfb
|
||||
run: sudo apt -y install qt6-base-dev qt6-declarative-dev qml6-module-qtqml-models qml6-module-qtquick-controls qml6-module-qtquick-dialogs qml6-module-qtqml-xmllistmodel qml6-module-qt-labs-settings qml6-module-qt-labs-platform qml6-module-qt-labs-folderlistmodel qt6-tools-dev-tools qt6-tools-dev qml6-module-qtquick-templates libqt6svg6-dev libgcrypt20-dev xvfb qml6-module-qt5compat-graphicaleffects qml6-module-qtqml-workerscript qml6-module-qtquick-layouts qml6-module-qtcore
|
||||
- name: build
|
||||
run: DEV_MODE=ON make release -j3
|
||||
- name: test qml
|
||||
|
@ -56,7 +56,7 @@ jobs:
|
|||
- uses: eine/setup-msys2@v2
|
||||
with:
|
||||
update: true
|
||||
install: mingw-w64-x86_64-toolchain make mingw-w64-x86_64-pcre mingw-w64-x86_64-cmake mingw-w64-x86_64-boost mingw-w64-x86_64-openssl mingw-w64-x86_64-zeromq mingw-w64-x86_64-libsodium mingw-w64-x86_64-hidapi mingw-w64-x86_64-protobuf-c mingw-w64-x86_64-libusb mingw-w64-x86_64-unbound git mingw-w64-x86_64-qt5 mingw-w64-x86_64-libgcrypt mingw-w64-x86_64-angleproject
|
||||
install: mingw-w64-x86_64-toolchain make mingw-w64-x86_64-pcre mingw-w64-x86_64-cmake mingw-w64-x86_64-boost mingw-w64-x86_64-openssl mingw-w64-x86_64-zeromq mingw-w64-x86_64-libsodium mingw-w64-x86_64-hidapi mingw-w64-x86_64-protobuf-c mingw-w64-x86_64-libusb mingw-w64-x86_64-unbound git mingw-w64-x86_64-qt6 mingw-w64-x86_64-libgcrypt mingw-w64-x86_64-angleproject
|
||||
- name: build
|
||||
run: DEV_MODE=ON make release-win64 -j2
|
||||
- name: deploy
|
||||
|
@ -78,12 +78,12 @@ jobs:
|
|||
pyenv install 3.12.0
|
||||
pip install defusedxml
|
||||
- name: download qt
|
||||
run: python monero-gui/.github/qt_helper.py mac_x64 desktop 5.15.2 clang_64 c384008156fe63cc183bade0316828c598ff3e5074397c0c9ccc588d6cdc5aca
|
||||
run: python monero-gui/.github/qt_helper.py mac_x64 desktop 6.8.2 clang_64 bb304d352a6bd6c88c9d109ab458064bbe0b729f2f09d00d8a9c1b6f7f996f23
|
||||
working-directory: ../
|
||||
- name: build
|
||||
run: |
|
||||
mkdir build && cd build
|
||||
cmake -D CMAKE_BUILD_TYPE=Release -D ARCH=default -D CMAKE_PREFIX_PATH=/Users/runner/work/monero-gui/5.15.2/clang_64 ..
|
||||
cmake -D CMAKE_BUILD_TYPE=Release -D ARCH=default -D CMAKE_PREFIX_PATH=/Users/runner/work/monero-gui/6.8.2/lib/cmake/Qt6 -D DEV_MODE=ON ..
|
||||
make
|
||||
- name: deploy
|
||||
run: make deploy
|
||||
|
@ -112,7 +112,7 @@ jobs:
|
|||
restore-keys: |
|
||||
docker-linux-static-
|
||||
- name: install dependencies
|
||||
run: sudo apt -y install xvfb libxcb-icccm4 libxcb-image0 libxcb-keysyms1 libxcb-randr0 libxcb-render-util0 libxcb-xkb1 libxcb-shape0 libxkbcommon-x11-0
|
||||
run: sudo apt -y install xvfb libxcb-icccm4 libxcb-image0 libxcb-keysyms1 libxcb-randr0 libxcb-render-util0 libxcb-xkb1 libxcb-shape0 libxkbcommon-x11-0 libopengl0 libegl-dev
|
||||
- name: free up diskspace
|
||||
run: ${{env.FREE_DISKSPACE}}
|
||||
- name: prepare build environment
|
||||
|
@ -148,7 +148,7 @@ jobs:
|
|||
- name: prepare build environment
|
||||
run: docker build --tag monero:build-env-windows --build-arg THREADS=3 --file Dockerfile.windows .
|
||||
- name: build
|
||||
run: docker run --rm -v /home/runner/work/monero-gui/monero-gui:/monero-gui -w /monero-gui monero:build-env-windows sh -c 'make depends root=/depends target=x86_64-w64-mingw32 tag=win-x64 -j3'
|
||||
run: docker run --rm -v /home/runner/work/monero-gui/monero-gui:/monero-gui -w /monero-gui -e THREADS=2 monero:build-env-windows
|
||||
- name: sha256sum
|
||||
run: shasum -a256 /home/runner/work/monero-gui/monero-gui/build/x86_64-w64-mingw32/release/bin/monero-wallet-gui.exe
|
||||
- uses: actions/upload-artifact@v4
|
||||
|
@ -182,7 +182,7 @@ jobs:
|
|||
- uses: actions/upload-artifact@v4
|
||||
with:
|
||||
name: ${{ github.job }}
|
||||
path: /home/runner/work/monero-gui/monero-gui/build/Android/release/android-build/monero-gui.apk
|
||||
path: /home/runner/work/monero-gui/monero-gui/build/Android/release/android-build/monero-wallet-gui.apk
|
||||
|
||||
source-archive:
|
||||
runs-on: ubuntu-20.04
|
||||
|
|
266
CMakeLists.txt
266
CMakeLists.txt
|
@ -1,4 +1,4 @@
|
|||
cmake_minimum_required(VERSION 3.12)
|
||||
cmake_minimum_required(VERSION 3.21.1)
|
||||
project(monero-gui)
|
||||
|
||||
message(STATUS "Initiating compile using CMake ${CMAKE_VERSION}")
|
||||
|
@ -16,12 +16,7 @@ option(WITH_DESKTOP_ENTRY "Ask to install desktop entry on first startup" ON)
|
|||
option(WITH_UPDATER "Regularly check for new updates" ON)
|
||||
option(DEV_MODE "Checkout latest monero master on build" OFF)
|
||||
|
||||
if(DEV_MODE)
|
||||
# DEV_MODE checks out the monero submodule to master, which requires C++17.
|
||||
set(CMAKE_CXX_STANDARD 17)
|
||||
else()
|
||||
set(CMAKE_CXX_STANDARD 11)
|
||||
endif()
|
||||
set(CMAKE_CXX_STANDARD 17)
|
||||
set(CMAKE_CXX_STANDARD_REQUIRED ON)
|
||||
|
||||
list(INSERT CMAKE_MODULE_PATH 0 "${CMAKE_SOURCE_DIR}/cmake")
|
||||
|
@ -122,21 +117,19 @@ if(UNIX AND NOT APPLE AND NOT ANDROID)
|
|||
endif()
|
||||
endif()
|
||||
|
||||
set(QT5_LIBRARIES
|
||||
Qt5Core
|
||||
Qt5Quick
|
||||
Qt5Gui
|
||||
Qt5Qml
|
||||
Qt5Svg
|
||||
Qt5Xml
|
||||
set(QT6_MODULES
|
||||
Core
|
||||
Gui
|
||||
Widgets
|
||||
Quick
|
||||
QuickControls2
|
||||
Qml
|
||||
Svg
|
||||
Xml
|
||||
)
|
||||
|
||||
if(WITH_SCANNER)
|
||||
list(APPEND QT5_LIBRARIES Qt5Multimedia)
|
||||
endif()
|
||||
|
||||
if(APPLE)
|
||||
list(APPEND QT5_LIBRARIES Qt5MacExtras)
|
||||
list(APPEND QT6_MODULES Multimedia)
|
||||
endif()
|
||||
|
||||
if(UNIX)
|
||||
|
@ -145,203 +138,212 @@ if(UNIX)
|
|||
set(CMAKE_PREFIX_PATH $ENV{CMAKE_PREFIX_PATH})
|
||||
endif()
|
||||
if(APPLE AND NOT CMAKE_PREFIX_PATH)
|
||||
execute_process(COMMAND brew --prefix qt5 OUTPUT_VARIABLE QT5_DIR OUTPUT_STRIP_TRAILING_WHITESPACE)
|
||||
list(APPEND CMAKE_PREFIX_PATH ${QT5_DIR})
|
||||
execute_process(COMMAND brew --prefix qt6 OUTPUT_VARIABLE QT6_DIR OUTPUT_STRIP_TRAILING_WHITESPACE)
|
||||
list(APPEND CMAKE_PREFIX_PATH ${QT6_DIR})
|
||||
endif()
|
||||
endif()
|
||||
|
||||
find_package(PkgConfig REQUIRED)
|
||||
|
||||
# TODO: drop this once we switch to Qt 5.14+
|
||||
pkg_check_modules(Qt5QmlModels_PKG_CONFIG QUIET Qt5QmlModels)
|
||||
if(Qt5QmlModels_PKG_CONFIG_FOUND)
|
||||
list(APPEND QT5_LIBRARIES Qt5QmlModels)
|
||||
endif()
|
||||
|
||||
# TODO: drop this once we switch to Qt 5.12+
|
||||
find_package(Qt5XmlPatterns QUIET)
|
||||
if(Qt5XmlPatterns_FOUND)
|
||||
list(APPEND QT5_LIBRARIES Qt5XmlPatterns)
|
||||
endif()
|
||||
|
||||
foreach(QT5_MODULE ${QT5_LIBRARIES})
|
||||
find_package(${QT5_MODULE} REQUIRED)
|
||||
include_directories(${${QT5_MODULE}_INCLUDE_DIRS})
|
||||
foreach(QT6_MODULE ${QT6_MODULES})
|
||||
find_package(Qt6 REQUIRED COMPONENTS ${QT6_MODULE})
|
||||
include_directories(${Qt6${QT6_MODULE}_INCLUDE_DIRS})
|
||||
list(APPEND QT6_LIBRARIES Qt6::${QT6_MODULE})
|
||||
endforeach()
|
||||
|
||||
if(NOT (CMAKE_CROSSCOMPILING AND ANDROID))
|
||||
pkg_check_modules(QT5_PKG_CONFIG REQUIRED ${QT5_LIBRARIES})
|
||||
else()
|
||||
set(QT5_LIBRARIES_ABI)
|
||||
foreach(QT5_MODULE ${QT5_LIBRARIES})
|
||||
list(APPEND QT5_LIBRARIES_ABI "${QT5_MODULE}_${CMAKE_ANDROID_ARCH_ABI}")
|
||||
endforeach()
|
||||
pkg_check_modules(QT5_PKG_CONFIG REQUIRED ${QT5_LIBRARIES_ABI})
|
||||
endif()
|
||||
# TODO can be safely removed ?
|
||||
#if(NOT (CMAKE_CROSSCOMPILING AND ANDROID))
|
||||
# pkg_check_modules(QT6_PKG_CONFIG REQUIRED ${QT6_LIBRARIES})
|
||||
#else()
|
||||
# set(QT6_LIBRARIES_ABI)
|
||||
# foreach(QT6_MODULE ${QT6_LIBRARIES})
|
||||
# list(APPEND QT6_LIBRARIES_ABI "${QT6_MODULE}_${CMAKE_ANDROID_ARCH_ABI}")
|
||||
# endforeach()
|
||||
# pkg_check_modules(QT6_PKG_CONFIG REQUIRED ${QT6_LIBRARIES_ABI})
|
||||
#endif()
|
||||
|
||||
get_target_property(QMAKE_IMPORTED_LOCATION Qt5::qmake IMPORTED_LOCATION)
|
||||
get_target_property(QMAKE_IMPORTED_LOCATION Qt6::qmake IMPORTED_LOCATION)
|
||||
get_filename_component(QT_INSTALL_PREFIX "${QMAKE_IMPORTED_LOCATION}/../.." ABSOLUTE)
|
||||
|
||||
if(APPLE AND NOT STATIC)
|
||||
set(CMAKE_BUILD_RPATH "${QT_INSTALL_PREFIX}/lib")
|
||||
endif()
|
||||
|
||||
if(QT5_PKG_CONFIG_FOUND)
|
||||
set(QT5_PKG_CONFIG "QT5_PKG_CONFIG")
|
||||
if(QT6_PKG_CONFIG_FOUND)
|
||||
set(QT6_PKG_CONFIG "QT6_PKG_CONFIG")
|
||||
if(STATIC)
|
||||
set(QT5_PKG_CONFIG "${QT5_PKG_CONFIG}_STATIC")
|
||||
set(QT6_PKG_CONFIG "${QT6_PKG_CONFIG}_STATIC")
|
||||
endif()
|
||||
|
||||
if(UNIX AND CMAKE_PREFIX_PATH)
|
||||
if(APPLE)
|
||||
list(JOIN ${QT5_PKG_CONFIG}_LDFLAGS_OTHER " " ${QT5_PKG_CONFIG}_LDFLAGS_OTHER)
|
||||
list(JOIN ${QT6_PKG_CONFIG}_LDFLAGS_OTHER " " ${QT6_PKG_CONFIG}_LDFLAGS_OTHER)
|
||||
endif()
|
||||
# temporal workaround for https://bugreports.qt.io/browse/QTBUG-80922
|
||||
STRING(REPLACE "${QT5_PKG_CONFIG_Qt5Core_PREFIX}" "${QT_INSTALL_PREFIX}" ${QT5_PKG_CONFIG}_LDFLAGS_OTHER "${${QT5_PKG_CONFIG}_LDFLAGS_OTHER}")
|
||||
STRING(REPLACE "${QT5_PKG_CONFIG_Qt5Core_PREFIX}" "${QT_INSTALL_PREFIX}" ${QT5_PKG_CONFIG}_LIBRARIES "${${QT5_PKG_CONFIG}_LIBRARIES}")
|
||||
STRING(REPLACE "${QT5_PKG_CONFIG_Qt5Core_PREFIX}" "${QT_INSTALL_PREFIX}" ${QT5_PKG_CONFIG}_INCLUDE_DIRS "${${QT5_PKG_CONFIG}_INCLUDE_DIRS}")
|
||||
STRING(REPLACE "${QT5_PKG_CONFIG_Qt5Core_PREFIX}" "${QT_INSTALL_PREFIX}" ${QT5_PKG_CONFIG}_LIBRARY_DIRS "${${QT5_PKG_CONFIG}_LIBRARY_DIRS}")
|
||||
STRING(REPLACE "${QT6_PKG_CONFIG_Qt6Core_PREFIX}" "${QT_INSTALL_PREFIX}" ${QT6_PKG_CONFIG}_LDFLAGS_OTHER "${${QT6_PKG_CONFIG}_LDFLAGS_OTHER}")
|
||||
STRING(REPLACE "${QT6_PKG_CONFIG_Qt6Core_PREFIX}" "${QT_INSTALL_PREFIX}" ${QT6_PKG_CONFIG}_LIBRARIES "${${QT6_PKG_CONFIG}_LIBRARIES}")
|
||||
STRING(REPLACE "${QT6_PKG_CONFIG_Qt6Core_PREFIX}" "${QT_INSTALL_PREFIX}" ${QT6_PKG_CONFIG}_INCLUDE_DIRS "${${QT6_PKG_CONFIG}_INCLUDE_DIRS}")
|
||||
STRING(REPLACE "${QT6_PKG_CONFIG_Qt6Core_PREFIX}" "${QT_INSTALL_PREFIX}" ${QT6_PKG_CONFIG}_LIBRARY_DIRS "${${QT6_PKG_CONFIG}_LIBRARY_DIRS}")
|
||||
endif()
|
||||
|
||||
set(QT5_LIBRARIES ${${QT5_PKG_CONFIG}_LIBRARIES} ${${QT5_PKG_CONFIG}_LDFLAGS_OTHER})
|
||||
include_directories(${${QT5_PKG_CONFIG}_INCLUDE_DIRS})
|
||||
link_directories(${${QT5_PKG_CONFIG}_LIBRARY_DIRS})
|
||||
set(QT6_LIBRARIES ${${QT6_PKG_CONFIG}_LIBRARIES} ${${QT6_PKG_CONFIG}_LDFLAGS_OTHER})
|
||||
include_directories(${${QT6_PKG_CONFIG}_INCLUDE_DIRS})
|
||||
link_directories(${${QT6_PKG_CONFIG}_LIBRARY_DIRS})
|
||||
endif()
|
||||
|
||||
list(APPEND QT5_LIBRARIES
|
||||
${Qt5Gui_PLUGINS}
|
||||
${Qt5Svg_PLUGINS}
|
||||
${Qt5Qml_PLUGINS}
|
||||
${Qt5Network_PLUGINS}
|
||||
list(APPEND QT6_LIBRARIES
|
||||
${Qt6Gui_PLUGINS}
|
||||
${Qt6Svg_PLUGINS}
|
||||
${Qt6Qml_PLUGINS}
|
||||
${Qt6Network_PLUGINS}
|
||||
)
|
||||
|
||||
if(STATIC)
|
||||
set(QT5_EXTRA_PATHS ${QT5_PKG_CONFIG_Qt5Qml_PREFIX}/qml/Qt/labs/folderlistmodel)
|
||||
list(APPEND QT5_EXTRA_PATHS ${QT5_PKG_CONFIG_Qt5Qml_PREFIX}/qml/Qt/labs/settings)
|
||||
list(APPEND QT5_EXTRA_PATHS ${QT5_PKG_CONFIG_Qt5Qml_PREFIX}/qml/Qt/labs/platform)
|
||||
list(APPEND QT5_EXTRA_PATHS ${QT5_PKG_CONFIG_Qt5Qml_PREFIX}/qml/QtGraphicalEffects)
|
||||
list(APPEND QT5_EXTRA_PATHS ${QT5_PKG_CONFIG_Qt5Qml_PREFIX}/qml/QtGraphicalEffects/private)
|
||||
list(APPEND QT5_EXTRA_PATHS ${QT5_PKG_CONFIG_Qt5Qml_PREFIX}/qml/QtMultimedia)
|
||||
list(APPEND QT5_EXTRA_PATHS ${QT5_PKG_CONFIG_Qt5Qml_PREFIX}/qml/QtQml)
|
||||
list(APPEND QT5_EXTRA_PATHS ${QT5_PKG_CONFIG_Qt5Qml_PREFIX}/qml/QtQml/Models.2)
|
||||
list(APPEND QT5_EXTRA_PATHS ${QT5_PKG_CONFIG_Qt5Qml_PREFIX}/qml/QtQuick.2)
|
||||
list(APPEND QT5_EXTRA_PATHS ${QT5_PKG_CONFIG_Qt5Qml_PREFIX}/qml/QtQuick/Controls)
|
||||
list(APPEND QT5_EXTRA_PATHS ${QT5_PKG_CONFIG_Qt5Qml_PREFIX}/qml/QtQuick/Controls.2)
|
||||
list(APPEND QT5_EXTRA_PATHS ${QT5_PKG_CONFIG_Qt5Qml_PREFIX}/qml/QtQuick/Dialogs)
|
||||
list(APPEND QT5_EXTRA_PATHS ${QT5_PKG_CONFIG_Qt5Qml_PREFIX}/qml/QtQuick/Dialogs/Private)
|
||||
list(APPEND QT5_EXTRA_PATHS ${QT5_PKG_CONFIG_Qt5Qml_PREFIX}/qml/QtQuick/Layouts)
|
||||
list(APPEND QT5_EXTRA_PATHS ${QT5_PKG_CONFIG_Qt5Qml_PREFIX}/qml/QtQuick/PrivateWidgets)
|
||||
list(APPEND QT5_EXTRA_PATHS ${QT5_PKG_CONFIG_Qt5Qml_PREFIX}/qml/QtQuick/Templates.2)
|
||||
list(APPEND QT5_EXTRA_PATHS ${QT5_PKG_CONFIG_Qt5Qml_PREFIX}/qml/QtQuick/Window.2)
|
||||
list(APPEND QT5_EXTRA_PATHS ${QT5_PKG_CONFIG_Qt5Qml_PREFIX}/qml/QtQuick/XmlListModel)
|
||||
set(QT6_EXTRA_PATHS ${QT6_INSTALL_PREFIX}/qml/Qt/labs/folderlistmodel)
|
||||
list(APPEND QT6_EXTRA_PATHS ${QT6_INSTALL_PREFIX}/qml/Qt/labs/settings)
|
||||
list(APPEND QT6_EXTRA_PATHS ${QT6_INSTALL_PREFIX}/qml/Qt/labs/platform)
|
||||
list(APPEND QT6_EXTRA_PATHS ${QT6_INSTALL_PREFIX}/qml/Qt5Compat/GraphicalEffects)
|
||||
list(APPEND QT6_EXTRA_PATHS ${QT6_INSTALL_PREFIX}/qml/Qt5Compat/GraphicalEffects/private)
|
||||
list(APPEND QT6_EXTRA_PATHS ${QT6_INSTALL_PREFIX}/qml/QtMultimedia)
|
||||
list(APPEND QT6_EXTRA_PATHS ${QT6_INSTALL_PREFIX}/qml/QtQml)
|
||||
list(APPEND QT6_EXTRA_PATHS ${QT6_INSTALL_PREFIX}/qml/QtQml/Models)
|
||||
list(APPEND QT6_EXTRA_PATHS ${QT6_INSTALL_PREFIX}/qml/QtQuick)
|
||||
list(APPEND QT6_EXTRA_PATHS ${QT6_INSTALL_PREFIX}/qml/QtQuick/Controls)
|
||||
list(APPEND QT6_EXTRA_PATHS ${QT6_INSTALL_PREFIX}/qml/QtQuick/Controls/impl)
|
||||
list(APPEND QT6_EXTRA_PATHS ${QT6_INSTALL_PREFIX}/qml/QtQuick/Controls/Fusion)
|
||||
list(APPEND QT6_EXTRA_PATHS ${QT6_INSTALL_PREFIX}/qml/QtQuick/Controls/Fusion/impl)
|
||||
list(APPEND QT6_EXTRA_PATHS ${QT6_INSTALL_PREFIX}/qml/QtQuick/Controls/Basic)
|
||||
list(APPEND QT6_EXTRA_PATHS ${QT6_INSTALL_PREFIX}/qml/QtQuick/Controls/Basic/impl)
|
||||
list(APPEND QT6_EXTRA_PATHS ${QT6_INSTALL_PREFIX}/qml/QtQuick/Dialogs)
|
||||
list(APPEND QT6_EXTRA_PATHS ${QT6_INSTALL_PREFIX}/qml/QtQuick/Layouts)
|
||||
list(APPEND QT6_EXTRA_PATHS ${QT6_INSTALL_PREFIX}/qml/QtQuick/PrivateWidgets)
|
||||
list(APPEND QT6_EXTRA_PATHS ${QT6_INSTALL_PREFIX}/qml/QtQuick/Templates)
|
||||
list(APPEND QT6_EXTRA_PATHS ${QT6_INSTALL_PREFIX}/qml/QtQuick/Window)
|
||||
#list(APPEND QT6_EXTRA_PATHS ${QT6_INSTALL_PREFIX}/qml/QtQuick/tooling)
|
||||
list(APPEND QT6_EXTRA_PATHS ${QT6_INSTALL_PREFIX}/qml/QtQml/XmlListModel)
|
||||
list(APPEND QT6_EXTRA_PATHS ${QT6_INSTALL_PREFIX}/qml/QtCore)
|
||||
|
||||
set(QT5_EXTRA_LIBRARIES_LIST
|
||||
set(QT6_EXTRA_LIBRARIES_LIST
|
||||
qtquickdialogsplugin
|
||||
Qt6QuickDialogs2
|
||||
Qt6QuickDialogs2Utils
|
||||
Qt6QuickDialogs2QuickImpl
|
||||
qtquicktemplates2plugin
|
||||
Qt5QuickTemplates2
|
||||
Qt6QuickTemplates2
|
||||
qtquickcontrols2plugin
|
||||
Qt5QuickControls2
|
||||
dialogplugin
|
||||
dialogsprivateplugin
|
||||
Qt6QuickControls2
|
||||
Qt6QuickControls2Impl
|
||||
qtquickcontrols2fusionstyleplugin
|
||||
qtquickcontrols2fusionstyleimplplugin
|
||||
Qt6QuickControls2Fusion
|
||||
Qt6QuickControls2FusionStyleImpl
|
||||
qtquickcontrols2basicstyleplugin
|
||||
qtquickcontrols2basicstyleimplplugin
|
||||
Qt6QuickControls2Basic
|
||||
qmlfolderlistmodelplugin
|
||||
Qt6LabsFolderListModel
|
||||
qmlsettingsplugin
|
||||
qtlabsplatformplugin
|
||||
Qt6LabsSettings
|
||||
labsplatformplugin
|
||||
Qt6LabsPlatform
|
||||
qmlxmllistmodelplugin
|
||||
Qt6QmlXmlListModel
|
||||
qquicklayoutsplugin
|
||||
Qt6QuickLayouts
|
||||
modelsplugin
|
||||
#Qt6QmlModels
|
||||
#Qt6Core5Compat
|
||||
)
|
||||
|
||||
if(WITH_SCANNER)
|
||||
list(APPEND QT5_EXTRA_LIBRARIES_LIST
|
||||
list(APPEND QT6_EXTRA_LIBRARIES_LIST
|
||||
declarative_multimedia
|
||||
Qt5MultimediaQuick
|
||||
Qt6MultimediaQuick
|
||||
)
|
||||
endif()
|
||||
|
||||
list(APPEND QT5_EXTRA_LIBRARIES_LIST
|
||||
list(APPEND QT6_EXTRA_LIBRARIES_LIST
|
||||
qtgraphicaleffectsplugin
|
||||
qtgraphicaleffectsprivate
|
||||
qtgraphicaleffectsprivateplugin
|
||||
qtquick2plugin
|
||||
qtquickcontrolsplugin
|
||||
widgetsplugin
|
||||
windowplugin
|
||||
quickwindowplugin
|
||||
#quicktoolingplugin
|
||||
#qtquickcontrols2implplugin
|
||||
qmlplugin
|
||||
qtqmlcoreplugin
|
||||
Qt6QmlCore
|
||||
)
|
||||
|
||||
if(NOT ${Qt5Core_VERSION} VERSION_LESS 5.14)
|
||||
list(APPEND QT5_EXTRA_LIBRARIES_LIST qmlplugin)
|
||||
endif()
|
||||
|
||||
set(QT5_EXTRA_LIBRARIES)
|
||||
foreach(LIBRARY ${QT5_EXTRA_LIBRARIES_LIST})
|
||||
find_library(${LIBRARY}_LIBRARY ${LIBRARY} PATHS ${QT5_EXTRA_PATHS} REQUIRED)
|
||||
list(APPEND QT5_EXTRA_LIBRARIES ${${LIBRARY}_LIBRARY})
|
||||
set(QT6_EXTRA_LIBRARIES)
|
||||
foreach(LIBRARY ${QT6_EXTRA_LIBRARIES_LIST})
|
||||
find_library(${LIBRARY}_LIBRARY ${LIBRARY} PATHS ${QT6_EXTRA_PATHS} REQUIRED)
|
||||
list(APPEND QT6_EXTRA_LIBRARIES ${${LIBRARY}_LIBRARY})
|
||||
endforeach()
|
||||
|
||||
if(MINGW)
|
||||
if(CMAKE_BUILD_TYPE STREQUAL "Debug")
|
||||
list(APPEND QT5_EXTRA_LIBRARIES D3D11 Dwrite D2d1)
|
||||
list(APPEND QT6_EXTRA_LIBRARIES D3D11 Dwrite D2d1)
|
||||
endif()
|
||||
endif()
|
||||
|
||||
set(QT5_LIBRARIES
|
||||
${QT5_EXTRA_LIBRARIES}
|
||||
${QT5_LIBRARIES}
|
||||
set(QT6_LIBRARIES
|
||||
${QT6_EXTRA_LIBRARIES}
|
||||
${QT6_LIBRARIES}
|
||||
)
|
||||
|
||||
set(QT5_INTEGRATION_LIBRARIES_LIST
|
||||
Qt5EventDispatcherSupport
|
||||
Qt5PacketProtocol
|
||||
Qt5ThemeSupport
|
||||
Qt5FontDatabaseSupport
|
||||
)
|
||||
#set(QT6_INTEGRATION_LIBRARIES_LIST
|
||||
# Qt6EventDispatcherSupport
|
||||
# Qt6PacketProtocol
|
||||
# Qt6ThemeSupport
|
||||
# Qt6FontDatabaseSupport
|
||||
#)
|
||||
|
||||
if(UNIX AND NOT APPLE)
|
||||
list(APPEND QT5_INTEGRATION_LIBRARIES_LIST
|
||||
Qt5XcbQpa
|
||||
Qt5ServiceSupport
|
||||
Qt5GlxSupport
|
||||
list(APPEND QT6_INTEGRATION_LIBRARIES_LIST
|
||||
Qt6XcbQpa
|
||||
# Qt6ServiceSupport
|
||||
# Qt6GlxSupport
|
||||
)
|
||||
elseif(MINGW)
|
||||
list(APPEND QT5_INTEGRATION_LIBRARIES_LIST qtfreetype)
|
||||
list(APPEND QT6_INTEGRATION_LIBRARIES_LIST Qt6BundledFreetype)
|
||||
endif()
|
||||
|
||||
foreach(LIBRARY ${QT5_INTEGRATION_LIBRARIES_LIST})
|
||||
find_library(${LIBRARY}_LIBRARY ${LIBRARY} PATHS ${QT5_EXTRA_PATHS} REQUIRED)
|
||||
list(APPEND QT5_LIBRARIES ${${LIBRARY}_LIBRARY})
|
||||
foreach(LIBRARY ${QT6_INTEGRATION_LIBRARIES_LIST})
|
||||
find_library(${LIBRARY}_LIBRARY ${LIBRARY} PATHS ${QT6_EXTRA_PATHS} REQUIRED)
|
||||
list(APPEND QT6_LIBRARIES ${${LIBRARY}_LIBRARY})
|
||||
endforeach()
|
||||
|
||||
if(UNIX AND NOT APPLE)
|
||||
pkg_check_modules(X11XCB_XCBGLX REQUIRED x11-xcb xcb-glx)
|
||||
list(APPEND QT5_LIBRARIES ${X11XCB_XCBGLX_LIBRARIES})
|
||||
pkg_check_modules(FONTCONFIG REQUIRED fontconfig)
|
||||
list(APPEND QT5_LIBRARIES ${FONTCONFIG_STATIC_LIBRARIES})
|
||||
list(APPEND QT6_LIBRARIES ${X11XCB_XCBGLX_LIBRARIES})
|
||||
#pkg_check_modules(FONTCONFIG REQUIRED fontconfig)
|
||||
#list(APPEND QT6_LIBRARIES ${FONTCONFIG_STATIC_LIBRARIES})
|
||||
endif()
|
||||
endif()
|
||||
|
||||
if(ANDROID)
|
||||
set(QT5_EXTRA_LIBRARIES_LIST
|
||||
set(QT6_EXTRA_LIBRARIES_LIST
|
||||
GLESv2
|
||||
log
|
||||
z
|
||||
jnigraphics
|
||||
android
|
||||
EGL
|
||||
Qt5VirtualKeyboard_${CMAKE_ANDROID_ARCH_ABI}
|
||||
c++_shared
|
||||
)
|
||||
foreach(LIBRARY ${QT5_EXTRA_LIBRARIES_LIST})
|
||||
foreach(LIBRARY ${QT6_EXTRA_LIBRARIES_LIST})
|
||||
find_library(${LIBRARY}_LIBRARY ${LIBRARY} PATHS "${ANDROID_TOOLCHAIN_ROOT}/sysroot/usr/lib/${CMAKE_LIBRARY_ARCHITECTURE}/${ANDROID_PLATFORM_LEVEL}" REQUIRED)
|
||||
list(APPEND QT5_LIBRARIES ${${LIBRARY}_LIBRARY})
|
||||
list(APPEND QT6_LIBRARIES ${${LIBRARY}_LIBRARY})
|
||||
endforeach()
|
||||
endif()
|
||||
|
||||
if(MINGW)
|
||||
set(CMAKE_CXX_FLAGS_DEBUG "${CMAKE_CXX_FLAGS_DEBUG} -Wa,-mbig-obj")
|
||||
set(EXTRA_LIBRARIES mswsock;ws2_32;iphlpapi;crypt32;bcrypt)
|
||||
if(DEPENDS)
|
||||
set(ICU_LIBRARIES icuio icui18n icuuc icudata icutu iconv)
|
||||
else()
|
||||
set(ICU_LIBRARIES icuio icuin icuuc icudt icutu iconv)
|
||||
endif()
|
||||
# Find mingw libversion (to avoid confusion with monero's libversion)
|
||||
set(CMAKE_FIND_DEBUG_MODE TRUE)
|
||||
find_library(VERSION_LIBRARY version REQUIRED)
|
||||
list(APPEND EXTRA_LIBRARIES ${VERSION_LIBRARY})
|
||||
elseif(APPLE)
|
||||
set(EXTRA_LIBRARIES "-framework AppKit")
|
||||
elseif(OPENBSD OR ANDROID)
|
||||
|
@ -450,7 +452,7 @@ message(STATUS "Using C security hardening flags: ${C_SECURITY_FLAGS}")
|
|||
message(STATUS "Using C++ security hardening flags: ${CXX_SECURITY_FLAGS}")
|
||||
message(STATUS "Using linker security hardening flags: ${LD_SECURITY_FLAGS}")
|
||||
|
||||
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -std=c11 ${C_SECURITY_FLAGS}")
|
||||
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${C_SECURITY_FLAGS}")
|
||||
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${CXX_SECURITY_FLAGS}")
|
||||
set(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} ${LD_SECURITY_FLAGS} ${STATIC_FLAGS}")
|
||||
|
||||
|
|
|
@ -1,30 +1,30 @@
|
|||
FROM debian:buster
|
||||
FROM debian:bookworm
|
||||
|
||||
ARG THREADS=1
|
||||
ARG ANDROID_NDK_REVISION=23c
|
||||
ARG ANDROID_NDK_HASH=e5053c126a47e84726d9f7173a04686a71f9a67a
|
||||
ARG ANDROID_SDK_REVISION=7302050_latest
|
||||
ARG ANDROID_SDK_HASH=7a00faadc0864f78edd8f4908a629a46d622375cbe2e5814e82934aebecdb622
|
||||
ARG QT_VERSION=v5.15.16-lts-lgpl
|
||||
ARG ANDROID_NDK_REVISION=26d
|
||||
ARG ANDROID_NDK_HASH=fcdad75a765a46a9cf6560353f480db251d14765
|
||||
ARG ANDROID_SDK_REVISION=11076708_latest
|
||||
ARG ANDROID_SDK_HASH=2d2d50857e4eb553af5a6dc3ad507a17adf43d115264b1afc116f95c92e5e258
|
||||
ARG QT_VERSION=v6.8.2
|
||||
|
||||
WORKDIR /opt/android
|
||||
ENV WORKDIR=/opt/android
|
||||
|
||||
ENV ANDROID_NATIVE_API_LEVEL=31
|
||||
ENV ANDROID_NATIVE_API_LEVEL=34
|
||||
ENV ANDROID_API=android-${ANDROID_NATIVE_API_LEVEL}
|
||||
ENV ANDROID_CLANG=aarch64-linux-android${ANDROID_NATIVE_API_LEVEL}-clang
|
||||
ENV ANDROID_CLANGPP=aarch64-linux-android${ANDROID_NATIVE_API_LEVEL}-clang++
|
||||
ENV ANDROID_NDK_ROOT=${WORKDIR}/android-ndk-r${ANDROID_NDK_REVISION}
|
||||
ENV ANDROID_SDK_ROOT=${WORKDIR}/cmdline-tools
|
||||
ENV JAVA_HOME=/usr/lib/jvm/java-11-openjdk-amd64
|
||||
ENV JAVA_HOME=/usr/lib/jvm/java-17-openjdk-amd64
|
||||
ENV PATH=${JAVA_HOME}/bin:${PATH}
|
||||
ENV PREFIX=${WORKDIR}/prefix
|
||||
ENV TOOLCHAIN_DIR=${ANDROID_NDK_ROOT}/toolchains/llvm/prebuilt/linux-x86_64
|
||||
|
||||
RUN apt-get update \
|
||||
&& apt-get install -y ant automake build-essential ca-certificates-java file gettext git libc6 libncurses5 \
|
||||
libssl-dev libstdc++6 libtinfo5 libtool libz1 openjdk-11-jdk-headless openjdk-11-jre-headless pkg-config python3 \
|
||||
unzip wget
|
||||
libssl-dev libstdc++6 libtinfo5 libtool libz1 openjdk-17-jdk-headless openjdk-17-jre-headless pkg-config python3 \
|
||||
unzip wget ninja-build
|
||||
|
||||
RUN PACKAGE_NAME=commandlinetools-linux-${ANDROID_SDK_REVISION}.zip \
|
||||
&& wget -q https://dl.google.com/android/repository/${PACKAGE_NAME} \
|
||||
|
@ -38,7 +38,15 @@ RUN PACKAGE_NAME=android-ndk-r${ANDROID_NDK_REVISION}-linux.zip \
|
|||
&& unzip -q ${PACKAGE_NAME} \
|
||||
&& rm -f ${PACKAGE_NAME}
|
||||
|
||||
RUN echo y | ${ANDROID_SDK_ROOT}/bin/sdkmanager --sdk_root=${ANDROID_SDK_ROOT} "build-tools;28.0.3" "platforms;${ANDROID_API}" "tools" > /dev/null
|
||||
RUN echo y | ${ANDROID_SDK_ROOT}/bin/sdkmanager --sdk_root=${ANDROID_SDK_ROOT} "build-tools;35.0.1" "platforms;${ANDROID_API}" "tools" > /dev/null
|
||||
|
||||
RUN git clone -b v3.31.4 --depth 1 https://github.com/Kitware/CMake \
|
||||
&& cd CMake \
|
||||
&& git reset --hard 569b821a138a4d3f7f4cc42c0cf5ae5e68d56f96 \
|
||||
&& ./bootstrap \
|
||||
&& make -j${THREADS} \
|
||||
&& make -j${THREADS} install \
|
||||
&& rm -rf $(pwd)
|
||||
|
||||
ENV HOST_PATH=${PATH}
|
||||
ENV PATH=${TOOLCHAIN_DIR}/aarch64-linux-android/bin:${TOOLCHAIN_DIR}/bin:${PATH}
|
||||
|
@ -50,45 +58,74 @@ RUN wget -q https://github.com/madler/zlib/releases/download/v${ZLIB_VERSION}/zl
|
|||
&& tar -xzf zlib-${ZLIB_VERSION}.tar.gz \
|
||||
&& rm zlib-${ZLIB_VERSION}.tar.gz \
|
||||
&& cd zlib-${ZLIB_VERSION} \
|
||||
&& CC=${ANDROID_CLANG} CXX=${ANDROID_CLANGPP} ./configure --prefix=${PREFIX} --static \
|
||||
&& CFLAGS="-fPIC" CXXFLAGS="-fPIC" CC=${ANDROID_CLANG} CXX=${ANDROID_CLANGPP} ./configure --prefix=${PREFIX} --static \
|
||||
&& make -j${THREADS} \
|
||||
&& make -j${THREADS} install \
|
||||
&& rm -rf $(pwd)
|
||||
|
||||
RUN git clone git://code.qt.io/qt/qt5.git -b ${QT_VERSION} --depth 1 \
|
||||
&& cd qt5 \
|
||||
&& perl init-repository --module-subset=default,-qtwebengine \
|
||||
&& PATH=${HOST_PATH} ./configure -v -developer-build -release \
|
||||
RUN git clone git://code.qt.io/qt/qt5.git -b ${QT_VERSION} --depth 1 && \
|
||||
cd qt5 && \
|
||||
git clone git://code.qt.io/qt/qtbase.git -b ${QT_VERSION} --depth 1 && \
|
||||
git clone git://code.qt.io/qt/qtdeclarative.git -b ${QT_VERSION} --depth 1 && \
|
||||
git clone git://code.qt.io/qt/qt5compat.git -b ${QT_VERSION} --depth 1 && \
|
||||
git clone git://code.qt.io/qt/qtimageformats.git -b ${QT_VERSION} --depth 1 && \
|
||||
git clone git://code.qt.io/qt/qtmultimedia.git -b ${QT_VERSION} --depth 1 && \
|
||||
git clone git://code.qt.io/qt/qtquickeffectmaker.git -b ${QT_VERSION} --depth 1 && \
|
||||
git clone git://code.qt.io/qt/qtquicktimeline.git -b ${QT_VERSION} --depth 1 && \
|
||||
git clone git://code.qt.io/qt/qtshadertools.git -b ${QT_VERSION} --depth 1 && \
|
||||
git clone git://code.qt.io/qt/qtsvg.git -b ${QT_VERSION} --depth 1 && \
|
||||
git clone git://code.qt.io/qt/qttools.git -b ${QT_VERSION} --depth 1 && \
|
||||
git clone git://code.qt.io/qt/qttranslations.git -b ${QT_VERSION} --depth 1
|
||||
|
||||
RUN cd qt5 && \
|
||||
mkdir build_host && \
|
||||
cd build_host && \
|
||||
../configure -developer-build -no-opengl -no-warnings-are-errors \
|
||||
-nomake tests -nomake examples \
|
||||
-no-feature-assistant -no-feature-designer -no-feature-distancefieldgenerator \
|
||||
-no-feature-pixeltool -no-feature-qtattributionsscanner -no-feature-qtdiag
|
||||
|
||||
RUN cd qt5/build_host && \
|
||||
cmake --build . --target host_tools -j${THREADS}
|
||||
|
||||
#RUN cd qt5/build_host && \
|
||||
# cmake --install .
|
||||
|
||||
RUN cd qt5 && \
|
||||
mkdir build_android && \
|
||||
cd build_android && \
|
||||
PATH=${HOST_PATH} ../configure -developer-build -release \
|
||||
-qt-host-path /opt/android/qt5/build_host/qtbase \
|
||||
-xplatform android-clang \
|
||||
-android-ndk-platform ${ANDROID_API} \
|
||||
-android-ndk ${ANDROID_NDK_ROOT} \
|
||||
-android-sdk ${ANDROID_SDK_ROOT} \
|
||||
-android-ndk-host linux-x86_64 \
|
||||
-no-dbus \
|
||||
-opengl es2 \
|
||||
-no-use-gold-linker \
|
||||
-no-sql-mysql \
|
||||
-no-sql-sqlite \
|
||||
-opensource -confirm-license \
|
||||
-android-arch arm64-v8a \
|
||||
-android-abis arm64-v8a \
|
||||
-prefix ${PREFIX} \
|
||||
-nomake tools -nomake tests -nomake examples \
|
||||
-skip qtwebengine \
|
||||
-skip qtserialport \
|
||||
-skip qtconnectivity \
|
||||
-skip qttranslations \
|
||||
-skip qtpurchasing \
|
||||
-skip qtgamepad -skip qtscript -skip qtdoc \
|
||||
-no-warnings-are-errors \
|
||||
&& PATH=${HOST_PATH} make -j${THREADS} \
|
||||
&& PATH=${HOST_PATH} make -j${THREADS} install \
|
||||
&& cd qttools/src/linguist/lrelease \
|
||||
&& ../../../../qtbase/bin/qmake \
|
||||
&& PATH=${HOST_PATH} make -j${THREADS} install \
|
||||
&& cd ../../../.. \
|
||||
&& rm -rf $(pwd)
|
||||
-skip qt3d -skip qtactiveqt -skip qtcanvas3d -skip qtcharts -skip qtquick3d \
|
||||
-skip qtquick3dphysics -skip qtcoap -skip qtdatavis3d \
|
||||
-skip qt3d -skip qtactiveqt -skip qtcanvas3d -skip qtcharts -skip qtcoap -skip qtconnectivity -skip qtdatavis3d \
|
||||
-skip qtdoc -skip qtfeedback -skip qtgamepad -skip qtgraphs -skip qtgrpc -skip qthttpserver -skip qtlanguageserver -skip qtlocation -skip qtlottie -skip qtmqtt -skip qtnetworkauth -skip qtopcua -skip qtpim -skip qtpositioning -skip qtqa \
|
||||
-skip qtremoteobjects -skip qtrepotools -skip qtscxml -skip qtsensors -skip qtserialbus -skip qtserialport -skip qtspeech -skip qtsystems \
|
||||
-skip qtwayland -skip qtwebchannel -skip qtwebengine -skip qtwebglplugin -skip qtwebsockets -skip qtwebview \
|
||||
-skip gamepad -skip serialbus -skip location -skip webengine \
|
||||
-nomake examples -nomake tests -skip qtquick3d -skip qtquick3dphysics -skip qttranslations -skip qtxmlpatterns \
|
||||
-no-feature-designer -no-feature-distancefieldgenerator -no-feature-pixeltool -no-feature-qtattributionsscanner \
|
||||
-no-feature-qtdiag -no-feature-qtplugininfo \
|
||||
-no-warnings-are-errors -no-feature-qml-worker-script -no-feature-assistant
|
||||
|
||||
ARG ICONV_VERSION=1.16
|
||||
ARG ICONV_HASH=e6a1b1b589654277ee790cce3734f07876ac4ccfaecbee8afa0b649cf529cc04
|
||||
RUN cd qt5/build_android && PATH=${HOST_PATH} cmake --build . -j${THREADS} \
|
||||
&& PATH=${HOST_PATH} cmake --install .
|
||||
|
||||
ARG ICONV_VERSION=1.18
|
||||
ARG ICONV_HASH=3b08f5f4f9b4eb82f151a7040bfd6fe6c6fb922efe4b1659c66ea933276965e8
|
||||
RUN wget -q http://ftp.gnu.org/pub/gnu/libiconv/libiconv-${ICONV_VERSION}.tar.gz \
|
||||
&& echo "${ICONV_HASH} libiconv-${ICONV_VERSION}.tar.gz" | sha256sum -c \
|
||||
&& tar -xzf libiconv-${ICONV_VERSION}.tar.gz \
|
||||
|
@ -196,27 +233,26 @@ RUN git clone -b libgcrypt-1.10.1 --depth 1 git://git.gnupg.org/libgcrypt.git \
|
|||
&& make -j${THREADS} install \
|
||||
&& rm -rf $(pwd)
|
||||
|
||||
RUN git clone -b v3.31.4 --depth 1 https://github.com/Kitware/CMake \
|
||||
&& cd CMake \
|
||||
&& git reset --hard 569b821a138a4d3f7f4cc42c0cf5ae5e68d56f96 \
|
||||
&& PATH=${HOST_PATH} ./bootstrap \
|
||||
&& PATH=${HOST_PATH} make -j${THREADS} \
|
||||
&& PATH=${HOST_PATH} make -j${THREADS} install \
|
||||
&& rm -rf $(pwd)
|
||||
RUN cp ${WORKDIR}/qt5/build_host/qtbase/bin/lrelease /usr/bin
|
||||
RUN cp ${WORKDIR}/qt5/build_host/qtbase/libexec/rcc /usr/bin/
|
||||
|
||||
#ENV PATH=${PATH}:/opt/android/qt5/build_host/qtbase/bin
|
||||
|
||||
# Workaround
|
||||
ENV NEW_SDK_ROOT=${WORKDIR}/sdk
|
||||
RUN mkdir ${NEW_SDK_ROOT} \
|
||||
&& cp -r ${ANDROID_SDK_ROOT}/licenses ${NEW_SDK_ROOT} \
|
||||
&& cp -r ${ANDROID_SDK_ROOT}/platforms ${NEW_SDK_ROOT} \
|
||||
&& cp -r ${ANDROID_SDK_ROOT}/build-tools ${NEW_SDK_ROOT}
|
||||
&& cp -r ${ANDROID_SDK_ROOT}/build-tools ${NEW_SDK_ROOT} \
|
||||
&& rm -rf ${ANDROID_SDK_ROOT} \
|
||||
&& mv ${NEW_SDK_ROOT} ${ANDROID_SDK_ROOT}
|
||||
|
||||
CMD set -ex \
|
||||
&& cd /monero-gui \
|
||||
&& mkdir -p build/Android/release \
|
||||
&& cd build/Android/release \
|
||||
&& cmake \
|
||||
-DCMAKE_TOOLCHAIN_FILE="${ANDROID_NDK_ROOT}/build/cmake/android.toolchain.cmake" \
|
||||
-DCMAKE_TOOLCHAIN_FILE="${PREFIX}/lib/cmake/Qt6/qt.toolchain.cmake" \
|
||||
-DCMAKE_PREFIX_PATH="${PREFIX}" \
|
||||
-DCMAKE_FIND_ROOT_PATH="${PREFIX}" \
|
||||
-DCMAKE_BUILD_TYPE=Release \
|
||||
|
@ -225,11 +261,12 @@ CMD set -ex \
|
|||
-DANDROID_ABI="arm64-v8a" \
|
||||
-DANDROID_TOOLCHAIN=clang \
|
||||
-DBoost_USE_STATIC_RUNTIME=ON \
|
||||
-DLRELEASE_PATH="${PREFIX}/bin" \
|
||||
-DLRELEASE_PATH="/usr/bin" \
|
||||
-DQT_ANDROID_APPLICATION_BINARY="monero-wallet-gui" \
|
||||
-DANDROID_SDK="${NEW_SDK_ROOT}" \
|
||||
-DWITH_SCANNER=ON \
|
||||
-DWITH_DESKTOP_ENTRY=OFF \
|
||||
-DANDROID_SDK="${ANDROID_SDK_ROOT}" \
|
||||
-DQT_ANDROID_DEPLOYMENT_TYPE="debug" \
|
||||
../../.. \
|
||||
&& PATH=${HOST_PATH} make generate_translations_header \
|
||||
&& sed -i -e "s#../monero/external/randomx/librandomx.a##" src/CMakeFiles/monero-wallet-gui.dir/link.txt \
|
||||
|
|
115
Dockerfile.linux
115
Dockerfile.linux
|
@ -1,7 +1,7 @@
|
|||
FROM ubuntu:16.04
|
||||
FROM ubuntu:20.04
|
||||
|
||||
ARG THREADS=1
|
||||
ARG QT_VERSION=v5.15.16-lts-lgpl
|
||||
ARG QT_VERSION=v6.8.2
|
||||
|
||||
ENV CFLAGS="-fPIC"
|
||||
ENV CPPFLAGS="-fPIC"
|
||||
|
@ -9,9 +9,10 @@ ENV CXXFLAGS="-fPIC"
|
|||
ENV SOURCE_DATE_EPOCH=1397818193
|
||||
|
||||
RUN apt update && \
|
||||
apt install -y automake autopoint bison gettext git gperf libgl1-mesa-dev libglib2.0-dev \
|
||||
libpng12-dev libpthread-stubs0-dev libsodium-dev libtool-bin libudev-dev libusb-1.0-0-dev mesa-common-dev \
|
||||
pkg-config python wget xutils-dev
|
||||
DEBIAN_FRONTEND=noninteractive apt install -y automake autopoint bison gettext git gperf libgl1-mesa-dev libglib2.0-dev \
|
||||
libpthread-stubs0-dev libsodium-dev libtool-bin mesa-common-dev \
|
||||
pkg-config python3 wget xutils-dev make libclang-dev \
|
||||
g++ ninja-build libx11-xcb-dev libxcb-image0-dev libxcb-cursor-dev
|
||||
|
||||
RUN git clone -b xorgproto-2020.1 --depth 1 https://gitlab.freedesktop.org/xorg/proto/xorgproto && \
|
||||
cd xorgproto && \
|
||||
|
@ -21,9 +22,9 @@ RUN git clone -b xorgproto-2020.1 --depth 1 https://gitlab.freedesktop.org/xorg/
|
|||
make -j$THREADS install && \
|
||||
rm -rf $(pwd)
|
||||
|
||||
RUN git clone -b 1.12 --depth 1 https://gitlab.freedesktop.org/xorg/proto/xcbproto && \
|
||||
RUN git clone -b xcb-proto-1.17.0 --depth 1 https://gitlab.freedesktop.org/xorg/proto/xcbproto && \
|
||||
cd xcbproto && \
|
||||
git reset --hard 6398e42131eedddde0d98759067dde933191f049 && \
|
||||
git reset --hard 77d7fc04da729ddc5ed4aacf30253726fac24dca && \
|
||||
./autogen.sh && \
|
||||
make -j$THREADS && \
|
||||
make -j$THREADS install && \
|
||||
|
@ -37,9 +38,9 @@ RUN git clone -b libXau-1.0.9 --depth 1 https://gitlab.freedesktop.org/xorg/lib/
|
|||
make -j$THREADS install && \
|
||||
rm -rf $(pwd)
|
||||
|
||||
RUN git clone -b 1.12 --depth 1 https://gitlab.freedesktop.org/xorg/lib/libxcb && \
|
||||
RUN git clone -b libxcb-1.17.0 --depth 1 https://gitlab.freedesktop.org/xorg/lib/libxcb && \
|
||||
cd libxcb && \
|
||||
git reset --hard d34785a34f28fa6a00f8ce00d87e3132ff0f6467 && \
|
||||
git reset --hard 622152ee42a310876f10602601206954b8d0613e && \
|
||||
./autogen.sh --enable-shared --disable-static && \
|
||||
make -j$THREADS && \
|
||||
make -j$THREADS install && \
|
||||
|
@ -50,45 +51,37 @@ RUN git clone -b 1.12 --depth 1 https://gitlab.freedesktop.org/xorg/lib/libxcb &
|
|||
cp src/.libs/libxcb-xinerama.a /usr/local/lib/ && \
|
||||
rm -rf $(pwd)
|
||||
|
||||
RUN git clone -b 0.4.0 --depth 1 https://gitlab.freedesktop.org/xorg/lib/libxcb-util && \
|
||||
RUN git clone -b xcb-util-0.4.1 --depth 1 https://gitlab.freedesktop.org/xorg/lib/libxcb-util && \
|
||||
cd libxcb-util && \
|
||||
git reset --hard acf790d7752f36e450d476ad79807d4012ec863b && \
|
||||
git submodule init && \
|
||||
git clone --depth 1 https://gitlab.freedesktop.org/xorg/util/xcb-util-m4 m4 && \
|
||||
git -C m4 reset --hard c617eee22ae5c285e79e81ec39ce96862fd3262f && \
|
||||
./autogen.sh --enable-shared --disable-static && \
|
||||
make -j$THREADS && \
|
||||
make -j$THREADS install && \
|
||||
rm -rf $(pwd)
|
||||
|
||||
RUN git clone -b 0.4.0 --depth 1 https://gitlab.freedesktop.org/xorg/lib/libxcb-image && \
|
||||
RUN git clone -b xcb-util-image-0.4.1 --depth 1 https://gitlab.freedesktop.org/xorg/lib/libxcb-image && \
|
||||
cd libxcb-image && \
|
||||
git reset --hard d882052fb2ce439c6483fce944ba8f16f7294639 && \
|
||||
git submodule init && \
|
||||
git clone --depth 1 https://gitlab.freedesktop.org/xorg/util/xcb-util-m4 m4 && \
|
||||
git -C m4 reset --hard c617eee22ae5c285e79e81ec39ce96862fd3262f && \
|
||||
./autogen.sh --enable-shared --disable-static && \
|
||||
make -j$THREADS && \
|
||||
make -j$THREADS install && \
|
||||
rm -rf $(pwd)
|
||||
|
||||
RUN git clone -b 0.4.0 --depth 1 https://gitlab.freedesktop.org/xorg/lib/libxcb-keysyms && \
|
||||
RUN git clone -b xcb-util-keysyms-0.4.1 --depth 1 https://gitlab.freedesktop.org/xorg/lib/libxcb-keysyms && \
|
||||
cd libxcb-keysyms && \
|
||||
git reset --hard 0e51ee5570a6a80bdf98770b975dfe8a57f4eeb1 && \
|
||||
git submodule init && \
|
||||
git clone --depth 1 https://gitlab.freedesktop.org/xorg/util/xcb-util-m4 m4 && \
|
||||
git -C m4 reset --hard c617eee22ae5c285e79e81ec39ce96862fd3262f && \
|
||||
./autogen.sh --enable-shared --disable-static && \
|
||||
make -j$THREADS && \
|
||||
make -j$THREADS install && \
|
||||
rm -rf $(pwd)
|
||||
|
||||
RUN git clone -b 0.3.9 --depth 1 https://gitlab.freedesktop.org/xorg/lib/libxcb-render-util && \
|
||||
RUN git clone -b xcb-util-renderutil-0.3.10 --depth 1 https://gitlab.freedesktop.org/xorg/lib/libxcb-render-util && \
|
||||
cd libxcb-render-util && \
|
||||
git reset --hard 0317caf63de532fd7a0493ed6afa871a67253747 && \
|
||||
git submodule init && \
|
||||
git clone --depth 1 https://gitlab.freedesktop.org/xorg/util/xcb-util-m4 m4 && \
|
||||
git -C m4 reset --hard c617eee22ae5c285e79e81ec39ce96862fd3262f && \
|
||||
./autogen.sh --enable-shared --disable-static && \
|
||||
make -j$THREADS && \
|
||||
make -j$THREADS install && \
|
||||
|
@ -121,28 +114,25 @@ RUN git clone -b v1.3 --depth 1 https://github.com/madler/zlib && \
|
|||
make -j$THREADS install && \
|
||||
rm -rf $(pwd)
|
||||
|
||||
RUN git clone -b VER-2-10-2 --depth 1 https://gitlab.freedesktop.org/freetype/freetype.git && \
|
||||
RUN git clone -b VER-2-13-3 --depth 1 https://gitlab.freedesktop.org/freetype/freetype.git && \
|
||||
cd freetype && \
|
||||
git reset --hard 132f19b779828b194b3fede187cee719785db4d8 && \
|
||||
./autogen.sh && \
|
||||
./configure --disable-shared --enable-static --with-zlib=no && \
|
||||
make -j$THREADS && \
|
||||
make -j$THREADS install && \
|
||||
rm -rf $(pwd)
|
||||
|
||||
RUN wget https://github.com/libexpat/libexpat/releases/download/R_2_4_8/expat-2.4.8.tar.bz2 && \
|
||||
echo "a247a7f6bbb21cf2ca81ea4cbb916bfb9717ca523631675f99b3d4a5678dcd16 expat-2.4.8.tar.bz2" | sha256sum -c && \
|
||||
tar -xf expat-2.4.8.tar.bz2 && \
|
||||
rm expat-2.4.8.tar.bz2 && \
|
||||
cd expat-2.4.8 && \
|
||||
RUN wget https://github.com/libexpat/libexpat/releases/download/R_2_6_4/expat-2.6.4.tar.bz2 && \
|
||||
tar -xf expat-2.6.4.tar.bz2 && \
|
||||
rm expat-2.6.4.tar.bz2 && \
|
||||
cd expat-2.6.4 && \
|
||||
./configure --enable-static --disable-shared --prefix=/usr && \
|
||||
make -j$THREADS && \
|
||||
make -j$THREADS install && \
|
||||
rm -rf $(pwd)
|
||||
|
||||
RUN git clone -b 2.13.92 --depth 1 https://gitlab.freedesktop.org/fontconfig/fontconfig && \
|
||||
RUN git clone -b 2.14.2 --depth 1 https://gitlab.freedesktop.org/fontconfig/fontconfig && \
|
||||
cd fontconfig && \
|
||||
git reset --hard b1df1101a643ae16cdfa1d83b939de2497b1bf27 && \
|
||||
./autogen.sh --disable-shared --enable-static --sysconfdir=/etc --localstatedir=/var && \
|
||||
make -j$THREADS && \
|
||||
make -j$THREADS install && \
|
||||
|
@ -185,50 +175,52 @@ RUN wget https://www.nlnetlabs.nl/downloads/unbound/unbound-1.16.2.tar.gz && \
|
|||
make -j$THREADS install && \
|
||||
rm -rf $(pwd)
|
||||
|
||||
RUN git clone -b v3.30.7 --depth 1 https://github.com/Kitware/CMake && \
|
||||
cd CMake && \
|
||||
./bootstrap && \
|
||||
make -j$THREADS && \
|
||||
make -j$THREADS install && \
|
||||
rm -rf $(pwd)
|
||||
|
||||
RUN rm /usr/lib/x86_64-linux-gnu/libX11.a && \
|
||||
rm /usr/lib/x86_64-linux-gnu/libXext.a && \
|
||||
rm /usr/lib/x86_64-linux-gnu/libX11-xcb.a && \
|
||||
rm -f /usr/lib/x86_64-linux-gnu/libXext.a && \
|
||||
rm -f /usr/lib/x86_64-linux-gnu/libX11-xcb.a && \
|
||||
git clone git://code.qt.io/qt/qt5.git -b ${QT_VERSION} --depth 1 && \
|
||||
cd qt5 && \
|
||||
git clone git://code.qt.io/qt/qtbase.git -b ${QT_VERSION} --depth 1 && \
|
||||
git clone git://code.qt.io/qt/qtdeclarative.git -b ${QT_VERSION} --depth 1 && \
|
||||
git clone git://code.qt.io/qt/qtgraphicaleffects.git -b ${QT_VERSION} --depth 1 && \
|
||||
git clone git://code.qt.io/qt/qt5compat.git -b ${QT_VERSION} --depth 1 && \
|
||||
git clone git://code.qt.io/qt/qtimageformats.git -b ${QT_VERSION} --depth 1 && \
|
||||
git clone git://code.qt.io/qt/qtmultimedia.git -b ${QT_VERSION} --depth 1 && \
|
||||
git clone git://code.qt.io/qt/qtquickcontrols.git -b ${QT_VERSION} --depth 1 && \
|
||||
git clone git://code.qt.io/qt/qtquickcontrols2.git -b ${QT_VERSION} --depth 1 && \
|
||||
git clone git://code.qt.io/qt/qtquickeffectmaker.git -b ${QT_VERSION} --depth 1 && \
|
||||
git clone git://code.qt.io/qt/qtquicktimeline.git -b ${QT_VERSION} --depth 1 && \
|
||||
git clone git://code.qt.io/qt/qtshadertools.git -b ${QT_VERSION} --depth 1 && \
|
||||
git clone git://code.qt.io/qt/qtsvg.git -b ${QT_VERSION} --depth 1 && \
|
||||
git clone git://code.qt.io/qt/qttools.git -b ${QT_VERSION} --depth 1 && \
|
||||
git clone git://code.qt.io/qt/qttranslations.git -b ${QT_VERSION} --depth 1 && \
|
||||
git clone git://code.qt.io/qt/qtx11extras.git -b ${QT_VERSION} --depth 1 && \
|
||||
git clone git://code.qt.io/qt/qtxmlpatterns.git -b ${QT_VERSION} --depth 1 && \
|
||||
sed -ri s/\(Libs:.*\)/\\1\ -lexpat/ /usr/local/lib/pkgconfig/fontconfig.pc && \
|
||||
sed -ri s/\(Libs:.*\)/\\1\ -lz/ /usr/local/lib/pkgconfig/freetype2.pc && \
|
||||
sed -ri s/\(Libs:.*\)/\\1\ -lXau/ /usr/local/lib/pkgconfig/xcb.pc && \
|
||||
sed -i s/\\/usr\\/X11R6\\/lib64/\\/usr\\/local\\/lib/ qtbase/mkspecs/linux-g++-64/qmake.conf && \
|
||||
./configure --prefix=/usr -platform linux-g++-64 -opensource -confirm-license -release -static -no-avx \
|
||||
-opengl desktop -qpa xcb -xcb -xcb-xlib -feature-xlib -system-freetype -fontconfig -glib \
|
||||
-no-dbus -no-feature-qml-worker-script -no-linuxfb -no-openssl -no-sql-sqlite -no-kms -no-use-gold-linker \
|
||||
-qt-harfbuzz -qt-libjpeg -qt-libpng -qt-pcre -qt-zlib \
|
||||
-skip qt3d -skip qtandroidextras -skip qtcanvas3d -skip qtcharts -skip qtconnectivity -skip qtdatavis3d \
|
||||
-skip qtdoc -skip qtgamepad -skip qtlocation -skip qtmacextras -skip qtnetworkauth -skip qtpurchasing \
|
||||
-skip qtscript -skip qtscxml -skip qtsensors -skip qtserialbus -skip qtserialport -skip qtspeech -skip qttools \
|
||||
-skip qtvirtualkeyboard -skip qtwayland -skip qtwebchannel -skip qtwebengine -skip qtwebsockets -skip qtwebview \
|
||||
-skip qtwinextras -skip qtx11extras -skip gamepad -skip serialbus -skip location -skip webengine \
|
||||
-nomake examples -nomake tests -nomake tools && \
|
||||
make -j$THREADS && \
|
||||
make -j$THREADS install && \
|
||||
cd qttools/src/linguist/lrelease && \
|
||||
../../../../qtbase/bin/qmake && \
|
||||
make -j$THREADS && \
|
||||
make -j$THREADS install && \
|
||||
cd ../../../.. && \
|
||||
-qt-harfbuzz -qt-libjpeg -qt-libpng -qt-pcre -system-zlib \
|
||||
-skip qt3d -skip qtactiveqt -skip qtcanvas3d -skip qtcharts -skip qtcoap -skip qtconnectivity -skip qtdatavis3d \
|
||||
-skip qtdoc -skip qtfeedback -skip qtgamepad -skip qtgraphs -skip qtgrpc -skip qthttpserver -skip qtlanguageserver -skip qtlocation -skip qtlottie -skip qtmqtt -skip qtnetworkauth -skip qtopcua -skip qtpim -skip qtpositioning -skip qtqa \
|
||||
-skip qtremoteobjects -skip qtrepotools -skip qtscxml -skip qtsensors -skip qtserialbus -skip qtserialport -skip qtspeech -skip qtsystems \
|
||||
-skip qtvirtualkeyboard -skip qtwayland -skip qtwebchannel -skip qtwebengine -skip qtwebglplugin -skip qtwebsockets -skip qtwebview \
|
||||
-skip gamepad -skip serialbus -skip location -skip webengine \
|
||||
-nomake examples -nomake tests -skip qtquick3d -skip qtquick3dphysics -skip qttranslations -skip qtxmlpatterns \
|
||||
-no-feature-designer -no-feature-distancefieldgenerator -no-feature-pixeltool -no-feature-qtattributionsscanner \
|
||||
-no-feature-qtdiag -no-feature-qtplugininfo -no-feature-androiddeployqt && \
|
||||
sed -i -e "s#libfontconfig.a#libfontconfig.a /usr/lib/libexpat.a#" build.ninja && \
|
||||
sed -i -e "s#/usr/local/lib/libfreetype.a \+/usr/local/lib/libfontconfig.a#/usr/local/lib/libfontconfig.a /usr/local/lib/libfreetype.a#" build.ninja && \
|
||||
cmake --build . -j$THREADS && \
|
||||
cmake --install . && \
|
||||
rm -rf $(pwd)
|
||||
|
||||
RUN git clone -b v1.0.26 --depth 1 https://github.com/libusb/libusb && \
|
||||
cd libusb && \
|
||||
git reset --hard 4239bc3a50014b8e6a5a2a59df1fff3b7469543b && \
|
||||
./autogen.sh --disable-shared --enable-static && \
|
||||
./autogen.sh --disable-shared --enable-static --disable-udev && \
|
||||
make -j$THREADS && \
|
||||
make -j$THREADS install && \
|
||||
rm -rf $(pwd)
|
||||
|
@ -236,8 +228,7 @@ RUN git clone -b v1.0.26 --depth 1 https://github.com/libusb/libusb && \
|
|||
RUN git clone -b hidapi-0.13.1 --depth 1 https://github.com/libusb/hidapi && \
|
||||
cd hidapi && \
|
||||
git reset --hard 4ebce6b5059b086d05ca7e091ce04a5fd08ac3ac && \
|
||||
./bootstrap && \
|
||||
./configure --disable-shared --enable-static && \
|
||||
cmake -DHIDAPI_WITH_HIDRAW=OFF -DBUILD_SHARED_LIBS=OFF . && \
|
||||
make -j$THREADS && \
|
||||
make -j$THREADS install && \
|
||||
rm -rf $(pwd)
|
||||
|
@ -278,10 +269,6 @@ RUN git clone -b v21.5 --depth 1 https://github.com/protocolbuffers/protobuf &&
|
|||
make -j$THREADS install && \
|
||||
rm -rf $(pwd)
|
||||
|
||||
RUN git clone -b v3.24.0 --depth 1 https://github.com/Kitware/CMake && \
|
||||
cd CMake && \
|
||||
git reset --hard 4be24f031a4829db75b85062cc67125035d8831e && \
|
||||
./bootstrap && \
|
||||
make -j$THREADS && \
|
||||
make -j$THREADS install && \
|
||||
rm -rf $(pwd)
|
||||
RUN rm /usr/lib/x86_64-linux-gnu/libgobject-2.0.a \
|
||||
/usr/lib/x86_64-linux-gnu/libgio-2.0.a \
|
||||
/usr/lib/x86_64-linux-gnu/libglib-2.0.a
|
||||
|
|
|
@ -1,20 +1,21 @@
|
|||
FROM ubuntu:20.04
|
||||
FROM ubuntu:24.04
|
||||
|
||||
ARG THREADS=1
|
||||
ARG QT_VERSION=v5.15.16-lts-lgpl
|
||||
ARG QT_VERSION=v6.8.2
|
||||
ENV SOURCE_DATE_EPOCH=1397818193
|
||||
|
||||
RUN apt update && \
|
||||
DEBIAN_FRONTEND=noninteractive apt install -y build-essential cmake g++-mingw-w64 gettext git libtool pkg-config \
|
||||
python && \
|
||||
ninja-build \
|
||||
python3 && \
|
||||
rm -rf /var/lib/apt/lists/*
|
||||
|
||||
RUN update-alternatives --set x86_64-w64-mingw32-g++ $(which x86_64-w64-mingw32-g++-posix) && \
|
||||
update-alternatives --set x86_64-w64-mingw32-gcc $(which x86_64-w64-mingw32-gcc-posix)
|
||||
|
||||
RUN git clone -b v0.18.2.0 --depth 1 https://github.com/monero-project/monero && \
|
||||
RUN git clone -b v0.18.3.4 --depth 1 https://github.com/monero-project/monero && \
|
||||
cd monero && \
|
||||
git reset --hard 99be9a044f3854f339548e2d99c539c18d7b1b01 && \
|
||||
git reset --hard b089f9ee69924882c5d14dd1a6991deb05d9d1cd && \
|
||||
cp -a contrib/depends / && \
|
||||
cd .. && \
|
||||
rm -rf monero
|
||||
|
@ -25,37 +26,48 @@ RUN git clone git://code.qt.io/qt/qt5.git -b ${QT_VERSION} --depth 1 && \
|
|||
cd qt5 && \
|
||||
git clone git://code.qt.io/qt/qtbase.git -b ${QT_VERSION} --depth 1 && \
|
||||
git clone git://code.qt.io/qt/qtdeclarative.git -b ${QT_VERSION} --depth 1 && \
|
||||
git clone git://code.qt.io/qt/qtgraphicaleffects.git -b ${QT_VERSION} --depth 1 && \
|
||||
git clone git://code.qt.io/qt/qt5compat.git -b ${QT_VERSION} --depth 1 && \
|
||||
git clone git://code.qt.io/qt/qtimageformats.git -b ${QT_VERSION} --depth 1 && \
|
||||
git clone git://code.qt.io/qt/qtmultimedia.git -b ${QT_VERSION} --depth 1 && \
|
||||
git clone git://code.qt.io/qt/qtquickcontrols.git -b ${QT_VERSION} --depth 1 && \
|
||||
git clone git://code.qt.io/qt/qtquickcontrols2.git -b ${QT_VERSION} --depth 1 && \
|
||||
git clone git://code.qt.io/qt/qtquickeffectmaker.git -b ${QT_VERSION} --depth 1 && \
|
||||
git clone git://code.qt.io/qt/qtquicktimeline.git -b ${QT_VERSION} --depth 1 && \
|
||||
git clone git://code.qt.io/qt/qtshadertools.git -b ${QT_VERSION} --depth 1 && \
|
||||
git clone git://code.qt.io/qt/qtsvg.git -b ${QT_VERSION} --depth 1 && \
|
||||
git clone git://code.qt.io/qt/qttools.git -b ${QT_VERSION} --depth 1 && \
|
||||
git clone git://code.qt.io/qt/qttranslations.git -b ${QT_VERSION} --depth 1 && \
|
||||
git clone git://code.qt.io/qt/qtxmlpatterns.git -b ${QT_VERSION} --depth 1 && \
|
||||
./configure --prefix=/depends/x86_64-w64-mingw32 -xplatform win32-g++ \
|
||||
mkdir /usr/qt_host && \
|
||||
cd /usr/qt_host && \
|
||||
/qt5/configure -developer-build -no-opengl -no-warnings-are-errors \
|
||||
-skip qtquickeffectmaker -skip qtquicktimeline -skip qt5compat -skip qtmultimedia \
|
||||
-no-feature-androiddeployqt -no-feature-printsupport --no-feature-sql \
|
||||
-no-feature-designer -no-feature-distancefieldgenerator \
|
||||
-no-feature-pixeltool -no-feature-qtattributionsscanner -no-feature-qtdiag \
|
||||
-nomake tests -nomake examples && \
|
||||
cmake --build . --target host_tools -j${THREADS} && \
|
||||
cd /qt5 && \
|
||||
./configure --prefix=/depends/x86_64-w64-mingw32 -platform linux-g++-64 -xplatform win32-g++ \
|
||||
-qt-host-path "/usr/qt_host/qtbase" \
|
||||
-device-option CROSS_COMPILE=/usr/bin/x86_64-w64-mingw32- \
|
||||
-I $(pwd)/qtbase/src/3rdparty/angle/include \
|
||||
-opensource -confirm-license -release -static -static-runtime -opengl dynamic -no-angle \
|
||||
-opensource -confirm-license -release -static -static-runtime -opengl dynamic \
|
||||
-no-avx -no-openssl -no-sql-sqlite \
|
||||
-no-feature-qml-worker-script -no-openssl -no-sql-sqlite \
|
||||
-qt-freetype -qt-harfbuzz -qt-libjpeg -qt-libpng -qt-pcre -qt-zlib \
|
||||
-skip gamepad -skip location -skip qt3d -skip qtactiveqt -skip qtandroidextras \
|
||||
-no-feature-qml-worker-script \
|
||||
-qt-freetype -qt-harfbuzz -qt-libjpeg -qt-libpng -qt-pcre -qt-zlib -no-dbus \
|
||||
-skip gamepad -skip location -skip qt3d -skip qtactiveqt \
|
||||
-skip qtcanvas3d -skip qtcharts -skip qtconnectivity -skip qtdatavis3d -skip qtdoc \
|
||||
-skip qtgamepad -skip qtlocation -skip qtmacextras -skip qtnetworkauth -skip qtpurchasing \
|
||||
-skip qtscript -skip qtscxml -skip qtsensors -skip qtserialbus -skip qtserialport \
|
||||
-skip qtspeech -skip qttools -skip qtvirtualkeyboard -skip qtwayland -skip qtwebchannel \
|
||||
-skip qtwebengine -skip qtwebsockets -skip qtwebview -skip qtwinextras -skip qtx11extras \
|
||||
-skip qtspeech -skip qtvirtualkeyboard -skip qtwayland -skip qtwebchannel \
|
||||
-skip qtwebengine -skip qtwebsockets -skip qtwebview \
|
||||
-skip serialbus -skip webengine \
|
||||
-nomake examples -nomake tests -nomake tools && \
|
||||
make -j$THREADS && \
|
||||
make -j$THREADS install && \
|
||||
cd qttools/src/linguist/lrelease && \
|
||||
../../../../qtbase/bin/qmake && \
|
||||
make -j$THREADS && \
|
||||
make -j$THREADS install && \
|
||||
cd ../../../.. && \
|
||||
-skip qtcoap -skip qtfeedback -skip qtgraphs -skip qtgrpc -skip qthttpserver -skip qtlanguageserver -skip qtlottie -skip qtmqtt -skip qtopcua -skip qtpim -skip qtpositioning -skip qtqa \
|
||||
-skip qtremoteobjects -skip qtrepotools -skip qtsystems -skip qtwebglplugin \
|
||||
-nomake examples -nomake tests -skip qtquick3d -skip qtquick3dphysics -skip qttranslations -skip qtxmlpatterns \
|
||||
-no-feature-designer -no-feature-distancefieldgenerator -no-feature-pixeltool -no-feature-qtattributionsscanner \
|
||||
-no-feature-qtdiag -no-feature-qtplugininfo -no-feature-androiddeployqt -no-linuxfb \
|
||||
CMAKE_TOOLCHAIN_FILE=/depends/x86_64-w64-mingw32/share/toolchain.cmake \
|
||||
HOST=x86_64-w64-mingw32 && \
|
||||
cmake --build . -j$THREADS && \
|
||||
cmake --install . && \
|
||||
rm -rf $(pwd)
|
||||
|
||||
RUN git clone -b libgpg-error-1.38 --depth 1 git://git.gnupg.org/libgpg-error.git && \
|
||||
|
@ -80,3 +92,18 @@ RUN git clone -b libgcrypt-1.8.5 --depth 1 git://git.gnupg.org/libgcrypt.git &&
|
|||
make -j$THREADS install && \
|
||||
cd .. && \
|
||||
rm -rf libgcrypt
|
||||
|
||||
# Cannot cmake install qt host with partial build (target host_tools)
|
||||
# Adding paths to find 'lrelease' and 'rcc' binaries
|
||||
ENV PATH=/usr/qt_host/qtbase/bin:/usr/qt_host/qtbase/libexec:${PATH}
|
||||
|
||||
# TODO :
|
||||
CMD mkdir -p build/x86_64-w64-mingw32/release \
|
||||
&& cd build/x86_64-w64-mingw32/release \
|
||||
#&& cp /usr/x86_64-w64-mingw32/lib/libversion.a /depends/x86_64-w64-mingw32/lib/ \
|
||||
&& cmake -D STATIC=ON -D BUILD_TAG=win-x64 -D CMAKE_BUILD_TYPE=Release \
|
||||
-D CMAKE_TOOLCHAIN_FILE=/depends/x86_64-w64-mingw32/share/toolchain.cmake ../../.. \
|
||||
-D CMAKE_PREFIX_PATH=/usr/x86_64-w64-mingw32 \
|
||||
&& sed -i -e "s#-licu#-L/depends/x86_64-w64-mingw32/lib -licu#" src/CMakeFiles/monero-wallet-gui.dir/linkLibs.rsp \
|
||||
&& sed -i '37i #include <cstdint>' ../../../monero/contrib/epee/include/net/http_base.h \
|
||||
&& make -j$THREADS
|
||||
|
|
|
@ -27,8 +27,8 @@
|
|||
// THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
import QtQuick 2.9
|
||||
import QtQuick.Layouts 1.1
|
||||
import QtGraphicalEffects 1.0
|
||||
import QtQuick.Layouts
|
||||
import Qt5Compat.GraphicalEffects
|
||||
import moneroComponents.Wallet 1.0
|
||||
import moneroComponents.NetworkType 1.0
|
||||
import moneroComponents.Clipboard 1.0
|
||||
|
|
5
Makefile
5
Makefile
|
@ -54,7 +54,10 @@ release-linux-ppc64le:
|
|||
mkdir -p $(builddir)/release && cd $(builddir)/release && cmake -D DEV_MODE=$(or ${DEV_MODE},OFF) -DMANUAL_SUBMODULES=${MANUAL_SUBMODULES} -D ARCH="ppc64le" -D CMAKE_BUILD_TYPE=Release $(topdir) && $(MAKE)
|
||||
|
||||
release-static:
|
||||
mkdir -p $(builddir)/release && cd $(builddir)/release && cmake -D STATIC=ON -D DEV_MODE=$(or ${DEV_MODE},OFF) -DMANUAL_SUBMODULES=${MANUAL_SUBMODULES} -D ARCH="x86-64" -D BUILD_64=ON -D CMAKE_BUILD_TYPE=Release $(topdir) && $(MAKE)
|
||||
mkdir -p $(builddir)/release && cd $(builddir)/release && cmake -D STATIC=ON -D DEV_MODE=$(or ${DEV_MODE},OFF) -DMANUAL_SUBMODULES=${MANUAL_SUBMODULES} -D ARCH="x86-64" -D BUILD_64=ON -D CMAKE_BUILD_TYPE=Release -D QT_QML_DEBUG=ON $(topdir)
|
||||
sed -i -e "s#libfontconfig.a#libfontconfig.a /usr/lib/libexpat.a#" build/release/src/CMakeFiles/monero-wallet-gui.dir/link.txt
|
||||
sed -i -e "s#/usr/local/lib/libfreetype.a /usr/local/lib/libfontconfig.a#/usr/local/lib/libfontconfig.a /usr/local/lib/libfreetype.a#" build/release/src/CMakeFiles/monero-wallet-gui.dir/link.txt
|
||||
cd $(builddir)/release && $(MAKE)
|
||||
|
||||
debug-static-win64:
|
||||
mkdir -p $(builddir)/debug && cd $(builddir)/debug && cmake -D STATIC=ON -G "MSYS Makefiles" -D DEV_MODE=$(or ${DEV_MODE},ON) -DMANUAL_SUBMODULES=${MANUAL_SUBMODULES} -D ARCH="x86-64" -D BUILD_64=ON -D CMAKE_BUILD_TYPE=Debug -D BUILD_TAG="win-x64" -D CMAKE_TOOLCHAIN_FILE=$(topdir)/cmake/64-bit-toolchain.cmake -D MSYS2_FOLDER=$(shell cd ${MINGW_PREFIX}/.. && pwd -W) -D MINGW=ON $(topdir) && $(MAKE)
|
||||
|
|
|
@ -29,10 +29,9 @@
|
|||
|
||||
import QtQml 2.0
|
||||
import QtQuick 2.9
|
||||
import QtQuick.Controls 2.0
|
||||
import QtQuick.Controls 1.4
|
||||
import QtQuick.Layouts 1.1
|
||||
import QtGraphicalEffects 1.0
|
||||
import QtQuick.Controls
|
||||
import QtQuick.Layouts
|
||||
import Qt5Compat.GraphicalEffects
|
||||
import moneroComponents.Wallet 1.0
|
||||
|
||||
import "./pages"
|
||||
|
@ -204,8 +203,8 @@ Rectangle {
|
|||
anchors.fill:parent
|
||||
clip: true // otherwise animation will affect left panel
|
||||
|
||||
delegate: StackViewDelegate {
|
||||
pushTransition: StackViewTransition {
|
||||
/*delegate: StackViewDelegate {
|
||||
/*pushTransition: StackViewTransition {
|
||||
PropertyAnimation {
|
||||
target: enterItem
|
||||
property: "x"
|
||||
|
@ -223,7 +222,7 @@ Rectangle {
|
|||
easing.type: Easing.OutCubic
|
||||
}
|
||||
}
|
||||
}
|
||||
}*/
|
||||
}
|
||||
|
||||
}// flickable
|
||||
|
|
18
README.md
18
README.md
|
@ -94,7 +94,7 @@ Packaging for your favorite distribution would be a welcome contribution!
|
|||
|
||||
## Compiling the Monero GUI from source
|
||||
|
||||
*Note*: Qt 5.9.7 is the minimum version required to build the GUI.
|
||||
*Note*: Qt 6.TODO.TODO is the minimum version required to build the GUI.
|
||||
|
||||
*Note*: Official GUI releases use monero-wallet-gui from this process alongside the supporting binaries (monerod, etc) from the [CLI deterministic builds](https://github.com/monero-project/monero/blob/release-v0.18/contrib/gitian/README.md).
|
||||
|
||||
|
@ -151,7 +151,7 @@ Packaging for your favorite distribution would be a welcome contribution!
|
|||
\* `<MONERO_GUI_DIR_FULL_PATH>` - absolute path to `monero-gui` directory
|
||||
|
||||
### Building Android APK with Docker (any OS) *Experimental*
|
||||
- Minimum Android 9 Pie (API 28)
|
||||
- Minimum Android 14 `Upside Down Cake` (API 34)
|
||||
- ARMv8-A 64-bit CPU
|
||||
1. Install Docker [https://docs.docker.com/engine/install/](https://docs.docker.com/engine/install/)
|
||||
2. Clone the repository
|
||||
|
@ -177,7 +177,7 @@ Packaging for your favorite distribution would be a welcome contribution!
|
|||
- [Enable adb debugging on your device](https://developer.android.com/studio/command-line/adb.html#Enabling)
|
||||
* Connect your device with USB and install Monero GUI APK with adb:
|
||||
```
|
||||
adb install build/Android/release/android-build/monero-gui.apk
|
||||
adb install build/Android/release/android-build/monero-wallet-gui.apk
|
||||
```
|
||||
* Troubleshooting:
|
||||
```
|
||||
|
@ -191,7 +191,7 @@ Packaging for your favorite distribution would be a welcome contribution!
|
|||
* Using a web server
|
||||
```
|
||||
mkdir /usr/tmp
|
||||
cp build/Android/release/android-build/monero-gui.apk /usr/tmp
|
||||
cp build/Android/release/android-build/monero-wallet-gui.apk /usr/tmp
|
||||
docker run -d -v /usr/tmp:/usr/share/nginx/html:ro -p 8080:80 nginx
|
||||
```
|
||||
Now it should be accessible through a web browser at
|
||||
|
@ -219,9 +219,9 @@ Packaging for your favorite distribution would be a welcome contribution!
|
|||
|
||||
2. Install Qt:
|
||||
|
||||
*Note*: The Qt 5.9.7 or newer requirement makes **some** distributions (mostly based on Debian, like Ubuntu 16.x or Linux Mint 18.x) obsolete due to their repositories containing an older Qt version.
|
||||
*Note*: The Qt 6.TODO.TODO or newer requirement makes **some** distributions (mostly based on Debian, like Ubuntu 16.x or Linux Mint 18.x) obsolete due to their repositories containing an older Qt version.
|
||||
|
||||
The recommended way is to install 5.9.7 from the [official Qt installer](https://www.qt.io/download-qt-installer) or [compiling it yourself](https://wiki.qt.io/Install_Qt_5_on_Ubuntu). This ensures you have the correct version. Higher versions *can* work but as it differs from our production build target, slight differences may occur.
|
||||
The recommended way is to install 6.TODO.TODO from the [official Qt installer](https://www.qt.io/download-qt-installer) or [compiling it yourself](https://wiki.qt.io/Install_Qt_5_on_Ubuntu). This ensures you have the correct version. Higher versions *can* work but as it differs from our production build target, slight differences may occur.
|
||||
|
||||
The following instructions will fetch Qt from your distribution's repositories instead. Take note of what version it installs. Your mileage may vary.
|
||||
|
||||
|
@ -234,17 +234,17 @@ The following instructions will fetch Qt from your distribution's repositories i
|
|||
|
||||
The *qml* USE flag must be enabled.
|
||||
|
||||
`sudo emerge dev-qt/qtcore:5 dev-qt/qtdeclarative:5 dev-qt/qtquickcontrols:5 dev-qt/qtquickcontrols2:5 dev-qt/qtgraphicaleffects:5`
|
||||
`sudo emerge dev-qt/qtcore:6 dev-qt/qtdeclarative:6 dev-qt/qtquickcontrols:6 dev-qt/qtgraphicaleffects:6`
|
||||
|
||||
- Optional : To build the flag `WITH_SCANNER`
|
||||
|
||||
- For Debian distributions (Debian, Ubuntu, Mint, Tails...)
|
||||
|
||||
`sudo apt install qtmultimedia5-dev qml-module-qtmultimedia`
|
||||
`sudo apt install qt6multimedia6-dev qml6-module-qtmultimedia`
|
||||
|
||||
- For Gentoo
|
||||
|
||||
`emerge dev-qt/qtmultimedia:5`
|
||||
`emerge dev-qt/qtmultimedia:6`
|
||||
|
||||
|
||||
3. Clone repository
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
if(APPLE OR (WIN32 AND NOT STATIC))
|
||||
add_custom_target(deploy)
|
||||
get_target_property(_qmake_executable Qt5::qmake IMPORTED_LOCATION)
|
||||
get_target_property(_qmake_executable Qt6::qmake IMPORTED_LOCATION)
|
||||
get_filename_component(_qt_bin_dir "${_qmake_executable}" DIRECTORY)
|
||||
|
||||
if(APPLE AND NOT IOS)
|
||||
|
@ -37,6 +37,17 @@ if(APPLE OR (WIN32 AND NOT STATIC))
|
|||
)
|
||||
endif()
|
||||
|
||||
# libbost_chrono-mt.dylib has a dependency on libboost_system-mt.dylib, maydeployqt does not copy it by itself
|
||||
find_package(Boost COMPONENTS system)
|
||||
get_target_property(BOOST_SYSTEM_LIB_PATH Boost::system LOCATION)
|
||||
if(EXISTS ${BOOST_SYSTEM_LIB_PATH})
|
||||
add_custom_command(TARGET deploy
|
||||
POST_BUILD
|
||||
COMMAND ${CMAKE_COMMAND} -E copy "${BOOST_SYSTEM_LIB_PATH}" "$<TARGET_FILE_DIR:monero-wallet-gui>/../Frameworks/"
|
||||
COMMENT "Copying libboost_system-mt.dylib"
|
||||
)
|
||||
endif()
|
||||
|
||||
# Apple Silicon requires all binaries to be codesigned
|
||||
find_program(CODESIGN_EXECUTABLE NAMES codesign)
|
||||
if(CODESIGN_EXECUTABLE)
|
||||
|
@ -49,8 +60,11 @@ if(APPLE OR (WIN32 AND NOT STATIC))
|
|||
|
||||
elseif(WIN32)
|
||||
find_program(WINDEPLOYQT_EXECUTABLE windeployqt HINTS "${_qt_bin_dir}")
|
||||
get_target_property(_qmlimportscanner_executable Qt6::qmlimportscanner IMPORTED_LOCATION)
|
||||
get_filename_component(_qml_bin_dir "${_qmlimportscanner_executable}" DIRECTORY)
|
||||
|
||||
add_custom_command(TARGET monero-wallet-gui POST_BUILD
|
||||
COMMAND "${CMAKE_COMMAND}" -E env PATH="${_qt_bin_dir}" "${WINDEPLOYQT_EXECUTABLE}" "$<TARGET_FILE:monero-wallet-gui>" -no-translations -qmldir="${CMAKE_SOURCE_DIR}"
|
||||
COMMAND "${CMAKE_COMMAND}" -E env PATH="${_qml_bin_dir}\;${_qt_bin_dir}" "${WINDEPLOYQT_EXECUTABLE}" "$<TARGET_FILE:monero-wallet-gui>" -no-translations -qmldir="${CMAKE_SOURCE_DIR}"
|
||||
COMMENT "Running windeployqt..."
|
||||
)
|
||||
set(WIN_DEPLOY_DLLS
|
||||
|
|
|
@ -9,8 +9,8 @@
|
|||
file(GLOB_RECURSE UI_FILES *.ui)
|
||||
file(GLOB_RECURSE CODE_FILES *.cpp)
|
||||
|
||||
qt5_wrap_ui(UI_HEADERS ${UI_FILES})
|
||||
#qt5_add_resources(RESOURCE_FILES ../resources/resources.qrc)
|
||||
qt6_wrap_ui(UI_HEADERS ${UI_FILES})
|
||||
#qt6_add_resources(RESOURCE_FILES ../resources/resources.qrc)
|
||||
|
||||
# Windows application icon
|
||||
if (WIN32)
|
||||
|
@ -35,7 +35,7 @@ add_executable(${CMAKE_PROJECT_NAME} WIN32
|
|||
${WINDOWS_RES_FILE}
|
||||
)
|
||||
target_link_libraries(${CMAKE_PROJECT_NAME}
|
||||
Qt5::Widgets
|
||||
Qt6::Widgets
|
||||
)
|
||||
|
||||
if (UNIX)
|
||||
|
|
|
@ -27,8 +27,8 @@
|
|||
// THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
import QtQuick 2.9
|
||||
import QtQuick.Layouts 1.1
|
||||
import QtGraphicalEffects 1.0
|
||||
import QtQuick.Layouts
|
||||
import Qt5Compat.GraphicalEffects
|
||||
import FontAwesome 1.0
|
||||
|
||||
import "." 1.0
|
||||
|
|
|
@ -27,10 +27,9 @@
|
|||
// THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
import QtQuick 2.9
|
||||
import QtQuick.Controls 1.4
|
||||
import QtQuick.Dialogs 1.2
|
||||
import QtQuick.Layouts 1.1
|
||||
import QtQuick.Controls.Styles 1.4
|
||||
import QtQuick.Controls
|
||||
import QtQuick.Dialogs
|
||||
import QtQuick.Layouts
|
||||
import QtQuick.Window 2.0
|
||||
import moneroComponents.Wallet 1.0
|
||||
|
||||
|
|
|
@ -26,12 +26,10 @@
|
|||
// 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.
|
||||
|
||||
import QtQuick 2.9
|
||||
import QtQuick.Controls 1.2
|
||||
import QtQuick.Controls 2.2 as QtQuickControls2
|
||||
import QtQuick.Layouts 1.2
|
||||
import QtGraphicalEffects 1.0
|
||||
import QtQuick.Controls.Styles 1.2
|
||||
import QtQuick
|
||||
import QtQuick.Controls
|
||||
import QtQuick.Layouts
|
||||
import Qt5Compat.GraphicalEffects
|
||||
import FontAwesome 1.0
|
||||
|
||||
import "." as MoneroComponents
|
||||
|
@ -246,10 +244,10 @@ Item {
|
|||
}
|
||||
}
|
||||
|
||||
QtQuickControls2.Popup {
|
||||
Popup {
|
||||
id: popup
|
||||
padding: 0
|
||||
closePolicy: QtQuickControls2.Popup.CloseOnEscape | QtQuickControls2.Popup.CloseOnPressOutsideParent
|
||||
closePolicy: Popup.CloseOnEscape | Popup.CloseOnPressOutsideParent
|
||||
onOpened: {
|
||||
calendar.visibleMonth = currentDate.getMonth();
|
||||
calendar.visibleYear = currentDate.getFullYear();
|
||||
|
@ -290,7 +288,7 @@ Item {
|
|||
height: 1
|
||||
}
|
||||
|
||||
Calendar {
|
||||
MonthGrid {
|
||||
id: calendar
|
||||
anchors.left: parent.left
|
||||
anchors.right: parent.right
|
||||
|
@ -298,9 +296,9 @@ Item {
|
|||
anchors.margins: 1
|
||||
anchors.bottomMargin: 10
|
||||
height: 220
|
||||
frameVisible: false
|
||||
//frameVisible: false
|
||||
|
||||
style: CalendarStyle {
|
||||
/*style: CalendarStyle {
|
||||
gridVisible: false
|
||||
background: Rectangle { color: MoneroComponents.Style.middlePanelBackgroundColor }
|
||||
dayDelegate: Item {
|
||||
|
@ -458,7 +456,7 @@ Item {
|
|||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}*/
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -27,8 +27,8 @@
|
|||
// THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
import QtQuick 2.9
|
||||
import QtQuick.Layouts 1.1
|
||||
import QtGraphicalEffects 1.0
|
||||
import QtQuick.Layouts
|
||||
import Qt5Compat.GraphicalEffects
|
||||
|
||||
import FontAwesome 1.0
|
||||
|
||||
|
|
|
@ -28,9 +28,8 @@
|
|||
|
||||
import QtQuick 2.9
|
||||
import QtQuick.Controls 2.0
|
||||
import QtQuick.Dialogs 1.2
|
||||
import QtQuick.Layouts 1.1
|
||||
import QtQuick.Controls.Styles 1.4
|
||||
import QtQuick.Dialogs
|
||||
import QtQuick.Layouts
|
||||
import QtQuick.Window 2.0
|
||||
|
||||
import "../components" as MoneroComponents
|
||||
|
|
|
@ -28,10 +28,10 @@
|
|||
|
||||
import "../components" as MoneroComponents
|
||||
|
||||
import QtQuick 2.9
|
||||
import QtQuick.XmlListModel 2.0
|
||||
import QtQuick.Layouts 1.2
|
||||
import QtQuick.Controls 2.0
|
||||
import QtQuick
|
||||
import QtQml.XmlListModel
|
||||
import QtQuick.Layouts
|
||||
import QtQuick.Controls
|
||||
|
||||
|
||||
Drawer {
|
||||
|
@ -176,13 +176,13 @@ Drawer {
|
|||
source: "/lang/languages.xml"
|
||||
query: "/languages/language"
|
||||
|
||||
XmlRole { name: "display_name"; query: "@display_name/string()" }
|
||||
XmlRole { name: "locale"; query: "@locale/string()" }
|
||||
XmlRole { name: "wallet_language"; query: "@wallet_language/string()" }
|
||||
XmlRole { name: "flag"; query: "@flag/string()" }
|
||||
XmlListModelRole { name: "display_name"; elementName: "display_name" }
|
||||
XmlListModelRole { name: "locale"; elementName: "locale" }
|
||||
XmlListModelRole { name: "wallet_language"; elementName: "wallet_language" }
|
||||
XmlListModelRole { name: "flag"; elementName: "flag" }
|
||||
// TODO: XmlListModel is read only, we should store current language somewhere else
|
||||
// and set current language accordingly
|
||||
XmlRole { name: "isCurrent"; query: "@enabled/string()" }
|
||||
XmlListModelRole { name: "isCurrent"; elementName: "enabled" }
|
||||
|
||||
onStatusChanged: {
|
||||
if(status === XmlListModel.Ready){
|
||||
|
|
|
@ -28,8 +28,8 @@
|
|||
|
||||
import FontAwesome 1.0
|
||||
import QtQuick 2.9
|
||||
import QtGraphicalEffects 1.0
|
||||
import QtQuick.Layouts 1.1
|
||||
import Qt5Compat.GraphicalEffects
|
||||
import QtQuick.Layouts
|
||||
|
||||
import "../components" as MoneroComponents
|
||||
|
||||
|
|
|
@ -27,7 +27,7 @@
|
|||
// THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
import QtQuick 2.9
|
||||
import QtGraphicalEffects 1.0
|
||||
import Qt5Compat.GraphicalEffects
|
||||
|
||||
import "../components" as MoneroComponents
|
||||
import "effects/" as MoneroEffects
|
||||
|
|
|
@ -28,9 +28,8 @@
|
|||
|
||||
import QtQuick 2.9
|
||||
import QtQuick.Controls 2.0
|
||||
import QtQuick.Dialogs 1.2
|
||||
import QtQuick.Layouts 1.1
|
||||
import QtQuick.Controls.Styles 1.4
|
||||
import QtQuick.Dialogs
|
||||
import QtQuick.Layouts
|
||||
import QtQuick.Window 2.0
|
||||
import FontAwesome 1.0
|
||||
|
||||
|
|
|
@ -28,8 +28,7 @@
|
|||
|
||||
import QtQuick 2.9
|
||||
import QtQuick.Window 2.1
|
||||
import QtQuick.Controls 1.4
|
||||
import QtQuick.Controls.Styles 1.4
|
||||
import QtQuick.Controls
|
||||
import QtQuick.Layouts 1.1
|
||||
|
||||
import "../components" as MoneroComponents
|
||||
|
@ -74,14 +73,14 @@ Rectangle {
|
|||
width: 60
|
||||
height: 60
|
||||
anchors.centerIn: parent
|
||||
source: "qrc:///images/monero-vector.svg"
|
||||
source: "qrc:///images/moneroLogo_white.png"
|
||||
mipmap: true
|
||||
}
|
||||
|
||||
BusyIndicator {
|
||||
running: parent.visible
|
||||
anchors.centerIn: imgLogo
|
||||
style: BusyIndicatorStyle {
|
||||
/*style: BusyIndicatorStyle {
|
||||
indicator: Image {
|
||||
visible: control.running
|
||||
source: "qrc:///images/busy-indicator.png"
|
||||
|
@ -93,7 +92,7 @@ Rectangle {
|
|||
to: 360
|
||||
}
|
||||
}
|
||||
}
|
||||
}*/
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -28,7 +28,7 @@
|
|||
|
||||
import QtQuick 2.9
|
||||
import QtQuick.Controls 2.2
|
||||
import QtQuick.Layouts 1.1
|
||||
import QtQuick.Layouts
|
||||
|
||||
import "." as MoneroComponents
|
||||
|
||||
|
|
|
@ -26,10 +26,9 @@
|
|||
// 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.
|
||||
|
||||
import QtQuick.Controls 1.2
|
||||
import QtQuick.Controls.Styles 1.2
|
||||
import QtQuick.Controls
|
||||
import QtQuick 2.9
|
||||
import QtQuick.Layouts 1.1
|
||||
import QtQuick.Layouts
|
||||
|
||||
import "../js/Utils.js" as Utils
|
||||
import "../components" as MoneroComponents
|
||||
|
|
|
@ -26,12 +26,11 @@
|
|||
// 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.
|
||||
|
||||
import QtQuick 2.9
|
||||
import QtQuick.Controls 2.0
|
||||
import QtQuick.Dialogs 1.2
|
||||
import QtQuick.Layouts 1.1
|
||||
import QtQuick.Controls.Styles 1.4
|
||||
import QtQuick.Window 2.0
|
||||
import QtQuick
|
||||
import QtQuick.Controls
|
||||
import QtQuick.Dialogs
|
||||
import QtQuick.Layouts
|
||||
import QtQuick.Window
|
||||
|
||||
import "../components" as MoneroComponents
|
||||
import "effects/" as MoneroEffects
|
||||
|
|
|
@ -28,9 +28,9 @@
|
|||
|
||||
import QtQuick 2.9
|
||||
import QtQuick.Controls 2.2
|
||||
import QtGraphicalEffects 1.0
|
||||
import Qt5Compat.GraphicalEffects
|
||||
import FontAwesome 1.0
|
||||
import QtQuick.Layouts 1.1
|
||||
import QtQuick.Layouts
|
||||
|
||||
import "../components" as MoneroComponents
|
||||
import "../components/effects/" as MoneroEffects
|
||||
|
|
|
@ -128,7 +128,7 @@ Rectangle {
|
|||
readOnly: true
|
||||
wrapMode: Text.Wrap
|
||||
labelText: qsTr("Transaction file location:") + translationManager.emptyString
|
||||
text: walletManager.urlToLocalPath(saveTxDialog.fileUrl)
|
||||
text: walletManager.urlToLocalPath(saveTxDialog.selectedFile)
|
||||
fontSize: 16
|
||||
}
|
||||
|
||||
|
@ -161,7 +161,7 @@ Rectangle {
|
|||
width: 200
|
||||
KeyNavigation.tab: doneButton
|
||||
onClicked: {
|
||||
oshelper.openContainingFolder(walletManager.urlToLocalPath(saveTxDialog.fileUrl))
|
||||
oshelper.openContainingFolder(walletManager.urlToLocalPath(saveTxDialog.selectedFile))
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -28,8 +28,8 @@
|
|||
|
||||
import QtQuick 2.9
|
||||
import QtQuick.Window 2.0
|
||||
import QtGraphicalEffects 1.0
|
||||
import QtQuick.Layouts 1.2
|
||||
import Qt5Compat.GraphicalEffects
|
||||
import QtQuick.Layouts
|
||||
|
||||
import FontAwesome 1.0
|
||||
import "." as MoneroComponents
|
||||
|
|
|
@ -27,9 +27,8 @@
|
|||
// THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
import QtQuick 2.9
|
||||
import QtQuick.Controls 1.4 as QtQuickControls1
|
||||
import QtQuick.Controls 2.2
|
||||
import QtQuick.Layouts 1.1
|
||||
import QtQuick.Controls
|
||||
import QtQuick.Layouts
|
||||
|
||||
import "../components" as MoneroComponents
|
||||
import FontAwesome 1.0
|
||||
|
@ -188,7 +187,7 @@ Rectangle {
|
|||
Layout.fillWidth: true
|
||||
Layout.preferredHeight: 71
|
||||
|
||||
QtQuickControls1.BusyIndicator {
|
||||
BusyIndicator {
|
||||
id: txAmountBusyIndicator
|
||||
Layout.fillHeight: true
|
||||
Layout.fillWidth: true
|
||||
|
@ -379,7 +378,7 @@ Rectangle {
|
|||
Layout.fillWidth: true
|
||||
Layout.preferredHeight: 50
|
||||
|
||||
QtQuickControls1.BusyIndicator {
|
||||
BusyIndicator {
|
||||
visible: !bottomTextAnimation.running
|
||||
running: !bottomTextAnimation.running
|
||||
scale: .5
|
||||
|
|
|
@ -27,7 +27,7 @@
|
|||
// THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
import QtQuick 2.9
|
||||
import QtGraphicalEffects 1.0
|
||||
import Qt5Compat.GraphicalEffects
|
||||
|
||||
import "../" as MoneroComponents
|
||||
|
||||
|
|
|
@ -27,7 +27,7 @@
|
|||
// THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
import QtQuick 2.9
|
||||
import QtGraphicalEffects 1.0
|
||||
import Qt5Compat.GraphicalEffects
|
||||
|
||||
import "../" as MoneroComponents
|
||||
|
||||
|
|
|
@ -27,7 +27,7 @@
|
|||
// THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
import QtQuick 2.9
|
||||
import QtGraphicalEffects 1.0
|
||||
import Qt5Compat.GraphicalEffects
|
||||
|
||||
import "../" as MoneroComponents
|
||||
import FontAwesome 1.0
|
||||
|
|
|
@ -1 +1 @@
|
|||
qt5_add_resources(RESOURCE_FILES *.otf)
|
||||
qt6_add_resources(RESOURCE_FILES *.otf)
|
||||
|
|
|
@ -1 +1 @@
|
|||
qt5_add_resources(RESOURCE_FILES *.png)
|
||||
qt6_add_resources(RESOURCE_FILES *.png)
|
||||
|
|
|
@ -119,7 +119,7 @@ Source: "bin\opengl32sw.dll"; DestDir: "{app}"; Flags: ignoreversion
|
|||
; Deleting them is simpler and faster than forcing a full re-install.
|
||||
[InstallDelete]
|
||||
Type: filesandordirs; Name: "{app}\translations"
|
||||
Type: files; Name: "{app}\Qt5*.dll"
|
||||
Type: files; Name: "{app}\Qt6*.dll"
|
||||
Type: filesandordirs; Name: "{app}\Qt"
|
||||
Type: filesandordirs; Name: "{app}\audio"
|
||||
Type: filesandordirs; Name: "{app}\bearer"
|
||||
|
|
|
@ -1 +1 @@
|
|||
qt5_add_resources(RESOURCE_FILES *.js)
|
||||
qt6_add_resources(RESOURCE_FILES *.js)
|
||||
|
|
32
main.qml
32
main.qml
|
@ -26,13 +26,12 @@
|
|||
// 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.
|
||||
|
||||
import QtQml.Models 2.2
|
||||
import QtQuick 2.9
|
||||
import QtQuick.Window 2.0
|
||||
import QtQuick.Controls 1.1
|
||||
import QtQuick.Controls.Styles 1.1
|
||||
import QtQuick.Dialogs 1.2
|
||||
import QtGraphicalEffects 1.0
|
||||
import Qt5Compat.GraphicalEffects
|
||||
import QtQml.Models
|
||||
import QtQuick
|
||||
import QtQuick.Window
|
||||
import QtQuick.Controls
|
||||
import QtQuick.Dialogs
|
||||
|
||||
import FontAwesome 1.0
|
||||
|
||||
|
@ -904,8 +903,8 @@ ApplicationWindow {
|
|||
FileDialog {
|
||||
id: saveTxDialog
|
||||
title: "Please choose a location"
|
||||
folder: "file://" + appWindow.accountsDir
|
||||
selectExisting: false;
|
||||
currentFolder: "file://" + appWindow.accountsDir
|
||||
fileMode: FileDialog.SaveFile;
|
||||
|
||||
onAccepted: {
|
||||
handleTransactionConfirmed()
|
||||
|
@ -949,12 +948,12 @@ ApplicationWindow {
|
|||
// View only wallet - we save the tx
|
||||
if(viewOnly){
|
||||
// No file specified - abort
|
||||
if(!saveTxDialog.fileUrl) {
|
||||
if(!saveTxDialog.selectedFile) {
|
||||
currentWallet.disposeTransaction(transaction)
|
||||
return;
|
||||
}
|
||||
|
||||
var path = walletManager.urlToLocalPath(saveTxDialog.fileUrl)
|
||||
var path = walletManager.urlToLocalPath(saveTxDialog.selectedFile)
|
||||
|
||||
// Store to file
|
||||
transaction.setFilename(path);
|
||||
|
@ -1361,7 +1360,7 @@ ApplicationWindow {
|
|||
} else if (isLinux) {
|
||||
confirmationDialog.title = qsTr("Desktop entry") + translationManager.emptyString;
|
||||
confirmationDialog.text = qsTr("Would you like to register Monero GUI Desktop entry?") + translationManager.emptyString;
|
||||
confirmationDialog.icon = StandardIcon.Question;
|
||||
// confirmationDialog.icon = QMessageBox::Question;
|
||||
confirmationDialog.cancelText = qsTr("No") + translationManager.emptyString;
|
||||
confirmationDialog.okText = qsTr("Yes") + translationManager.emptyString;
|
||||
confirmationDialog.onAcceptedCallback = function() {
|
||||
|
@ -1646,18 +1645,17 @@ ApplicationWindow {
|
|||
}
|
||||
|
||||
// Choose blockchain folder
|
||||
FileDialog {
|
||||
FolderDialog {
|
||||
id: blockchainFileDialog
|
||||
property string directory: ""
|
||||
signal changed();
|
||||
|
||||
title: "Please choose a folder"
|
||||
selectFolder: true
|
||||
folder: "file://" + persistentSettings.blockchainDataDir
|
||||
currentFolder: "file://" + persistentSettings.blockchainDataDir
|
||||
|
||||
onRejected: console.log("data dir selection canceled")
|
||||
onAccepted: {
|
||||
var dataDir = walletManager.urlToLocalPath(blockchainFileDialog.fileUrl)
|
||||
var dataDir = walletManager.urlToLocalPath(blockchainFileDialog.folder)
|
||||
var validator = daemonManager.validateDataDir(dataDir);
|
||||
if(validator.valid) {
|
||||
persistentSettings.blockchainDataDir = dataDir;
|
||||
|
@ -1685,7 +1683,7 @@ ApplicationWindow {
|
|||
confirmationDialog.open()
|
||||
}
|
||||
|
||||
blockchainFileDialog.directory = blockchainFileDialog.fileUrl;
|
||||
blockchainFileDialog.directory = blockchainFileDialog.folder;
|
||||
delete validator;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -28,9 +28,8 @@
|
|||
|
||||
import QtQuick 2.9
|
||||
import QtQuick.Controls 2.0
|
||||
import QtQuick.Controls.Styles 1.4
|
||||
import QtQuick.Layouts 1.1
|
||||
import QtQuick.Dialogs 1.2
|
||||
import QtQuick.Layouts
|
||||
import QtQuick.Dialogs
|
||||
import FontAwesome 1.0
|
||||
|
||||
import "../components" as MoneroComponents
|
||||
|
|
|
@ -28,8 +28,8 @@
|
|||
|
||||
import QtQuick 2.9
|
||||
import QtQuick.Controls 2.0
|
||||
import QtQuick.Layouts 1.1
|
||||
import QtQuick.Dialogs 1.2
|
||||
import QtQuick.Layouts
|
||||
import QtQuick.Dialogs
|
||||
|
||||
import "../components" as MoneroComponents
|
||||
import "../components/effects/" as MoneroEffects
|
||||
|
|
|
@ -27,9 +27,8 @@
|
|||
// THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
import QtQuick 2.9
|
||||
import QtQuick.Controls 1.4
|
||||
import QtQuick.Controls.Styles 1.4
|
||||
import QtQuick.Layouts 1.1
|
||||
import QtQuick.Controls
|
||||
import QtQuick.Layouts
|
||||
import "../components" as MoneroComponents
|
||||
import "."
|
||||
|
||||
|
@ -127,24 +126,22 @@ ColumnLayout {
|
|||
anchors.fill: parent
|
||||
clip: false // otherwise animation will affect left panel
|
||||
|
||||
delegate: StackViewDelegate {
|
||||
pushTransition: StackViewTransition {
|
||||
PropertyAnimation {
|
||||
target: enterItem
|
||||
property: "x"
|
||||
from: (navbarId.currentIndex < navbarId.previousIndex ? 1 : -1) * - target.width
|
||||
to: 0
|
||||
duration: 300
|
||||
easing.type: Easing.OutCubic
|
||||
}
|
||||
PropertyAnimation {
|
||||
target: exitItem
|
||||
property: "x"
|
||||
from: 0
|
||||
to: (navbarId.currentIndex < navbarId.previousIndex ? 1 : -1) * target.width
|
||||
duration: 300
|
||||
easing.type: Easing.OutCubic
|
||||
}
|
||||
pushEnter: Transition {
|
||||
PropertyAnimation {
|
||||
target: enterItem
|
||||
property: "x"
|
||||
from: (navbarId.currentIndex < navbarId.previousIndex ? 1 : -1) * - target.width
|
||||
to: 0
|
||||
duration: 300
|
||||
easing.type: Easing.OutCubic
|
||||
}
|
||||
PropertyAnimation {
|
||||
target: exitItem
|
||||
property: "x"
|
||||
from: 0
|
||||
to: (navbarId.currentIndex < navbarId.previousIndex ? 1 : -1) * target.width
|
||||
duration: 300
|
||||
easing.type: Easing.OutCubic
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1 +1 @@
|
|||
qt5_add_resources(RESOURCE_FILES *.qrc)
|
||||
qt6_add_resources(RESOURCE_FILES *.qrc)
|
||||
|
|
|
@ -26,10 +26,10 @@
|
|||
// 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.
|
||||
|
||||
import QtQuick 2.0
|
||||
import QtQuick.Layouts 1.1
|
||||
import QtQuick.Dialogs 1.2
|
||||
import QtGraphicalEffects 1.0
|
||||
import QtQuick
|
||||
import QtQuick.Layouts
|
||||
import QtQuick.Dialogs
|
||||
import Qt5Compat.GraphicalEffects
|
||||
import moneroComponents.Wallet 1.0
|
||||
import moneroComponents.WalletManager 1.0
|
||||
import moneroComponents.TransactionHistory 1.0
|
||||
|
@ -1753,15 +1753,14 @@ Rectangle {
|
|||
+ translationManager.emptyString;
|
||||
}
|
||||
|
||||
FileDialog {
|
||||
FolderDialog {
|
||||
id: writeCSVFileDialog
|
||||
title: qsTr("Please choose a folder") + translationManager.emptyString
|
||||
selectFolder: true
|
||||
onRejected: {
|
||||
console.log("csv write canceled")
|
||||
}
|
||||
onAccepted: {
|
||||
var dataDir = walletManager.urlToLocalPath(writeCSVFileDialog.fileUrl);
|
||||
var dataDir = walletManager.urlToLocalPath(writeCSVFileDialog.folder);
|
||||
var written = currentWallet.history.writeCSV(currentWallet.currentSubaddressAccount, dataDir);
|
||||
|
||||
if(written !== ""){
|
||||
|
@ -1792,7 +1791,7 @@ Rectangle {
|
|||
}
|
||||
catch(err) {}
|
||||
finally {
|
||||
writeCSVFileDialog.folder = _folder;
|
||||
writeCSVFileDialog.currentFolder = _folder;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -27,10 +27,9 @@
|
|||
// THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
import QtQuick 2.9
|
||||
import QtQuick.Controls 1.4
|
||||
import QtQuick.Controls.Styles 1.4
|
||||
import QtQuick.Layouts 1.1
|
||||
import QtQuick.Dialogs 1.2
|
||||
import QtQuick.Controls
|
||||
import QtQuick.Layouts
|
||||
import QtQuick.Dialogs
|
||||
import moneroComponents.Clipboard 1.0
|
||||
import "../version.js" as Version
|
||||
import "../components" as MoneroComponents
|
||||
|
|
|
@ -28,8 +28,8 @@
|
|||
|
||||
import QtQml.Models 2.2
|
||||
import QtQuick 2.9
|
||||
import QtQuick.Layouts 1.1
|
||||
import QtQuick.Dialogs 1.2
|
||||
import QtQuick.Layouts
|
||||
import QtQuick.Dialogs
|
||||
import "../components" as MoneroComponents
|
||||
import moneroComponents.Wallet 1.0
|
||||
import moneroComponents.P2PoolManager 1.0
|
||||
|
|
|
@ -26,11 +26,11 @@
|
|||
// 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.
|
||||
|
||||
import QtQuick 2.9
|
||||
import QtQuick.Controls 2.0
|
||||
import QtQuick.Controls.Styles 1.4
|
||||
import QtQuick.Layouts 1.1
|
||||
import QtQuick.Dialogs 1.2
|
||||
import QtCore
|
||||
import QtQuick
|
||||
import QtQuick.Controls
|
||||
import QtQuick.Layouts
|
||||
import QtQuick.Dialogs
|
||||
import FontAwesome 1.0
|
||||
|
||||
import "../components" as MoneroComponents
|
||||
|
@ -261,8 +261,8 @@ Rectangle {
|
|||
amountToReceiveXMR.text = fiatApiConvertToXMR(amountToReceiveFiat.text);
|
||||
}
|
||||
}
|
||||
validator: RegExpValidator {
|
||||
regExp: /^\s*(\d{1,8})?([\.,]\d{1,2})?\s*$/
|
||||
validator: RegularExpressionValidator {
|
||||
regularExpression: /^\s*(\d{1,8})?([\.,]\d{1,2})?\s*$/
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -321,8 +321,8 @@ Rectangle {
|
|||
amountToReceiveFiat.text = fiatApiConvertToFiat(amountToReceiveXMR.text);
|
||||
}
|
||||
}
|
||||
validator: RegExpValidator {
|
||||
regExp: /^\s*(\d{1,8})?([\.,]\d{1,12})?\s*$/
|
||||
validator: RegularExpressionValidator {
|
||||
regularExpression: /^\s*(\d{1,8})?([\.,]\d{1,12})?\s*$/
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -744,24 +744,24 @@ Rectangle {
|
|||
|
||||
MessageDialog {
|
||||
id: receivePageDialog
|
||||
standardButtons: StandardButton.Ok
|
||||
buttons: MessageDialog.Ok
|
||||
}
|
||||
|
||||
FileDialog {
|
||||
id: qrFileDialog
|
||||
title: qsTr("Please choose a name") + translationManager.emptyString
|
||||
folder: shortcuts.pictures
|
||||
selectExisting: false
|
||||
currentFolder: StandardPaths.writableLocation(StandardPaths.PicturesLocation)
|
||||
fileMode: FileDialog.SaveFile
|
||||
nameFilters: ["Image (*.png)"]
|
||||
onAccepted: {
|
||||
if(!walletManager.saveQrCode(generateQRCodeString(), walletManager.urlToLocalPath(fileUrl))) {
|
||||
console.log("Failed to save QrCode to file " + walletManager.urlToLocalPath(fileUrl) )
|
||||
if(!walletManager.saveQrCode(generateQRCodeString(), walletManager.urlToLocalPath(selectedFile))) {
|
||||
console.log("Failed to save QrCode to file " + walletManager.urlToLocalPath(selectedFile) )
|
||||
receivePageDialog.title = qsTr("Save QrCode") + translationManager.emptyString;
|
||||
receivePageDialog.text = qsTr("Failed to save QrCode to ") + walletManager.urlToLocalPath(fileUrl) + translationManager.emptyString;
|
||||
receivePageDialog.text = qsTr("Failed to save QrCode to ") + walletManager.urlToLocalPath(selectedFile) + translationManager.emptyString;
|
||||
receivePageDialog.icon = StandardIcon.Error
|
||||
receivePageDialog.open()
|
||||
} else {
|
||||
appWindow.showStatusMessage(qsTr("QR code saved to ") + walletManager.urlToLocalPath(fileUrl) + translationManager.emptyString, 3);
|
||||
appWindow.showStatusMessage(qsTr("QR code saved to ") + walletManager.urlToLocalPath(selectedFile) + translationManager.emptyString, 3);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -27,10 +27,9 @@
|
|||
// THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
import QtQuick 2.9
|
||||
import QtQuick.Controls 1.4
|
||||
import QtQuick.Controls.Styles 1.4
|
||||
import QtQuick.Layouts 1.1
|
||||
import QtQuick.Dialogs 1.2
|
||||
import QtQuick.Controls
|
||||
import QtQuick.Layouts
|
||||
import QtQuick.Dialogs
|
||||
|
||||
import "../components" as MoneroComponents
|
||||
import moneroComponents.Clipboard 1.0
|
||||
|
@ -81,7 +80,7 @@ Rectangle {
|
|||
|
||||
MessageDialog {
|
||||
id: sharedRingDBDialog
|
||||
standardButtons: StandardButton.Ok
|
||||
buttons: MessageDialog.Ok
|
||||
}
|
||||
|
||||
MoneroComponents.Label {
|
||||
|
|
|
@ -27,10 +27,9 @@
|
|||
// THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
import QtQuick 2.9
|
||||
import QtQuick.Controls 1.4
|
||||
import QtQuick.Controls.Styles 1.4
|
||||
import QtQuick.Layouts 1.1
|
||||
import QtQuick.Dialogs 1.2
|
||||
import QtQuick.Controls
|
||||
import QtQuick.Layouts
|
||||
import QtQuick.Dialogs
|
||||
|
||||
import moneroComponents.Clipboard 1.0
|
||||
import moneroComponents.WalletManager 1.0
|
||||
|
@ -49,7 +48,7 @@ Rectangle {
|
|||
// dynamically change onclose handler
|
||||
property var onCloseCallback
|
||||
id: signatureVerificationMessage
|
||||
standardButtons: StandardButton.Ok
|
||||
buttons: MessageDialog.Ok
|
||||
onAccepted: {
|
||||
if (onCloseCallback) {
|
||||
onCloseCallback()
|
||||
|
@ -401,22 +400,22 @@ Rectangle {
|
|||
FileDialog {
|
||||
id: signFileDialog
|
||||
title: qsTr("Please choose a file to sign") + translationManager.emptyString;
|
||||
folder: "file://"
|
||||
currentFolder: "file://"
|
||||
nameFilters: [ "*"]
|
||||
|
||||
onAccepted: {
|
||||
signFileLine.text = walletManager.urlToLocalPath(signFileDialog.fileUrl)
|
||||
signFileLine.text = walletManager.urlToLocalPath(signFileDialog.selectedFile)
|
||||
}
|
||||
}
|
||||
|
||||
FileDialog {
|
||||
id: verifyFileDialog
|
||||
title: qsTr("Please choose a file to verify") + translationManager.emptyString;
|
||||
folder: "file://"
|
||||
currentFolder: "file://"
|
||||
nameFilters: [ "*"]
|
||||
|
||||
onAccepted: {
|
||||
verifyFileLine.text = walletManager.urlToLocalPath(verifyFileDialog.fileUrl)
|
||||
verifyFileLine.text = walletManager.urlToLocalPath(verifyFileDialog.selectedFile)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -26,11 +26,11 @@
|
|||
// 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.
|
||||
|
||||
import QtQml.Models 2.2
|
||||
import QtQuick 2.9
|
||||
import QtQuick.Controls 1.4
|
||||
import QtQuick.Layouts 1.1
|
||||
import QtQuick.Dialogs 1.2
|
||||
import QtQml.Models
|
||||
import QtQuick
|
||||
import QtQuick.Controls
|
||||
import QtQuick.Layouts
|
||||
import QtQuick.Dialogs
|
||||
import moneroComponents.Clipboard 1.0
|
||||
import moneroComponents.PendingTransaction 1.0
|
||||
import moneroComponents.Wallet 1.0
|
||||
|
@ -480,8 +480,8 @@ Rectangle {
|
|||
|
||||
amount = text;
|
||||
}
|
||||
validator: RegExpValidator {
|
||||
regExp: /^\s*(\d{1,8})?([\.,]\d{1,12})?\s*$/
|
||||
validator: RegularExpressionValidator {
|
||||
regularExpression: /^\s*(\d{1,8})?([\.,]\d{1,12})?\s*$/
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -989,11 +989,11 @@ Rectangle {
|
|||
FileDialog {
|
||||
id: signTxDialog
|
||||
title: qsTr("Please choose a file") + translationManager.emptyString
|
||||
folder: "file://" + appWindow.accountsDir
|
||||
currentFolder: "file://" + appWindow.accountsDir
|
||||
nameFilters: [ "Unsigned transfers (*)"]
|
||||
|
||||
onAccepted: {
|
||||
var path = walletManager.urlToLocalPath(fileUrl);
|
||||
var path = walletManager.urlToLocalPath(selectedFile);
|
||||
// Load the unsigned tx from file
|
||||
var transaction = currentWallet.loadTxFile(path);
|
||||
|
||||
|
@ -1033,11 +1033,11 @@ Rectangle {
|
|||
FileDialog {
|
||||
id: submitTxDialog
|
||||
title: qsTr("Please choose a file") + translationManager.emptyString
|
||||
folder: "file://" + appWindow.accountsDir
|
||||
currentFolder: "file://" + appWindow.accountsDir
|
||||
nameFilters: [ "signed transfers (*)"]
|
||||
|
||||
onAccepted: {
|
||||
if(!currentWallet.submitTxFile(walletManager.urlToLocalPath(fileUrl))){
|
||||
if(!currentWallet.submitTxFile(walletManager.urlToLocalPath(selectedFile))){
|
||||
informationPopup.title = qsTr("Error") + translationManager.emptyString;
|
||||
informationPopup.text = qsTr("Can't submit transaction: ") + currentWallet.errorString
|
||||
informationPopup.icon = StandardIcon.Critical
|
||||
|
@ -1059,11 +1059,10 @@ Rectangle {
|
|||
|
||||
FileDialog {
|
||||
id: exportOutputsDialog
|
||||
selectMultiple: false
|
||||
selectExisting: false
|
||||
fileMode: FileDialog.SaveFile
|
||||
onAccepted: {
|
||||
console.log(walletManager.urlToLocalPath(exportOutputsDialog.fileUrl))
|
||||
if (currentWallet.exportOutputs(walletManager.urlToLocalPath(exportOutputsDialog.fileUrl), true)) {
|
||||
console.log(walletManager.urlToLocalPath(exportOutputsDialog.selectedFile))
|
||||
if (currentWallet.exportOutputs(walletManager.urlToLocalPath(exportOutputsDialog.selectedFile), true)) {
|
||||
appWindow.showStatusMessage(qsTr("Outputs successfully exported to file") + translationManager.emptyString, 3);
|
||||
} else {
|
||||
appWindow.showStatusMessage(currentWallet.errorString, 5);
|
||||
|
@ -1076,12 +1075,11 @@ Rectangle {
|
|||
|
||||
FileDialog {
|
||||
id: importOutputsDialog
|
||||
selectMultiple: false
|
||||
selectExisting: true
|
||||
fileMode: FileDialog.OpenFile
|
||||
title: qsTr("Please choose a file") + translationManager.emptyString
|
||||
onAccepted: {
|
||||
console.log(walletManager.urlToLocalPath(importOutputsDialog.fileUrl))
|
||||
if (currentWallet.importOutputs(walletManager.urlToLocalPath(importOutputsDialog.fileUrl))) {
|
||||
console.log(walletManager.urlToLocalPath(importOutputsDialog.selectedFile))
|
||||
if (currentWallet.importOutputs(walletManager.urlToLocalPath(importOutputsDialog.selectedFile))) {
|
||||
appWindow.showStatusMessage(qsTr("Outputs successfully imported to wallet") + translationManager.emptyString, 3);
|
||||
} else {
|
||||
appWindow.showStatusMessage(currentWallet.errorString, 5);
|
||||
|
@ -1095,11 +1093,10 @@ Rectangle {
|
|||
//ExportKeyImagesDialog
|
||||
FileDialog {
|
||||
id: exportKeyImagesDialog
|
||||
selectMultiple: false
|
||||
selectExisting: false
|
||||
fileMode: FileDialog.SaveFile
|
||||
onAccepted: {
|
||||
console.log(walletManager.urlToLocalPath(exportKeyImagesDialog.fileUrl))
|
||||
if (currentWallet.exportKeyImages(walletManager.urlToLocalPath(exportKeyImagesDialog.fileUrl), true)) {
|
||||
console.log(walletManager.urlToLocalPath(exportKeyImagesDialog.selectedFile))
|
||||
if (currentWallet.exportKeyImages(walletManager.urlToLocalPath(exportKeyImagesDialog.selectedFile), true)) {
|
||||
appWindow.showStatusMessage(qsTr("Key images successfully exported to file") + translationManager.emptyString, 3);
|
||||
} else {
|
||||
appWindow.showStatusMessage(currentWallet.errorString, 5);
|
||||
|
@ -1113,12 +1110,11 @@ Rectangle {
|
|||
//ImportKeyImagesDialog
|
||||
FileDialog {
|
||||
id: importKeyImagesDialog
|
||||
selectMultiple: false
|
||||
selectExisting: true
|
||||
fileMode: FileDialog.OpenFile
|
||||
title: qsTr("Please choose a file") + translationManager.emptyString
|
||||
onAccepted: {
|
||||
console.log(walletManager.urlToLocalPath(importKeyImagesDialog.fileUrl))
|
||||
if (currentWallet.importKeyImages(walletManager.urlToLocalPath(importKeyImagesDialog.fileUrl))) {
|
||||
console.log(walletManager.urlToLocalPath(importKeyImagesDialog.selectedFile))
|
||||
if (currentWallet.importKeyImages(walletManager.urlToLocalPath(importKeyImagesDialog.selectedFile))) {
|
||||
appWindow.showStatusMessage(qsTr("Key images successfully imported to wallet") + translationManager.emptyString, 3);
|
||||
} else {
|
||||
appWindow.showStatusMessage(currentWallet.errorString, 5);
|
||||
|
|
|
@ -26,10 +26,9 @@
|
|||
// 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.
|
||||
|
||||
import QtQuick 2.9
|
||||
import QtQuick.Controls 1.4
|
||||
import QtQuick.Controls.Styles 1.4
|
||||
import QtQuick.Layouts 1.1
|
||||
import QtQuick
|
||||
import QtQuick.Controls
|
||||
import QtQuick.Layouts
|
||||
|
||||
import "../components" as MoneroComponents
|
||||
import moneroComponents.Clipboard 1.0
|
||||
|
@ -125,8 +124,8 @@ Rectangle {
|
|||
}
|
||||
error = walletManager.amountFromString(text) > appWindow.getUnlockedBalance();
|
||||
}
|
||||
validator: RegExpValidator {
|
||||
regExp: /^\s*(\d{1,8})?([\.,]\d{1,12})?\s*$/
|
||||
validator: RegularExpressionValidator {
|
||||
regularExpression: /^\s*(\d{1,8})?([\.,]\d{1,12})?\s*$/
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -1,9 +1,9 @@
|
|||
import QtQuick 2.9
|
||||
import QtQuick.Layouts 1.1
|
||||
import QtQuick.Controls 2.0
|
||||
import QtGraphicalEffects 1.0
|
||||
import QtQuick.Controls.Styles 1.4
|
||||
import QtQuick.Dialogs 1.2
|
||||
import QtCore
|
||||
import QtQuick
|
||||
import QtQuick.Layouts
|
||||
import QtQuick.Controls
|
||||
import Qt5Compat.GraphicalEffects
|
||||
import QtQuick.Dialogs
|
||||
|
||||
import moneroComponents.Clipboard 1.0
|
||||
import moneroComponents.Wallet 1.0
|
||||
|
@ -485,8 +485,8 @@ Item {
|
|||
amountToReceive.text = '0' + amountToReceive.text;
|
||||
}
|
||||
}
|
||||
validator: RegExpValidator {
|
||||
regExp: /^(\d{1,8})?([\.]\d{1,12})?$/
|
||||
validator: RegularExpressionValidator {
|
||||
regularExpression: /^(\d{1,8})?([\.]\d{1,12})?$/
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -675,20 +675,20 @@ Item {
|
|||
|
||||
MessageDialog {
|
||||
id: merchantPageDialog
|
||||
standardButtons: StandardButton.Ok
|
||||
buttons: MessageDialog.Ok
|
||||
}
|
||||
|
||||
FileDialog {
|
||||
id: qrFileDialog
|
||||
title: "Please choose a name"
|
||||
folder: shortcuts.pictures
|
||||
selectExisting: false
|
||||
currentFolder: StandardPaths.writableLocation(StandardPaths.PicturesLocation)
|
||||
fileMode: FileDialog.SaveFile
|
||||
nameFilters: ["Image (*.png)"]
|
||||
onAccepted: {
|
||||
if (!walletManager.saveQrCode(walletManager.make_uri(appWindow.current_address, walletManager.amountFromString(amountToReceive.text)), walletManager.urlToLocalPath(fileUrl))) {
|
||||
console.log("Failed to save QrCode to file " + walletManager.urlToLocalPath(fileUrl) )
|
||||
if (!walletManager.saveQrCode(walletManager.make_uri(appWindow.current_address, walletManager.amountFromString(amountToReceive.text)), walletManager.urlToLocalPath(selectedFile))) {
|
||||
console.log("Failed to save QrCode to file " + walletManager.urlToLocalPath(selectedFile) )
|
||||
receivePageDialog.title = qsTr("Save QrCode") + translationManager.emptyString;
|
||||
receivePageDialog.text = qsTr("Failed to save QrCode to ") + walletManager.urlToLocalPath(fileUrl) + translationManager.emptyString;
|
||||
receivePageDialog.text = qsTr("Failed to save QrCode to ") + walletManager.urlToLocalPath(selectedFile) + translationManager.emptyString;
|
||||
receivePageDialog.icon = StandardIcon.Error
|
||||
receivePageDialog.open()
|
||||
}
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
import QtQuick 2.9
|
||||
import QtQuick.Layouts 1.1
|
||||
import QtGraphicalEffects 1.0
|
||||
import QtQuick.Layouts
|
||||
import Qt5Compat.GraphicalEffects
|
||||
|
||||
import "../../components" as MoneroComponents
|
||||
|
||||
|
|
|
@ -28,8 +28,8 @@
|
|||
|
||||
import QtQuick 2.9
|
||||
import QtQuick.Window 2.0
|
||||
import QtGraphicalEffects 1.0
|
||||
import QtQuick.Layouts 1.2
|
||||
import Qt5Compat.GraphicalEffects
|
||||
import QtQuick.Layouts
|
||||
|
||||
import FontAwesome 1.0
|
||||
import "../../components/" as MoneroComponents
|
||||
|
|
|
@ -1,8 +1,7 @@
|
|||
import QtQuick 2.9
|
||||
import QtQuick.Controls 2.0
|
||||
import QtQuick.Controls.Styles 1.4
|
||||
import QtQuick.Layouts 1.1
|
||||
import QtQuick.Dialogs 1.2
|
||||
import QtQuick.Layouts
|
||||
import QtQuick.Dialogs
|
||||
|
||||
import "../../js/Utils.js" as Utils
|
||||
import "../../components" as MoneroComponents
|
||||
|
|
|
@ -26,11 +26,10 @@
|
|||
// 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.
|
||||
|
||||
import QtQuick 2.9
|
||||
import QtQuick.Controls 1.4
|
||||
import QtQuick.Controls.Styles 1.4
|
||||
import QtQuick.Layouts 1.1
|
||||
import QtQuick.Dialogs 1.2
|
||||
import QtQuick
|
||||
import QtQuick.Controls
|
||||
import QtQuick.Layouts
|
||||
import QtQuick.Dialogs
|
||||
import "../../js/Windows.js" as Windows
|
||||
import "../../js/Utils.js" as Utils
|
||||
import "../../components" as MoneroComponents
|
||||
|
@ -142,7 +141,7 @@ ColumnLayout {
|
|||
anchors.fill: parent
|
||||
clip: false // otherwise animation will affect left panel
|
||||
|
||||
delegate: StackViewDelegate {
|
||||
/*delegate: StackViewDelegate {
|
||||
pushTransition: StackViewTransition {
|
||||
PropertyAnimation {
|
||||
target: enterItem
|
||||
|
@ -161,7 +160,7 @@ ColumnLayout {
|
|||
easing.type: Easing.OutCubic
|
||||
}
|
||||
}
|
||||
}
|
||||
}*/
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -26,10 +26,10 @@
|
|||
// 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.
|
||||
|
||||
import QtQuick 2.9
|
||||
import QtQuick.Layouts 1.1
|
||||
import QtQuick.Controls 2.0
|
||||
import QtQuick.Dialogs 1.2
|
||||
import QtQuick
|
||||
import QtQuick.Layouts
|
||||
import QtQuick.Controls
|
||||
import QtQuick.Dialogs
|
||||
|
||||
import "../../js/Wizard.js" as Wizard
|
||||
import "../../js/Utils.js" as Utils
|
||||
|
|
|
@ -26,10 +26,10 @@
|
|||
// 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.
|
||||
|
||||
import QtQuick 2.9
|
||||
import QtQuick.Layouts 1.1
|
||||
import QtQuick.Controls 2.0
|
||||
import QtQuick.Dialogs 1.2
|
||||
import QtQuick
|
||||
import QtQuick.Layouts
|
||||
import QtQuick.Controls
|
||||
import QtQuick.Dialogs
|
||||
|
||||
import "../../js/Utils.js" as Utils
|
||||
import "../../js/Windows.js" as Windows
|
||||
|
|
|
@ -26,9 +26,9 @@
|
|||
// 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.
|
||||
|
||||
import QtQuick 2.9
|
||||
import QtQuick.Layouts 1.1
|
||||
import QtQuick.Controls 2.2
|
||||
import QtQuick
|
||||
import QtQuick.Layouts
|
||||
import QtQuick.Controls
|
||||
|
||||
import "../../js/Utils.js" as Utils
|
||||
import "../../components" as MoneroComponents
|
||||
|
|
|
@ -26,9 +26,9 @@
|
|||
// 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.
|
||||
|
||||
import QtQuick 2.9
|
||||
import QtQuick.Layouts 1.1
|
||||
import QtQuick.Controls 2.0
|
||||
import QtQuick
|
||||
import QtQuick.Layouts
|
||||
import QtQuick.Controls
|
||||
import FontAwesome 1.0
|
||||
|
||||
import "../../components" as MoneroComponents
|
||||
|
|
|
@ -26,10 +26,10 @@
|
|||
// 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.
|
||||
|
||||
import QtQuick 2.9
|
||||
import QtQuick.Layouts 1.1
|
||||
import QtQuick.Controls 2.0
|
||||
import QtQuick.Dialogs 1.2
|
||||
import QtQuick
|
||||
import QtQuick.Layouts
|
||||
import QtQuick.Controls
|
||||
import QtQuick.Dialogs
|
||||
import FontAwesome 1.0
|
||||
|
||||
import "../../js/Utils.js" as Utils
|
||||
|
|
|
@ -1,2 +1,2 @@
|
|||
[Controls]
|
||||
Style=Desktop
|
||||
Style=Fusion
|
||||
|
|
|
@ -2,7 +2,7 @@ add_subdirectory(QR-Code-scanner)
|
|||
add_subdirectory(openpgp)
|
||||
add_subdirectory(zxcvbn-c)
|
||||
|
||||
qt5_add_resources(RESOURCES ../qml.qrc)
|
||||
qt6_add_resources(RESOURCES ../qml.qrc)
|
||||
|
||||
# Compile source files (.h/.cpp)
|
||||
file(GLOB SOURCE_FILES
|
||||
|
@ -55,8 +55,8 @@ if(MINGW)
|
|||
set(ICON_RC ${CMAKE_CURRENT_BINARY_DIR}/icon.rc)
|
||||
set(ICON_RES ${CMAKE_CURRENT_BINARY_DIR}/icon.o)
|
||||
file(WRITE ${ICON_RC} "IDI_ICON1 ICON DISCARDABLE \"${ICON}\"")
|
||||
find_program(Qt5_WINDRES_EXECUTABLE NAMES windres x86_64-w64-mingw32-windres REQUIRED CMAKE_FIND_ROOT_PATH_BOTH)
|
||||
add_custom_command(OUTPUT ${ICON_RES} COMMAND ${Qt5_WINDRES_EXECUTABLE} ${ICON_RC} ${ICON_RES} MAIN_DEPENDENCY ${ICON_RC})
|
||||
find_program(Qt6_WINDRES_EXECUTABLE NAMES windres x86_64-w64-mingw32-windres REQUIRED CMAKE_FIND_ROOT_PATH_BOTH)
|
||||
add_custom_command(OUTPUT ${ICON_RES} COMMAND ${Qt6_WINDRES_EXECUTABLE} ${ICON_RC} ${ICON_RES} MAIN_DEPENDENCY ${ICON_RC})
|
||||
list(APPEND RESOURCES ${ICON_RES})
|
||||
endif()
|
||||
|
||||
|
@ -74,7 +74,7 @@ set(monero_wallet_gui_sources
|
|||
if(NOT ANDROID)
|
||||
add_executable(monero-wallet-gui ${EXECUTABLE_FLAG} ${monero_wallet_gui_sources})
|
||||
else()
|
||||
add_library(monero-wallet-gui SHARED ${monero_wallet_gui_sources})
|
||||
qt_add_executable(monero-wallet-gui ${monero_wallet_gui_sources})
|
||||
set_target_properties(monero-wallet-gui PROPERTIES COMPILE_DEFINITIONS "ANDROID")
|
||||
endif()
|
||||
|
||||
|
@ -89,7 +89,7 @@ target_include_directories(monero-wallet-gui PUBLIC ${OPENGL_INCLUDE_DIR})
|
|||
message(STATUS "OpenGL: include dir at ${OPENGL_INCLUDE_DIR}")
|
||||
message(STATUS "OpenGL: libraries at ${OPENGL_LIBRARIES}")
|
||||
|
||||
target_include_directories(monero-wallet-gui PUBLIC ${Qt5Gui_PRIVATE_INCLUDE_DIRS})
|
||||
target_include_directories(monero-wallet-gui PUBLIC ${Qt6Gui_PRIVATE_INCLUDE_DIRS})
|
||||
|
||||
target_include_directories(monero-wallet-gui PUBLIC
|
||||
${CMAKE_SOURCE_DIR}/monero/include
|
||||
|
@ -109,8 +109,8 @@ target_include_directories(monero-wallet-gui PUBLIC
|
|||
|
||||
target_compile_definitions(monero-wallet-gui
|
||||
PUBLIC
|
||||
${Qt5Widgets_DEFINITIONS}
|
||||
${Qt5Qml_DEFINITIONS}
|
||||
${Qt6Widgets_DEFINITIONS}
|
||||
${Qt6Qml_DEFINITIONS}
|
||||
)
|
||||
|
||||
if(APPLE)
|
||||
|
@ -121,16 +121,16 @@ if(APPLE)
|
|||
target_link_directories(monero-wallet-gui PRIVATE ${ICU_ROOT}/lib)
|
||||
endif()
|
||||
|
||||
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${Qt5Widgets_EXECUTABLE_COMPILE_FLAGS}")
|
||||
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${Qt6Widgets_EXECUTABLE_COMPILE_FLAGS}")
|
||||
|
||||
target_link_libraries(monero-wallet-gui
|
||||
target_link_libraries(monero-wallet-gui PRIVATE
|
||||
epee
|
||||
common
|
||||
net
|
||||
wallet_api
|
||||
qrcodegen
|
||||
easylogging
|
||||
${QT5_LIBRARIES}
|
||||
${QT6_LIBRARIES}
|
||||
${EXTRA_LIBRARIES}
|
||||
openpgp
|
||||
qrdecoder
|
||||
|
@ -139,13 +139,13 @@ target_link_libraries(monero-wallet-gui
|
|||
)
|
||||
|
||||
if(X11_FOUND)
|
||||
target_link_libraries(monero-wallet-gui ${X11_LIBRARIES})
|
||||
target_link_libraries(monero-wallet-gui PRIVATE ${X11_LIBRARIES})
|
||||
endif()
|
||||
|
||||
if(WITH_SCANNER)
|
||||
target_link_libraries(monero-wallet-gui qrscanner)
|
||||
target_link_libraries(monero-wallet-gui PRIVATE qrscanner)
|
||||
if(LINUX AND NOT ANDROID)
|
||||
target_link_libraries(monero-wallet-gui
|
||||
target_link_libraries(monero-wallet-gui PRIVATE
|
||||
jpeg
|
||||
v4l2
|
||||
v4lconvert
|
||||
|
@ -154,6 +154,16 @@ if(WITH_SCANNER)
|
|||
endif()
|
||||
endif()
|
||||
|
||||
if(STATIC OR ANDROID)
|
||||
# Allows to bundle quick control styles
|
||||
qt6_add_qml_module(monero-wallet-gui
|
||||
URI org.monero-project.monero-wallet-gui
|
||||
QML_FILES
|
||||
../main.qml
|
||||
)
|
||||
qt6_import_qml_plugins(monero-wallet-gui)
|
||||
endif()
|
||||
|
||||
add_custom_command(TARGET monero-wallet-gui POST_BUILD COMMAND ${CMAKE_COMMAND} -E copy $<TARGET_FILE:daemon> $<TARGET_FILE_DIR:monero-wallet-gui>)
|
||||
|
||||
include(Deploy)
|
||||
|
|
|
@ -3,7 +3,7 @@ add_library(qrdecoder STATIC
|
|||
)
|
||||
target_link_libraries(qrdecoder
|
||||
PUBLIC
|
||||
Qt5::Gui
|
||||
Qt6::Gui
|
||||
PRIVATE
|
||||
quirc
|
||||
)
|
||||
|
@ -13,9 +13,10 @@ if(WITH_SCANNER)
|
|||
QrCodeScanner.cpp
|
||||
QrScanThread.cpp
|
||||
)
|
||||
find_package(Qt6 REQUIRED COMPONENTS Multimedia)
|
||||
target_link_libraries(qrscanner
|
||||
PUBLIC
|
||||
Qt5::Multimedia
|
||||
Qt6::Multimedia
|
||||
qrdecoder
|
||||
)
|
||||
endif()
|
||||
|
|
|
@ -27,8 +27,9 @@
|
|||
// THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
#include "QrCodeScanner.h"
|
||||
#include <QVideoProbe>
|
||||
#include <QMediaCaptureSession>
|
||||
#include <QCamera>
|
||||
#include <QVideoSink>
|
||||
|
||||
QrCodeScanner::QrCodeScanner(QObject *parent)
|
||||
: QObject(parent)
|
||||
|
@ -36,18 +37,18 @@ QrCodeScanner::QrCodeScanner(QObject *parent)
|
|||
, m_processInterval(750)
|
||||
, m_enabled(true)
|
||||
{
|
||||
m_probe = new QVideoProbe(this);
|
||||
m_probe = new QMediaCaptureSession(this);
|
||||
m_thread = new QrScanThread(this);
|
||||
m_thread->start();
|
||||
QObject::connect(m_thread, SIGNAL(decoded(QString)), this, SIGNAL(decoded(QString)));
|
||||
QObject::connect(m_thread, SIGNAL(notifyError(const QString &, bool)), this, SIGNAL(notifyError(const QString &, bool)));
|
||||
connect(m_probe, SIGNAL(videoFrameProbed(QVideoFrame)), this, SLOT(processFrame(QVideoFrame)));
|
||||
connect(m_probe->videoSink(), SIGNAL(videoFrameChanged(const QVideoFrame&)), this, SLOT(processFrame(const QVideoFrame&)));
|
||||
}
|
||||
void QrCodeScanner::setSource(QCamera *camera)
|
||||
{
|
||||
m_probe->setSource(camera);
|
||||
m_probe->setCamera(camera);
|
||||
}
|
||||
void QrCodeScanner::processFrame(QVideoFrame frame)
|
||||
void QrCodeScanner::processFrame(const QVideoFrame &frame)
|
||||
{
|
||||
if(frame.isValid()){
|
||||
m_curFrame = frame;
|
||||
|
|
|
@ -33,7 +33,7 @@
|
|||
#include <QVideoFrame>
|
||||
#include "QrScanThread.h"
|
||||
|
||||
class QVideoProbe;
|
||||
class QMediaCaptureSession;
|
||||
class QCamera;
|
||||
|
||||
class QrCodeScanner : public QObject
|
||||
|
@ -51,7 +51,7 @@ public:
|
|||
void setEnabled(bool enabled);
|
||||
|
||||
public Q_SLOTS:
|
||||
void processFrame(QVideoFrame);
|
||||
void processFrame(const QVideoFrame&);
|
||||
|
||||
Q_SIGNALS:
|
||||
void enabledChanged();
|
||||
|
@ -66,7 +66,7 @@ protected:
|
|||
int m_processInterval;
|
||||
int m_enabled;
|
||||
QVideoFrame m_curFrame;
|
||||
QVideoProbe *m_probe;
|
||||
QMediaCaptureSession *m_probe;
|
||||
};
|
||||
|
||||
#endif
|
||||
|
|
|
@ -56,11 +56,7 @@ void QrScanThread::processQImage(const QImage &qimg)
|
|||
|
||||
void QrScanThread::processVideoFrame(const QVideoFrame &frame)
|
||||
{
|
||||
#if QT_VERSION < QT_VERSION_CHECK(5, 15, 0)
|
||||
processQImage( qt_imageFromVideoFrame(frame) );
|
||||
#else
|
||||
processQImage(frame.image());
|
||||
#endif
|
||||
processQImage(frame.toImage());
|
||||
}
|
||||
|
||||
void QrScanThread::stop()
|
||||
|
|
|
@ -203,7 +203,7 @@ QString TransactionHistory::writeCSV(quint32 accountIndex, QString out)
|
|||
quint64 blockHeight = info.blockHeight();
|
||||
QDateTime timeStamp = info.timestamp();
|
||||
QString date = info.date() + " " + info.time();
|
||||
uint epoch = timeStamp.toTime_t();
|
||||
uint epoch = timeStamp.toSecsSinceEpoch();
|
||||
QString displayAmount = info.displayAmount();
|
||||
QString paymentId = info.paymentId();
|
||||
if(paymentId == "0000000000000000"){
|
||||
|
|
|
@ -161,7 +161,7 @@ TransactionInfo::TransactionInfo(const Monero::TransactionInfo *pimpl, QObject *
|
|||
, m_description(QString::fromStdString(pimpl->description()))
|
||||
, m_pending(pimpl->isPending())
|
||||
, m_subaddrAccount(pimpl->subaddrAccount())
|
||||
, m_timestamp(QDateTime::fromTime_t(pimpl->timestamp()))
|
||||
, m_timestamp(QDateTime::fromSecsSinceEpoch(pimpl->timestamp()))
|
||||
, m_unlockTime(pimpl->unlockTime())
|
||||
{
|
||||
for (auto const &t: pimpl->transfers())
|
||||
|
|
|
@ -41,10 +41,6 @@
|
|||
#include "Subaddress.h"
|
||||
#include "SubaddressAccount.h"
|
||||
#include "model/TransactionHistoryModel.h"
|
||||
#include "model/TransactionHistorySortFilterModel.h"
|
||||
#include "model/AddressBookModel.h"
|
||||
#include "model/SubaddressModel.h"
|
||||
#include "model/SubaddressAccountModel.h"
|
||||
#include "wallet/api/wallet2_api.h"
|
||||
|
||||
#include <QFile>
|
||||
|
@ -229,13 +225,12 @@ void Wallet::storeAsync(const QJSValue &callback, const QString &path /* = "" */
|
|||
const auto future = m_scheduler.run(
|
||||
[this, path] {
|
||||
QMutexLocker locker(&m_asyncMutex);
|
||||
|
||||
return QJSValueList({m_walletImpl->store(path.toStdString())});
|
||||
return QJSValueList() << m_walletImpl->store(path.toStdString());
|
||||
},
|
||||
callback);
|
||||
if (!future.first)
|
||||
{
|
||||
QJSValue(callback).call(QJSValueList({false}));
|
||||
QJSValue(callback).call(QJSValueList() << false);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -45,6 +45,10 @@
|
|||
#include "NetworkType.h"
|
||||
#include "PassphraseHelper.h"
|
||||
#include "WalletListenerImpl.h"
|
||||
#include "model/TransactionHistorySortFilterModel.h"
|
||||
#include "model/AddressBookModel.h"
|
||||
#include "model/SubaddressModel.h"
|
||||
#include "model/SubaddressAccountModel.h"
|
||||
|
||||
namespace Monero {
|
||||
struct Wallet; // forward declaration
|
||||
|
@ -53,13 +57,9 @@ struct Wallet; // forward declaration
|
|||
|
||||
class TransactionHistory;
|
||||
class TransactionHistoryModel;
|
||||
class TransactionHistorySortFilterModel;
|
||||
class AddressBook;
|
||||
class AddressBookModel;
|
||||
class Subaddress;
|
||||
class SubaddressModel;
|
||||
class SubaddressAccount;
|
||||
class SubaddressAccountModel;
|
||||
|
||||
class Wallet : public QObject, public PassprasePrompter
|
||||
{
|
||||
|
|
|
@ -42,6 +42,7 @@
|
|||
#include <QMutex>
|
||||
#include <QMutexLocker>
|
||||
#include <QString>
|
||||
#include <QStringView>
|
||||
|
||||
#include "qt/updater.h"
|
||||
#include "qt/ScopeGuard.h"
|
||||
|
@ -426,7 +427,7 @@ QVariantMap WalletManager::parse_uri_to_object(const QString &uri) const
|
|||
{
|
||||
for (const QString &item : unknown_parameters)
|
||||
{
|
||||
const auto parsed_item = item.splitRef("=");
|
||||
const auto parsed_item = QStringView{item}.split('=');
|
||||
if (parsed_item.size() == 2)
|
||||
{
|
||||
extra_parameters.insert(parsed_item[0].toString(), parsed_item[1].toString());
|
||||
|
|
|
@ -72,7 +72,7 @@ bool filter::eventFilter(QObject *obj, QEvent *ev) {
|
|||
sks = "Ctrl";
|
||||
#endif
|
||||
} else {
|
||||
QKeySequence ks(ke->modifiers() + ke->key());
|
||||
QKeySequence ks(ke->modifiers(), ke->key());
|
||||
sks = ks.toString();
|
||||
}
|
||||
#ifndef Q_OS_MAC
|
||||
|
@ -106,7 +106,7 @@ bool filter::eventFilter(QObject *obj, QEvent *ev) {
|
|||
sks = "Ctrl";
|
||||
#endif
|
||||
} else {
|
||||
QKeySequence ks(ke->modifiers() + ke->key());
|
||||
QKeySequence ks(ke->modifiers(), ke->key());
|
||||
sks = ks.toString();
|
||||
}
|
||||
#ifndef Q_OS_MAC
|
||||
|
|
|
@ -34,7 +34,6 @@
|
|||
#include <QDebug>
|
||||
#include <QDesktopServices>
|
||||
#include <QObject>
|
||||
#include <QDesktopWidget>
|
||||
#include <QScreen>
|
||||
#include <QThread>
|
||||
|
||||
|
@ -121,7 +120,7 @@ Q_IMPORT_PLUGIN(QQmlProfilerServiceFactory)
|
|||
Q_IMPORT_PLUGIN(QQuickProfilerAdapterFactory)
|
||||
Q_IMPORT_PLUGIN(QQmlDebugServerFactory)
|
||||
Q_IMPORT_PLUGIN(QTcpServerConnectionFactory)
|
||||
Q_IMPORT_PLUGIN(QGenericEnginePlugin)
|
||||
//Q_IMPORT_PLUGIN(QGenericEnginePlugin)
|
||||
|
||||
#if QT_VERSION >= QT_VERSION_CHECK(5, 14, 0)
|
||||
Q_IMPORT_PLUGIN(QtQmlPlugin)
|
||||
|
@ -130,18 +129,18 @@ Q_IMPORT_PLUGIN(QtQmlModelsPlugin)
|
|||
Q_IMPORT_PLUGIN(QtQuick2Plugin)
|
||||
Q_IMPORT_PLUGIN(QtQuickLayoutsPlugin)
|
||||
Q_IMPORT_PLUGIN(QtGraphicalEffectsPlugin)
|
||||
Q_IMPORT_PLUGIN(QtGraphicalEffectsPrivatePlugin)
|
||||
Q_IMPORT_PLUGIN(QtQuick2WindowPlugin)
|
||||
Q_IMPORT_PLUGIN(QtQuickControls1Plugin)
|
||||
Q_IMPORT_PLUGIN(QtQuick2DialogsPlugin)
|
||||
Q_IMPORT_PLUGIN(QtQuick_WindowPlugin)
|
||||
Q_IMPORT_PLUGIN(QtQuickDialogsPlugin)
|
||||
Q_IMPORT_PLUGIN(QmlFolderListModelPlugin)
|
||||
Q_IMPORT_PLUGIN(QmlSettingsPlugin)
|
||||
Q_IMPORT_PLUGIN(QtLabsPlatformPlugin)
|
||||
Q_IMPORT_PLUGIN(QtQuick2DialogsPrivatePlugin)
|
||||
Q_IMPORT_PLUGIN(QtQuick2PrivateWidgetsPlugin)
|
||||
Q_IMPORT_PLUGIN(QtQuickControls2Plugin)
|
||||
Q_IMPORT_PLUGIN(QtQuickControls2FusionStylePlugin)
|
||||
Q_IMPORT_PLUGIN(QtQuickControls2FusionStyleImplPlugin)
|
||||
Q_IMPORT_PLUGIN(QtQuickControls2BasicStylePlugin)
|
||||
Q_IMPORT_PLUGIN(QtQuickTemplates2Plugin)
|
||||
Q_IMPORT_PLUGIN(QmlXmlListModelPlugin)
|
||||
Q_IMPORT_PLUGIN(QtQmlXmlListModelPlugin)
|
||||
Q_IMPORT_PLUGIN(QtQmlCorePlugin)
|
||||
#ifdef WITH_SCANNER
|
||||
Q_IMPORT_PLUGIN(QMultimediaDeclarativeModule)
|
||||
#endif
|
||||
|
@ -191,7 +190,7 @@ int main(int argc, char *argv[])
|
|||
MacOSHelper::disableWindowTabbing();
|
||||
#endif
|
||||
// disable "QApplication: invalid style override passed" warning
|
||||
if (isDesktop) qputenv("QT_STYLE_OVERRIDE", "fusion");
|
||||
if (isDesktop) qputenv("QT_STYLE_OVERRIDE", "Fusion");
|
||||
#ifdef Q_OS_LINUX
|
||||
// platform xcb by default
|
||||
if (isDesktop && qEnvironmentVariableIsEmpty("QT_QPA_PLATFORM")) qputenv("QT_QPA_PLATFORM", "xcb");
|
||||
|
@ -455,6 +454,9 @@ Verify update binary using 'shasum'-compatible (SHA256 algo) output signed by tw
|
|||
engine.rootContext()->setContextProperty("oshelper", &osHelper);
|
||||
|
||||
engine.addImportPath(":/fonts");
|
||||
#if defined(_WIN32) && !defined(MONERO_GUI_STATIC)
|
||||
engine.addImportPath(QCoreApplication::applicationDirPath() + "/qml");
|
||||
#endif
|
||||
|
||||
engine.rootContext()->setContextProperty("moneroAccountsDir", moneroAccountsDir);
|
||||
|
||||
|
|
|
@ -57,6 +57,8 @@
|
|||
#undef KeyRelease
|
||||
#undef FocusIn
|
||||
#undef FocusOut
|
||||
#undef Status
|
||||
#undef Always
|
||||
// #undef those Xlib #defines that conflict with QEvent::Type enum
|
||||
#include "qt/utils.h"
|
||||
#endif
|
||||
|
|
|
@ -32,6 +32,9 @@
|
|||
#include <vector>
|
||||
|
||||
#include <gcrypt.h>
|
||||
#if defined(_WIN32)
|
||||
#undef interface
|
||||
#endif
|
||||
|
||||
#include <span.h>
|
||||
|
||||
|
|
|
@ -126,7 +126,7 @@ void WalletKeysFilesModel::findWallets(const QString &moneroAccountsDir)
|
|||
quint8 networkType = networkTypeAndAddress.first;
|
||||
QString address = networkTypeAndAddress.second;
|
||||
|
||||
this->addWalletKeysFile(WalletKeysFiles(wallet, networkType, std::move(address)));
|
||||
this->addWalletKeysFile(WalletKeysFiles(QFileInfo(wallet), networkType, std::move(address)));
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -136,7 +136,7 @@ bool Downloader::get(const QString &url, const QString &hash, const QJSValue &ca
|
|||
{
|
||||
QString error;
|
||||
auto task = m_scheduler.run([this, &error, &response, &url] {
|
||||
error = m_network.get(m_httpClient, url, response);
|
||||
error = m_network.get(m_httpClient->impl(), url, response);
|
||||
});
|
||||
if (!task.first)
|
||||
{
|
||||
|
|
|
@ -30,7 +30,6 @@
|
|||
|
||||
#include <QtCore>
|
||||
#include <QtGui>
|
||||
#include <QtMac>
|
||||
#include "macoshelper.h"
|
||||
|
||||
#import <Foundation/Foundation.h>
|
||||
|
|
|
@ -37,11 +37,25 @@ using epee::net_utils::http::fields_list;
|
|||
using epee::net_utils::http::http_response_info;
|
||||
using epee::net_utils::http::abstract_http_client;
|
||||
|
||||
bool _HttpClient::on_header(const epee::net_utils::http::http_response_info &headers)
|
||||
{
|
||||
if(not m_parent->on_header(headers))
|
||||
return false;
|
||||
return net::http::client::on_header(headers);
|
||||
}
|
||||
bool _HttpClient::handle_target_data(std::string &piece_of_transfer)
|
||||
{
|
||||
if(not m_parent->handle_target_data(piece_of_transfer))
|
||||
return false;
|
||||
return net::http::client::handle_target_data(piece_of_transfer);
|
||||
}
|
||||
|
||||
HttpClient::HttpClient(QObject *parent /* = nullptr */)
|
||||
: QObject(parent)
|
||||
, m_cancel(false)
|
||||
, m_contentLength(0)
|
||||
, m_received(0)
|
||||
, m_impl(new _HttpClient(this))
|
||||
{
|
||||
}
|
||||
|
||||
|
@ -78,7 +92,7 @@ bool HttpClient::on_header(const http_response_info &headers)
|
|||
m_received = 0;
|
||||
emit receivedChanged();
|
||||
|
||||
return net::http::client::on_header(headers);
|
||||
return true;
|
||||
}
|
||||
|
||||
bool HttpClient::handle_target_data(std::string &piece_of_transfer)
|
||||
|
@ -91,7 +105,7 @@ bool HttpClient::handle_target_data(std::string &piece_of_transfer)
|
|||
m_received += piece_of_transfer.size();
|
||||
emit receivedChanged();
|
||||
|
||||
return net::http::client::handle_target_data(piece_of_transfer);
|
||||
return true;
|
||||
}
|
||||
|
||||
Network::Network(QObject *parent)
|
||||
|
|
|
@ -40,31 +40,57 @@
|
|||
|
||||
#include "FutureScheduler.h"
|
||||
|
||||
class HttpClient : public QObject, public net::http::client
|
||||
class HttpClient;
|
||||
|
||||
|
||||
// QObject doesn't mix well with net::http::client
|
||||
class _HttpClient : public net::http::client
|
||||
{
|
||||
public:
|
||||
_HttpClient(HttpClient* parent):m_parent(parent){}
|
||||
bool on_header(const epee::net_utils::http::http_response_info &headers) final;
|
||||
bool handle_target_data(std::string &piece_of_transfer) final;
|
||||
|
||||
private:
|
||||
HttpClient* m_parent;
|
||||
};
|
||||
|
||||
class HttpClient : public QObject
|
||||
{
|
||||
Q_OBJECT
|
||||
Q_PROPERTY(quint64 contentLength READ contentLength NOTIFY contentLengthChanged);
|
||||
Q_PROPERTY(quint64 received READ received NOTIFY receivedChanged);
|
||||
|
||||
|
||||
public:
|
||||
HttpClient(QObject *parent = nullptr);
|
||||
|
||||
void cancel();
|
||||
quint64 contentLength() const;
|
||||
quint64 received() const;
|
||||
std::shared_ptr<epee::net_utils::http::abstract_http_client> impl()
|
||||
{
|
||||
return m_impl;
|
||||
}
|
||||
bool set_proxy(const std::string &address)
|
||||
{
|
||||
return m_impl->set_proxy(address);
|
||||
}
|
||||
|
||||
signals:
|
||||
void contentLengthChanged() const;
|
||||
void receivedChanged() const;
|
||||
|
||||
protected:
|
||||
bool on_header(const epee::net_utils::http::http_response_info &headers) final;
|
||||
bool handle_target_data(std::string &piece_of_transfer) final;
|
||||
friend class _HttpClient;
|
||||
bool on_header(const epee::net_utils::http::http_response_info &headers);
|
||||
bool handle_target_data(std::string &piece_of_transfer);
|
||||
|
||||
private:
|
||||
std::atomic<bool> m_cancel;
|
||||
std::atomic<size_t> m_contentLength;
|
||||
std::atomic<size_t> m_received;
|
||||
std::shared_ptr<_HttpClient> m_impl;
|
||||
};
|
||||
|
||||
class Network : public QObject
|
||||
|
|
|
@ -28,10 +28,12 @@
|
|||
|
||||
#if defined(_WIN32) && !defined(MONERO_GUI_STATIC)
|
||||
#include <Winsock2.h>
|
||||
#undef interface
|
||||
#endif
|
||||
|
||||
#include "updater.h"
|
||||
|
||||
#include <QStringView>
|
||||
#include <common/util.h>
|
||||
|
||||
#include <openpgp/hash.h>
|
||||
|
@ -124,7 +126,7 @@ QByteArray Updater::getHash(const void *data, size_t size) const
|
|||
|
||||
QByteArray Updater::parseShasumOutput(const QString &message, const QString &filename) const
|
||||
{
|
||||
for (const auto &line : message.splitRef("\n"))
|
||||
for (const auto &line : QStringView{message}.split('\n'))
|
||||
{
|
||||
const auto trimmed = line.trimmed();
|
||||
if (trimmed.endsWith(filename))
|
||||
|
|
|
@ -1,10 +1,18 @@
|
|||
find_package(Qt5Core REQUIRED)
|
||||
find_package(Qt6Core REQUIRED)
|
||||
|
||||
find_package(Qt5LinguistTools QUIET)
|
||||
if(NOT Qt5_LRELEASE_EXECUTABLE)
|
||||
find_program(Qt5_LRELEASE_EXECUTABLE lrelease REQUIRED CMAKE_FIND_ROOT_PATH_BOTH)
|
||||
find_package(Qt6 REQUIRED COMPONENTS LinguistTools)
|
||||
|
||||
get_target_property(Qt6_LRELEASE_EXECUTABLE Qt6::lrelease IMPORTED_LOCATION_RELEASE)
|
||||
if(NOT Qt6_LRELEASE_EXECUTABLE)
|
||||
find_program(Qt6_LRELEASE_EXECUTABLE lrelease REQUIRED CMAKE_FIND_ROOT_PATH_BOTH)
|
||||
endif()
|
||||
|
||||
get_target_property(Qt6Core_RCC_EXECUTABLE Qt6::rcc IMPORTED_LOCATION_RELEASE)
|
||||
if(NOT Qt6Core_RCC_EXECUTABLE)
|
||||
find_program(Qt6Core_RCC_EXECUTABLE rcc REQUIRED CMAKE_FIND_ROOT_PATH_BOTH)
|
||||
endif()
|
||||
|
||||
|
||||
file(GLOB TS_FILES *.ts)
|
||||
|
||||
set(QM_FILES)
|
||||
|
@ -16,7 +24,7 @@ foreach(TS_FILE ${TS_FILES})
|
|||
|
||||
add_custom_command(
|
||||
OUTPUT ${QM_FILE}
|
||||
COMMAND ${Qt5_LRELEASE_EXECUTABLE} -compress -nounfinished -removeidentical ${TS_FILE} -qm ${QM_FILE}
|
||||
COMMAND ${Qt6_LRELEASE_EXECUTABLE} -compress -nounfinished -removeidentical ${TS_FILE} -qm ${QM_FILE}
|
||||
DEPENDS ${TS_FILE}
|
||||
)
|
||||
|
||||
|
@ -36,7 +44,7 @@ set_source_files_properties(${TRANSLATIONS_QRC} PROPERTIES SKIP_AUTORCC ON)
|
|||
set(TRANSLATIONS_CPP ${CMAKE_CURRENT_BINARY_DIR}/qrc_translations.cpp)
|
||||
add_custom_command(
|
||||
OUTPUT ${TRANSLATIONS_CPP}
|
||||
COMMAND ${Qt5Core_RCC_EXECUTABLE}
|
||||
COMMAND ${Qt6Core_RCC_EXECUTABLE}
|
||||
ARGS --name translations --output ${TRANSLATIONS_CPP} ${TRANSLATIONS_QRC}
|
||||
MAIN_DEPENDENCY ${TRANSLATIONS_QRC}
|
||||
DEPENDS ${QM_FILES}
|
||||
|
@ -46,4 +54,4 @@ set_source_files_properties(${TRANSLATIONS_CPP} PROPERTIES SKIP_AUTOMOC ON)
|
|||
set_source_files_properties(${TRANSLATIONS_CPP} PROPERTIES SKIP_AUTOUIC ON)
|
||||
|
||||
add_library(translations ${TRANSLATIONS_CPP})
|
||||
target_link_libraries(translations PUBLIC Qt5::Core)
|
||||
target_link_libraries(translations PUBLIC Qt6::Core)
|
||||
|
|
|
@ -1 +1 @@
|
|||
qt5_add_resources(RESOURCE_FILES *.qrc)
|
||||
qt6_add_resources(RESOURCE_FILES *.qrc)
|
||||
|
|
|
@ -27,7 +27,7 @@
|
|||
// THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
import QtQuick 2.9
|
||||
import QtQuick.Layouts 1.2
|
||||
import QtQuick.Layouts
|
||||
import QtQuick.Controls 2.0
|
||||
import FontAwesome 1.0
|
||||
|
||||
|
|
|
@ -29,11 +29,10 @@
|
|||
import QtQml 2.0
|
||||
import QtQuick 2.9
|
||||
import QtQuick.Controls 2.0
|
||||
import QtQuick.Controls 1.4
|
||||
import QtGraphicalEffects 1.0
|
||||
import QtQuick.Controls.Styles 1.4
|
||||
import QtQuick.Layouts 1.2
|
||||
import QtQuick.Dialogs 1.2
|
||||
import QtQuick.Controls
|
||||
import Qt5Compat.GraphicalEffects
|
||||
import QtQuick.Layouts
|
||||
import QtQuick.Dialogs
|
||||
import moneroComponents.Wallet 1.0
|
||||
|
||||
import "../js/Wizard.js" as Wizard
|
||||
|
@ -289,7 +288,7 @@ Rectangle {
|
|||
anchors.fill: parent
|
||||
clip: true
|
||||
|
||||
delegate: StackViewDelegate {
|
||||
/*delegate: StackViewDelegate {
|
||||
pushTransition: StackViewTransition {
|
||||
PropertyAnimation {
|
||||
target: enterItem
|
||||
|
@ -308,7 +307,7 @@ Rectangle {
|
|||
easing.type: Easing.OutCubic
|
||||
}
|
||||
}
|
||||
}
|
||||
}*/
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -317,12 +316,12 @@ Rectangle {
|
|||
FileDialog {
|
||||
id: fileDialog
|
||||
title: qsTr("Please choose a file") + translationManager.emptyString
|
||||
folder: "file://" + appWindow.accountsDir
|
||||
currentFolder: "file://" + appWindow.accountsDir
|
||||
nameFilters: [ "Wallet files (*.keys)"]
|
||||
sidebarVisible: false
|
||||
//sidebarVisible: false
|
||||
|
||||
onAccepted: {
|
||||
var keysPath = walletManager.urlToLocalPath(fileDialog.fileUrl)
|
||||
var keysPath = walletManager.urlToLocalPath(fileDialog.selectedFile)
|
||||
persistentSettings.nettype = oshelper.getNetworkTypeFromFile(keysPath);
|
||||
wizardController.openWalletFile(keysPath);
|
||||
}
|
||||
|
|
|
@ -26,9 +26,9 @@
|
|||
// 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.
|
||||
|
||||
import QtQuick 2.9
|
||||
import QtQuick.Dialogs 1.2
|
||||
import QtQuick.Layouts 1.2
|
||||
import QtQuick
|
||||
import QtQuick.Dialogs
|
||||
import QtQuick.Layouts
|
||||
import QtQuick.Controls 2.0
|
||||
|
||||
import moneroComponents.Wallet 1.0
|
||||
|
@ -208,8 +208,8 @@ Rectangle {
|
|||
labelFontSize: 14
|
||||
placeholderFontSize: 16
|
||||
placeholderText: qsTr("Restore height") + translationManager.emptyString
|
||||
validator: RegExpValidator {
|
||||
regExp: /^(\d+|\d{4}-\d{2}-\d{2})$/
|
||||
validator: RegularExpressionValidator {
|
||||
regularExpression: /^(\d+|\d{4}-\d{2}-\d{2})$/
|
||||
}
|
||||
text: "1"
|
||||
}
|
||||
|
@ -229,7 +229,7 @@ Rectangle {
|
|||
labelFontSize: 14
|
||||
placeholderText: "<major>:<minor>"
|
||||
placeholderFontSize: 16
|
||||
validator: RegExpValidator { regExp: /(\d+):(\d+)?$/ }
|
||||
validator: RegularExpressionValidator { regularExpression: /(\d+):(\d+)?$/ }
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -27,8 +27,8 @@
|
|||
// THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
import QtQuick 2.9
|
||||
import QtQuick.Dialogs 1.2
|
||||
import QtQuick.Layouts 1.2
|
||||
import QtQuick.Dialogs
|
||||
import QtQuick.Layouts
|
||||
import QtQuick.Controls 2.0
|
||||
|
||||
import "../js/Wizard.js" as Wizard
|
||||
|
|
|
@ -27,8 +27,8 @@
|
|||
// THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
import QtQuick 2.9
|
||||
import QtQuick.Dialogs 1.2
|
||||
import QtQuick.Layouts 1.2
|
||||
import QtQuick.Dialogs
|
||||
import QtQuick.Layouts
|
||||
import QtQuick.Controls 2.0
|
||||
import moneroComponents.Clipboard 1.0
|
||||
|
||||
|
|
|
@ -27,7 +27,7 @@
|
|||
// THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
import QtQuick 2.9
|
||||
import QtQuick.Layouts 1.2
|
||||
import QtQuick.Layouts
|
||||
import QtQuick.Controls 2.0
|
||||
|
||||
import "../components" as MoneroComponents
|
||||
|
|
|
@ -27,7 +27,7 @@
|
|||
// THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
import QtQuick 2.9
|
||||
import QtQuick.Layouts 1.2
|
||||
import QtQuick.Layouts
|
||||
import QtQuick.Controls 2.0
|
||||
|
||||
import "../components" as MoneroComponents
|
||||
|
|
|
@ -27,7 +27,7 @@
|
|||
// THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
import QtQuick 2.9
|
||||
import QtQuick.Layouts 1.2
|
||||
import QtQuick.Layouts
|
||||
import QtQuick.Controls 2.0
|
||||
|
||||
import "../js/Wizard.js" as Wizard
|
||||
|
|
|
@ -27,8 +27,8 @@
|
|||
// THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
import QtQuick 2.9
|
||||
import QtQuick.Dialogs 1.2
|
||||
import QtQuick.Layouts 1.2
|
||||
import QtQuick.Dialogs
|
||||
import QtQuick.Layouts
|
||||
import QtQuick.Controls 2.0
|
||||
|
||||
import "../js/Wizard.js" as Wizard
|
||||
|
|
|
@ -31,7 +31,7 @@ import "../components"
|
|||
import "../components" as MoneroComponents
|
||||
|
||||
import QtQuick 2.9
|
||||
import QtQuick.Layouts 1.2
|
||||
import QtQuick.Layouts
|
||||
import QtQuick.Controls 2.0
|
||||
|
||||
|
||||
|
|
|
@ -27,8 +27,8 @@
|
|||
// THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
import QtQuick 2.9
|
||||
import QtQuick.Dialogs 1.2
|
||||
import QtQuick.Layouts 1.2
|
||||
import QtQuick.Dialogs
|
||||
import QtQuick.Layouts
|
||||
import QtQuick.Controls 2.0
|
||||
import moneroComponents.NetworkType 1.0
|
||||
|
||||
|
|
|
@ -27,7 +27,7 @@
|
|||
// THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
import QtQuick 2.9
|
||||
import QtQuick.Layouts 1.2
|
||||
import QtQuick.Layouts
|
||||
import QtQuick.Controls 2.0
|
||||
|
||||
import "../components"
|
||||
|
|
|
@ -27,9 +27,9 @@
|
|||
// THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
import QtQuick 2.9
|
||||
import QtQuick.Dialogs 1.2
|
||||
import QtQuick.Layouts 1.2
|
||||
import QtGraphicalEffects 1.0
|
||||
import QtQuick.Dialogs
|
||||
import QtQuick.Layouts
|
||||
import Qt5Compat.GraphicalEffects
|
||||
import QtQuick.Controls 2.0
|
||||
|
||||
import "../components" as MoneroComponents
|
||||
|
|
|
@ -27,7 +27,7 @@
|
|||
// THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
import QtQuick 2.9
|
||||
import QtQuick.Layouts 1.2
|
||||
import QtQuick.Layouts
|
||||
import QtQuick.Controls 2.0
|
||||
|
||||
import "../js/Wizard.js" as Wizard
|
||||
|
|
|
@ -27,7 +27,7 @@
|
|||
// THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
import QtQuick 2.9
|
||||
import QtQuick.Layouts 1.2
|
||||
import QtQuick.Layouts
|
||||
import QtQuick.Controls 2.0
|
||||
|
||||
import "../js/Wizard.js" as Wizard
|
||||
|
|
|
@ -27,8 +27,8 @@
|
|||
// THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
import QtQuick 2.9
|
||||
import QtQuick.Dialogs 1.2
|
||||
import QtQuick.Layouts 1.2
|
||||
import QtQuick.Dialogs
|
||||
import QtQuick.Layouts
|
||||
import QtQuick.Controls 2.0
|
||||
|
||||
import "../js/Wizard.js" as Wizard
|
||||
|
|
|
@ -27,7 +27,7 @@
|
|||
// THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
import QtQuick 2.9
|
||||
import QtQuick.Layouts 1.2
|
||||
import QtQuick.Layouts
|
||||
import QtQuick.Controls 2.0
|
||||
|
||||
import "../js/Wizard.js" as Wizard
|
||||
|
|
|
@ -27,10 +27,10 @@
|
|||
// THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
import QtQuick 2.9
|
||||
import QtQuick.Dialogs 1.2
|
||||
import QtQuick.Layouts 1.2
|
||||
import QtQuick.Dialogs
|
||||
import QtQuick.Layouts
|
||||
import QtQuick.Controls 2.0
|
||||
import QtGraphicalEffects 1.0
|
||||
import Qt5Compat.GraphicalEffects
|
||||
import Qt.labs.folderlistmodel 2.1
|
||||
import moneroComponents.NetworkType 1.0
|
||||
import moneroComponents.WalletKeysFilesModel 1.0
|
||||
|
|
Some files were not shown because too many files have changed in this diff Show more
Loading…
Reference in a new issue