ControllerRackView: do not loose focus when adding controller
[lmms.git] / include / automation_track.h
blob18d43ede667f2f6119b4bc7abab86653b6fcfa42
1 /*
2 * automation_track.h - declaration of class automationTrack, which handles
3 * automation of objects without a track
5 * Copyright (c) 2008 Tobias Doerffel <tobydox/at/users.sourceforge.net>
6 * Copyright (c) 2006-2008 Javier Serrano Polo <jasp00/at/users.sourceforge.net>
7 *
8 * This file is part of Linux MultiMedia Studio - http://lmms.sourceforge.net
10 * This program is free software; you can redistribute it and/or
11 * modify it under the terms of the GNU General Public
12 * License as published by the Free Software Foundation; either
13 * version 2 of the License, or (at your option) any later version.
15 * This program is distributed in the hope that it will be useful,
16 * but WITHOUT ANY WARRANTY; without even the implied warranty of
17 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
18 * General Public License for more details.
20 * You should have received a copy of the GNU General Public
21 * License along with this program (see COPYING); if not, write to the
22 * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
23 * Boston, MA 02110-1301 USA.
28 #ifndef _AUTOMATION_TRACK_H
29 #define _AUTOMATION_TRACK_H
31 #include "track.h"
34 class automationTrack : public track
36 public:
37 automationTrack( trackContainer * _tc, bool _hidden = false );
38 virtual ~automationTrack();
40 virtual bool play( const midiTime & _start, const fpp_t _frames,
41 const f_cnt_t _frame_base,
42 Sint16 _tco_num = -1 );
44 virtual QString nodeName() const
46 return( "automationtrack" );
49 virtual trackView * createView( trackContainerView * );
50 virtual trackContentObject * createTCO( const midiTime & _pos );
52 virtual void saveTrackSpecificSettings( QDomDocument & _doc,
53 QDomElement & _parent );
54 virtual void loadTrackSpecificSettings( const QDomElement & _this );
56 private:
57 friend class automationTrackView;
59 } ;
63 class automationTrackView : public trackView
65 public:
66 automationTrackView( automationTrack * _at, trackContainerView * _tcv );
67 virtual ~automationTrackView();
69 virtual void dragEnterEvent( QDragEnterEvent * _dee );
70 virtual void dropEvent( QDropEvent * _de );
72 } ;
75 #endif