mirror of
https://github.com/AxioDL/amuse.git
synced 2025-12-08 21:17:49 +00:00
Editor: Include headers where necessary
Avoids propagating dependencies through indirect inclusions, and also gets rid of some header dependencies entirely.
This commit is contained in:
@@ -1,10 +1,14 @@
|
||||
#include "KeyboardWidget.hpp"
|
||||
|
||||
#include <QApplication>
|
||||
#include <QHBoxLayout>
|
||||
#include <QSvgRenderer>
|
||||
#include <QMouseEvent>
|
||||
#include <QScrollArea>
|
||||
#include <QApplication>
|
||||
#include <QScrollBar>
|
||||
#include <QSvgRenderer>
|
||||
|
||||
#include "Common.hpp"
|
||||
#include "StatusBarWidget.hpp"
|
||||
|
||||
const QString NaturalKeyNames[] = {QStringLiteral("C"), QStringLiteral("D"), QStringLiteral("E"), QStringLiteral("F"),
|
||||
QStringLiteral("G"), QStringLiteral("A"), QStringLiteral("B")};
|
||||
@@ -70,6 +74,8 @@ KeyboardWidget::KeyboardWidget(QWidget* parent) : QWidget(parent) {
|
||||
setMouseTracking(true);
|
||||
}
|
||||
|
||||
KeyboardWidget::~KeyboardWidget() = default;
|
||||
|
||||
std::pair<int, int> KeyboardWidget::_getOctaveAndKey(QMouseEvent* event) const {
|
||||
for (KeyboardOctave* oct : m_widgets) {
|
||||
QPoint localPos = oct->mapFromParent(event->pos());
|
||||
@@ -144,6 +150,8 @@ void KeyboardWidget::showEvent(QShowEvent* event) {
|
||||
|
||||
KeyboardSlider::KeyboardSlider(QWidget* parent) : QSlider(parent) {}
|
||||
|
||||
KeyboardSlider::~KeyboardSlider() = default;
|
||||
|
||||
void KeyboardSlider::enterEvent(QEvent* event) {
|
||||
if (m_statusFocus)
|
||||
m_statusFocus->enter();
|
||||
|
||||
Reference in New Issue
Block a user