~ubuntu-branches/ubuntu/raring/muse/raring-proposed

« back to all changes in this revision

Viewing changes to muse/instruments/editinstrument.h

  • Committer: Package Import Robot
  • Author(s): Alessio Treglia
  • Date: 2012-11-22 01:16:59 UTC
  • mto: This revision was merged to the branch mainline in revision 23.
  • Revision ID: package-import@ubuntu.com-20121122011659-a2fwbf33ceqe1s0t
Tags: upstream-2.1~rc1
ImportĀ upstreamĀ versionĀ 2.1~rc1

Show diffs side-by-side

added added

removed removed

Lines of Context:
4
4
//  $Id: editinstrument.h,v 1.1.1.1.2.4 2009/05/31 05:12:12 terminator356 Exp $
5
5
//
6
6
//  (C) Copyright 2003 Werner Schweer (ws@seh.de)
 
7
//  (C) Copyright 2012 Tim E. Real (terminator356 on users dot sourceforge dot net)
7
8
//
8
9
//  This program is free software; you can redistribute it and/or
9
10
//  modify it under the terms of the GNU General Public License
31
32
class QDialog;
32
33
class QMenu;
33
34
class QCloseEvent;
 
35
class QGridLayout;
 
36
class QStringListModel;
 
37
class QString;
 
38
class QAction;
34
39
 
35
40
namespace MusEGui {
36
41
 
 
42
class Header;
 
43
class DList;
 
44
 
37
45
//---------------------------------------------------------
38
46
//   EditInstrument
39
47
//---------------------------------------------------------
44
52
      MusECore::MidiInstrument workingInstrument;
45
53
      QListWidgetItem*  oldMidiInstrument;
46
54
      QTreeWidgetItem* oldPatchItem;
 
55
 
 
56
      Header* dlist_header;
 
57
      DList* dlist;
 
58
      QScrollBar* dlist_vscroll;
 
59
      QGridLayout* dlist_grid;
 
60
      QStringListModel* patch_coll_model;
 
61
 
 
62
 
 
63
 
47
64
      void closeEvent(QCloseEvent*);
48
65
      int checkDirty(MusECore::MidiInstrument*, bool isClose = false);
49
66
      bool fileSave(MusECore::MidiInstrument*, const QString&);
51
68
      void updateInstrument(MusECore::MidiInstrument*);
52
69
      void updatePatch(MusECore::MidiInstrument*, MusECore::Patch*);
53
70
      void updatePatchGroup(MusECore::MidiInstrument*, MusECore::PatchGroup*);
 
71
      void updateSysex(MusECore::MidiInstrument*, MusECore::SysEx*);
54
72
      void changeInstrument();
55
73
      QTreeWidgetItem* addControllerToView(MusECore::MidiController* mctrl);
56
74
      QString getPatchItemText(int);
57
75
      void enableDefaultControls(bool, bool);
 
76
      void enableNonCtrlControls(bool);
58
77
      void setDefaultPatchName(int);
59
78
      int getDefaultPatchNumber();
60
79
      void setDefaultPatchNumbers(int);
67
86
      virtual void fileOpen();
68
87
      virtual void fileSave();
69
88
      virtual void fileSaveAs();
70
 
      virtual void fileExit();
 
89
      virtual void fileClose();
71
90
      virtual void helpWhatsThis();
72
91
      void instrumentChanged();
73
92
      void tabChanged(QWidget*);
83
102
      void deleteControllerClicked();
84
103
      void newControllerClicked();
85
104
      void addControllerClicked();
 
105
      void ctrlPopupTriggered(QAction*);
86
106
      void ctrlTypeChanged(int);
87
107
      void ctrlNameReturn();
88
 
      void ctrlHNumChanged(int);
89
 
      void ctrlLNumChanged(int);
 
108
      void ctrlNumChanged();
90
109
      void ctrlMinChanged(int);
91
110
      void ctrlMaxChanged(int);
92
111
      void ctrlDefaultChanged(int);
93
 
      //void sysexChanged(); DELETETHIS?
94
 
      //void deleteSysexClicked();
95
 
      //void newSysexClicked();
 
112
      void ctrlShowInMidiChanged(int);
 
113
      void ctrlShowInDrumChanged(int);
 
114
      void sysexChanged(QListWidgetItem*, QListWidgetItem*);
 
115
      void deleteSysexClicked();
 
116
      void newSysexClicked();
96
117
      void ctrlNullParamHChanged(int);
97
118
      void ctrlNullParamLChanged(int);
 
119
      
 
120
      void patchCollectionSpinboxChanged(int);
 
121
      void patchCollectionCheckboxChanged(bool);
 
122
      void patchActivated(const QModelIndex&);
 
123
      void addPatchCollection();
 
124
      void delPatchCollection();
 
125
      void copyPatchCollection();
 
126
      void patchCollectionUp();
 
127
      void patchCollectionDown();
 
128
      void repopulatePatchCollections();
 
129
      void storePatchCollection();
 
130
      void fetchPatchCollection();
98
131
 
99
132
   public:
 
133
      enum TabType { Patches=0, DrumMaps=1, Controllers=2, Sysex=3 };
 
134
      
100
135
      EditInstrument(QWidget* parent = 0, Qt::WFlags fl = Qt::Window);
 
136
      void findInstrument(const QString& find_instrument);
 
137
      void showTab(TabType);
101
138
      };
102
139
 
103
140
} // namespace MusEGui