summaryrefslogtreecommitdiff
path: root/library/applnk.cpp
Unidiff
Diffstat (limited to 'library/applnk.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r--library/applnk.cpp6
1 files changed, 4 insertions, 2 deletions
diff --git a/library/applnk.cpp b/library/applnk.cpp
index c82d3b9..874a1b6 100644
--- a/library/applnk.cpp
+++ b/library/applnk.cpp
@@ -672,35 +672,37 @@ void AppLnk::execute() const
672{ 672{
673 execute( QStringList::split( ' ', property( "Arguments" ) ) ); 673 execute( QStringList::split( ' ', property( "Arguments" ) ) );
674} 674}
675 675
676/*! 676/*!
677 Executes the application associated with this AppLnk, with 677 Executes the application associated with this AppLnk, with
678 \a args as arguments. 678 \a args as arguments.
679 679
680 \sa exec() 680 \sa exec()
681*/ 681*/
682void AppLnk::execute(const QStringList& args) const 682void AppLnk::execute(const QStringList& args) const
683{ 683{
684#ifdef Q_WS_QWS 684#ifdef Q_WS_QWS
685 if ( !mRotation.isEmpty() ) { 685 if ( !mRotation.isEmpty() ) {
686 // ######## this will only work in the server 686 // ######## this will only work in the server
687 int rot = QPEApplication::defaultRotation(); 687 int rot = QPEApplication::defaultRotation();
688 int j = 0;
688 rot = (rot+mRotation.toInt())%360; 689 rot = (rot+mRotation.toInt())%360;
689 QCString old = getenv("QWS_DISPLAY"); 690 QCString old = getenv( "QWS_DISPLAY" ) ? getenv( "QWS_DISPLAY" ) : "Transformed";
690 setenv("QWS_DISPLAY", QString("Transformed:Rot%1:0").arg(rot), 1); 691 QString driver( old.left( ( ( j = old.find( ':' ) ) >= 0 ) ? j : old.size() ).data() );
692 setenv( "QWS_DISPLAY", QString( "%1:Rot%2:0" ).arg( driver ).arg( rot ), 1 );
691 invoke(args); 693 invoke(args);
692 setenv("QWS_DISPLAY", old.data(), 1); 694 setenv("QWS_DISPLAY", old.data(), 1);
693 } else 695 } else
694#endif 696#endif
695 invoke(args); 697 invoke(args);
696} 698}
697 699
698/*! 700/*!
699 Invokes the application associated with this AppLnk, with 701 Invokes the application associated with this AppLnk, with
700 \a args as arguments. Rotation is not taken into account by 702 \a args as arguments. Rotation is not taken into account by
701 this function, so you should not call it directly. 703 this function, so you should not call it directly.
702 704
703 \sa execute() 705 \sa execute()
704*/ 706*/
705void AppLnk::invoke(const QStringList& args) const 707void AppLnk::invoke(const QStringList& args) const
706{ 708{