root/branches/jackMidi/gui/src/SoundLibrary/SoundLibraryPanel.h @ 539

Revision 539, 2.5 KB (checked in by gabriel, 5 years ago)

Merge rev 505:528 from trunk

Line 
1/*
2 * Hydrogen
3 * Copyright(c) 2002-2008 by Alex >Comix< Cominu [comix@users.sourceforge.net]
4 *
5 * http://www.hydrogen-music.org
6 *
7 * This program is free software; you can redistribute it and/or modify
8 * it under the terms of the GNU General Public License as published by
9 * the Free Software Foundation; either version 2 of the License, or
10 * (at your option) any later version.
11 *
12 * This program is distributed in the hope that it will be useful,
13 * but WITHOUT ANY WARRANTY, without even the implied warranty of
14 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15 * GNU General Public License for more details.
16 *
17 * You should have received a copy of the GNU General Public License
18 * along with this program; if not, write to the Free Software
19 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
20 *
21 */
22
23#ifndef SOUND_LIBRARY_PANEL_H
24#define SOUND_LIBRARY_PANEL_H
25
26#include "config.h"
27
28#include <QtGui>
29
30#include <vector>
31
32#include <hydrogen/Object.h>
33
34namespace H2Core
35{
36        class Song;
37        class Drumkit;
38        class SoundLibrary;
39}
40
41class SoundLibraryTree;
42class ToggleButton;
43
44class SoundLibraryPanel : public QWidget, private Object
45{
46Q_OBJECT
47public:
48        SoundLibraryPanel( QWidget* parent );
49        ~SoundLibraryPanel();
50
51        void updateDrumkitList();
52        void test_expandedItems();
53        void update_background_color();
54
55private slots:
56        void on_DrumkitList_ItemChanged( QTreeWidgetItem* current, QTreeWidgetItem* previous );
57        void on_DrumkitList_itemActivated( QTreeWidgetItem* item, int column );
58        void on_DrumkitList_leftClicked( QPoint pos );
59        void on_DrumkitList_rightClicked( QPoint pos );
60        void on_DrumkitList_mouseMove( QMouseEvent* event );
61
62        void on_drumkitLoadAction();
63        void on_drumkitDeleteAction();
64        void on_drumkitPropertiesAction();
65        void on_drumkitExportAction();
66        void on_instrumentDeleteAction();
67        void on_songLoadAction();
68        void on_patternLoadAction();
69        void on_patternDeleteAction();
70
71private:
72        SoundLibraryTree *__sound_library_tree;
73        //FileBrowser *m_pFileBrowser;
74
75        QPoint __start_drag_position;
76        QMenu* __drumkit_menu;
77        QMenu* __instrument_menu;
78        QMenu* __song_menu;
79        QMenu* __pattern_menu;
80        QMenu* __pattern_menu_list;
81
82        QTreeWidgetItem* __system_drumkits_item;
83        QTreeWidgetItem* __user_drumkits_item;
84        QTreeWidgetItem* __song_item;
85        QTreeWidgetItem* __pattern_item;
86        QTreeWidgetItem* __pattern_item_list;
87
88        std::vector<H2Core::Drumkit*> __system_drumkit_info_list;
89        std::vector<H2Core::Drumkit*> __user_drumkit_info_list;
90        bool __expand_pattern_list;
91        bool __expand_songs_list;
92        void restore_background_color();
93        void change_background_color();
94
95};
96
97#endif
Note: See TracBrowser for help on using the browser.