1 /* 2 * gui/widgets/track.h - Track view 3 * 4 * Copyright (C) 2019 Alexandros Theodotou 5 * 6 * This file is part of Zrythm 7 * 8 * Zrythm is free software: you can redistribute it and/or modify 9 * it under the terms of the GNU Affero General Public License as published by 10 * the Free Software Foundation, either version 3 of the License, or 11 * (at your option) any later version. 12 * 13 * Zrythm is distributed in the hope that it will be useful, 14 * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 * GNU Affero General Public License for more details. 17 * 18 * You should have received a copy of the GNU Affero General Public License 19 * along with Zrythm. If not, see <https://www.gnu.org/licenses/>. 20 */ 21 22 #ifndef __GUI_WIDGETS_AUDIO_TRACK_H__ 23 #define __GUI_WIDGETS_AUDIO_TRACK_H__ 24 25 #include "audio/channel.h" 26 #include "gui/widgets/track.h" 27 28 #include <gtk/gtk.h> 29 30 #define AUDIO_TRACK_WIDGET_TYPE \ 31 (audio_track_widget_get_type ()) 32 G_DECLARE_FINAL_TYPE (AudioTrackWidget, 33 audio_track_widget, 34 Z, 35 AUDIO_TRACK_WIDGET, 36 TrackWidget) 37 38 typedef struct _AutomationTracklistWidget 39 AutomationTracklistWidget; 40 typedef struct Track AudioTrack; 41 42 /** 43 * Top is the track part and bot is the automation part 44 */ 45 typedef struct _AudioTrackWidget 46 { 47 TrackWidget parent_instance; 48 GtkToggleButton * record; 49 GtkToggleButton * solo; 50 GtkToggleButton * mute; 51 GtkToggleButton * show_lanes; 52 GtkToggleButton * show_automation; 53 } AudioTrackWidget; 54 55 /** 56 * Creates a new track widget from the given track. 57 */ 58 AudioTrackWidget * 59 audio_track_widget_new (Track * track); 60 61 /** 62 * Updates changes in the backend to the ui 63 */ 64 void 65 audio_track_widget_refresh (AudioTrackWidget * self); 66 67 void 68 audio_track_widget_refresh_buttons ( 69 AudioTrackWidget * self); 70 71 #endif 72