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 736013 - replace deprecated widgets
replace deprecated widgets
Status: RESOLVED FIXED
Product: gnome-control-center
Classification: Core
Component: general
unspecified
Other Linux
: Normal normal
: ---
Assigned To: Control-Center Maintainers
Control-Center Maintainers
Depends on:
Blocks:
 
 
Reported: 2014-09-04 08:25 UTC by Ondrej Holy
Modified: 2015-01-16 16:49 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
build.log (99.81 KB, text/x-log)
2014-09-04 08:25 UTC, Ondrej Holy
  Details
um-editable-combo: avoid using deprecated GtkAlignment and GtkMisc (3.48 KB, patch)
2014-09-04 08:28 UTC, Ondrej Holy
committed Details | Review
um-editable-button: avoid using deprecated GtkAlignment and GtkMisc (2.69 KB, patch)
2014-09-04 08:28 UTC, Ondrej Holy
committed Details | Review
cc-editable-entry: avoid using deprecated GtkAlignment and GtkMisc (2.88 KB, patch)
2014-10-06 10:49 UTC, Ondrej Holy
committed Details | Review
mouse: avoid using deprecated GtkAlignment and GtkMisc (19.46 KB, patch)
2014-10-06 10:50 UTC, Ondrej Holy
needs-work Details | Review
mouse: avoid using deprecated GtkAlignment and GtkMisc (19.21 KB, patch)
2014-10-20 09:42 UTC, Ondrej Holy
committed Details | Review
cc-editable-entry: don't use deprecated xalign on GtkButton (1.08 KB, patch)
2014-11-07 15:56 UTC, Ondrej Holy
committed Details | Review
mouse: replace deprecated stuff (5.42 KB, patch)
2014-11-07 15:56 UTC, Ondrej Holy
needs-work Details | Review
user-accounts: replace deprecated stuff (8.64 KB, patch)
2014-11-07 15:57 UTC, Ondrej Holy
committed Details | Review
cc-language-chooser: remove deprecated GtkMisc (904 bytes, patch)
2014-11-07 15:57 UTC, Ondrej Holy
committed Details | Review
printers: Stop using x/yalign properties on CcEditableEntry instances (3.42 KB, patch)
2014-11-19 20:24 UTC, Rui Matos
none Details | Review
mouse: replace deprecated stuff (5.58 KB, patch)
2014-11-20 11:01 UTC, Ondrej Holy
committed Details | Review

Description Ondrej Holy 2014-09-04 08:25:48 UTC
Created attachment 285317 [details]
build.log

Deprecated widgets shouldn't be used in the code of g-c-c. See warnings in the attached build.log. 

This is especially GtkMisc and GtkAlignment, which can be easily replaced by the GtkWidget properties. See manual for the details:
https://developer.gnome.org/gtk3/unstable/GtkMisc.html#GtkMisc.description
https://developer.gnome.org/gtk3/unstable/GtkAlignment.html#GtkAlignment.description
Comment 1 Ondrej Holy 2014-09-04 08:28:21 UTC
Created attachment 285318 [details] [review]
um-editable-combo: avoid using deprecated GtkAlignment and GtkMisc
Comment 2 Ondrej Holy 2014-09-04 08:28:48 UTC
Created attachment 285319 [details] [review]
um-editable-button: avoid using deprecated GtkAlignment and GtkMisc
Comment 3 Bastien Nocera 2014-09-04 10:38:39 UTC
Review of attachment 285318 [details] [review]:

Looks fine.
Comment 4 Bastien Nocera 2014-09-04 10:39:06 UTC
Review of attachment 285319 [details] [review]:

Looks good as well.
Comment 5 Ondrej Holy 2014-10-06 10:49:38 UTC
Created attachment 287832 [details] [review]
cc-editable-entry: avoid using deprecated GtkAlignment and GtkMisc
Comment 6 Ondrej Holy 2014-10-06 10:50:11 UTC
Created attachment 287833 [details] [review]
mouse: avoid using deprecated GtkAlignment and GtkMisc
Comment 7 Bastien Nocera 2014-10-16 10:51:39 UTC
Review of attachment 287832 [details] [review]:

