diff options
author | Szymon Kłos <szymon.klos@collabora.com> | 2020-03-31 15:42:28 +0200 |
---|---|---|
committer | Szymon Kłos <szymon.klos@collabora.com> | 2020-06-23 09:09:00 +0200 |
commit | 526c4bd5dbe0225a1ff14ff1e7fe32151ab7d29d (patch) | |
tree | 29a5daa61b43de15fbaa4fec544de7f644370682 /include | |
parent | e0d0274c2b806f5148b413926ec2e58c75ce04a1 (diff) |
jsdialog: use Idle timer to send updates
Change-Id: Ib4f18bab1279c622b576dca53169b40c4a2526bc
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/94482
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Szymon Kłos <szymon.klos@collabora.com>
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/96847
Tested-by: Jenkins
Diffstat (limited to 'include')
-rw-r--r-- | include/vcl/jsdialog/jsdialogbuilder.hxx | 17 |
1 files changed, 14 insertions, 3 deletions
diff --git a/include/vcl/jsdialog/jsdialogbuilder.hxx b/include/vcl/jsdialog/jsdialogbuilder.hxx index 161d770d613a..62f6d11a2d7a 100644 --- a/include/vcl/jsdialog/jsdialogbuilder.hxx +++ b/include/vcl/jsdialog/jsdialogbuilder.hxx @@ -22,13 +22,24 @@ class ComboBox; typedef std::map<OString, weld::Widget*> WidgetMap; -class JSDialogSender +class JSDialogNotifyIdle : public Idle { - VclPtr<vcl::Window> m_aOwnedToplevel; + VclPtr<vcl::Window> m_aWindow; + std::string m_LastNotificationMessage; + +public: + JSDialogNotifyIdle(VclPtr<vcl::Window> aWindow); + + void Invoke() override; +}; + +class VCL_DLLPUBLIC JSDialogSender +{ + std::unique_ptr<JSDialogNotifyIdle> mpIdleNotify; public: JSDialogSender(VclPtr<vcl::Window> aOwnedToplevel) - : m_aOwnedToplevel(aOwnedToplevel) + : mpIdleNotify(new JSDialogNotifyIdle(aOwnedToplevel)) { } |