Olive
effectrow.h
1 #ifndef EFFECTROW_H
2 #define EFFECTROW_H
3 
4 #include <QObject>
5 #include <QVector>
6 
7 class Effect;
8 class QGridLayout;
9 class EffectField;
10 class QLabel;
11 class QPushButton;
12 class ComboAction;
13 class QHBoxLayout;
14 class KeyframeNavigator;
15 class ClickableLabel;
16 
17 class EffectRow : public QObject {
18  Q_OBJECT
19 public:
20  EffectRow(Effect* parent, bool save, QGridLayout* uilayout, const QString& n, int row, bool keyframable = true);
21  ~EffectRow();
22  EffectField* add_field(int type, const QString &id, int colspan = 1);
23  void add_widget(QWidget *w);
24  EffectField* field(int i);
25  int fieldCount();
26  void set_keyframe_now(ComboAction *ca);
27  void delete_keyframe_at_time(ComboAction *ca, long time);
28  ClickableLabel* label;
29  Effect* parent_effect;
30  bool savable;
31  const QString& get_name();
32 
33  bool isKeyframing();
34  void setKeyframing(bool);
35 public slots:
36  void goto_previous_key();
37  void toggle_key();
38  void goto_next_key();
39  void focus_row();
40 private slots:
41  void set_keyframe_enabled(bool);
42 private:
43  bool keyframing;
44  QGridLayout* ui;
45  QString name;
46  int ui_row;
47  QVector<EffectField*> fields;
48  QVector<QWidget*> widgets;
49 
50  KeyframeNavigator* keyframe_nav;
51 
52  bool just_made_unsafe_keyframe;
53  QVector<int> unsafe_keys;
54  QVector<QVariant> unsafe_old_data;
55  QVector<bool> key_is_new;
56 
57  int column_count;
58 };
59 
60 #endif // EFFECTROW_H
Definition: keyframenavigator.h:9
Definition: clickablelabel.h:6
Definition: undo.h:32
Definition: effect.h:146
Definition: effectrow.h:17
Definition: effectfield.h:23