Looks good otherwise.

::: shell/cc-editable-entry.c
@@ +237,3 @@
         if (priv->width_chars != n_chars) {
                 label = gtk_bin_get_child (GTK_BIN (priv->button));
+

white space change.
Comment 8 Bastien Nocera 2014-10-16 10:53:10 UTC
Review of attachment 287833 [details] [review]:

libgd change snuck in. Looks good otherwise.
Comment 9 Ondrej Holy 2014-10-20 09:42:31 UTC
Created attachment 288904 [details] [review]
mouse: avoid using deprecated GtkAlignment and GtkMisc

Libgd change snuck out...
Comment 10 Bastien Nocera 2014-10-20 09:48:05 UTC
Review of attachment 288904 [details] [review]:

Looks good to commit after branching.
Comment 11 Ondrej Holy 2014-10-31 07:55:58 UTC
Comment on attachment 285318 [details] [review]
um-editable-combo: avoid using deprecated GtkAlignment and GtkMisc

commit d6a0c18f094694f14a9a4cc95b0147fd3c587aae
Comment 12 Ondrej Holy 2014-10-31 07:56:37 UTC
Comment on attachment 285319 [details] [review]
um-editable-button: avoid using deprecated GtkAlignment and GtkMisc

commit 946ff4eb3c80d7199c279f25a8aaae85e7bd8bcb
Comment 13 Ondrej Holy 2014-10-31 07:56:56 UTC
Comment on attachment 287832 [details] [review]
cc-editable-entry: avoid using deprecated GtkAlignment and GtkMisc

commit 192888fea4dcf10dc0139f8a6215499e4ede5e54
Comment 14 Ondrej Holy 2014-10-31 07:57:17 UTC
Comment on attachment 288904 [details] [review]
mouse: avoid using deprecated GtkAlignment and GtkMisc

commit 2640a9dfd7ac5ac51ac4aeb73e82916839bf8294
Comment 15 Ondrej Holy 2014-11-07 15:56:20 UTC
Created attachment 290182 [details] [review]
cc-editable-entry: don't use deprecated xalign on GtkButton
Comment 16 Ondrej Holy 2014-11-07 15:56:44 UTC
Created attachment 290183 [details] [review]
mouse: replace deprecated stuff
Comment 17 Ondrej Holy 2014-11-07 15:57:04 UTC
Created attachment 290184 [details] [review]
user-accounts: replace deprecated stuff
Comment 18 Ondrej Holy 2014-11-07 15:57:21 UTC
Created attachment 290186 [details] [review]
cc-language-chooser: remove deprecated GtkMisc
Comment 19 Ondrej Holy 2014-11-07 15:58:32 UTC
Hopefully this removes/replaces all deprecated stuff in my panels and get rid of those warnings :-)
Comment 20 Rui Matos 2014-11-19 20:15:20 UTC
Review of attachment 290184 [details] [review]:

ok
Comment 21 Rui Matos 2014-11-19 20:15:42 UTC
Review of attachment 290186 [details] [review]:

ok
Comment 22 Rui Matos 2014-11-19 20:15:46 UTC
Review of attachment 290183 [details] [review]:

::: panels/mouse/gnome-mouse-test.c
@@ +310,3 @@
 				  gtk_adjustment_get_upper (adjustment));
 
+	provider = GTK_STYLE_PROVIDER (gtk_css_provider_new ());

This instance needs to be unrefed at the end below

@@ +312,3 @@
+	provider = GTK_STYLE_PROVIDER (gtk_css_provider_new ());
+	gtk_css_provider_load_from_data (GTK_CSS_PROVIDER (provider), "* {background: #565854}", -1, NULL);
+	gtk_style_context_add_provider (gtk_widget_get_style_context (WID ("viewport")), provider, G_MAXUINT);

GTK_STYLE_PROVIDER_PRIORITY_APPLICATION seems like the priority value that we should use here
Comment 23 Rui Matos 2014-11-19 20:15:50 UTC
Review of attachment 290182 [details] [review]:

