wizarda
14th January 2011, 05:52
Hi All,
I have created an application with a splash screen as it should be. The problem is that whenever I tap on the splash screen on my device (tested on N8 and E7), the application disappears and the background i.e. the phone menu is displayed. The application still runs in the background.
This application makes use of the internet and so it does its initial network lookup while the splash screen is on.
This issue does not occur with other applications which does not deal with initial network lookup.
The code for splash screen is as follows:
QPixmap splashPix(":/Images/splash_new.png");
QSplashScreen *splash = new QSplashScreen;
splash->setPixmap(splashPix);
splash->showFullScreen();
splash->raise();
Qt::Alignment topRight = Qt::AlignRight | Qt::AlignTop;
splash->showMessage(QObject::tr("Checking connectivity"),
Qt::AlignJustify, Qt::white);
Utils::sleep(1);
splash->showMessage(QObject::tr("Checking connectivity."),
Qt::AlignJustify, Qt::white);
Utils::sleep(1);
splash->showMessage(QObject::tr("Checking connectivity.."),
Qt::AlignJustify, Qt::white);
Utils::sleep(1);
splash->showMessage(QObject::tr("Checking connectivity..."),
Qt::AlignJustify, Qt::white);
splash->clearMessage();
net = isConnectedToNetwork(); // connection status call
if(net)
{
//Found an interface. Show status & proceed normally.
splash->showMessage(QObject::tr("Connection Found !!"),
Qt::AlignJustify, Qt::green);
qWarning("Connection found....");
Utils::sleep(2);
splash->showMessage(QObject::tr("Launching application"),
Qt::AlignJustify, Qt::green);
Utils::sleep(1);
splash->showMessage(QObject::tr("Launching application."),
Qt::AlignJustify, Qt::green);
Utils::sleep(1);
splash->showMessage(QObject::tr("Launching application.."),
Qt::AlignJustify, Qt::green);
Utils::sleep(1);
splash->showMessage(QObject::tr("Launching application..."),
Qt::AlignJustify, Qt::green);
Utils::sleep(1);
}
else
{
qWarning("Comes here");
splash->showMessage(QObject::tr("No Internet Connection !!\nPlease check the network settings.\nTrackIt will now exit..."),
Qt::AlignJustify, Qt::red);
Utils::sleep(5);
return -1;
}
Utils::sleep(5);
splash->clearMessage();
splash->finish(w);
w->showFullScreen();
delete splash;
splash = NULL;
Can anyone please help me with this issue?
Thanks and Regards.
I have created an application with a splash screen as it should be. The problem is that whenever I tap on the splash screen on my device (tested on N8 and E7), the application disappears and the background i.e. the phone menu is displayed. The application still runs in the background.
This application makes use of the internet and so it does its initial network lookup while the splash screen is on.
This issue does not occur with other applications which does not deal with initial network lookup.
The code for splash screen is as follows:
QPixmap splashPix(":/Images/splash_new.png");
QSplashScreen *splash = new QSplashScreen;
splash->setPixmap(splashPix);
splash->showFullScreen();
splash->raise();
Qt::Alignment topRight = Qt::AlignRight | Qt::AlignTop;
splash->showMessage(QObject::tr("Checking connectivity"),
Qt::AlignJustify, Qt::white);
Utils::sleep(1);
splash->showMessage(QObject::tr("Checking connectivity."),
Qt::AlignJustify, Qt::white);
Utils::sleep(1);
splash->showMessage(QObject::tr("Checking connectivity.."),
Qt::AlignJustify, Qt::white);
Utils::sleep(1);
splash->showMessage(QObject::tr("Checking connectivity..."),
Qt::AlignJustify, Qt::white);
splash->clearMessage();
net = isConnectedToNetwork(); // connection status call
if(net)
{
//Found an interface. Show status & proceed normally.
splash->showMessage(QObject::tr("Connection Found !!"),
Qt::AlignJustify, Qt::green);
qWarning("Connection found....");
Utils::sleep(2);
splash->showMessage(QObject::tr("Launching application"),
Qt::AlignJustify, Qt::green);
Utils::sleep(1);
splash->showMessage(QObject::tr("Launching application."),
Qt::AlignJustify, Qt::green);
Utils::sleep(1);
splash->showMessage(QObject::tr("Launching application.."),
Qt::AlignJustify, Qt::green);
Utils::sleep(1);
splash->showMessage(QObject::tr("Launching application..."),
Qt::AlignJustify, Qt::green);
Utils::sleep(1);
}
else
{
qWarning("Comes here");
splash->showMessage(QObject::tr("No Internet Connection !!\nPlease check the network settings.\nTrackIt will now exit..."),
Qt::AlignJustify, Qt::red);
Utils::sleep(5);
return -1;
}
Utils::sleep(5);
splash->clearMessage();
splash->finish(w);
w->showFullScreen();
delete splash;
splash = NULL;
Can anyone please help me with this issue?
Thanks and Regards.