Commit Graph

29855 Commits

Author SHA1 Message Date
Matthias Clasen
9f94736c92 Remove selection-handling leftovers
The selection_get and selection_received vfuncs are
no longer used, remove them.
2018-01-02 18:14:14 -05:00
Matthias Clasen
12e4f4256d Drop an unused enum value
We haven't had a GtkWindow::frame-event since the
linux-fb backends demise.
2018-01-02 18:14:13 -05:00
Matthias Clasen
5f608a1d07 Revert "inspector: Stop using GtkWidget::event"
This reverts commit 1268440c35.

Turns out we'll keep ::event, so this was misguided.
2018-01-02 18:14:08 -05:00
Matthias Clasen
750341414d Revert "treeviewcolumn: Stop using GtkWidget::event"
This reverts commit da74314779.

Turns out we'll keep ::event, so this was misguided.
2018-01-02 18:14:04 -05:00
Matthias Clasen
506b436f09 Revert "text handler: Stop using GtkWidget::event"
This reverts commit 74f563b501.

Turns out we'll keep ::event, so this was misguided.
2018-01-02 18:13:34 -05:00
Matthias Clasen
361a3885b5 spinner cell: Avoid a crash
The icon helper is not used, so no point in crashing
while trying to destroy it.
2018-01-02 18:05:30 -05:00
Matthias Clasen
d072201b12 docs: Don't mention non-longer-existing signals
The ::window-state-event signal no longer exists.
2018-01-02 18:05:19 -05:00
Timm Bäder
355b883f32 stack-allocate GtkCssLookup instances 2018-01-02 08:36:10 +01:00
Timm Bäder
9ef700b161 css parser: Reuse one GString
Instead of creating a new one for every ident, name and string, just
create one GString and reuse it. This means the GString we keep around
will grow to the maximum size of any ident, name or string we parse,
which is still not terribly large.
2018-01-02 08:10:06 +01:00
Daniel Boles
ab0edd1091 themes: missing specificity bump on expander arrow
Commit 4ee02725b4 made the :hover apply to
the title node, not the arrow node, but the selectors it added were not
caught by the recent commits fixing the specificity of title > arrow.
2018-01-01 21:22:23 +00:00
Daniel Boles
3bcbf4cf4e themes: Regenerate CSS to reflect recent commits
a lot of them, in this case
2018-01-01 19:53:43 +00:00
Daniel Boles
4878eea06b HighContrast: Avoid expander↔combobox interference
as per commit 4241c4bdbd
2018-01-01 18:54:13 +00:00
Matthias Clasen
17bad98084 emoji: Accept unpaired releases for variations
This enables a single long-press-move-release gesture
for picking a variation. This is not perfect yet: We
don't get hover in this case.
2017-12-30 23:24:22 -05:00
Matthias Clasen
72c9853999 list, flow box: Make unpaired releases opt-in
We don't want a pointer that is moved off a scrollbar
to trigger a row when it gets released. To avoid this,
require an explicit opt-in to handling unpaired-releases.
2017-12-30 23:23:16 -05:00
Matthias Clasen
1be0b6d2d5 dnd: Drop docs that are no longer relevant
We no longer take an event as argument, so no
need to explain how to obtain a suitable event.
2017-12-30 22:46:28 -05:00
Matthias Clasen
74f563b501 text handler: Stop using GtkWidget::event
This signal is going away.
2017-12-30 22:38:14 -05:00
Matthias Clasen
da74314779 treeviewcolumn: Stop using GtkWidget::event
This signal is going away.
2017-12-30 22:27:54 -05:00
Matthias Clasen
1268440c35 inspector: Stop using GtkWidget::event
This signal is going away.
2017-12-30 22:13:45 -05:00
Matthias Clasen
7d659b21e6 Drop deprecated text view layers
These have been marked as deprecated, so lets drop them.
2017-12-29 13:13:36 -05:00
Arnaud Rebillout
25523e60c3 gtk: remove non-breaking space, probably there by mistake
Signed-off-by: Arnaud Rebillout <elboulangero@gmail.com>

