diff options
author | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2010-07-31 19:44:01 +0000 |
---|---|---|
committer | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2010-07-31 19:44:01 +0000 |
commit | 479f5f799523bffbcc83dff581a2299c047c6fff (patch) | |
tree | 186aae707ed02aac6c7cab2fb14e97f72aca5e36 /kjsembed/bindings/size_imp.cpp | |
parent | f1dbff6145c98324ff82e34448b7483727e8ace4 (diff) | |
download | tdebindings-479f5f799523bffbcc83dff581a2299c047c6fff.tar.gz tdebindings-479f5f799523bffbcc83dff581a2299c047c6fff.zip |
Trinity Qt initial conversion
git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdebindings@1157645 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'kjsembed/bindings/size_imp.cpp')
-rw-r--r-- | kjsembed/bindings/size_imp.cpp | 26 |
1 files changed, 13 insertions, 13 deletions
diff --git a/kjsembed/bindings/size_imp.cpp b/kjsembed/bindings/size_imp.cpp index 09c01427..d773507d 100644 --- a/kjsembed/bindings/size_imp.cpp +++ b/kjsembed/bindings/size_imp.cpp @@ -21,7 +21,7 @@ #include <kjsembed/global.h> #include "size_imp.h" -#include <qsize.h> +#include <tqsize.h> #include <kjsembed/jsvalueproxy.h> #include <kjsembed/jsbinding.h> @@ -38,7 +38,7 @@ Size::~Size() } void Size::addBindings( KJS::ExecState *exec, KJS::Object &object ) { - if( !JSProxy::checkType(object, JSProxy::ValueProxy, "QSize") ) return; + if( !JSProxy::checkType(object, JSProxy::ValueProxy, "TQSize") ) return; JSProxy::MethodTable methods[] = { { Methodwidth, "width"}, @@ -58,9 +58,9 @@ void Size::addBindings( KJS::ExecState *exec, KJS::Object &object ) { // JSProxy::EnumTable enums[] = { - { "ScaleFree", (int)QSize::ScaleFree }, - { "ScaleMin", (int)QSize::ScaleMin }, - { "ScaleMax", (int)QSize::ScaleMax }, + { "ScaleFree", (int)TQSize::ScaleFree }, + { "ScaleMin", (int)TQSize::ScaleMin }, + { "ScaleMax", (int)TQSize::ScaleMax }, { 0, 0 } }; @@ -68,10 +68,10 @@ void Size::addBindings( KJS::ExecState *exec, KJS::Object &object ) { } KJS::Value Size::call( KJS::ExecState *exec, KJS::Object &self, const KJS::List &args ) { - if( !JSProxy::checkType(self, JSProxy::ValueProxy, "QSize") ) return KJS::Value(); + if( !JSProxy::checkType(self, JSProxy::ValueProxy, "TQSize") ) return KJS::Value(); KJS::Value retValue = KJS::Value(); JSValueProxy *vp = JSProxy::toValueProxy( self.imp() ); - QSize val = vp->toVariant().toSize(); + TQSize val = vp->toVariant().toSize(); switch ( mid ) { case Methodwidth: @@ -89,14 +89,14 @@ KJS::Value Size::call( KJS::ExecState *exec, KJS::Object &self, const KJS::List case Methodscale: { if( args.size() == 2 ) { - QSize sz = extractQSize(exec, args, 0); + TQSize sz = extractQSize(exec, args, 0); int mode = extractInt(exec, args, 1); - val.scale(sz, (QSize::ScaleMode)mode); + val.scale(sz, (TQSize::ScaleMode)mode); } else { int x = extractInt(exec, args, 0); int y = extractInt(exec, args, 1); int mode = extractInt(exec, args, 2); - val.scale(x,y, (QSize::ScaleMode)mode); + val.scale(x,y, (TQSize::ScaleMode)mode); } break; } @@ -105,18 +105,18 @@ KJS::Value Size::call( KJS::ExecState *exec, KJS::Object &self, const KJS::List break; case MethodexpandedTo: { - QSize sz = extractQSize(exec, args, 0); + TQSize sz = extractQSize(exec, args, 0); retValue = convertToValue( exec, val.expandedTo(sz) ); break; } case MethodboundedTo: { - QSize sz = extractQSize(exec, args, 0); + TQSize sz = extractQSize(exec, args, 0); retValue = convertToValue( exec, val.boundedTo(sz) ); break; } default: - QString msg = i18n( "Size has no method %1" ).arg(mid); + TQString msg = i18n( "Size has no method %1" ).arg(mid); return throwError(exec, msg); break; } |