Matthias Clasen
d9a146f54a
Change icon-size properties
...
We no longer support registering custom icon sizes, so
we can make these properties just enums. This also lets
us specify them by nick in ui files. Nice!
2017-11-15 14:22:17 -05:00
Matthias Clasen
a28cf475af
image: Update docs
...
Mention the new icon-size style classes, update the docs
for removed arguments and return values, and add new
functions to the docs.
2017-11-15 14:22:17 -05:00
Matthias Clasen
f16fb1373e
Document -gtk-icon-size
...
Add this property to the list of CSS properties.
2017-11-15 14:22:17 -05:00
Matthias Clasen
43a9b82797
Support -gtk-icon-size for builtins
...
This makes css icons more similar to themed icons, which
is the overall goal here.
2017-11-15 14:22:17 -05:00
Matthias Clasen
0d23606653
Drop gtk_icon_size_lookup
...
Add a new, private gtk_image_get_image_size to replace it, and
update the remaining callers in a suitable way.
2017-11-15 14:22:17 -05:00
Matthias Clasen
866ff2b8f0
recentchooser: Use GIcon instead of GdkPixbuf
2017-11-15 14:22:17 -05:00
Matthias Clasen
c6c3427507
iconhelper: Query size via CSS
...
Instead of looking at the icon size, look at the CSS value for
-gtk-icon-size. Set style classes depending on icon size instead.
Trivially change Adwaita and HighContrast to report the same values as
before.
2017-11-15 14:22:17 -05:00
Matthias Clasen
2301d8d90b
enums: Change GtkIconSize values
...
The new values are the ones we intend to keep. The old ones had
duplicated meanings and nobody knew which one to take.
2017-11-15 14:22:17 -05:00
Benjamin Otte
e5da85631a
image: Don't take icon size in set_from_definition()
2017-11-15 14:22:17 -05:00
Matthias Clasen
67268bcc23
filechooserwidget: icon size is always 16
2017-11-15 14:22:17 -05:00
Matthias Clasen
b598a5ab78
filechooserbutton: icon size is always 16
...
So define it that way.
2017-11-15 14:22:17 -05:00
Benjamin Otte
e0a5f4e081
cellrendererspinner: Don't track old icon size
...
It was only used to avoid gtk_icon_size_lookup() calls and those aren't
expensive.
2017-11-15 14:22:17 -05:00
Matthias Clasen
dbfaa99107
image: Remove icon-size argument from icon setters
...
Instead, add a function gtk_image_set_icon_size() for the cases where
overriding the icon size is necessary.
Treat icon sizes the same way as pixel sizes, too. So gtk_image_clear()
no longer unsets the icon size.
2017-11-15 14:22:17 -05:00
Benjamin Otte
049cc6aa01
image: Change getters
...
Instead of returning the icon size with them, make
gtk_image_get_icon_name() and gtk_image_get_gicon() only return the icon
itself.
As a benefit, we can turn them into regular getters that return values
instead of requiring out parameters.
Instead, provide gtk_image_get_icon_size() to query the icon size.
2017-11-15 14:22:17 -05:00
Benjamin Otte
f53b72e5ff
button: Get rid of icon size
...
In fact, make gtk_button_new_from_icon_name() just set the icon-name
property instead of creating a GtkImage.
2017-11-15 14:22:16 -05:00
Benjamin Otte
3da65ff233
scalebutton: Remove icon size
2017-11-15 14:22:16 -05:00
Benjamin Otte
a7754a14b5
toolbar: Remove icon sizes
2017-11-15 14:22:16 -05:00
Benjamin Otte
8df61992d7
tooltips: Remove GtkIconSize usage
2017-11-15 14:22:16 -05:00
Benjamin Otte
129dc7d73b
css: Add -gtk-icon-size
...
This will replace GtkIconSize in future patches.
2017-11-15 14:22:16 -05:00
Benjamin Otte
dcc2577b97
introspection: Fix build
2017-11-15 19:33:26 +01:00
Benjamin Otte
e9629a5149
wayland: Fix initial cursor
...
Make sure the initial cursor isn't random which would happen due to an
early exit when cursor == pointer->cursor triggered because both were
NULL.
2017-11-15 19:07:17 +01:00
Benjamin Otte
4c4e914806
gdk: Replace GDK_NONE with NULL
2017-11-15 19:07:17 +01:00
Benjamin Otte
cb941956d3
gdk: Turn GdkAtom into a const char *
...
Instead of an integer, it is now a char pointer. We also use
g_intern_string() instead of doing the interning ourselves.
2017-11-15 19:07:17 +01:00
Benjamin Otte
0451c6d30c
gdk: Make GDK_NONE Atom translate to NULL
...
Instead of the string "NONE" we now use NULL.
2017-11-15 19:07:17 +01:00
Benjamin Otte
a385a50260
gdk: Get rid of magic special atoms
2017-11-15 19:07:17 +01:00
Benjamin Otte
41f9a174e2
x11: Remove special casing for GdkAtoms
...
This is in preparation for the GdkAtom removal
2017-11-15 19:07:17 +01:00
Benjamin Otte
5a1a11bcde
dnd: Make GtkDragDest and GtkDragSource use GtkTargetList
...
This gets rid of GtkTargetEntry in the API and consistently uses
GtkTargetList.
2017-11-15 19:07:17 +01:00
Benjamin Otte
7efc5a1558
clipboard: Consistently use GtkTargetList
...
Some code was using GtkTargetList, some used GtkTargetEntry and some
GtkTargetPair.
2017-11-15 19:07:16 +01:00
Benjamin Otte
fb94f79094
selection: Remove #ifdef WAYLAND
...
Instead, turn the functions into backend API:
gdk_broadway_display_add_selection_targets()
gdk_broadway_display_clear_selection_targets()
Remove the old per-backend functions, too.
2017-11-15 19:07:16 +01:00
Benjamin Otte
13ca03efb1
cellrendererpixbuf: Remove stock-detail property
...
GTK3 didn't use that property already...
2017-11-14 18:37:38 -05:00
Benjamin Otte
515b13fdd5
messagedialog: Remove unused header
2017-11-14 18:24:43 -05:00
Matthias Clasen
0436cc44fc
win32: Remove all checks for GDK_WINDOW_ROOT
...
We are no longer creating windows of this type, so no
need to check for it.
2017-11-14 18:16:19 -05:00
Matthias Clasen
e2682e62a8
win32: Remove all uses of get_root_window
...
This is following similar changes done in the x11 and
broadway backends, but it has not been built.
Some fixups may be needed.
2017-11-14 18:16:19 -05:00
Benjamin Otte
77efc60a15
placessiderbar: Fix sunny compilation
...
Make compilation not warn about unused variables when compiling with
HAVE_CLOUDPROVIDERS undefined.
2017-11-13 23:45:18 +01:00
Benjamin Otte
457bf3b604
widget: No need to update events
...
GtkWindow queues for all events anyway, so the needed ones are already
there.
2017-11-13 23:41:38 +01:00
Benjamin Otte
ed1b6a9bed
gdkwindow: Remove event_mask arguments from constructors
2017-11-13 23:41:38 +01:00
Benjamin Otte
ef5a6835b2
window: Set ALL_EVENT_MASK
...
This is a trivial commit that does a big change: We now ignore event masks.
Further commits will clean up code, but if bisection ends up here, you
know it's because code is getting delivered events that it weren't getting
before.
2017-11-13 23:41:37 +01:00
Benjamin Otte
de40ced21c
gdk: Fix GDK_ALL_EVENTS_MASK
...
This mask was forgotten to update when the last 2 event masks were
added, probably because it looks like it's already maxed.
2017-11-13 23:41:37 +01:00
Benjamin Otte
9d56cee622
widget: Remove gtk_widget_set_device_enabled()
...
Nobody is using it.
2017-11-13 23:41:37 +01:00
Matthias Clasen
5f73afae3d
x11: Remove mentions of GDK_WINDOW_ROOT
...
This backend never creates a window of this type, so no
need to check for it anymore.
2017-11-13 16:47:50 -05:00
Matthias Clasen
964cdaf3a3
x11: Stop creating a root window
...
We no longer need it.
2017-11-13 16:39:54 -05:00
Matthias Clasen
5999b1c73a
x11: Store toplevel list in GdkDisplay
...
This will let us get rid of the root window.
2017-11-13 16:32:34 -05:00
Matthias Clasen
8af666cb4f
x11: Remove another use of the root window
...
We just need the X root window here.
2017-11-13 16:09:47 -05:00
Matthias Clasen
724863c275
icontheme: Add a trailing / when enumerating resources
...
This avoids extra string copies in GResource.
2017-11-13 12:13:42 -05:00
Carlos Soriano
1b1cb8295b
gtkplacessidebar: Fix new tab/window handling for cloud accounts
...
It wasn't taking into account whether the sidebar had support for them
or not, resulting in a file chooser with open in new tab/window menu
items when it's not supported.
To fix it, do as with the other menus and check for the availability of
new tab/window flags.
https://bugzilla.gnome.org/show_bug.cgi?id=786123
2017-11-13 16:57:02 +01:00
Carlos Soriano
f54e7712c5
gtkplacessidebar: Adapt to libcloudproviders 0.2.x
...
And a few improvements on the way.
https://bugzilla.gnome.org/show_bug.cgi?id=786123
2017-11-13 16:55:10 +01:00
Matthias Clasen
2ff175938d
application: Append a / to the icon resource path
...
g_resources_enumerate_children expects the path to end
in a '/' (even though thats not stated in the docs), and
will copy it if that isn't the case. Avoid the copy
by putting a '/' there to begin with.
2017-11-13 07:35:18 -05:00
Matthias Clasen
ec1ea0db04
icontheme: Append a / to the resource path
...
g_resources_enumerate_children expects the path to end
in a '/' (even though thats not stated in the docs), and
will copy it if that isn't the case. Avoid the copy
by putting a '/' there to begin with.
2017-11-13 07:33:35 -05:00
Benjamin Otte
e0d3602331
a11y: Handle a treeview with no columns
...
Code was spewing criticals to stderr because of nonexisting columns. So
check that there's actually an existing column first.
2017-11-13 03:51:53 +01:00
Benjamin Otte
b968147e0a
treeview: Only update vadjustment in size_allocate()
...
The 2 calls even do different things, but because the one in allocate
always overrides the one here...
2017-11-13 01:53:45 +01:00