https://bugzilla.gnome.org/show_bug.cgi?id=791710
2017-12-29 12:51:31 -05:00
Timm Bäder
c1573a1fda window: Avoid a set-but-not-used warning 2017-12-29 08:59:53 +01:00
Timm Bäder
a61eecc22e snapshot: Don't create clip nodes with 0 width or height 2017-12-28 16:48:35 +01:00
Matthias Clasen
4241c4bdbd Adwaita: Avoid expander<>combobox interference
Putting a combobox in an expander was causing the combo arrow
to go sideways. Increase the specificity with which we address
the expander arrow to avoid that.
2017-12-28 08:40:39 -05:00
Matthias Clasen
e90787d975 fontchooser: Add global keynav
Starting to type should focus the search entry and start
a search.
2017-12-27 17:29:24 -05:00
Matthias Clasen
06ad134876 Add an unrealize function to GtkLabel
We need to drpo the primary clipboard when the label
is getting unrealized while holding it. This fixes
a crash in the accessibility-dump test.
2017-12-26 23:33:39 -05:00
Matthias Clasen
c176d0c3d8 Simplify ui files
Run gtk3-builder-tool simplify over all our ui files.
2017-12-26 23:12:37 -05:00
Matthias Clasen
8c10849094 Avoid excess notification for GdkEventControllerScroll::flags
We have a test that checks this, and it is the right thing to do.
2017-12-26 20:06:06 -05:00
Matthias Clasen
8d9414c228 Avoid excess notification for GdkCellRendererPixbuf::icon-size
We have a test that checks this, and it is right thing to do.
2017-12-26 20:06:06 -05:00
Matthias Clasen
f307fa99a5 Drop gratitious use of GdkPoint
This is the only use of this undocumented struct,
and it does not make this code any better. Just drop it.
2017-12-26 13:00:27 -05:00
Matthias Clasen
d04f66eb52 Add GtkIconSize back to the docs
And document how it works now.
2017-12-26 08:40:43 -05:00
Matthias Clasen
b379ca3e02 check button: Fix inconsistent state
This has been broken since the inconsistent state
was moved here in 2aea8dfee9.
2017-12-25 11:36:39 -05:00
Emmanuele Bassi
f27dd8834b docs: Add missing signal parameter
The `flags` parameter is missing, and the introspection scanner is
complaining about it.
2017-12-21 19:00:28 +00:00
Emmanuele Bassi
18a56cd795 build: Ensure we introspect the print operation sources
The documentation and annotations for some of the print API is defined
in platform-specific source files, so we need to ensure we're passing
those files to the introspection scanner in order to avoid warnings, and
to get the appropriate introspected API.
2017-12-21 18:57:25 +00:00
Timm Bäder
358c139a43 gl renderer: Rework once more
Last time, I swear.
2017-12-21 19:12:30 +01:00
Timm Bäder
b488329104 GskRenderer: Remove viewport property 2017-12-21 18:25:52 +01:00
Timm Bäder
19871cfd68 snapshot: Add & use API for linear gradient nodes
This way, we can also clip the created node bounds to the current clip
of the GtkSnapshot. This works as long as we don't modify the start and
end points, and happens all the time while rendering.
2017-12-21 18:25:52 +01:00
Timm Bäder
d9f1620b2f snapshot: Directly clip color nodes
Clipping a color node is trivial so we do it here directly since that
might later save the entire clip node as well as freeing the fragment
shaders from coloring lots of pixels that will be clipped away.
2017-12-21 18:25:52 +01:00
Timm Bäder
8107b1a2dd snapshot: Fix typo 2017-12-21 18:25:51 +01:00
Matthias Clasen
1c3f343baf Remove font-name leftovers
There were still a few places where the font-name
property was used internally.
2017-12-21 12:18:53 -05:00
Matthias Clasen
559a2bf033 Add a missing include 2017-12-21 12:18:10 -05:00
Matthias Clasen
6ff3222cbd font button: Drop the font-name property
We already have the GtkFontChooser::font property
which serves the same purpose, so get rid of the
duplication.
2017-12-21 11:10:44 -05:00
Matthias Clasen
8581345acc Remove debug spew 2017-12-21 08:04:26 -05:00
Matthias Clasen
495d00e925 Fix a mis-merge 2017-12-20 10:36:25 -05:00
Matthias Clasen
22f9562928 Implement font-feature-settings
This is a missing part of the CSS font level 3 module.
2017-12-20 10:31:30 -05:00
Matthias Clasen
6042b82964 Update the docs for GtkCssChange
The docs were out of sync with the flags we actually have.
2017-12-20 08:46:03 -05:00
Matthias Clasen
5478bd59bf Fix a crash introduced in the previous commit
The signatures of row-inserted and row-deleted are not
identical, so we need to be a bit more careful here.
2017-12-19 14:17:55 -05:00
Matthias Clasen
1b05474979 font chooser: Simplify some code
Instead of separate handlers, just keep a single
handler for both row-inserted and row-deleted.
Slightly less work that way.
2017-12-19 12:10:47 -05:00
Matthias Clasen
e5154547f8 font chooser: Stop listening to style-updated
The only time a style-updated indicates we need
to reload fonts is when it is synthesized by GtkSettings
in response to a fontconfig timestamp change, but
we are listening to those already, anyway.
2017-12-19 11:45:56 -05:00
Timm Bäder
fcbbaae63c window: Make sure an event has a display
This fixes a crash happening later on when something tries to access the
event's display.
2017-12-19 07:39:29 +01:00
Matthias Clasen
675a4111e9 emoji: Skip overly wide fallback rendering
Some emoji fonts (such as Emoji One), render Emoji sequences
such as some of the family variations using multiple individual
glyphs. This rendering is too wide and breaks our grid layout.
Therefore, we will just skip any sequence whose rendering is
more than twice as wide as a simple smiley.
2017-12-17 22:11:24 -05:00
Matthias Clasen
22269902ed Avoid calling unsetenv too late
Stash the DESKTOP_AUTOSTART_ID env var in a constructor,
before any threads have been created.

