-
-
Notifications
You must be signed in to change notification settings - Fork 7.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add Vertical Mixer Toggle #1257
Conversation
76af689
to
c031174
Compare
Hi! A few things here.
|
c031174
to
eba4fdc
Compare
|
eba4fdc
to
4599429
Compare
b380993
to
1e8b501
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
These are the number of little things that could be changed. If you have time, I would advise taking a look at them and amending.
Other than than those minor commit issues, this PR looks and works great. Very well done.
@@ -2,6 +2,7 @@ | |||
|
|||
#include <obs.hpp> | |||
#include <QWidget> | |||
#include <QPaintEvent> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
QPaintEvent is not necessary in this file due to type forwarding. It will in fact slow compile time of any source file that includes this header.
UI/volume-control.hpp
Outdated
~VolumeMeter(); | ||
explicit VolumeMeter(QWidget *parent = nullptr, | ||
obs_volmeter_t *obs_volmeter = nullptr); | ||
~VolumeMeter() override; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The override
keyword is not really something that you need to use on a destructor. Destructors cannot have multiple declarations/definitions, and can't change parameters, therefore the override
keyword has no real purpose on a destructor.
UI/volume-control.hpp
Outdated
VolControl(OBSSource source, bool showConfig = false); | ||
~VolControl(); | ||
explicit VolControl(OBSSource source, bool showConfig = false); | ||
~VolControl() override; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Again, the override
keyword is not really something that you need to use on a destructor. Destructors cannot change parameters.
void VolumeMeter::paintInputMeter(QPainter &painter, int x, int y, | ||
int width, int height, float peakHold) | ||
void VolumeMeter::paintInputMeter(QPainter &painter, int x, int y, int width, | ||
int height, float peakHold) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This probably should have gone in the "Cleanup includes and code style" commit.
UI/volume-control.cpp
Outdated
@@ -9,7 +9,6 @@ | |||
#include <QSlider> | |||
#include <QLabel> | |||
#include <QPainter> | |||
#include <utility> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Seems like this probably should have gone in the "Avoid copies" commit.
1e8b501
to
cc4f874
Compare
UI/data/themes/Acri.qss
Outdated
border-radius: 3px; | ||
width: 10px; | ||
height: 18px; | ||
margin: 0 -3px; /* handle is placed by default on the contents rect of the groove. Expand outside the groove */ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just a tiny indent inconsistency here, you'll notice the indent of these four lines is inconsistent with the previous lines. Make sure to double-check your commit diffs in the future.
cc4f874
to
c7c328d
Compare
Add toggle to change horizontal and vertical Mixer.