ok
Comment 24 Rui Matos 2014-11-19 20:24:35 UTC
Created attachment 291035 [details] [review]
printers: Stop using x/yalign properties on CcEditableEntry instances

Commit 192888fea4dcf10dc0139f8a6215499e4ede5e54 made this widget
inherit from GtkBin instead of GtkAlignment and thus made this panel
abort on load due to the properties in the .ui file becoming invalid.
Comment 25 Ondrej Holy 2014-11-20 10:42:59 UTC
Comment on attachment 290182 [details] [review]
cc-editable-entry: don't use deprecated xalign on GtkButton

commit bd5ac1078d8f3f29d9f740aa00f55df1cd6d4e2f
Comment 26 Ondrej Holy 2014-11-20 10:43:29 UTC
Comment on attachment 290184 [details] [review]
user-accounts: replace deprecated stuff

commit 320f6e617bb78f1ecea0ef974e90430daf3329c5
Comment 27 Ondrej Holy 2014-11-20 10:43:58 UTC
Comment on attachment 290186 [details] [review]
cc-language-chooser: remove deprecated GtkMisc

commit e9af927e5fa444206ac4b78d45b540a6295d4c6a
Comment 28 Ondrej Holy 2014-11-20 10:47:11 UTC
Comment on attachment 291035 [details] [review]
printers: Stop using x/yalign properties on CcEditableEntry instances

Marek was already fixing this crashes before some time, please discuss it with him :-)
Comment 29 Ondrej Holy 2014-11-20 10:48:08 UTC
Thanks for the reviews, I will fix the last patch soon...
Comment 30 Ondrej Holy 2014-11-20 11:01:21 UTC
Created attachment 291077 [details] [review]
mouse: replace deprecated stuff
Comment 31 Rui Matos 2014-11-20 11:24:57 UTC
Review of attachment 291077 [details] [review]:

looks fine
Comment 32 Ondrej Holy 2014-11-20 13:28:18 UTC
Comment on attachment 291077 [details] [review]
mouse: replace deprecated stuff

commit 71aca7abdb090ccf4ba5ba52e178ce799424f7ce
Comment 33 Marek Kašík 2014-11-24 16:11:10 UTC
(In reply to comment #24)
> Created an attachment (id=291035) [details] [review]
> printers: Stop using x/yalign properties on CcEditableEntry instances
> 
> Commit 192888fea4dcf10dc0139f8a6215499e4ede5e54 made this widget
> inherit from GtkBin instead of GtkAlignment and thus made this panel
> abort on load due to the properties in the .ui file becoming invalid.

Hi,

I've prepared a similar patch for this and some related issues here: https://bugzilla.gnome.org/show_bug.cgi?id=739737.
Comment 34 Bastien Nocera 2015-01-16 08:30:08 UTC
(In reply to comment #33)
> (In reply to comment #24)
> > Created an attachment (id=291035) [details] [review] [details] [review]
> > printers: Stop using x/yalign properties on CcEditableEntry instances
> > 
> > Commit 192888fea4dcf10dc0139f8a6215499e4ede5e54 made this widget
> > inherit from GtkBin instead of GtkAlignment and thus made this panel
> > abort on load due to the properties in the .ui file becoming invalid.
> 
> Hi,
> 
> I've prepared a similar patch for this and some related issues here:
> https://bugzilla.gnome.org/show_bug.cgi?id=739737.

Is that patch obsolete and the bug fixed then?
Comment 35 Ondrej Holy 2015-01-16 08:40:58 UTC
Comment on attachment 291035 [details] [review]
printers: Stop using x/yalign properties on CcEditableEntry instances

Yes, this is obsolete, however there are still some warnings about deprecated widgets while compiling, so I think the bug is valid...
Comment 36 Rui Matos 2015-01-16 16:49:55 UTC
(In reply to comment #35)
> (From update of attachment 291035 [details] [review])
> Yes, this is obsolete, however there are still some warnings about deprecated
> widgets while compiling, so I think the bug is valid...

The few remaining ones should be gone when all the patches in bug 740986 and bug 691559 land