https://bugzilla.gnome.org/show_bug.cgi?id=790963
2017-12-17 17:32:05 -05:00
Matthias Clasen
9a7624b47a inspector: Allow to bump scale to 3
Might as well allow this, for 'large scale testing'.
2017-12-17 16:40:10 -05:00
Matthias Clasen
21064a41b5 Remove unneeded deprecation guards
No deprecated api used in here, it seems.
2017-12-17 13:15:18 -05:00
Matthias Clasen
1293209d23 Don't place dnd cursor in placeholder text
That is just misleading - the entire placeholder text is going
to be replaced by the drop.
2017-12-17 10:52:33 -05:00
Benjamin Otte
f824439137 dnd: Get rid of IPC widgets
Instead, pass the source window to gdk_drag_begin().

Also make Wayland use this window instead of the one under the pointer
(though those 2 Windows are most likely the same anyway).
2017-12-16 02:48:12 +01:00
Benjamin Otte
8f6194a883 dnd: Remove unused function
The function was referencing itself in ways that bamboozled gcc:
  static void
  foo (void)
  {
    g_signal_handlers_disconnect_by_func (NULL, foo, NULL);
  }

Well done, function, you get your own commit!
2017-12-16 02:48:12 +01:00
Benjamin Otte
510581e0ef x11: Use gdk_drag_context_get_display() 2017-12-16 02:48:12 +01:00
Matthias Clasen
4573d2d19b listbox: Fix a crash during keynav
The code was asserting something that was not always holding
true. We can hit row == NULL here on page-up too. Handle that
case by moving to the first row.

