eclipse.platform.swt icon indicating copy to clipboard operation
eclipse.platform.swt copied to clipboard

These webkit constants have the wrong value

Open jonahgraham opened this issue 2 months ago • 4 comments

These constants: https://github.com/eclipse-platform/eclipse.platform.swt/blob/5edaae049d453673cf36b8dee2144b32688037c3/bundles/org.eclipse.swt/Eclipse%20SWT%20WebKit/gtk/org/eclipse/swt/internal/webkit/WebKitGTK.java#L79-L87

Which are used to convert error number to message here https://github.com/eclipse-platform/eclipse.platform.swt/blob/210dfa91419ca8d6385a74ac846bf31eb97491c8/bundles/org.eclipse.swt/Eclipse%20SWT%20WebKit/gtk/org/eclipse/swt/browser/WebKit.java#L2537

are wrong.

They should be 1<<N instead of N.

jonahgraham avatar Oct 29 '25 15:10 jonahgraham

The correct value in gio source but I don't know where the docs are for this. I thought they would be https://docs.gtk.org/gio but 🤷

jonahgraham avatar Oct 29 '25 15:10 jonahgraham

It's supposed to be listed at https://docs.gtk.org/gio/index.html#enums according to me. I don't know whether you want to open an issue for them to fix it.

akurtakov avatar Oct 29 '25 16:10 akurtakov

I filed the issue https://gitlab.gnome.org/GNOME/glib/-/issues/3815 and while filing it I found the page https://docs.gtk.org/gio/flags.TlsCertificateFlags.html is there but not linked from enums section.

jonahgraham avatar Oct 29 '25 17:10 jonahgraham

Ahh! They are bitfields, not enums - https://docs.gtk.org/gio/index.html#bitfields

jonahgraham avatar Oct 29 '25 18:10 jonahgraham