X-Git-Url: https://git.sesse.net/?a=blobdiff_plain;ds=sidebyside;f=src%2Fdefinitions.h;h=592156e192831d6e0327d27a201758ec3d8e2472;hb=58c5d98d7ea0cbe8745a52a0d55414cf56938d97;hp=b525a77fe2cea48d4859c1c7c96717e6118b160a;hpb=3b176bab2ad91159c0a4a7dbe5f278f646115218;p=kdenlive diff --git a/src/definitions.h b/src/definitions.h index b525a77f..592156e1 100644 --- a/src/definitions.h +++ b/src/definitions.h @@ -32,8 +32,10 @@ const int MAXCLIPDURATION = 15000; + namespace Kdenlive { enum MONITORID { noMonitor, clipMonitor, projectMonitor, recordMonitor, stopmotionMonitor, dvdMonitor }; + const int DefaultThumbHeight = 100; /*const QString clipMonitor("clipMonitor"); const QString recordMonitor("recordMonitor"); const QString projectMonitor("projectMonitor"); @@ -84,7 +86,7 @@ public: isMute(0), isBlind(0), isLocked(0), - duration(0) {}; + duration(0) {} }; typedef QMap stringMap; @@ -101,7 +103,7 @@ public: /** cropDuration is the duration of the clip */ GenTime cropDuration; int track; - ItemInfo() : track(0) {}; + ItemInfo() : track(0) {} }; class TransitionInfo { @@ -119,7 +121,7 @@ public: TransitionInfo() : b_track(0), a_track(0), - forceTrack(0) {}; + forceTrack(0) {} }; class MltVideoProfile { @@ -146,7 +148,7 @@ public: sample_aspect_den(0), display_aspect_num(0), display_aspect_den(0), - colorspace(0) {}; + colorspace(0) {} bool operator==(const MltVideoProfile& point) const { if (!description.isEmpty() && point.description == description) return true; @@ -225,13 +227,13 @@ class EffectsParameterList: public QList < EffectParameter > public: EffectsParameterList(): QList < EffectParameter >() {} bool hasParam(const QString &name) const { - for (int i = 0; i < size(); i++) + for (int i = 0; i < size(); ++i) if (at(i).name() == name) return true; return false; } void setParamValue(const QString &name, const QString &value) { bool found = false; - for (int i = 0; i < size(); i++) + for (int i = 0; i < size(); ++i) if (at(i).name() == name) { // update value replace(i, EffectParameter(name, value)); @@ -240,8 +242,8 @@ public: if (!found) addParam(name, value); } - QString paramValue(const QString &name, QString defaultValue = QString()) const { - for (int i = 0; i < size(); i++) { + QString paramValue(const QString &name, const QString &defaultValue = QString()) const { + for (int i = 0; i < size(); ++i) { if (at(i).name() == name) return at(i).value(); } return defaultValue; @@ -251,7 +253,7 @@ public: append(EffectParameter(name, value)); } void removeParam(const QString &name) { - for (int i = 0; i < size(); i++) + for (int i = 0; i < size(); ++i) if (at(i).name() == name) { removeAt(i); break; @@ -263,7 +265,7 @@ class CommentedTime { public: CommentedTime(): t(GenTime(0)), type(0) {} - CommentedTime(const GenTime &time, QString comment, int markerType = 0) + CommentedTime(const GenTime &time, const QString& comment, int markerType = 0) : t(time), c(comment), type(markerType) { } QString comment() const { @@ -272,7 +274,7 @@ public: GenTime time() const { return t; } - void setComment(QString comm) { + void setComment(const QString &comm) { c = comm; } void setMarkerType(int t) { @@ -299,7 +301,7 @@ public: return Qt::cyan; break; } - }; + } /* Implementation of > operator; Works identically as with basic types. */ bool operator>(CommentedTime op) const { @@ -330,9 +332,6 @@ private: GenTime t; QString c; int type; - - - }; QDebug operator << (QDebug qd, const ItemInfo &info);