https://bugzilla.gnome.org/show_bug.cgi?id=791549
2017-12-15 18:48:50 -05:00
Benjamin Otte
cb9867cb48 dnd: Remove handler for nonexisting signal
The signal has been gone since e3e9bf4bea
2017-12-15 23:57:33 +01:00
Benjamin Otte
31119c89df gtk: Remove unused include 2017-12-15 23:53:18 +01:00
Benjamin Otte
a04afde35c gdk: Remove DRAG_STATUS and DROP_FINISHED events
Those are source-side events that are handled by signals of the
Dragontext these days.
2017-12-15 23:48:36 +01:00
Juan Pablo Ugarte
e0ce028c88 css: Fix segfault when GtkCssStyleChange is NULL on gtk_widget_real_style_updated()
https://bugzilla.gnome.org/show_bug.cgi?id=791281
2017-12-15 10:28:21 -03:00
Matthias Clasen
e92c0e85ec Replace gdk_keymap_get_for_display by gdk_display_get_keymap
Replace all uses of the old function by the new one.
No functional change.
2017-12-15 07:44:58 -05:00
Matthias Clasen
fd85ff0c7a Drop gdk_keymap_get_default()
It is better to use the explicit keymap getter - the
default display may not even use the current gdk backend.
2017-12-14 23:57:54 -05:00
Matthias Clasen
9194ee4973 gdk: Drop GDK_DAMAGE
We haven't been generating events of this type
since we dropped offscreen windows.
2017-12-14 23:35:08 -05:00
Matthias Clasen
65fc43a1f3 Drop GDK_CLIENT_EVENT
We never generate events of this type, so no need
to carry it around.
2017-12-14 22:55:03 -05:00
Matthias Clasen
a4a2ecb21a widget: Remove the ::window-state-event signal
We no longer use this signal, so remove it.
2017-12-14 22:24:06 -05:00
Matthias Clasen
0313b8f0bc gtk: Stop handling GdkEventWindowState
These events have been superseded by GdkWindow::state.
2017-12-14 22:24:06 -05:00
Matthias Clasen
8476fc3fb0 menu: Stop using GdkEventWindowState
These events are going away.
2017-12-14 22:24:06 -05:00
Matthias Clasen
c1f9d7cb16 a11y: Stop using GdkEventWindowState
These events are going way.
2017-12-14 22:24:06 -05:00
Matthias Clasen
40d57ff884 headerbar: Stop using GdkEventWindowState
Use GdkWindow::state instead - the event is going away.
2017-12-14 22:24:06 -05:00
Matthias Clasen
1e1904a9b8 gtk: Stop using GdkEventWindowState
We can instead use the new GdkWindow::state property
change notification. The event is going away.
2017-12-14 22:24:06 -05:00
Daniel Boles
fe20fc3128 FileChooser: Update set_local_only() doc’s default
The property now defaults to FALSE, but the setter doc didn’t reflect it

While here, add a missing apostrophe too.

https://bugzilla.gnome.org/show_bug.cgi?id=791176
2017-12-14 15:36:43 +00:00
Benjamin Otte
920259c250 x11: Get rid of default Atom converters
No, using the default Wayland display is not okay to query Atoms.
2017-12-14 13:35:32 +01:00
Matthias Clasen
54a6273191 Drop gdk_atom_intern
Atoms are just interned strings now, so we can just
use g_intern_string.
2017-12-13 23:39:03 -05:00
Matthias Clasen
4c083c1ed4 Drop gdk_atom_name
Since atoms are just interned strings now, we can just
cast them to const char * where needed.
2017-12-13 23:26:23 -05:00
Matthias Clasen
e3e9bf4bea Remove no-longer-used signals
GtkWidget::selection-get and ::selection-received are no
longer used, so get rid of them.
2017-12-13 22:53:50 -05:00
Benjamin Otte
b49a9b9933 dnd: Remove gdk_drag_get_selection()
Without selections, drags can't have them either.

Also included is removing the selection from GtkSelectionData.

Includes a bunch of crude cleanups to Wayland code that no longer has to
care about selection atoms.
2017-12-14 04:39:22 +01:00
Benjamin Otte
f2bb2024c8 gdk: Remove properties
They are not used anymore.

Gone with them are PropertyNotify events.
2017-12-14 03:05:34 +01:00
Benjamin Otte
38d8fa0b6a gesture: Fix gcc constness warning 2017-12-14 03:05:34 +01:00
Benjamin Otte
d7f34874ab x11: Make unsetting transient-for work
... and just unset it from GtkWindow instead of fiddling with
properties.
2017-12-14 03:05:34 +01:00
Benjamin Otte
a4b42f0b73 gdk: Remove selection defines
And with it, remove the selections section from the docs.

