After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 589457 - Fix up window property notification for "title"
Fix up window property notification for "title"
Status: RESOLVED FIXED
Product: mutter
Classification: Core
Component: general
git master
Other Linux
: Normal normal
: ---
Assigned To: gnome-shell-maint
gnome-shell-maint
Depends on:
Blocks:
 
 
Reported: 2009-07-23 07:16 UTC by Jon Nettleton
Modified: 2009-08-21 16:42 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Fix window title changes (1.79 KB, patch)
2009-07-23 07:17 UTC, Jon Nettleton
needs-work Details | Review
[MetaWindow]: Always notify on title property change (1.14 KB, patch)
2009-08-21 16:40 UTC, Colin Walters
none Details | Review

Description Jon Nettleton 2009-07-23 07:16:58 UTC
set_title_text was incorrectly returning the boolean modified instead of TRUE on completion.  modified is used internally for other purposes and although the title was not modified, it was being set.  set_window_title was failing to send gobject notifications because of this.  To also better reflect this change I have changed the gboolean variable in set_window_title to updated instead of modified to better reflect what is going on.
Comment 1 Jon Nettleton 2009-07-23 07:17:36 UTC
Created attachment 139049 [details] [review]
Fix window title changes
Comment 2 Jon Nettleton 2009-07-23 08:53:23 UTC
sorry filed this incorrectly.  sloppy clicking
Comment 3 Owen Taylor 2009-07-28 23:21:12 UTC
The existing meaning of the return value:

 "the title we are using was modified from the title provided by the application"

is still needed to get window->using_net_wm_visible_name set properly. I think what you want instead is to simply not conditionalize the notification on modified.
Comment 4 Colin Walters 2009-08-21 16:40:25 UTC
Created attachment 141357 [details] [review]
[MetaWindow]: Always notify on title property change

The previous notification code was attempting to use the "modified"
boolean returned from set_title_text, but "that boolean doesn't mean
what you think it means".  It actually means "I truncated the title".

Just always notify, it's far simpler than trying to compute
when we don't need to, and callers can compress if they really need
to.