mirror of
https://github.com/mudita/MuditaOS.git
synced 2026-05-25 00:59:39 -04:00
EGD-2180 Issue with gui::ShowMode
This commit is contained in:
@@ -112,7 +112,7 @@ void DesktopMainWindow::setVisibleState() {
|
||||
}
|
||||
}
|
||||
|
||||
void DesktopMainWindow::onBeforeShow( ShowMode mode, uint32_t command, SwitchData* data ) {
|
||||
void DesktopMainWindow::onBeforeShow( ShowMode mode, SwitchData* data ) {
|
||||
|
||||
//update time
|
||||
time->setText( topBar->getTimeString() );
|
||||
@@ -155,13 +155,13 @@ bool DesktopMainWindow::onInput( const InputEvent& inputEvent ) {
|
||||
if( app->getPinLocked())
|
||||
//if there was no application on to before closing proceed normally to pin protection window.
|
||||
if( lockTimeoutApplilcation.empty()) {
|
||||
application->switchWindow( "PinLockWindow", 0, nullptr );
|
||||
application->switchWindow( "PinLockWindow" );
|
||||
}
|
||||
else {
|
||||
std::unique_ptr<LockPhoneData> data = std::make_unique<LockPhoneData>();
|
||||
data->setPrevApplication( lockTimeoutApplilcation );
|
||||
lockTimeoutApplilcation = "";
|
||||
application->switchWindow( "PinLockWindow", 0, std::move(data) );
|
||||
application->switchWindow( "PinLockWindow", std::move(data) );
|
||||
}
|
||||
|
||||
else {
|
||||
@@ -189,7 +189,7 @@ bool DesktopMainWindow::onInput( const InputEvent& inputEvent ) {
|
||||
else {
|
||||
//pressing enter moves user to menu screen
|
||||
if( inputEvent.keyCode == KeyCode::KEY_ENTER ) {
|
||||
application->switchWindow( "MenuWindow", 0, nullptr );
|
||||
application->switchWindow( "MenuWindow" );
|
||||
}
|
||||
//if numeric key was pressed record that key and send it to call application with a switch command
|
||||
else if(( inputEvent.keyChar >= '0') && ( inputEvent.keyChar <= '9') ) {
|
||||
@@ -215,7 +215,7 @@ bool DesktopMainWindow::onInput( const InputEvent& inputEvent ) {
|
||||
}
|
||||
//long press of right function button move user to power off window
|
||||
else if (inputEvent.keyCode == KeyCode::KEY_RF) {
|
||||
application->switchWindow( "PowerOffWindow", 0, nullptr );
|
||||
application->switchWindow( "PowerOffWindow" );
|
||||
}
|
||||
}
|
||||
return false;
|
||||
|
||||
Reference in New Issue
Block a user