So selections are gone for good now.
2017-12-14 03:05:34 +01:00
Carlos Garnacho
332b640cd3 gtk: Make gtk_get_current_event() return a reference
All callers in gtk seem to be ok with it, and it makes sense if
we are dealing with events as "static after delivered".
2017-12-14 01:05:48 +01:00
Carlos Garnacho
ee178947d7 gtk: Avoid some event copies
Those places can do with an extra reference.
2017-12-14 01:05:48 +01:00
Carlos Garnacho
d491e49fd6 gtk: s/gdk_event_free/g_object_unref/ 2017-12-14 01:05:48 +01:00
Carlos Garnacho
47f04afa48 gtk: Remove CONSTRUCT_ONLY flag from GtkEventControllerScroll::flags
There is a gtk_event_controller_scroll_set_flags() call that's meant
to be called after construction (eg. due to scrolledwindow relayouts
hiding/showing scrollbars). The property shouldn't be construct-only
for consistence.
2017-12-14 01:05:48 +01:00
Carlos Garnacho
0c8c9f59fc gtk: Adapt marshallers to GdkEvent as GObject 2017-12-14 01:05:48 +01:00
Carlos Garnacho
33330ad001 gtk/a11y: Use allocated events
Using stack allocated GdkEvent will not be ok when they become
objects.
2017-12-14 00:58:32 +01:00
Carlos Garnacho
59cab36035 gdk: Fold GdkEventPrivate fields into event structs
Now all events structs are private, it doesn't make as much sense
having GdkEventPrivate wrapping allocating events. This is a first
step towards removing it.
2017-12-14 00:58:32 +01:00
Carlos Garnacho
64decbfd74 gdk: Remove GdkEventType argument from GdkEvent union
It won't stand true anymore that the GdkEventType argument is the
first field of the GdkEvent* structs. All callers have been updated
to use event->any.type instead.
2017-12-14 00:58:32 +01:00
Carlos Garnacho
b9db0b55cb gdk: Refurbish GdkEvent struct hierarchy
Make all specific event structs contain a GdkEventAny, so the base
struct can be extended without modifying structs all over the place.
2017-12-14 00:58:32 +01:00
Matthias Clasen
9aba77e31b Redo drag source event handling
Let the gesture itself handle the events.
2017-12-13 18:56:42 -05:00
Benjamin Otte
54f9aef0d4 gdk: Remove gdk_selection_convert()
It's not used anymore.
2017-12-14 00:44:26 +01:00
Benjamin Otte
ca5f859dc8 dnd: Only send DELETE request on X11
This is Xdnd-specific and doesn't need to happen elsewhere.
2017-12-13 23:52:55 +01:00
Benjamin Otte
4042d5f242 gdk: Remove ability to own a selection
With this, the GDK_EVENT_SELECTION_REQUEST and GDK_EVENT_SELECTION_CLEAR
and the associated GtkWidget signals are gone, too.
2017-12-13 23:39:02 +01:00
Benjamin Otte
cb3ef5b642 xxx: don't claim dnd selection 2017-12-13 19:37:11 +01:00
Benjamin Otte
b66052f3ce gdk: Remove gdk_selection_add_targets()
It's not needed anymore, now that we can look at the content provider's
formats.

Alose remove all the API in GTK that was used to set it.
2017-12-13 19:27:51 +01:00
Benjamin Otte
65eab87238 x11: Move selection handling to GDK
Instead of claiming the selection in GTK, claim it in the X11 dnd code.
Also handle SelectionRequest and SelectionClear X events there.
2017-12-13 18:31:06 +01:00
Benjamin Otte
8648d5409e dnd: Pass content to gdk_drag_begin()
Instead of just passing the GdkContentFormats, we are now passing the
GdkContentProvider to gdk_drag_begin().
This means that GDK itself can now query the data from the provider
directly instead of having to send selection events.

