summaryrefslogtreecommitdiff
Side-by-side diff
Diffstat (more/less context) (ignore whitespace changes)
-rw-r--r--library/qpeapplication.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/library/qpeapplication.h b/library/qpeapplication.h
index cff3e43..6486cad 100644
--- a/library/qpeapplication.h
+++ b/library/qpeapplication.h
@@ -180,63 +180,63 @@ private:
};
enum Transformation { Rot0, Rot90, Rot180, Rot270 }; /* from qgfxtransformed_qws.cpp */
inline int TransToDeg ( Transformation t )
{
int d = static_cast<int>( t );
return d * 90;
}
inline Transformation DegToTrans ( int d )
{
Transformation t = static_cast<Transformation>( d / 90 );
return t;
}
/*
* Set current rotation of Opie, and rotation for newly started apps.
* Differs from setDefaultRotation in that 1) it rotates currently running apps,
* and 2) does not set deforient or save orientation to qpe.conf.
*/
inline void QPEApplication::setCurrentRotation( int r )
{
// setTransformation has been introduced in Qt/Embedded 2.3.4 snapshots
// for compatibility with the SharpROM use fallback to setDefaultTransformation()
#if QT_VERSION > 233
Transformation e = DegToTrans( r );
QCString old = getenv("QWS_DISPLAY") ? getenv( "QWS_DISPLAY" ) : "Transformed";
int j = 0;
QString driver( old.left( ( ( j = old.find( ':' ) ) >= 0 ) ? j : old.size() ).data() );
::setenv( "QWS_DISPLAY", QString( "%1:Rot%2:0" ).arg( driver ).arg( r ).latin1(), 1 );
qApp->desktop()->qwsDisplay()->setTransformation( e );
#else
setDefaultRotation( r );
#endif
}
/*
* Qtopia 1.7 SDK compatibility macros
* FIXME: Support Opie Quicklaunch Interface
*/
#define QTOPIA_ADD_APPLICATION(NAME,IMPLEMENTATION) \
int main( int argc, char** argv ) \
{ \
- QPEApplication app = QPEApplication( argc, argv ); \
+ QPEApplication app( argc, argv ); \
IMPLEMENTATION* mw = new IMPLEMENTATION(); \
app.showMainWidget( mw ); \
app.exec(); \
}
#define QTOPIA_MAIN // Bee-Bop-Alula
/*
* -remove me
*/
#ifdef Q_WS_QWS
extern Q_EXPORT QRect qt_maxWindowRect;
#endif
#endif