From c3830d3efb6c4a9426e4745d78c3ee5b4833320d Mon Sep 17 00:00:00 2001 From: Klaus Basan Date: Tue, 21 Feb 2017 00:16:32 +0100 Subject: [PATCH] refs #887, stub for copy config (cache/settings) UI --- .../components/configurationwizard.ui | 54 +++++++++++++++++-- .../components/copyconfigurationcomponent.cpp | 27 ++++++++++ .../components/copyconfigurationcomponent.h | 43 +++++++++++++++ .../components/copyconfigurationcomponent.ui | 54 +++++++++++++++++++ src/blackgui/share/qss/stdwidget.qss | 6 +++ 5 files changed, 179 insertions(+), 5 deletions(-) create mode 100644 src/blackgui/components/copyconfigurationcomponent.cpp create mode 100644 src/blackgui/components/copyconfigurationcomponent.h create mode 100644 src/blackgui/components/copyconfigurationcomponent.ui diff --git a/src/blackgui/components/configurationwizard.ui b/src/blackgui/components/configurationwizard.ui index ebbe03a5c..850d00d12 100644 --- a/src/blackgui/components/configurationwizard.ui +++ b/src/blackgui/components/configurationwizard.ui @@ -1,7 +1,7 @@ - + CConfigurationWizard - + 0 @@ -11,9 +11,53 @@ - Wizard + swift configuration wizard - - + + QWizard::ClassicStyle + + + + Copy configuration + + + Copy cache and setting values + + + + 4 + + + 4 + + + 4 + + + 4 + + + + + + 0 + 100 + + + + + + + + + + BlackGui::Components::CCopyConfigurationComponent + QFrame +
blackgui/components/copyconfigurationcomponent.h
+ 1 +
+
+ +
diff --git a/src/blackgui/components/copyconfigurationcomponent.cpp b/src/blackgui/components/copyconfigurationcomponent.cpp new file mode 100644 index 000000000..de787c995 --- /dev/null +++ b/src/blackgui/components/copyconfigurationcomponent.cpp @@ -0,0 +1,27 @@ +/* Copyright (C) 2017 + * swift project Community / Contributors + * + * This file is part of swift Project. It is subject to the license terms in the LICENSE file found in the top-level + * directory of this distribution and at http://www.swift-project.org/license.html. No part of swift project, + * including this file, may be copied, modified, propagated, or distributed except according to the terms + * contained in the LICENSE file. + */ + +#include "copyconfigurationcomponent.h" +#include "ui_copyconfigurationcomponent.h" + +namespace BlackGui +{ + namespace Components + { + CCopyConfigurationComponent::CCopyConfigurationComponent(QWidget *parent) : + QFrame(parent), + ui(new Ui::CCopyConfigurationComponent) + { + ui->setupUi(this); + } + + CCopyConfigurationComponent::~CCopyConfigurationComponent() + { } + } // ns +} // ns diff --git a/src/blackgui/components/copyconfigurationcomponent.h b/src/blackgui/components/copyconfigurationcomponent.h new file mode 100644 index 000000000..270d56a01 --- /dev/null +++ b/src/blackgui/components/copyconfigurationcomponent.h @@ -0,0 +1,43 @@ +/* Copyright (C) 2017 + * swift project Community / Contributors + * + * This file is part of swift Project. It is subject to the license terms in the LICENSE file found in the top-level + * directory of this distribution and at http://www.swift-project.org/license.html. No part of swift project, + * including this file, may be copied, modified, propagated, or distributed except according to the terms + * contained in the LICENSE file. + */ + +//! \file + +#ifndef BLACKGUI_COMPONENTS_COPYCONFIGURATION_H +#define BLACKGUI_COMPONENTS_COPYCONFIGURATION_H + +#include "blackgui/blackguiexport.h" +#include + +namespace Ui { class CCopyConfigurationComponent; } +namespace BlackGui +{ + namespace Components + { + /** + * Copy configuration (ie settings and cache files) + */ + class BLACKGUI_EXPORT CCopyConfigurationComponent : public QFrame + { + Q_OBJECT + + public: + //! Constructor + explicit CCopyConfigurationComponent(QWidget *parent = nullptr); + + //! Destructor + virtual ~CCopyConfigurationComponent(); + + private: + QScopedPointer ui; + }; + } // ns +} // ns + +#endif // guard diff --git a/src/blackgui/components/copyconfigurationcomponent.ui b/src/blackgui/components/copyconfigurationcomponent.ui new file mode 100644 index 000000000..6035c2e12 --- /dev/null +++ b/src/blackgui/components/copyconfigurationcomponent.ui @@ -0,0 +1,54 @@ + + + CCopyConfigurationComponent + + + + 0 + 0 + 640 + 480 + + + + Frame + + + QFrame::StyledPanel + + + QFrame::Raised + + + + + + Destination + + + + + + + + + + + + Source + + + + + + + + + + + + + + + + diff --git a/src/blackgui/share/qss/stdwidget.qss b/src/blackgui/share/qss/stdwidget.qss index 3f19c84e8..42d755617 100644 --- a/src/blackgui/share/qss/stdwidget.qss +++ b/src/blackgui/share/qss/stdwidget.qss @@ -68,6 +68,12 @@ QDialog::separator:hover { background: transparent; } +/* selector QWizard not working, so using individual components */ +BlackGui--Components--CCopyConfigurationComponent { + background: black; /* background is background color here */ + background-image: url(:/textures/icons/textures/texture-inner.jpg); +} + QFileDialog #sidebar { background: black; }