Skip to content

Commit

Permalink
UI: Replace themeID and style hints with class property
Browse files Browse the repository at this point in the history
  • Loading branch information
Warchamp7 authored and RytoEX committed Oct 4, 2024
1 parent 71775e3 commit cb02696
Show file tree
Hide file tree
Showing 33 changed files with 586 additions and 648 deletions.
6 changes: 3 additions & 3 deletions UI/adv-audio-control.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,7 @@ OBSAdvAudioCtrl::OBSAdvAudioCtrl(QGridLayout *, obs_source_t *source_)
active->setText(isActive ? QTStr("Basic.Stats.Status.Active")
: QTStr("Basic.Stats.Status.Inactive"));
if (isActive)
setThemeID(active, "error");
setClasses(active, "text-danger");
active->setSizePolicy(QSizePolicy::Maximum, QSizePolicy::Fixed);

volume->setMinimum(MIN_DB - 0.1);
Expand Down Expand Up @@ -370,10 +370,10 @@ void OBSAdvAudioCtrl::SourceActiveChanged(bool isActive)
{
if (isActive && obs_source_audio_active(source)) {
active->setText(QTStr("Basic.Stats.Status.Active"));
setThemeID(active, "error");
setClasses(active, "text-danger");
} else {
active->setText(QTStr("Basic.Stats.Status.Inactive"));
setThemeID(active, "");
setClasses(active, "");
}
}

Expand Down
Loading

0 comments on commit cb02696

Please sign in to comment.