Ardour  9.0-pre0-582-g084a23a80d
export_file_notebook.h
Go to the documentation of this file.
1 /*
2  * Copyright (C) 2008-2012 Sakari Bergen <sakari.bergen@beatwaves.net>
3  * Copyright (C) 2009-2010 Paul Davis <paul@linuxaudiosystems.com>
4  * Copyright (C) 2009 David Robillard <d@drobilla.net>
5  * Copyright (C) 2014 Colin Fletcher <colin.m.fletcher@googlemail.com>
6  * Copyright (C) 2016-2019 Robin Gareus <robin@gareus.org>
7  * Copyright (C) 2016 Tim Mayberry <mojofunk@gmail.com>
8  *
9  * This program is free software; you can redistribute it and/or modify
10  * it under the terms of the GNU General Public License as published by
11  * the Free Software Foundation; either version 2 of the License, or
12  * (at your option) any later version.
13  *
14  * This program is distributed in the hope that it will be useful,
15  * but WITHOUT ANY WARRANTY; without even the implied warranty of
16  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17  * GNU General Public License for more details.
18  *
19  * You should have received a copy of the GNU General Public License along
20  * with this program; if not, write to the Free Software Foundation, Inc.,
21  * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
22  */
23 
24 #pragma once
25 
26 #include <sigc++/signal.h>
27 
28 #include <gtkmm/alignment.h>
29 #include <gtkmm/box.h>
30 #include <gtkmm/button.h>
31 #include <gtkmm/checkbutton.h>
32 #include <gtkmm/label.h>
33 #include <gtkmm/notebook.h>
34 
36 #include "ardour/session_handle.h"
37 
38 #include "export_format_selector.h"
41 
43 {
44 public:
45 
47 
48  void set_session_and_manager (ARDOUR::Session * s, std::shared_ptr<ARDOUR::ExportProfileManager> manager);
51 
52  std::shared_ptr<SoundcloudExportSelector> soundcloud_export_selector;
53 
54  sigc::signal<void> CriticalSelectionChanged;
55 
56 private:
57 
58  typedef std::shared_ptr<ARDOUR::ExportProfileManager> ManagerPtr;
59  typedef std::shared_ptr<ARDOUR::ExportFormatSpecification> FormatPtr;
60  typedef std::shared_ptr<ARDOUR::ExportFilename> FilenamePtr;
61  class FilePage;
62 
64 
67  void remove_file_page (FilePage * page);
70 
71  sigc::connection page_change_connection;
72  void handle_page_change (GtkNotebookPage*, uint32_t page);
73 
77 
79  uint32_t page_counter;
80 
81  class FilePage : public Gtk::VBox
82  {
83  public:
87 
88  virtual ~FilePage ();
89 
91  void set_remove_sensitive (bool value);
92  std::string get_format_name () const;
93  bool get_soundcloud_upload () const;
94 
96 
100 
103 
104  sigc::signal<void> CriticalSelectionChanged;
105 
106  private:
113 
117 
118  /* GUI components */
119 
124 
128 
136 
137  uint32_t tab_number;
138 
140  sigc::connection analysis_button_connection;
141  sigc::connection reimport_button_connection;
142  };
143 };
144 
std::shared_ptr< FormatState > FormatStatePtr
std::shared_ptr< FilenameState > FilenameStatePtr
ExportFormatSelector format_selector
ARDOUR::ExportProfileManager::FilenameStatePtr filename_state
ARDOUR::ExportProfileManager::FilenameStatePtr get_filename_state() const
bool get_soundcloud_upload() const
std::string get_format_name() const
FilePage(ARDOUR::Session *s, ManagerPtr profile_manager, ExportFileNotebook *parent, uint32_t number, ARDOUR::ExportProfileManager::FormatStatePtr format_state, ARDOUR::ExportProfileManager::FilenameStatePtr filename_state)
sigc::connection soundcloud_button_connection
ARDOUR::ExportProfileManager::FormatStatePtr format_state
sigc::connection analysis_button_connection
sigc::signal< void > CriticalSelectionChanged
sigc::connection reimport_button_connection
PBD::ScopedConnection format_connection
ARDOUR::ExportProfileManager::FormatStatePtr get_format_state() const
void save_format_to_manager(FormatPtr format)
ExportFilenameSelector filename_selector
void set_remove_sensitive(bool value)
void update_example_filenames()
sigc::signal< void > CriticalSelectionChanged
std::shared_ptr< ARDOUR::ExportFormatSpecification > FormatPtr
void remove_file_page(FilePage *page)
std::shared_ptr< ARDOUR::ExportFilename > FilenamePtr
std::shared_ptr< ARDOUR::ExportProfileManager > ManagerPtr
std::shared_ptr< SoundcloudExportSelector > soundcloud_export_selector
void handle_page_change(GtkNotebookPage *, uint32_t page)
void set_session_and_manager(ARDOUR::Session *s, std::shared_ptr< ARDOUR::ExportProfileManager > manager)
void update_soundcloud_upload()
void update_remove_file_page_sensitivity()
void add_file_page(ARDOUR::ExportProfileManager::FormatStatePtr format_state, ARDOUR::ExportProfileManager::FilenameStatePtr filename_state)
sigc::connection page_change_connection
struct _GtkNotebookPage GtkNotebookPage
Definition: gtknotebook.h:58