keep the transient auto-analyse dialog from showing up more than once per launch...
authorBen Loftis <ben@glw.com>
Wed, 19 Aug 2009 13:33:02 +0000 (13:33 +0000)
committerBen Loftis <ben@glw.com>
Wed, 19 Aug 2009 13:33:02 +0000 (13:33 +0000)
git-svn-id: svn://localhost/ardour2/branches/2.0-ongoing@5547 d708f5d6-7413-0410-9779-e7cbd77b26cf

libs/ardour/audioregion.cc

index 9a627472d7cc394e5510ef2b23e347b977cacdba..87d79c6c2c2e7811e3b2a43c21da07c7e4052c66 100644 (file)
@@ -1636,14 +1636,21 @@ AudioRegion::get_transients (AnalysisFeatureList& results, bool force_new)
 
        /* no existing/complete transient info */
 
+       static bool analyse_dialog_shown = false;
        if (!Config->get_auto_analyse_audio()) {
-               pl->session().Dialog (_("\
+               if ( !analyse_dialog_shown ) {
+                       pl->session().Dialog (_("\
 You have requested an operation that requires audio analysis.\n\n\
 You currently have \"auto-analyse-audio\" disabled, which means\n\
 that transient data must be generated every time it is required.\n\n\
 If you are doing work that will require transient data on a\n\
 regular basis, you should probably enable \"auto-analyse-audio\"\n\
-then quit ardour and restart."));
+then quit ardour and restart.\n\n\
+This dialog will not display again.  But you may notice a slight delay\n\
+in this and future transient-detection operations.\n\
+"));
+                       analyse_dialog_shown = true;  //only show this dialog once 
+                       }
        }
 
        TransientDetector t (pl->session().frame_rate());