00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022 #ifndef TRACKPAN_H
00023 #define TRACKPAN_H
00024
00025 #include "Command.h"
00026
00027 class Sheet;
00028 class Track;
00029
00030 class TrackPan : public Command
00031 {
00032 Q_OBJECT
00033 Q_CLASSINFO("pan_left", tr("To Left"));
00034 Q_CLASSINFO("pan_right", tr("To Right"));
00035
00036 public :
00037 TrackPan(Track* track, QVariantList args);
00038
00039 int begin_hold();
00040 int finish_hold();
00041 int prepare_actions();
00042 int do_action();
00043 int undo_action();
00044 void cancel_action();
00045
00046 int jog();
00047
00048 void set_cursor_shape(int useX, int useY);
00049
00050 private :
00051 struct Data {
00052 QPoint mousePos;
00053 int origX;
00054 };
00055 Data* d;
00056
00057 float m_origPan;
00058 float m_newPan;
00059 Track* m_track;
00060
00061 public slots:
00062 void pan_left(bool autorepeat);
00063 void pan_right(bool autorepeat);
00064
00065 };
00066
00067 #endif
00068
00069