Use this to provide the private API gdk_drag_context_write() that allows
backends to pass an output stream that this data will be written to.
Implement this as the mechanism for providing drag data on Wayland.

And to make this all work, implement a content provider named
GtkDragContent that is implemented by reverting to the old DND
drag-data-get machinery inside GTK, so for widgets everything works just
like before.
2017-12-13 15:05:27 +01:00
Matthias Clasen
c30cd885dd A forgotten file
These changes belong to the scale button autoscrollling
commit.
2017-12-12 23:23:17 -05:00
Matthias Clasen
7e02ad648c toolbar: Stop using legacy event signals
We can reuse the button gesture here.
2017-12-12 22:55:48 -05:00
Matthias Clasen
fa7ef93bc5 scalebutton: Add autoscrolling
Use the smooth autoscrolling that the scale can do,
and at the same time stop using legacy event signals.
2017-12-12 22:21:43 -05:00
Matthias Clasen
05fbd32c4d button: Add private api to get at the gesture
Attaching another gesture from the outside does not
work currently, so let widgets share their button's
gesture for now.
2017-12-12 22:18:19 -05:00
Matthias Clasen
b891d205dd range: Add private api to autoscroll
This will be used to scroll the scale in scale buttons.
2017-12-12 22:17:49 -05:00
Matthias Clasen
2f6f8a7e6f path bar: Drop non-functional hold-to-scroll code
Scrolling a path bar is of marginal usefulness - you need to
find a really deep place in your filesystem hierarchy in order
to scroll one or two places at best. And the code we had for
this was not working. And it was using legacy event handlers.
Instead of fixing it, remove it.
2017-12-12 20:49:31 -05:00
Matthias Clasen
1b9aa1b708 a11y: drop the focus tracker
This code was doing horrible things, and the atk documentation
for the focus tracking feature says that this is deprecated and
not used anymore. So lets not do it.
2017-12-12 14:49:44 -05:00
Matthias Clasen
33fdcca2cf placesview: Make middle click work
This does not cost us much, and improves consistency.
2017-12-12 13:56:15 -05:00
Matthias Clasen
6896e9402e Deprecate many legacy event signals
Mark the following signals as deprecated:
event, event-after, button-press-event, button-release-event,
touch-event, scroll-event, motion-notify-event, enter-notify-event,
leave-notify-event, property-notify-event, selection-clear-event,
selection-request-event, selection-notify-event, selection-received,
selection-get, proximity-in-event, proximity-out-event. Most
of these have suitable replacements in event controllers and
gestures already. The selection-related signals will soon be
irrelevant when selection handling moves to GDK.

Set G_ENABLE_DIAGNOSTIC=1 to see deprecation
warnings for uses of these signals.
2017-12-12 11:04:49 -05:00
Matthias Clasen
20bdb347cd Install gtkeventcontrollermotion.h
Public headers need to be listed in gtk/meson.build.
This was overlooked when I added the controller.
2017-12-12 10:39:16 -05:00
Matthias Clasen
c3851c5469 paned: Stop using motion notify
We can use the new motion event controller that
was introduced for this purpose.
2017-12-12 09:42:05 -05:00
Matthias Clasen
3aa6890e3e about dialog: Stop using event-after as well
We can just use a multipress gesture for this purpose.
2017-12-12 09:42:05 -05:00
Matthias Clasen
56a41f174e about dialog: Stop using motion notify
We can use the new motion event controller for this.
2017-12-12 09:42:05 -05:00
Matthias Clasen
ecdf8c64fe label: Use GtkEventControllerMotion
This lets us avoid legacy event signals here.
2017-12-12 09:42:05 -05:00
Matthias Clasen
911f9fb0ee Add a simple motion eventcontroller
This can serve as a replacement for the legacy
event signals for enter/leave/motion notify.
2017-12-12 09:42:05 -05:00
Benjamin Otte
b80d14ba19 placessidebar: Don't use root coordinates 2017-12-12 00:31:49 +01:00
Benjamin Otte
04ac4c66ae dnd: Pass device, not event
You don't start a dnd operation with a device, you start it with an
event.
2017-12-12 00:31:49 +01:00
Benjamin Otte
23c798b41d dnd: No longer allow passing -1
Nobody ever does that and special cases are evil.
2017-12-12 00:29:51 +01:00
Benjamin Otte
756b276070 dnd: Remove button argument from drag_begin()
It was unused.
2017-12-12 00:29:51 +01:00
Matthias Clasen
1e4aeb2efb calendar: Stop using a legacy event handler
Replace the motion_notify handler by a drag gesture.
2017-12-10 22:15:12 -05:00
Matthias Clasen
474d36499a Adwaita: Set an icon size for drag icons
This makes drag icons set from icon names come out
at a size that it large enough to not disappear under
the drag cursor.
2017-12-10 21:17:13 -05:00
Matthias Clasen
c2bdae23a1 Set a style class for drag icons
This lets us use the new icon-size machinery to
ensure we don't have tiny drag icons when using
named icons.
2017-12-10 21:16:31 -05:00
Benjamin Otte
643a6c2311 gdk: Remove gdk_drag_manage_dnd()
Instead, pass the actions as part of gdk_drag_begin() and insist DND is
always managed.

