From 79681755a6d79760691660789e507fc26950a9b9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Axel=20D=C3=B6rfler?= Date: Thu, 26 Feb 2004 18:26:50 +0000 Subject: [PATCH] StateWatcher now only sends the update message if some state actually has changed. git-svn-id: file:///srv/svn/repos/haiku/trunk/current@6766 a95241bf-73f2-0310-859d-f6bbb57e9c96 --- src/apps/diskprobe/DataEditor.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/apps/diskprobe/DataEditor.cpp b/src/apps/diskprobe/DataEditor.cpp index 8822ebd36b..89b3bf7fe9 100644 --- a/src/apps/diskprobe/DataEditor.cpp +++ b/src/apps/diskprobe/DataEditor.cpp @@ -145,7 +145,9 @@ StateWatcher::~StateWatcher() if (fWasModified != fEditor.IsModified()) update.AddBool("modified", fEditor.IsModified()); - fEditor.SendNotices(kMsgDataEditorStateChange, &update); + // only send an update if we have to report anything + if (!update.IsEmpty()) + fEditor.SendNotices(kMsgDataEditorStateChange, &update); }