/[svn]/gigedit/trunk/src/gigedit/mainwindow.h
ViewVC logotype

Diff of /gigedit/trunk/src/gigedit/mainwindow.h

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1262 by persson, Sun Jul 22 15:07:08 2007 UTC revision 1411 by schoenebeck, Fri Oct 12 17:46:29 2007 UTC
# Line 32  Line 32 
32  #include <gtkmm/treestore.h>  #include <gtkmm/treestore.h>
33  #include <gtkmm/uimanager.h>  #include <gtkmm/uimanager.h>
34  #include <gtkmm/window.h>  #include <gtkmm/window.h>
35    #include <gtkmm/statusbar.h>
36    #include <gtkmm/image.h>
37    
38  #include <sstream>  #include <sstream>
39    
# Line 55  class InstrumentProps : public Gtk::Wind Line 57  class InstrumentProps : public Gtk::Wind
57  public:  public:
58      InstrumentProps();      InstrumentProps();
59      void set_instrument(gig::Instrument* instrument);      void set_instrument(gig::Instrument* instrument);
60      sigc::signal<void> signal_instrument_changed();      sigc::signal<void>& signal_instrument_changed();
61  protected:  protected:
62      Gtk::VBox vbox;      Gtk::VBox vbox;
63      Gtk::HButtonBox buttonBox;      Gtk::HButtonBox buttonBox;
# Line 117  public: Line 119  public:
119      void load_file(const char* name);      void load_file(const char* name);
120      void load_instrument(gig::Instrument* instr);      void load_instrument(gig::Instrument* instr);
121      void file_changed();      void file_changed();
122        sigc::signal<void, gig::File*>& signal_file_structure_to_be_changed();
123        sigc::signal<void, gig::File*>& signal_file_structure_changed();
124        sigc::signal<void, std::list<gig::Sample*> >& signal_samples_to_be_removed();
125        sigc::signal<void>& signal_samples_removed();
126        sigc::signal<void, gig::Region*>& signal_region_to_be_changed();
127        sigc::signal<void, gig::Region*>& signal_region_changed();
128        sigc::signal<void, gig::DimensionRegion*>& signal_dimreg_to_be_changed();
129        sigc::signal<void, gig::DimensionRegion*>& signal_dimreg_changed();
130        sigc::signal<void, gig::Sample*/*old*/, gig::Sample*/*new*/>& signal_sample_ref_changed();
131    
132  protected:  protected:
133      Glib::RefPtr<Gtk::ActionGroup> actionGroup;      Glib::RefPtr<Gtk::ActionGroup> actionGroup;
134      Glib::RefPtr<Gtk::UIManager> uiManager;      Glib::RefPtr<Gtk::UIManager> uiManager;
135    
136        Gtk::Statusbar m_StatusBar;
137        Gtk::Label     m_AttachedStateLabel;
138        Gtk::Image     m_AttachedStateImage;
139    
140      RegionChooser m_RegionChooser;      RegionChooser m_RegionChooser;
141      DimRegionChooser m_DimRegionChooser;      DimRegionChooser m_DimRegionChooser;
142    
143      PropDialog propDialog;      PropDialog propDialog;
144      InstrumentProps instrumentProps;      InstrumentProps instrumentProps;
145    
146        sigc::signal<void, gig::File*> file_structure_to_be_changed_signal;
147        sigc::signal<void, gig::File*> file_structure_changed_signal;
148        sigc::signal<void, std::list<gig::Sample*> > samples_to_be_removed_signal;
149        sigc::signal<void> samples_removed_signal;
150        sigc::signal<void, gig::Region*> region_to_be_changed_signal;
151        sigc::signal<void, gig::Region*> region_changed_signal;
152        sigc::signal<void, gig::DimensionRegion*> dimreg_to_be_changed_signal;
153        sigc::signal<void, gig::DimensionRegion*> dimreg_changed_signal;
154        sigc::signal<void, gig::Sample*/*old*/, gig::Sample*/*new*/> sample_ref_changed_signal;
155    
156      void on_instrument_selection_change(int index);      void on_instrument_selection_change(int index);
157      void on_sel_change();      void on_sel_change();
158      void region_changed();      void region_changed();
# Line 216  protected: Line 241  protected:
241    
242      LoadDialog* load_dialog;      LoadDialog* load_dialog;
243      Loader* loader;      Loader* loader;
244      void load_gig(gig::File* gig, const char* filename);      void load_gig(gig::File* gig, const char* filename, bool isSharedInstrument = false);
245    
246      gig::File* file;      gig::File* file;
247        bool file_is_shared;
248      bool file_has_name;      bool file_has_name;
249      bool file_is_changed;      bool file_is_changed;
250      std::string filename;      std::string filename;
251      std::string current_dir;      std::string current_dir;
252    
253        void set_file_is_shared(bool);
254    
255      bool file_save();      bool file_save();
256      bool file_save_as();      bool file_save_as();
257        bool check_if_savable();
258    
259      void on_button_release(GdkEventButton* button);      void on_button_release(GdkEventButton* button);
260        void on_sample_treeview_drag_begin(const Glib::RefPtr<Gdk::DragContext>& context);
261      void on_sample_treeview_drag_data_get(const Glib::RefPtr<Gdk::DragContext>&,      void on_sample_treeview_drag_data_get(const Glib::RefPtr<Gdk::DragContext>&,
262                                            Gtk::SelectionData& selection_data, guint, guint);                                            Gtk::SelectionData& selection_data, guint, guint);
263      void on_sample_label_drop_drag_data_received(const Glib::RefPtr<Gdk::DragContext>& context,      void on_sample_label_drop_drag_data_received(const Glib::RefPtr<Gdk::DragContext>& context,
264                                                   int, int,                                                   int, int,
265                                                   const Gtk::SelectionData& selection_data,                                                   const Gtk::SelectionData& selection_data,
266                                                   guint, guint time);                                                   guint, guint time);
267    
268      void sample_name_changed(const Gtk::TreeModel::Path& path,      void sample_name_changed(const Gtk::TreeModel::Path& path,
269                               const Gtk::TreeModel::iterator& iter);                               const Gtk::TreeModel::iterator& iter);
270      void instrument_name_changed(const Gtk::TreeModel::Path& path,      void instrument_name_changed(const Gtk::TreeModel::Path& path,
# Line 243  protected: Line 274  protected:
274      void __clear();      void __clear();
275    
276      bool close_confirmation_dialog();      bool close_confirmation_dialog();
277        bool leaving_shared_mode_dialog();
278    
279      Gtk::Menu* popup_menu;      Gtk::Menu* popup_menu;
280    
281      bool on_delete_event(GdkEventAny* event);      bool on_delete_event(GdkEventAny* event);
282    
283        bool first_call_to_drag_data_get;
284  };  };
285    
286  #endif  #endif

Legend:
Removed from v.1262  
changed lines
  Added in v.1411

  ViewVC Help
Powered by ViewVC