From 96e0b46931e44ea9c32aa57308ea2134493caed6 Mon Sep 17 00:00:00 2001 From: leo Date: Mon, 16 Mar 2015 01:47:55 +0000 Subject: [PATCH] Show hidden pieces with a different color in the timeline. --- common/lc_model.cpp | 4 ++++ common/lc_timelinewidget.cpp | 5 +++++ 2 files changed, 9 insertions(+) diff --git a/common/lc_model.cpp b/common/lc_model.cpp index 245e5dc4..9388ab5d 100644 --- a/common/lc_model.cpp +++ b/common/lc_model.cpp @@ -3004,6 +3004,7 @@ void lcModel::HideSelectedPieces() } UpdateSelection(); + gMainWindow->UpdateTimeline(false); gMainWindow->UpdateFocusObject(NULL); gMainWindow->UpdateAllViews(); } @@ -3019,6 +3020,7 @@ void lcModel::HideUnselectedPieces() } UpdateSelection(); + gMainWindow->UpdateTimeline(false); gMainWindow->UpdateAllViews(); } @@ -3033,6 +3035,7 @@ void lcModel::UnhideSelectedPieces() } UpdateSelection(); + gMainWindow->UpdateTimeline(false); gMainWindow->UpdateAllViews(); } @@ -3042,6 +3045,7 @@ void lcModel::UnhideAllPieces() mPieces[PieceIdx]->SetHidden(false); UpdateSelection(); + gMainWindow->UpdateTimeline(false); gMainWindow->UpdateAllViews(); } diff --git a/common/lc_timelinewidget.cpp b/common/lc_timelinewidget.cpp index 409b44db..a63da1e9 100644 --- a/common/lc_timelinewidget.cpp +++ b/common/lc_timelinewidget.cpp @@ -147,6 +147,11 @@ void lcTimelineWidget::Update(bool Clear) } } + QColor Color = palette().text().color(); + if (Piece->IsHidden()) + Color.setAlpha(128); + PieceItem->setTextColor(0, Color); + PieceItem->setSelected(Piece->IsSelected()); PieceItemIndex++; }