diff options
author | Timothy Pearson <kb9vqf@pearsoncomputing.net> | 2011-12-05 15:55:57 -0600 |
---|---|---|
committer | Timothy Pearson <kb9vqf@pearsoncomputing.net> | 2011-12-05 15:55:57 -0600 |
commit | 9ba04742771370f59740e32e11c5f3a1e6a1b70a (patch) | |
tree | c81c34dae2b3b1ea73801bf18a960265dc4207f7 /qtjava/designer/juic/java/methods.xsl | |
parent | 1a96c45b22d01378202d9dc7ed9c47acd30f966e (diff) | |
download | tdebindings-9ba04742771370f59740e32e11c5f3a1e6a1b70a.tar.gz tdebindings-9ba04742771370f59740e32e11c5f3a1e6a1b70a.zip |
Initial TQt conversion
Diffstat (limited to 'qtjava/designer/juic/java/methods.xsl')
-rw-r--r-- | qtjava/designer/juic/java/methods.xsl | 26 |
1 files changed, 13 insertions, 13 deletions
diff --git a/qtjava/designer/juic/java/methods.xsl b/qtjava/designer/juic/java/methods.xsl index 388ba32e..48b426e7 100644 --- a/qtjava/designer/juic/java/methods.xsl +++ b/qtjava/designer/juic/java/methods.xsl @@ -55,7 +55,7 @@ KApplication app = new KApplication(); </xsl:when> <xsl:otherwise> - QApplication app = new QApplication(args); + TQApplication app = new TQApplication(args); </xsl:otherwise> </xsl:choose> <xsl:value-of select="$mainClass"/> myWidget = new <xsl:value-of select="$mainClass"/>(); @@ -74,7 +74,7 @@ * @param code string coded data * @param isCompressed need data to be uncompressed */ - private static QPixmap decodePixmap(int size, String code, boolean isCompressed) { + private static TQPixmap decodePixmap(int size, String code, boolean isCompressed) { int len = code.length() >> 1; byte [] data = new byte[len]; try { @@ -87,9 +87,9 @@ pic = new byte [size]; inflater.setInput(data); inflater.inflate(pic, 0, size); - return new QPixmap(pic); + return new TQPixmap(pic); } else { - return new QPixmap(data); + return new TQPixmap(data); } } catch (Exception e) { @@ -108,36 +108,36 @@ * ... */ public void polish() { - <xsl:for-each select="//widget[@class = 'QDataTable' or @class = 'QDataBrowser']"> + <xsl:for-each select="//widget[@class = 'TQDataTable' or @class = 'TQDataBrowser']"> <xsl:if test="not( property[@name = 'frameworkCode']/bool = 'false' )"> <xsl:variable name="dataName" select="java:getNodeName(.)"/> <xsl:variable name="conn" select="property[@name='database']/stringlist/string[1]"/> <xsl:variable name="table" select="property[@name='database']/stringlist/string[2]"/> <xsl:choose> - <xsl:when test="@class = 'QDataTable'"> + <xsl:when test="@class = 'TQDataTable'"> if ( <xsl:value-of select="$dataName"/> != null ) { - QSqlCursor cursor = <xsl:value-of select="$dataName"/>.sqlCursor(); + TQSqlCursor cursor = <xsl:value-of select="$dataName"/>.sqlCursor(); if ( cursor == null ) {<xsl:choose> <xsl:when test="$conn = '(default)'"> - cursor = new QSqlCursor( "<xsl:value-of select="$table"/>" );</xsl:when> + cursor = new TQSqlCursor( "<xsl:value-of select="$table"/>" );</xsl:when> <xsl:otherwise> - cursor = new QSqlCursor( "<xsl:value-of select="$table"/>", true, QSqlDatabase.database("<xsl:value-of select="$conn"/>") );</xsl:otherwise> + cursor = new TQSqlCursor( "<xsl:value-of select="$table"/>", true, TQSqlDatabase.database("<xsl:value-of select="$conn"/>") );</xsl:otherwise> </xsl:choose> if ( <xsl:value-of select="$dataName"/>.isReadOnly() ) - cursor.setMode( QSqlCursor.ReadOnly ); + cursor.setMode( TQSqlCursor.ReadOnly ); <xsl:value-of select="$dataName"/>.setSqlCursor( cursor, false, true ); } if ( !cursor.isActive() ) - <xsl:value-of select="$dataName"/>.refresh( QDataTable.RefreshAll ); + <xsl:value-of select="$dataName"/>.refresh( TQDataTable.RefreshAll ); } </xsl:when> <xsl:otherwise> if ( <xsl:value-of select="$dataName"/> != null ) { if ( <xsl:value-of select="$dataName"/>.sqlCursor() == null ) {<xsl:choose> <xsl:when test="$conn = '(default)'"> - QSqlCursor cursor = new QSqlCursor( "<xsl:value-of select="$table"/>" );</xsl:when> + TQSqlCursor cursor = new TQSqlCursor( "<xsl:value-of select="$table"/>" );</xsl:when> <xsl:otherwise> - QSqlCursor cursor = new QSqlCursor( "<xsl:value-of select="$table"/>", true, QSqlDatabase.database("<xsl:value-of select="$conn"/>") );</xsl:otherwise> + TQSqlCursor cursor = new TQSqlCursor( "<xsl:value-of select="$table"/>", true, TQSqlDatabase.database("<xsl:value-of select="$conn"/>") );</xsl:otherwise> </xsl:choose><xsl:text> </xsl:text> <xsl:value-of select="$dataName"/>.setSqlCursor( cursor, true ); |