aboutsummaryrefslogtreecommitdiff
path: root/src/mainwindow.cpp
diff options
context:
space:
mode:
authorLibravatar keshavbhatt <keshavnrj@gmail.com>2021-04-26 04:00:59 +0530
committerLibravatar keshavbhatt <keshavnrj@gmail.com>2021-04-26 04:00:59 +0530
commit536190c9378771e865a77d3efd87ec43c08688ef (patch)
tree78da3c83629a0e5718fe70e7604c010ce7487b69 /src/mainwindow.cpp
parent58b1141ab1339575d94aefae555538470822b967 (diff)
downloadwhatsie-536190c9378771e865a77d3efd87ec43c08688ef.tar.gz
whatsie-536190c9378771e865a77d3efd87ec43c08688ef.zip
allow app locking even if its not enabled in settings
Diffstat (limited to 'src/mainwindow.cpp')
-rw-r--r--src/mainwindow.cpp13
1 files changed, 7 insertions, 6 deletions
diff --git a/src/mainwindow.cpp b/src/mainwindow.cpp
index 18dc80c..9032d15 100644
--- a/src/mainwindow.cpp
+++ b/src/mainwindow.cpp
@@ -210,15 +210,16 @@ void MainWindow::lockApp()
if(lockWidget != nullptr && lockWidget->isLocked)
return;
- if(settings.value("asdfg").isValid() && settings.value("lockscreen").toBool()==false){
- QMessageBox::critical(this,QApplication::applicationName()+"| Error",
- "Unable to lock App, Enable AppLock in settings First.");
- this->show();
- return;
- }
+// if(settings.value("asdfg").isValid() && settings.value("lockscreen").toBool()==false){
+// QMessageBox::critical(this,QApplication::applicationName()+"| Error",
+// "Unable to lock App, Enable AppLock in settings First.");
+// this->show();
+// return;
+// }
if(settings.value("asdfg").isValid()){
init_lock();
+ lockWidget->lock_app();
}else{
QMessageBox msgBox;
msgBox.setText("App lock is not configured.");