summaryrefslogtreecommitdiff
path: root/src/progs/manaplus
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2018-03-08 01:43:04 +0300
committerAndrei Karas <akaras@inbox.ru>2018-03-08 01:43:04 +0300
commit5d190c3ae47aef32c1f1fe48f36dd27cec721cf3 (patch)
treee1788d79f031ff8196bd9de084cb95771770518d /src/progs/manaplus
parent676c5e978cbb312fbf4df8ec396c0f8b08944a96 (diff)
downloadplus-5d190c3ae47aef32c1f1fe48f36dd27cec721cf3.tar.gz
plus-5d190c3ae47aef32c1f1fe48f36dd27cec721cf3.tar.bz2
plus-5d190c3ae47aef32c1f1fe48f36dd27cec721cf3.tar.xz
plus-5d190c3ae47aef32c1f1fe48f36dd27cec721cf3.zip
Focus previous window after pin code accepted by server.
Diffstat (limited to 'src/progs/manaplus')
-rw-r--r--src/progs/manaplus/client.cpp8
-rw-r--r--src/progs/manaplus/client.h2
2 files changed, 10 insertions, 0 deletions
diff --git a/src/progs/manaplus/client.cpp b/src/progs/manaplus/client.cpp
index bc5007884..504916ea7 100644
--- a/src/progs/manaplus/client.cpp
+++ b/src/progs/manaplus/client.cpp
@@ -1853,6 +1853,14 @@ void Client::windowRemoved(const Window *const window)
mCurrentDialog = nullptr;
}
+void Client::focusWindow()
+{
+ if (mCurrentDialog != nullptr)
+ {
+ mCurrentDialog->requestFocus();
+ }
+}
+
void Client::logVars()
{
#ifdef ANDROID
diff --git a/src/progs/manaplus/client.h b/src/progs/manaplus/client.h
index 20ac722a5..28ab7323e 100644
--- a/src/progs/manaplus/client.h
+++ b/src/progs/manaplus/client.h
@@ -88,6 +88,8 @@ class Client final : public ConfigListener,
void windowRemoved(const Window *const window);
+ void focusWindow();
+
void slowLogic();
ServerInfo &getCurrentServer()