summaryrefslogtreecommitdiffstats
path: root/src/widget/wlibrarysidebar.cpp
diff options
context:
space:
mode:
authorRJ Ryan <rryan@mixxx.org>2016-04-25 12:46:45 -0700
committerRJ Ryan <rryan@mixxx.org>2016-04-25 12:48:44 -0700
commitaf0714af69bcd371b9e588ce59d07f60e2a4410d (patch)
tree4b44259344fb2cd6007184a69fcd6f95247a406e /src/widget/wlibrarysidebar.cpp
parent3592cdd57c8015f7c4552d0c643aabb6a657211c (diff)
Spring cleaning: Apply clang-tidy to src/widget.
Using LLVM 3.8.0: $ clang-tidy --fix --checks="*,-llvm-header-guard,-readability-implicit-bool-cast,-readability-else-after-return,-google-readability-todo" $(git ls src/widget | xargs) -- (flags to compile)
Diffstat (limited to 'src/widget/wlibrarysidebar.cpp')
-rw-r--r--src/widget/wlibrarysidebar.cpp5
1 files changed, 2 insertions, 3 deletions
diff --git a/src/widget/wlibrarysidebar.cpp b/src/widget/wlibrarysidebar.cpp
index a32f021732..5893ac9dc5 100644
--- a/src/widget/wlibrarysidebar.cpp
+++ b/src/widget/wlibrarysidebar.cpp
@@ -29,8 +29,7 @@ WLibrarySidebar::WLibrarySidebar(QWidget* parent)
header()->setHorizontalScrollMode(QAbstractItemView::ScrollPerPixel);
}
-WLibrarySidebar::~WLibrarySidebar() {
-}
+WLibrarySidebar::~WLibrarySidebar() = default;
void WLibrarySidebar::contextMenuEvent(QContextMenuEvent *event) {
@@ -196,7 +195,7 @@ void WLibrarySidebar::keyPressEvent(QKeyEvent* event) {
}
void WLibrarySidebar::selectIndex(const QModelIndex& index) {
- QItemSelectionModel* pModel = new QItemSelectionModel(model());
+ auto pModel = new QItemSelectionModel(model());
pModel->select(index, QItemSelectionModel::Select);
setSelectionModel(pModel);