From 84213140d44144e41f2108d6b20592173fd0558d Mon Sep 17 00:00:00 2001 From: Marco Gittler Date: Thu, 31 Jul 2008 19:37:10 +0000 Subject: [PATCH] make float vars big integers with factor svn path=/branches/KDE4/; revision=2352 --- src/initeffects.cpp | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/initeffects.cpp b/src/initeffects.cpp index d4cb8810..96c7e647 100644 --- a/src/initeffects.cpp +++ b/src/initeffects.cpp @@ -429,6 +429,12 @@ QDomDocument initEffects::createDescriptionFromMlt(Mlt::Repository* repository, if (paramdesc.get("minimum")) params.setAttribute("min", paramdesc.get("minimum")); if (QString(paramdesc.get("type")) == "integer") params.setAttribute("type", "constant"); + if (QString(paramdesc.get("type")) == "float") { + params.setAttribute("type", "constant"); + params.setAttribute("factor", "1000"); + if (paramdesc.get("maximum")) params.setAttribute("max", QString(paramdesc.get("maximum")).toFloat()*1000.0); + if (paramdesc.get("minimum")) params.setAttribute("min", QString(paramdesc.get("minimum")).toFloat()*1000.0); + } if (QString(paramdesc.get("type")) == "boolean") params.setAttribute("type", "bool"); if (!QString(paramdesc.get("format")).isEmpty() && QString(paramdesc.get("type")) != "geometry") { -- 2.39.2