Remove tooltips() member from ARDOUR_UI and use Gtk_UI::set_tip
[ardour.git] / gtk2_ardour / ardour_ui.h
1 /*
2     Copyright (C) 1999-2002 Paul Davis
3
4     This program is free software; you can redistribute it and/or modify
5     it under the terms of the GNU General Public License as published by
6     the Free Software Foundation; either version 2 of the License, or
7     (at your option) any later version.
8
9     This program is distributed in the hope that it will be useful,
10     but WITHOUT ANY WARRANTY; without even the implied warranty of
11     MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
12     GNU General Public License for more details.
13
14     You should have received a copy of the GNU General Public License
15     along with this program; if not, write to the Free Software
16     Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
17
18 */
19
20 #ifndef __ardour_gui_h__
21 #define __ardour_gui_h__
22
23 #include <time.h>
24
25 /* need _BSD_SOURCE to get timersub macros */
26
27 #ifdef _BSD_SOURCE
28 #include <sys/time.h>
29 #else
30 #define _BSD_SOURCE
31 #include <sys/time.h>
32 #undef _BSD_SOURCE
33 #endif
34
35 #include <list>
36 #include <cmath>
37
38
39 #include "pbd/xml++.h"
40 #include "pbd/controllable.h"
41 #include <gtkmm/box.h>
42 #include <gtkmm/frame.h>
43 #include <gtkmm/label.h>
44 #include <gtkmm/table.h>
45 #include <gtkmm/fixed.h>
46 #include <gtkmm/drawingarea.h>
47 #include <gtkmm/eventbox.h>
48 #include <gtkmm/menu.h>
49 #include <gtkmm/menuitem.h>
50 #include <gtkmm/button.h>
51 #include <gtkmm/togglebutton.h>
52 #include <gtkmm/treeview.h>
53 #include <gtkmm/menubar.h>
54 #include <gtkmm/textbuffer.h>
55 #include <gtkmm/adjustment.h>
56 #include <gtkmm2ext/gtk_ui.h>
57 #include <gtkmm2ext/click_box.h>
58 #include <gtkmm2ext/stateful_button.h>
59 #include <gtkmm2ext/bindable_button.h>
60
61 #include "ardour/ardour.h"
62 #include "ardour/types.h"
63 #include "ardour/utils.h"
64 #include "ardour/plugin.h"
65 #include "ardour/session_handle.h"
66 #include "ardour/system_exec.h"
67
68 #include "video_timeline.h"
69
70 #include "add_route_dialog.h"
71 #include "ardour_button.h"
72 #include "ardour_dialog.h"
73 #include "ardour_window.h"
74 #include "editing.h"
75 #include "enums.h"
76 #include "visibility_group.h"
77 #include "window_manager.h"
78
79 #ifdef COMPILER_MSVC
80 #include "about.h"
81 #include "add_video_dialog.h"
82 #include "big_clock_window.h"
83 #include "bundle_manager.h"
84 #include "engine_dialog.h"
85 #include "export_video_dialog.h"
86 #include "global_port_matrix.h"
87 #include "keyeditor.h"
88 #include "location_ui.h"
89 #include "rc_option_editor.h"
90 #include "route_params_ui.h"
91 #include "session_option_editor.h"
92 #include "speaker_dialog.h"
93 #else
94 class About;
95 class AddRouteDialog;
96 class AddVideoDialog;
97 class BigClockWindow;
98 class BundleManager;
99 class EngineControl;
100 class ExportVideoDialog;
101 class KeyEditor;
102 class LocationUIWindow;
103 class RCOptionEditor;
104 class RouteParams_UI;
105 class SessionOptionEditor;
106 class SpeakerDialog;
107 class GlobalPortMatrixWindow;
108 #endif
109
110 class VideoTimeLine;
111 class ArdourKeyboard;
112 class AudioClock;
113 class ButtonJoiner;
114 class ConnectionEditor;
115 class MainClock;
116 class Mixer_UI;
117 class PublicEditor;
118 class SaveAsDialog;
119 class SessionDialog;
120 class SessionOptionEditor;
121 class ShuttleControl;
122 class Splash;
123 class TimeInfoBox;
124 class Meterbridge;
125 class MidiTracer;
126 class NSM_Client;
127 class LevelMeterHBox;
128 class GUIObjectState;
129
130 namespace ARDOUR {
131         class ControlProtocolInfo;
132         class IO;
133         class Port;
134         class Route;
135         class RouteGroup;
136         class Location;
137         class ProcessThread;
138 }
139
140 namespace Gtkmm2ext {
141         class TearOff;
142 }
143
144 namespace Gtk {
145         class ProgressBar;
146 }
147
148 class ARDOUR_UI : public Gtkmm2ext::UI, public ARDOUR::SessionHandlePtr
149 {
150     public:
151         ARDOUR_UI (int *argcp, char **argvp[], const char* localedir);
152         ~ARDOUR_UI();
153
154         bool run_startup (bool should_be_new, std::string load_template);
155
156         void show_splash ();
157         void hide_splash ();
158
159         void launch_chat ();
160         void launch_manual ();
161         void launch_reference ();
162         void launch_tracker ();
163         void launch_subscribe ();
164         void launch_cheat_sheet ();
165         void launch_website ();
166         void launch_website_dev ();
167         void launch_forums ();
168         void launch_howto_report ();
169         void show_about ();
170         void hide_about ();
171
172         void load_from_application_api (const std::string& path);
173         void finish();
174
175         int load_session (const std::string& path, const std::string& snapshot, std::string mix_template = std::string());
176         bool session_loaded;
177         int build_session (const std::string& path, const std::string& snapshot, ARDOUR::BusProfile&);
178         bool session_is_new() const { return _session_is_new; }
179
180         ARDOUR::Session* the_session() { return _session; }
181
182         bool get_smart_mode () const;
183         
184         int get_session_parameters (bool quit_on_cancel, bool should_be_new = false, std::string load_template = "");
185         int  build_session_from_dialog (SessionDialog&, const std::string& session_name, const std::string& session_path);
186         bool ask_about_loading_existing_session (const std::string& session_path);
187
188         /// @return true if session was successfully unloaded.
189         int unload_session (bool hide_stuff = false);
190         void close_session();
191
192         int  save_state_canfail (std::string state_name = "", bool switch_to_it = false);
193         void save_state (const std::string & state_name = "", bool switch_to_it = false);
194
195         static ARDOUR_UI *instance () { return theArdourUI; }
196         
197         PublicEditor&     the_editor() { return *editor;}
198         Mixer_UI* the_mixer() { return mixer; }
199
200         void new_midi_tracer_window ();
201         void toggle_editing_space();
202         void toggle_mixer_space();
203         void toggle_keep_tearoffs();
204
205         static PublicEditor* _instance;
206
207         /** Emitted frequently with the audible frame, false, and the edit point as
208          *  parameters respectively.
209          *
210          *  (either RapidScreenUpdate || SuperRapidScreenUpdate - user-config)
211          */
212         static sigc::signal<void, framepos_t, bool, framepos_t> Clock;
213
214         static void close_all_dialogs () { CloseAllDialogs(); }
215         static sigc::signal<void> CloseAllDialogs;
216
217         XMLNode* editor_settings() const;
218         XMLNode* mixer_settings () const;
219         XMLNode* keyboard_settings () const;
220         XMLNode* tearoff_settings (const char*) const;
221
222         void save_ardour_state ();
223         gboolean configure_handler (GdkEventConfigure* conf);
224
225         void halt_on_xrun_message ();
226         void xrun_handler (framepos_t);
227         void create_xrun_marker (framepos_t);
228
229         GUIObjectState* gui_object_state;
230         
231         MainClock* primary_clock;
232         MainClock* secondary_clock;
233         void focus_on_clock ();
234         AudioClock*   big_clock;
235
236         TimeInfoBox* time_info_box;
237
238         VideoTimeLine *video_timeline;
239
240         void store_clock_modes ();
241         void restore_clock_modes ();
242         void reset_main_clocks ();
243
244         void synchronize_sync_source_and_video_pullup ();
245
246         void add_route (Gtk::Window* float_window);
247         void add_routes_part_two ();
248         void add_routes_thread ();
249
250         void add_video (Gtk::Window* float_window);
251         void remove_video ();
252         void start_video_server_menu (Gtk::Window* float_window);
253         bool start_video_server (Gtk::Window* float_window, bool popup_msg);
254         void stop_video_server (bool ask_confirm=false);
255         void flush_videotimeline_cache (bool localcacheonly=false);
256         void export_video (bool range = false);
257
258         void session_add_audio_track (
259                 int input_channels,
260                 int32_t output_channels,
261                 ARDOUR::TrackMode mode,
262                 ARDOUR::RouteGroup* route_group,
263                 uint32_t how_many,
264                 std::string const & name_template
265                 ) {
266
267                 session_add_audio_route (true, input_channels, output_channels, mode, route_group, how_many, name_template);
268         }
269
270         void session_add_audio_bus (int input_channels, int32_t output_channels, ARDOUR::RouteGroup* route_group,
271                                     uint32_t how_many, std::string const & name_template) {
272                 session_add_audio_route (false, input_channels, output_channels, ARDOUR::Normal, route_group, how_many, name_template);
273         }
274
275         void session_add_midi_track (ARDOUR::RouteGroup* route_group, uint32_t how_many, std::string const & name_template,
276                                      ARDOUR::PluginInfoPtr instrument) {
277                 session_add_midi_route (true, route_group, how_many, name_template, instrument);
278         }
279
280         void session_add_mixed_track (const ARDOUR::ChanCount& input, const ARDOUR::ChanCount& output, ARDOUR::RouteGroup* route_group, uint32_t how_many, std::string const & name_template,
281                                       ARDOUR::PluginInfoPtr instrument);
282
283         /*void session_add_midi_bus () {
284                 session_add_midi_route (false);
285         }*/
286
287         void attach_to_engine ();
288         void post_engine ();
289
290         gint exit_on_main_window_close (GdkEventAny *);
291
292         void maximise_editing_space ();
293         void restore_editing_space ();
294
295         void show_ui_prefs ();
296
297         void update_tearoff_visibility ();
298
299         void setup_profile ();
300         void setup_tooltips ();
301
302         void set_shuttle_fract (double);
303
304         void get_process_buffers ();
305         void drop_process_buffers ();
306
307         void reset_peak_display ();
308         void reset_route_peak_display (ARDOUR::Route*);
309         void reset_group_peak_display (ARDOUR::RouteGroup*);
310
311         const std::string& announce_string() const { return _announce_string; }
312
313         int disconnect_from_engine ();
314         int reconnect_to_engine ();
315         void hide_application ();
316
317   protected:
318         friend class PublicEditor;
319
320         void toggle_auto_play ();
321         void toggle_auto_input ();
322         void toggle_punch ();
323         void unset_dual_punch ();
324         bool ignore_dual_punch;
325         void toggle_punch_in ();
326         void toggle_punch_out ();
327         void show_loop_punch_ruler_and_disallow_hide ();
328         void reenable_hide_loop_punch_ruler_if_appropriate ();
329         void toggle_auto_return ();
330         void toggle_click ();
331         void toggle_audio_midi_setup ();
332         void toggle_session_auto_loop ();
333         void toggle_rc_options_window ();
334         void toggle_session_options_window ();
335
336   private:
337         PublicEditor*        editor;
338         Mixer_UI*            mixer;
339         NSM_Client*          nsm;
340         bool                _was_dirty;
341         bool                _mixer_on_top;
342         bool                _initial_verbose_plugin_scan;
343         bool first_time_engine_run;
344
345         void goto_editor_window ();
346         void goto_mixer_window ();
347         void toggle_mixer_window ();
348         void toggle_meterbridge ();
349         void toggle_editor_mixer ();
350
351         int  setup_windows ();
352         void setup_transport ();
353         void setup_clock ();
354
355         static ARDOUR_UI *theArdourUI;
356
357         int starting ();
358
359         int  ask_about_saving_session (const std::vector<std::string>& actions);
360
361         void save_session_at_its_request (std::string);
362         /* periodic safety backup, to be precise */
363         gint autosave_session();
364         void update_autosave();
365         sigc::connection _autosave_connection;
366
367         void map_transport_state ();
368         int32_t do_engine_start ();
369
370         void engine_halted (const char* reason, bool free_reason);
371         void engine_stopped ();
372         void engine_running ();
373
374         void use_config ();
375
376         void about_signal_response(int response);
377
378         Gtk::VBox     top_packer;
379
380         sigc::connection clock_signal_connection;
381         void         update_clocks ();
382         void         start_clocking ();
383         void         stop_clocking ();
384
385         bool main_window_state_event_handler (GdkEventWindowState*, bool window_was_editor);
386
387         void update_transport_clocks (framepos_t pos);
388         void record_state_changed ();
389
390         std::list<MidiTracer*> _midi_tracer_windows;
391
392         void detach_tearoff (Gtk::Box* parent, Gtk::Widget* contents);
393         void reattach_tearoff (Gtk::Box* parent, Gtk::Widget* contents, int32_t order);
394         void reattach_all_tearoffs ();
395
396         /* Transport Control */
397
398         Gtkmm2ext::TearOff*      transport_tearoff;
399         Gtk::Frame               transport_frame;
400         Gtk::HBox                transport_tearoff_hbox;
401         Gtk::HBox                transport_hbox;
402         Gtk::Fixed               transport_base;
403         Gtk::Fixed               transport_button_base;
404         Gtk::Frame               transport_button_frame;
405         Gtk::HBox                transport_button_hbox;
406         Gtk::VBox                transport_button_vbox;
407         Gtk::HBox                transport_option_button_hbox;
408         Gtk::VBox                transport_option_button_vbox;
409         Gtk::HBox                transport_clock_hbox;
410         Gtk::VBox                transport_clock_vbox;
411         Gtk::HBox                primary_clock_hbox;
412         Gtk::HBox                secondary_clock_hbox;
413
414         struct TransportControllable : public PBD::Controllable {
415             enum ToggleType {
416                     Roll = 0,
417                     Stop,
418                     RecordEnable,
419                     GotoStart,
420                     GotoEnd,
421                     AutoLoop,
422                     PlaySelection,
423             };
424
425             TransportControllable (std::string name, ARDOUR_UI&, ToggleType);
426             void set_value (double);
427             double get_value (void) const;
428
429             ARDOUR_UI& ui;
430             ToggleType type;
431         };
432
433         boost::shared_ptr<TransportControllable> roll_controllable;
434         boost::shared_ptr<TransportControllable> stop_controllable;
435         boost::shared_ptr<TransportControllable> goto_start_controllable;
436         boost::shared_ptr<TransportControllable> goto_end_controllable;
437         boost::shared_ptr<TransportControllable> auto_loop_controllable;
438         boost::shared_ptr<TransportControllable> play_selection_controllable;
439         boost::shared_ptr<TransportControllable> rec_controllable;
440
441         void toggle_follow_edits ();
442
443         void set_transport_controllable_state (const XMLNode&);
444         XMLNode& get_transport_controllable_state ();
445
446         ArdourButton roll_button;
447         ArdourButton stop_button;
448         ArdourButton goto_start_button;
449         ArdourButton goto_end_button;
450         ArdourButton auto_loop_button;
451         ArdourButton play_selection_button;
452         ArdourButton rec_button;
453
454         void toggle_external_sync ();
455         void toggle_time_master ();
456         void toggle_video_sync ();
457
458         ShuttleControl* shuttle_box;
459
460         ArdourButton auto_return_button;
461         ArdourButton follow_edits_button;
462         ArdourButton auto_input_button;
463         ArdourButton click_button;
464         ArdourButton sync_button;
465
466         ArdourButton auditioning_alert_button;
467         ArdourButton solo_alert_button;
468         ArdourButton feedback_alert_button;
469         ArdourButton error_alert_button;
470
471         Gtk::VBox alert_box;
472         Gtk::VBox meter_box;
473         LevelMeterHBox * editor_meter;
474         float            editor_meter_max_peak;
475         ArdourButton     editor_meter_peak_display;
476         bool             editor_meter_peak_button_release (GdkEventButton*);
477
478         void blink_handler (bool);
479         sigc::connection blink_connection;
480
481         void solo_blink (bool);
482         void sync_blink (bool);
483         void audition_blink (bool);
484         void feedback_blink (bool);
485         void error_blink (bool);
486         
487         void set_flat_buttons();
488
489         void soloing_changed (bool);
490         void auditioning_changed (bool);
491         void _auditioning_changed (bool);
492         
493         bool solo_alert_press (GdkEventButton* ev);
494         bool audition_alert_press (GdkEventButton* ev);
495         bool feedback_alert_press (GdkEventButton *);
496         bool error_alert_press (GdkEventButton *);
497
498         void big_clock_value_changed ();
499         void primary_clock_value_changed ();
500         void secondary_clock_value_changed ();
501
502         /* called by Blink signal */
503
504         void transport_rec_enable_blink (bool onoff);
505
506         Gtk::Menu*        session_popup_menu;
507
508         /* menu bar and associated stuff */
509
510         Gtk::MenuBar* menu_bar;
511         Gtk::EventBox menu_bar_base;
512         Gtk::HBox     menu_hbox;
513
514         void use_menubar_as_top_menubar ();
515         void build_menu_bar ();
516
517         Gtk::Label   wall_clock_label;
518         gint update_wall_clock ();
519
520         Gtk::Label   disk_space_label;
521         void update_disk_space ();
522
523         Gtk::Label   timecode_format_label;
524         void update_timecode_format ();
525
526         Gtk::Label   cpu_load_label;
527         void update_cpu_load ();
528
529         Gtk::Label   xrun_label;
530         void update_xrun_count ();
531
532         Gtk::Label   peak_thread_work_label;
533         void update_peak_thread_work ();
534
535         Gtk::Label   buffer_load_label;
536         void update_buffer_load ();
537
538         Gtk::Label   sample_rate_label;
539         void update_sample_rate (ARDOUR::framecnt_t);
540
541         Gtk::Label    format_label;
542         void update_format ();
543         
544         void every_second ();
545         void every_point_one_seconds ();
546         void every_point_zero_something_seconds ();
547
548         sigc::connection second_connection;
549         sigc::connection point_one_second_connection;
550         sigc::connection point_zero_something_second_connection;
551         sigc::connection fps_connection;
552
553         void set_fps_timeout_connection ();
554
555         void open_session ();
556         void open_recent_session ();
557         void save_template ();
558
559         void edit_metadata ();
560         void import_metadata ();
561
562         void session_add_audio_route (bool, int32_t, int32_t, ARDOUR::TrackMode, ARDOUR::RouteGroup *, uint32_t, std::string const &);
563         void session_add_midi_route (bool, ARDOUR::RouteGroup *, uint32_t, std::string const &, ARDOUR::PluginInfoPtr);
564
565         void set_transport_sensitivity (bool);
566
567         //stuff for ProTools-style numpad
568         void transport_numpad_event (int num);
569         void transport_numpad_decimal ();
570         bool _numpad_locate_happening;
571         int _pending_locate_num;
572         gint transport_numpad_timeout ();
573         sigc::connection _numpad_timeout_connection;
574
575         void transport_goto_nth_marker (int nth);
576         void transport_goto_zero ();
577         void transport_goto_start ();
578         void transport_goto_end ();
579         void transport_goto_wallclock ();
580         void transport_stop ();
581         void transport_record (bool roll);
582         void transport_roll ();
583         void transport_play_selection();
584         void transport_play_preroll(); 
585         void transport_forward (int option);
586         void transport_rewind (int option);
587         void transport_loop ();
588         void toggle_roll (bool with_abort, bool roll_out_of_bounded_mode);
589         bool trx_record_enable_all_tracks ();
590
591         bool _session_is_new;
592         void set_session (ARDOUR::Session *);
593         void connect_dependents_to_session (ARDOUR::Session *);
594         void we_have_dependents ();
595
596         void setup_session_options ();
597
598         guint32  last_key_press_time;
599
600         void snapshot_session (bool switch_to_it);
601
602         SaveAsDialog* save_as_dialog;
603
604         bool save_as_progress_update (float fraction, int64_t cnt, int64_t total, Gtk::Label* label, Gtk::ProgressBar* bar);
605         void save_session_as ();
606         void rename_session ();
607         void setup_order_hint (AddRouteDialog::InsertAt);
608
609         int         create_mixer ();
610         int         create_editor ();
611
612         Meterbridge  *meterbridge;
613         int         create_meterbridge ();
614         /* Dialogs that can be created via new<T> */
615
616         WM::Proxy<SpeakerDialog> speaker_config_window;
617         WM::Proxy<KeyEditor> key_editor;
618         WM::Proxy<RCOptionEditor> rc_option_editor;
619         WM::Proxy<AddRouteDialog> add_route_dialog;
620         WM::Proxy<About> about;
621         WM::Proxy<LocationUIWindow> location_ui;
622         WM::Proxy<RouteParams_UI> route_params;
623         WM::Proxy<EngineControl> audio_midi_setup;
624         WM::Proxy<ExportVideoDialog> export_video_dialog;
625
626         /* Windows/Dialogs that require a creator method */
627
628         WM::ProxyWithConstructor<SessionOptionEditor> session_option_editor;
629         WM::ProxyWithConstructor<AddVideoDialog> add_video_dialog;
630         WM::ProxyWithConstructor<BundleManager> bundle_manager;
631         WM::ProxyWithConstructor<BigClockWindow> big_clock_window;
632         WM::ProxyWithConstructor<GlobalPortMatrixWindow> audio_port_matrix;
633         WM::ProxyWithConstructor<GlobalPortMatrixWindow> midi_port_matrix;
634
635         /* creator methods */
636
637         SessionOptionEditor*    create_session_option_editor ();
638         BundleManager*          create_bundle_manager ();
639         AddVideoDialog*         create_add_video_dialog ();
640         BigClockWindow*         create_big_clock_window(); 
641         GlobalPortMatrixWindow* create_global_port_matrix (ARDOUR::DataType);
642
643         ARDOUR::SystemExec *video_server_process;
644
645         void handle_locations_change (ARDOUR::Location*);
646
647         /* Keyboard Handling */
648
649         ArdourKeyboard* keyboard;
650
651         /* Keymap handling */
652
653         void install_actions ();
654
655         void toggle_record_enable (uint32_t);
656
657         uint32_t rec_enabled_streams;
658         void count_recenabled_streams (ARDOUR::Route&);
659
660         Splash* splash;
661
662         void pop_back_splash (Gtk::Window&);
663
664         /* cleanup */
665
666         Gtk::MenuItem *cleanup_item;
667
668         void display_cleanup_results (ARDOUR::CleanupReport& rep, const gchar* list_title, const bool msg_delete);
669         void cleanup ();
670         void cleanup_peakfiles ();
671         void flush_trash ();
672
673         bool have_configure_timeout;
674         ARDOUR::microseconds_t last_configure_time;
675         gint configure_timeout ();
676
677         ARDOUR::microseconds_t last_peak_grab;
678         ARDOUR::microseconds_t last_shuttle_request;
679
680         bool have_disk_speed_dialog_displayed;
681         void disk_speed_dialog_gone (int ignored_response, Gtk::MessageDialog*);
682         void disk_overrun_handler ();
683         void disk_underrun_handler ();
684         void gui_idle_handler ();
685
686         void cancel_plugin_scan ();
687         void cancel_plugin_timeout ();
688         void plugin_scan_dialog (std::string type, std::string plugin, bool);
689         void plugin_scan_timeout (int);
690
691         void session_format_mismatch (std::string, std::string);
692
693         void session_dialog (std::string);
694         int pending_state_dialog ();
695         int sr_mismatch_dialog (ARDOUR::framecnt_t, ARDOUR::framecnt_t);
696
697         Gtk::MenuItem* jack_disconnect_item;
698         Gtk::MenuItem* jack_reconnect_item;
699         Gtk::Menu*     jack_bufsize_menu;
700
701         Glib::RefPtr<Gtk::ActionGroup> common_actions;
702
703         void editor_realized ();
704
705         std::vector<std::string> positional_sync_strings;
706
707         void toggle_send_midi_feedback ();
708         void toggle_use_mmc ();
709         void toggle_send_mmc ();
710         void toggle_send_mtc ();
711         void toggle_send_midi_clock ();
712
713         void toggle_use_osc ();
714
715         void parameter_changed (std::string);
716         void session_parameter_changed (std::string);
717
718         bool first_idle ();
719
720         void check_memory_locking ();
721
722         bool check_audioengine();
723         void audioengine_setup ();
724
725         void display_message (const char *prefix, gint prefix_len,
726                         Glib::RefPtr<Gtk::TextBuffer::Tag> ptag, Glib::RefPtr<Gtk::TextBuffer::Tag> mtag,
727                         const char *msg);
728         Gtk::Label status_bar_label;
729         bool status_bar_button_press (GdkEventButton*);
730
731         void loading_message (const std::string& msg);
732
733         PBD::ScopedConnectionList forever_connections;
734         PBD::ScopedConnection halt_connection; 
735
736         void step_edit_status_change (bool);
737
738         void platform_specific ();
739         void platform_setup ();
740
741         /* these are used only in response to a platform-specific "ShouldQuit" signal
742          */
743         bool idle_finish ();
744         void queue_finish ();
745         void fontconfig_dialog ();
746
747         int missing_file (ARDOUR::Session*s, std::string str, ARDOUR::DataType type);
748         int ambiguous_file (std::string file, std::vector<std::string> hits);
749
750         bool click_button_clicked (GdkEventButton *);
751
752         VisibilityGroup _status_bar_visibility;
753
754         /** A ProcessThread so that we have some thread-local buffers for use by
755          *  PluginEqGui::impulse_analysis ().
756          */
757         ARDOUR::ProcessThread* _process_thread;
758
759         void feedback_detected ();
760
761         ArdourButton             midi_panic_button;
762         void                     midi_panic ();
763
764         void successful_graph_sort ();
765         bool _feedback_exists;
766
767         enum ArdourLogLevel {
768                 LogLevelNone = 0,
769                 LogLevelInfo,
770                 LogLevelWarning,
771                 LogLevelError
772         };
773
774         ArdourLogLevel _log_not_acknowledged;
775
776         void resize_text_widgets ();
777
778         bool xrun_button_release (GdkEventButton* ev);
779
780         std::string _announce_string;
781         void check_announcements ();
782
783         int do_audio_midi_setup (uint32_t);
784         void audioengine_became_silent ();
785 };
786
787 #endif /* __ardour_gui_h__ */
788