A new side effect is that gdk_drag_begin() can now return %NULL.
2017-12-11 01:46:33 +01:00
Benjamin Otte
7e0844d92f dnd: No point in determining the keyboard
We only use the pointer.
2017-12-11 01:02:31 +01:00
Benjamin Otte
218efa62ef dnd: Pass dx/dy instead of x_root/y_root
This way, we don't need root coordinates when computing the dnd start
position.
2017-12-11 01:02:31 +01:00
Benjamin Otte
a7c3c794df dnd: Make gdk_drag_context_set_device() private
There's no need to call it from GTK anymore, because we pass the device
to gdk_drag_begin().
2017-12-11 01:02:31 +01:00
Benjamin Otte
33a634be33 calendar: Don't request drag data on every motion event
At least wait until we've received the previous one.
2017-12-11 01:02:31 +01:00
Benjamin Otte
565d8325c4 gdk: Remove outdated gdk_drag_begin() alternatives
There's only one that's ever used, so delete the others and rename this
one to gdk_drag_begin().
2017-12-11 01:02:31 +01:00
Matthias Clasen
6af4947e70 link button: Set a drag icon
It is a bit odd to drag nothing around, so set an icon.
2017-12-10 14:05:01 -05:00
Matthias Clasen
642588b9cd docs: Don't mention css for setting cursors
We don't have a plan to make this work, so lets not
talk about it in the docs.
2017-12-09 23:59:31 -05:00
Matthias Clasen
c35cb0eb1b entry: Allocate the progress bar only what it needs
We were allocating the progress bar to the full size
of the entry. This made entry icons loose their cursors,
since they were 'covered' by the progress bar, even though
it doesn't draw anything there.
2017-12-09 23:48:35 -05:00
Colomban Wendling
69344322d1 Fix updating the widget accessible description when using its tooltip
We need to notify ATK the description changed when the tooltip text associated
with the widget changes and gtk_widget_accessible_get_description() would use
it as the description.

https://bugzilla.gnome.org/show_bug.cgi?id=779009
2017-12-09 21:24:44 -05:00
Benjamin Otte
7a17865b22 dnd: Remove "delete" argument from gtk_drag_finish()
The argument is ignored by anything but X11.
It's treated like suggested_action == MOVE.

So do that in gtk_drag_finish(), too.
2017-12-10 01:33:38 +01:00
Benjamin Otte
803cbd576f dnd: Introduce gdk_drop_read_async() and use it
This is the replacement for selection usage.

Backend implementations for X11 (missing support for backwards compat
formats like COMPOUND_TEXT) and Wayland are included.

