-
Notifications
You must be signed in to change notification settings - Fork 2.7k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Implemented stubs for palette module
- Loading branch information
1 parent
b75fb05
commit 3c5d0ea
Showing
31 changed files
with
519 additions
and
22 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,18 +1,18 @@ | ||
<RCC> | ||
<qresource prefix="/"> | ||
<file>qml/MuseScore/Palette/MoreElementsPopup.qml</file> | ||
<file>qml/MuseScore/Palette/Palette.qml</file> | ||
<file>qml/MuseScore/Palette/PaletteGrid.qml</file> | ||
<file>qml/MuseScore/Palette/PalettesListPopup.qml</file> | ||
<file>qml/MuseScore/Palette/PalettesWidget.qml</file> | ||
<file>qml/MuseScore/Palette/PalettesWidgetHeader.qml</file> | ||
<file>qml/MuseScore/Palette/PaletteTree.qml</file> | ||
<file>qml/MuseScore/Palette/PlaceholderManager.qml</file> | ||
<file>qml/MuseScore/Palette/TreePaletteHeader.qml</file> | ||
<file>qml/MuseScore/Palette/utils.js</file> | ||
<file>qml/MuseScore/Palette/qmldir</file> | ||
<file>qml/MuseScore/Palette/CreateCustomPalettePopup.qml</file> | ||
<file>qml/MuseScore/Palette/PalettePropertiesDialog.qml</file> | ||
<file>qml/MuseScore/Palette/internal/CreateCustomPalettePopup.qml</file> | ||
<file>qml/MuseScore/Palette/internal/MoreElementsPopup.qml</file> | ||
<file>qml/MuseScore/Palette/internal/Palette.qml</file> | ||
<file>qml/MuseScore/Palette/internal/PaletteGrid.qml</file> | ||
<file>qml/MuseScore/Palette/internal/PalettesListPopup.qml</file> | ||
<file>qml/MuseScore/Palette/internal/PalettesWidgetHeader.qml</file> | ||
<file>qml/MuseScore/Palette/internal/PaletteTree.qml</file> | ||
<file>qml/MuseScore/Palette/internal/PlaceholderManager.qml</file> | ||
<file>qml/MuseScore/Palette/internal/TreePaletteHeader.qml</file> | ||
<file>qml/MuseScore/Palette/internal/utils.js</file> | ||
<file>qml/MuseScore/Palette/PaletteCellPropertiesDialog.qml</file> | ||
<file>qml/MuseScore/Palette/PalettePropertiesDialog.qml</file> | ||
</qresource> | ||
</RCC> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,13 +1,4 @@ | ||
module MuseScore.Palette | ||
MoreElementsPopup 1.0 MoreElementsPopup.qml | ||
PaletteGrid 1.0 PaletteGrid.qml | ||
Palette 1.0 Palette.qml | ||
PalettesListPopup 1.0 PalettesListPopup.qml | ||
PalettesWidgetHeader 1.0 PalettesWidgetHeader.qml | ||
PalettesWidget 1.0 PalettesWidget.qml | ||
PaletteTree 1.0 PaletteTree.qml | ||
PlaceholderManager 1.0 PlaceholderManager.qml | ||
TreePaletteHeader 1.0 TreePaletteHeader.qml | ||
CreateCustomPalettePopup 1.0 CreateCustomPalettePopup.qml | ||
PalettePropertiesDialog 1.0 PalettePropertiesDialog.qml | ||
PaletteCellPropertiesDialog 1.0 PaletteCellPropertiesDialog.qml |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
#============================================================================= | ||
# MuseScore | ||
# Music Composition & Notation | ||
# | ||
# Copyright (C) 2020 MuseScore BVBA and others | ||
# | ||
# This program is free software; you can redistribute it and/or modify | ||
# it under the terms of the GNU General Public License version 2. | ||
# | ||
# This program is distributed in the hope that it will be useful, | ||
# but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
# GNU General Public License for more details. | ||
# | ||
# You should have received a copy of the GNU General Public License | ||
# along with this program; if not, write to the Free Software | ||
# Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. | ||
#============================================================================= | ||
|
||
set(MODULE palette) | ||
|
||
set(MODULE_QRC ${CMAKE_CURRENT_LIST_DIR}/palette.qrc) | ||
|
||
set(MODULE_QML_IMPORT ${CMAKE_CURRENT_LIST_DIR}/qml) | ||
|
||
set(MODULE_SRC | ||
${CMAKE_CURRENT_LIST_DIR}/palettestubmodule.cpp | ||
${CMAKE_CURRENT_LIST_DIR}/palettestubmodule.h | ||
${CMAKE_CURRENT_LIST_DIR}/paletteadapterstub.cpp | ||
${CMAKE_CURRENT_LIST_DIR}/paletteadapterstub.h | ||
${CMAKE_CURRENT_LIST_DIR}/paletteconfigurationstub.cpp | ||
${CMAKE_CURRENT_LIST_DIR}/paletteconfigurationstub.h | ||
) | ||
|
||
include(${PROJECT_SOURCE_DIR}/build/module.cmake) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
<RCC> | ||
<qresource prefix="/"> | ||
<file>qml/MuseScore/Palette/PalettesWidget.qml</file> | ||
<file>qml/MuseScore/Palette/qmldir</file> | ||
<file>qml/MuseScore/Palette/PaletteCellPropertiesDialog.qml</file> | ||
<file>qml/MuseScore/Palette/PalettePropertiesDialog.qml</file> | ||
</qresource> | ||
</RCC> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,79 @@ | ||
//============================================================================= | ||
// MuseScore | ||
// Music Composition & Notation | ||
// | ||
// Copyright (C) 2020 MuseScore BVBA and others | ||
// | ||
// This program is free software; you can redistribute it and/or modify | ||
// it under the terms of the GNU General Public License version 2. | ||
// | ||
// This program is distributed in the hope that it will be useful, | ||
// but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
// GNU General Public License for more details. | ||
// | ||
// You should have received a copy of the GNU General Public License | ||
// along with this program; if not, write to the Free Software | ||
// Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. | ||
//============================================================================= | ||
#include "paletteadapterstub.h" | ||
|
||
#include <QAction> | ||
|
||
using namespace mu::palette; | ||
|
||
QAction* PaletteAdapterStub::getAction(const char*) const | ||
{ | ||
return new QAction(); | ||
} | ||
|
||
QString PaletteAdapterStub::actionHelp(const char*) const | ||
{ | ||
return QString(); | ||
} | ||
|
||
void PaletteAdapterStub::showMasterPalette(const QString&) | ||
{ | ||
} | ||
|
||
bool PaletteAdapterStub::isSelected() const | ||
{ | ||
return false; | ||
} | ||
|
||
bool PaletteAdapterStub::applyPaletteElement(Ms::Element*, Qt::KeyboardModifiers) | ||
{ | ||
return false; | ||
} | ||
|
||
Ms::PaletteWorkspace* PaletteAdapterStub::paletteWorkspace() const | ||
{ | ||
return nullptr; | ||
} | ||
|
||
mu::ValCh<bool> PaletteAdapterStub::paletteEnabled() const | ||
{ | ||
return mu::ValCh<bool>(); | ||
} | ||
|
||
void PaletteAdapterStub::setPaletteEnabled(bool) | ||
{ | ||
} | ||
|
||
void PaletteAdapterStub::requestPaletteSearch() | ||
{ | ||
} | ||
|
||
mu::async::Notification PaletteAdapterStub::paletteSearchRequested() const | ||
{ | ||
return mu::async::Notification(); | ||
} | ||
|
||
void PaletteAdapterStub::notifyElementDraggedToScoreView() | ||
{ | ||
} | ||
|
||
mu::async::Notification PaletteAdapterStub::elementDraggedToScoreView() const | ||
{ | ||
return mu::async::Notification(); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,48 @@ | ||
//============================================================================= | ||
// MuseScore | ||
// Music Composition & Notation | ||
// | ||
// Copyright (C) 2020 MuseScore BVBA and others | ||
// | ||
// This program is free software; you can redistribute it and/or modify | ||
// it under the terms of the GNU General Public License version 2. | ||
// | ||
// This program is distributed in the hope that it will be useful, | ||
// but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
// GNU General Public License for more details. | ||
// | ||
// You should have received a copy of the GNU General Public License | ||
// along with this program; if not, write to the Free Software | ||
// Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. | ||
//============================================================================= | ||
#ifndef MU_PALETTE_PALETTEADAPTERSTUB_H | ||
#define MU_PALETTE_PALETTEADAPTERSTUB_H | ||
|
||
#include "palette/ipaletteadapter.h" | ||
|
||
namespace mu::palette { | ||
class PaletteAdapterStub : public IPaletteAdapter | ||
{ | ||
public: | ||
QAction* getAction(const char* id) const override; | ||
QString actionHelp(const char* id) const override; | ||
|
||
void showMasterPalette(const QString&) override; | ||
|
||
// score | ||
bool isSelected() const override; | ||
bool applyPaletteElement(Ms::Element* element, Qt::KeyboardModifiers modifiers = {}) override; | ||
|
||
// qml | ||
Ms::PaletteWorkspace* paletteWorkspace() const override; | ||
mu::ValCh<bool> paletteEnabled() const override; | ||
void setPaletteEnabled(bool arg) override; | ||
void requestPaletteSearch() override; | ||
async::Notification paletteSearchRequested() const override; | ||
void notifyElementDraggedToScoreView() override; | ||
async::Notification elementDraggedToScoreView() const override; | ||
}; | ||
} | ||
|
||
#endif // MU_PALETTE_PALETTEADAPTERSTUB_H |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,94 @@ | ||
//============================================================================= | ||
// MuseScore | ||
// Music Composition & Notation | ||
// | ||
// Copyright (C) 2020 MuseScore BVBA and others | ||
// | ||
// This program is free software; you can redistribute it and/or modify | ||
// it under the terms of the GNU General Public License version 2. | ||
// | ||
// This program is distributed in the hope that it will be useful, | ||
// but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
// GNU General Public License for more details. | ||
// | ||
// You should have received a copy of the GNU General Public License | ||
// along with this program; if not, write to the Free Software | ||
// Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. | ||
//============================================================================= | ||
#include "paletteconfigurationstub.h" | ||
|
||
using namespace mu::palette; | ||
|
||
double PaletteConfigurationStub::paletteScaling() const | ||
{ | ||
return 0.f; | ||
} | ||
|
||
bool PaletteConfigurationStub::isSinglePalette() const | ||
{ | ||
return false; | ||
} | ||
|
||
QColor PaletteConfigurationStub::elementsBackgroundColor() const | ||
{ | ||
return QColor(); | ||
} | ||
|
||
QColor PaletteConfigurationStub::elementsColor() const | ||
{ | ||
return QColor(); | ||
} | ||
|
||
QColor PaletteConfigurationStub::gridColor() const | ||
{ | ||
return QColor(); | ||
} | ||
|
||
QColor PaletteConfigurationStub::accentColor() const | ||
{ | ||
return QColor(); | ||
} | ||
|
||
mu::async::Notification PaletteConfigurationStub::colorsChanged() const | ||
{ | ||
return mu::async::Notification(); | ||
} | ||
|
||
mu::io::path PaletteConfigurationStub::keySignaturesDirPath() const | ||
{ | ||
return mu::io::path(); | ||
} | ||
|
||
mu::io::path PaletteConfigurationStub::timeSignaturesDirPath() const | ||
{ | ||
return mu::io::path(); | ||
} | ||
|
||
bool PaletteConfigurationStub::useFactorySettings() const | ||
{ | ||
return false; | ||
} | ||
|
||
bool PaletteConfigurationStub::enableExperimental() const | ||
{ | ||
return false; | ||
} | ||
|
||
mu::ValCh<IPaletteConfiguration::PaletteConfig> PaletteConfigurationStub::paletteConfig(const QString&) const | ||
{ | ||
return mu::ValCh<IPaletteConfiguration::PaletteConfig>(); | ||
} | ||
|
||
void PaletteConfigurationStub::setPaletteConfig(const QString&, const IPaletteConfiguration::PaletteConfig&) | ||
{ | ||
} | ||
|
||
mu::ValCh<IPaletteConfiguration::PaletteCellConfig> PaletteConfigurationStub::paletteCellConfig(const QString&) const | ||
{ | ||
return mu::ValCh<IPaletteConfiguration::PaletteCellConfig>(); | ||
} | ||
|
||
void PaletteConfigurationStub::setPaletteCellConfig(const QString&, const IPaletteConfiguration::PaletteCellConfig&) | ||
{ | ||
} |
Oops, something went wrong.