Cleanup global namespace
This commit is contained in:
@@ -16,18 +16,18 @@
|
|||||||
#include <stdexcept>
|
#include <stdexcept>
|
||||||
|
|
||||||
namespace {
|
namespace {
|
||||||
constexpr int samplerates[] = { 44100, 48000, 96000, 192000 };
|
constexpr int samplerates[] = { 44100, 48000, 96000, 192000 };
|
||||||
|
|
||||||
constexpr int refreshrates[] = { 1, 15, 30, 50, 60 };
|
constexpr int refreshrates[] = { 1, 15, 30, 50, 60 };
|
||||||
|
|
||||||
constexpr int zoomlevels[] = { 50, 75, 100, 200, 400, 800 };
|
constexpr int zoomlevels[] = { 50, 75, 100, 200, 400, 800 };
|
||||||
|
|
||||||
template<typename T>
|
template<typename T>
|
||||||
void setActionsEnabled(const T &actions, bool enabled)
|
void setActionsEnabled(const T &actions, bool enabled)
|
||||||
{
|
{
|
||||||
for(auto action : actions)
|
for(auto action : actions)
|
||||||
action->setEnabled(enabled);
|
action->setEnabled(enabled);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
MainWindow::MainWindow(QWidget *parent) :
|
MainWindow::MainWindow(QWidget *parent) :
|
||||||
|
@@ -9,8 +9,10 @@
|
|||||||
// system includes
|
// system includes
|
||||||
#include <cmath>
|
#include <cmath>
|
||||||
|
|
||||||
qint32 framesForDuration(qint64 duration){
|
namespace {
|
||||||
return qint32(44100 * duration / 1000000LL);
|
qint32 framesForDuration(qint64 duration){
|
||||||
|
return qint32(44100 * duration / 1000000LL);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user