[Libreoffice-commits] core.git: desktop/source
Ashod Nakashian (via logerrit)
logerrit at kemper.freedesktop.org
Thu Jul 25 13:09:47 UTC 2019
desktop/source/lib/init.cxx | 13 +++++++++++++
1 file changed, 13 insertions(+)
New commits:
commit 6661ebe5d3c2ce12a99a6af4c8de51b61b279e57
Author: Ashod Nakashian <ashod.nakashian at collabora.co.uk>
AuthorDate: Sun May 5 20:26:42 2019 -0400
Commit: Noel Grandin <noel.grandin at collabora.co.uk>
CommitDate: Thu Jul 25 15:08:56 2019 +0200
LOK: Window creation supersedes any events on same window
This happens when we get multiple created events on
same window, interspersed with invalidations.
Change-Id: I2dbaa0f84306d770f1de047a23996209c28304fe
Reviewed-on: https://gerrit.libreoffice.org/76312
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin at collabora.co.uk>
diff --git a/desktop/source/lib/init.cxx b/desktop/source/lib/init.cxx
index 201b5d9c7dfe..9667f5eac821 100644
--- a/desktop/source/lib/init.cxx
+++ b/desktop/source/lib/init.cxx
@@ -1394,6 +1394,19 @@ void CallbackFlushHandler::queue(const int type, const char* data)
assert(aCallbackData.validate() && "Validation after setJson failed!");
}
}
+ else if (aTree.get<std::string>("action", "") == "created")
+ {
+ // Remove all previous actions on same dialog, if we are creating it anew.
+ removeAll([&nLOKWindowId](const queue_type::value_type& elem) {
+ if (elem.Type == LOK_CALLBACK_WINDOW)
+ {
+ const boost::property_tree::ptree& aOldTree = elem.getJson();
+ if (nLOKWindowId == aOldTree.get<unsigned>("id", 0))
+ return true;
+ }
+ return false;
+ });
+ }
}
break;
}
More information about the Libreoffice-commits
mailing list