Merge pull request #76979 from MewPurPur/unify-audio-bus-textures

Remove AudioBusEmpty.svg, use ProgressBar tint instead
This commit is contained in:
Rémi Verschelde 2023-05-12 10:06:55 +02:00
commit 645fd5ed0c
No known key found for this signature in database
GPG key ID: C3336907360768E1
3 changed files with 8 additions and 5 deletions

View file

@ -69,11 +69,15 @@ void EditorAudioBus::_notification(int p_what) {
switch (p_what) {
case NOTIFICATION_ENTER_TREE:
case NOTIFICATION_THEME_CHANGED: {
Ref<Texture2D> active_bus_texture = get_theme_icon(SNAME("BusVuActive"), SNAME("EditorIcons"));
for (int i = 0; i < CHANNELS_MAX; i++) {
channel[i].vu_l->set_under_texture(get_theme_icon(SNAME("BusVuEmpty"), SNAME("EditorIcons")));
channel[i].vu_l->set_progress_texture(get_theme_icon(SNAME("BusVuFull"), SNAME("EditorIcons")));
channel[i].vu_r->set_under_texture(get_theme_icon(SNAME("BusVuEmpty"), SNAME("EditorIcons")));
channel[i].vu_r->set_progress_texture(get_theme_icon(SNAME("BusVuFull"), SNAME("EditorIcons")));
channel[i].vu_l->set_under_texture(active_bus_texture);
channel[i].vu_l->set_tint_under(Color(0.75, 0.75, 0.75));
channel[i].vu_l->set_progress_texture(active_bus_texture);
channel[i].vu_r->set_under_texture(active_bus_texture);
channel[i].vu_r->set_tint_under(Color(0.75, 0.75, 0.75));
channel[i].vu_r->set_progress_texture(active_bus_texture);
channel[i].prev_active = true;
}

View file

Before

Width:  |  Height:  |  Size: 3.1 KiB

After

Width:  |  Height:  |  Size: 3.1 KiB

File diff suppressed because one or more lines are too long

Before

Width:  |  Height:  |  Size: 5.9 KiB