GTK code should be adapted to use gdk_drop_read_*() functions instead
of gtk_drag_get_data().
2017-12-10 01:09:14 +01:00
Benjamin Otte
234d34366a clipboard: Add the useful stuff from reverted commit
This is the parts of dc50e0637f that
should have been committed but were reverted in
b5c62cf86f to unbreak the build.
2017-12-10 01:09:14 +01:00
Carlos Garnacho
8233cf3688 gtkwindow: Allow edge resizing from corners if constraints forbid either side
The fix is twofold. First, when checking that a corner is resizable, we must
check the constraints on both edges. Second, when checking either edge we
must include both perpendicular sides in order to allow those to be
resizable when the constraint does not allow resizing the edge being
checked.
2017-12-09 22:19:57 +01:00
Carlos Garnacho
6b4dd4be6c gtkwindow: Use shadow border when calculating resize areas positions
This way resize areas are correctly positioned right outside the visible
window edge on all sides.
2017-12-09 17:33:44 +01:00
Carlos Garnacho
f6ef18ac74 gtkwindow: Do not account handle size when checking content area
This is necessary to bring back the L-shaped resize corners. On all edges
(not corners) the handle width is determined by the border size.
2017-12-09 17:32:02 +01:00
Rico Tzschichholz
d872640927 Fix some parameter name mismatches to make g-ir-scanner happier 2017-12-09 15:36:35 +01:00
Matthias Clasen
b3ebffa07d Switch the order for cursor lookup
When looking for the cursor to apply, start from the innermost
widget and go up. This is the right behavior for cases like
entry icons. The top-down order we were using so far is the
right behavior for cases like global wait cursors. Since we
have entry icons in gtk, but not global wait cursors, lets
pick the other order for now.
2017-12-09 08:35:23 -05:00
Timm Bäder
da0582075a treeview: Don't draw background twice
This is done unconditionally for all widgets these days.
2017-12-09 13:15:07 +01:00
Timm Bäder
f7f0461471 recorder: Show rounded clip node corner size info 2017-12-09 13:14:59 +01:00
Timm Bäder
329683f746 snapshot: Don't create blur nodes with radius 0 2017-12-09 13:14:51 +01:00
Timm Bäder
f6f1dfb55d snapshot: Collapse color matrix nodes
Color matrix nodes as the child of other color matrix nodes can happen
quite frequently as a result of CSS. To ease the renderer
implementations, collapse chains of color matrix nodes into one.
2017-12-09 13:14:44 +01:00
Matthias Clasen
e7ed7c1913 paned: Grab during the drag
This is necessary to ensure we get the right cursor.
2017-12-08 21:09:24 -05:00
Marco Trevisan (Treviño)
29f36fed08 cssshadowvalue: don't apply the y_scale offset twice to the shadow
As per commit 942e904 this changed causing a regression that
seems to be visible only when scale > 2.

https://bugzilla.gnome.org/show_bug.cgi?id=791363
2017-12-08 18:23:10 -05:00
Matthias Clasen
072f06abf7 Fix fallout from g_object_ref change
g_object_ref now returns the type of the object that was
passed. Introduce cast as necessary to avoid warnings due
to this.
2017-12-08 17:48:47 -05:00
Matthias Clasen
029a84aa74 Fix fallout from the show-close-button rename
I had overlooked ui files. We should really
validate those during build.
2017-12-08 11:29:14 -05:00
Matthias Clasen
fec0dc2b13 Rename GtkHeaderBar::show-close-button
It is about all window buttons, so rename it to ::show-title-buttons.

https://bugzilla.gnome.org/show_bug.cgi?id=779862
2017-12-07 22:37:06 -05:00
Colin Leroy
0156c52a2c placesview: Present FUSE-reachable network shares in Other Locations
The documentation about gtk_file_chooser_set_local_only() states
that "non-native files may still be available using the native
filesystem via a userspace filesystem (FUSE)."
The code that made this possible in GTK+2 was missing from GTK+3 and
that represented a regression for Linux users in numerous applications
(Firefox, Thunderbird, Chromium, ...)

https://bugzilla.gnome.org/show_bug.cgi?id=787128
2017-12-07 21:31:46 -05:00
Matthias Clasen
2d85e8df8b Fix a typo in the docs 2017-12-06 23:39:27 -05:00