Timm Bäder
3a3783dfcd
image: Stop using gtk_widget_get_content_size
2017-12-04 12:24:18 +01:00
Timm Bäder
dbc4796d6a
popover: Stop using gtk_widget_get_content_size
2017-12-03 22:05:15 +01:00
Timm Bäder
7cc9bee7a2
spinner: Stop using gtk_widget_get_content_size
2017-12-03 22:04:59 +01:00
Benjamin Otte
52b1cd40d1
gsk: Remove gsk_render_node_set_scaling_filters()
...
This is a leftover from the very early rendernode that we forgot to delete.
This can be seen by the fact that it is settable on an immutable object.
2017-12-03 21:57:21 +01:00
Piotr Drąg
794a2bfd00
Use Unicode quotation marks in new strings
...
See https://developer.gnome.org/hig/stable/typography.html
https://bugzilla.gnome.org/show_bug.cgi?id=772371
2017-12-03 18:38:39 +01:00
Piotr Drąg
a5815ad5c6
Update POTFILES.in
2017-12-03 18:24:36 +01:00
Руслан Ижбулатов
bcc77e169c
GDK W32: Remove stray debug code
...
I have no idea how this slipped into master (these two lines are not present
in the same commit that went into gtk-3-22).
2017-12-03 06:10:03 +00:00
Benjamin Otte
acee3809b3
dnd: Remove unused variables
2017-12-03 06:50:51 +01:00
Matthias Clasen
6ab72b2653
Remove GdkDragProtocol from the api
...
...together with apis that return it. We were not using this
information in GTK+ at all, so no need to provide it.
2017-12-03 06:41:08 +01:00
Matthias Clasen
8b1b9f8c55
Drop api that is only for unmanaged dnd
...
These functions are not needed as public api anymore.
2017-12-03 06:24:24 +01:00
Matthias Clasen
e74c46fc4e
dnd: Handle rootwin drop in gdk
...
This lets us drop the only use of the drag protocol in gtk.
2017-12-03 06:22:25 +01:00
Matthias Clasen
6cfb55a396
dnd: Remove much of the unmanaged dnd
2017-12-03 06:17:42 +01:00
Benjamin Otte
ff577e6c2c
wayland: Add primary clipboard subclass
...
I decided to put this in a custom subclass, because then I could keep
the whole gtk primary protocol self-contained.
The other option would have been reusing GdkWaylandClipboard, but that
didn't seem worth it, especially because that code needs to interact
with the DND machinery, while the primary doesn't.
2017-12-03 05:46:49 +01:00
Benjamin Otte
ef69daacdf
wayland: Implement taking over the clipboard
...
The clipboard is now complete.
That was fast.
2017-12-03 05:46:49 +01:00
Benjamin Otte
82002eabfe
wayland: Implement reading the clipboard
...
We now keep track of what's in the clipboard and allow people to read
its contents.
2017-12-03 05:46:49 +01:00
Benjamin Otte
00192266a1
wayland: Add skeleton for a GdkClipboardWayland
...
Creates the source file and a custom subclass and makes sure it's used
by GDK.
2017-12-03 05:46:49 +01:00
Benjamin Otte
437d70f569
gdk: Get rid of owner change events
...
They're unused now.
2017-12-03 05:46:49 +01:00
Benjamin Otte
2d5c82b4ec
gtk: Remove GtkClipboard
2017-12-03 05:46:49 +01:00
Benjamin Otte
c8edc6ed58
icon-browser: Port to new clipboard
2017-12-03 05:46:49 +01:00
Benjamin Otte
c833b47b21
gtk-demo: Port to GdkClipboard
2017-12-03 05:46:49 +01:00
Benjamin Otte
18bf0eb61a
clipboard: Change image convenience APIs
...
Don't use pixbufs anymore, use textures.
2017-12-03 05:46:49 +01:00
Benjamin Otte
a34836f35b
gdk: Add (de)serializers for GDK_TYPE_TEXTURE
...
We want to use textures more, so we should be able to use them for
copy/paste and dnd.
2017-12-03 05:46:49 +01:00
Benjamin Otte
ead67a7c17
x11: Handle case where clipboard was reclaimed quickly
...
When the reply to a TARGETS request comes in, the clipboard may already
be reclaimed by the local app. Deal with that case (in an ugly way,
strictly speaking we should use a cancellable here).
This happens for example at startup when the initial TARGETS requests
have not been answered until after the main widow popped up. And if such
a window immediately claims the primary clipboard (like when the initial
focus is inside an entry), this race will happen.
2017-12-03 05:46:49 +01:00
Benjamin Otte
24c934f8c0
entry: Port to GdkClipboard
2017-12-03 05:46:49 +01:00
Benjamin Otte
5abd7a39a2
x11: Implement storing the clipboard
2017-12-03 05:46:49 +01:00
Benjamin Otte
b75546d0fb
x11: Implement MULTIPLE requests
2017-12-03 05:46:48 +01:00
Benjamin Otte
3ea258de26
tests: Don't crash if widgets go away before clipboard
...
Don't g_signal_connect() to the clipboard without protection - the
clipboard might outlast you and still emit signals.
2017-12-03 05:46:48 +01:00
Benjamin Otte
ea18793965
x11: Introduce GdkX11PendingSelectionNotify
...
This object tracks the SelectionNotifyEvent that has to be sent in
response to a SelectionRequest.
Currently it just looks like code reshuffling, but it's a prerequisite
for handling MULTIPLE, which requires to only send the notify after
every stream has writtten at least once.
But anyway, code is cleaner now, so it's a win!
2017-12-03 05:46:48 +01:00
Benjamin Otte
bcc0d4b5f0
x11: Split out a function
...
This will be necessary for MULTIPLE handling.
2017-12-03 05:46:48 +01:00
Benjamin Otte
0ff3340da7
main: Implement storing all clipboards
2017-12-03 05:46:48 +01:00
Benjamin Otte
4cce109e16
application: Put shared code into a common function
2017-12-03 05:46:48 +01:00
Benjamin Otte
fe7c283aea
clipboard: Add infrastructure to store clipboards
...
Clipboard managers will be so happy once the backends actually implement
it!
2017-12-03 05:46:48 +01:00
Benjamin Otte
51e46cc898
contentprovider: Add ref_storable_formats()
...
This is to be used for advocating to clipboard managers.
2017-12-03 05:46:48 +01:00
Benjamin Otte
ca96fac488
filechooserwidget: Port to new clipboard
...
We use the new GDK_TYPE_FILE_LIST here.
2017-12-03 05:46:48 +01:00
Benjamin Otte
6b326b14c0
gdk: Add GDK_TYPE_FILE_LIST with serializers
...
This is a GSList of GFile and we want it so we can operate with lists of
files and text/uri-list.
I chose GSList over GList because that's what the GtkFileChooser API
uses, too.
2017-12-03 05:46:48 +01:00
Benjamin Otte
928c98a84e
gdk: Add serializers and deserializers for GFile
...
in particular, support:
GFile <=> text/uri-list
GFile => text/plain
2017-12-03 05:46:48 +01:00
Benjamin Otte
39d4622563
tests: Improve formats list for testclipboard2
2017-12-03 05:46:48 +01:00
Benjamin Otte
5632d0eabb
label: Port to new clipboard
2017-12-03 05:46:48 +01:00
Benjamin Otte
f53848c360
textview: Redo clipboard handling
...
Instead of using GtkClipboard and handling everything ourselves, we now
put GtkTextBuffer into the GdkClipboard and register (de)serializers for
text/plain.
2017-12-03 05:46:48 +01:00
Benjamin Otte
4e06aaeaa8
gdk: Add gdk_content_formats_new_for_gtype()
...
Many places create formats for a single tpye, so make it easy for them
to get this without having to create a builder first.
2017-12-03 05:46:48 +01:00
Benjamin Otte
cc07800570
gdk: Allow setting task data on (de)serializers
...
This mirrors GTask.
2017-12-03 05:46:48 +01:00
Benjamin Otte
c146132a4a
gtk-demo: Port clipboards example to new clipboard
2017-12-03 05:46:48 +01:00
Benjamin Otte
8cd5e0af1a
recentchooser: Port to GdkClipboard
2017-12-03 05:46:48 +01:00
Benjamin Otte
909b6877bd
linkbutton: Port to GdkClipboard
2017-12-03 05:46:48 +01:00
Benjamin Otte
825612b419
a11y: Port to GdkClipboard
2017-12-03 05:46:47 +01:00
Benjamin Otte
54c8a4b3b7
widget: Add gtk_widget_get_clipboard()
...
... and gtk_widget_get_primary_clipboard().
They both give out the new GdkClipboard.
2017-12-03 05:46:47 +01:00
Benjamin Otte
a59572f96d
widget: gtk_widget_get_clipboard => gtk_widget_get_old_clipboard
...
Just rename the function, so the previous one can be used for the
new clipboard.
2017-12-03 05:46:47 +01:00
Benjamin Otte
6fffa5b171
tests: Open a 2nd display in testclipboard2
...
This allows testing local transfer of data as well as remote transfer
(by transferring data between clipboards of both Displays).
2017-12-03 05:46:47 +01:00
Benjamin Otte
134076e738
x11: Implement claiming the X Selection with the clipboard
...
... and of course support writing to other apps.
2017-12-03 05:46:47 +01:00
Benjamin Otte
e2014850b9
tests: Add possibility to set invalid UTF-8 and clear clipboard
2017-12-03 05:46:47 +01:00