Commit Graph

47697 Commits

Author SHA1 Message Date
Matthias Clasen
449fd4a350 Use g_set_object in one more place 2016-05-03 22:15:17 -04:00
Timm Bäder
944f9d4f28 label: don't use set_text in gtk_label_new
It would just set up lots of things with the default values, but a
common case is that a few gtk_label_set_* calls follow.
2016-05-03 19:26:43 -04:00
Kjartan Maraas
e0ab19a8f0 Updated Norwegian bokmål translation. 2016-05-03 23:23:11 +02:00
Timm Bäder
4ae6f10ae9 label: minimum/natural size parameters are not nullable
Stop comparing them to NULL.
2016-05-03 16:25:57 -04:00
Timm Bäder
e75894da13 label: Don't set out parameters twice
We set them later again when we calculate the vertical size, so just
move the general assignment to -1 into the horizontal branch.
2016-05-03 16:25:57 -04:00
Timm Bäder
cb419794f8 widget: Remove useless NULL check
We are checking for allocation != NULL at the beginning of the function
already. This also means that the allocation parameter is not nullable.
2016-05-03 18:21:33 +02:00
Timm Bäder
71b360cc8e roundedbox: Initialize the hashtable key before using it
In mem_hash, we are iterating over the individual bytes of the key, so
make sure all of it is initialized.
2016-05-03 10:58:02 -04:00
Benjamin Otte
a72c4576b2 cssimagebuiltin: Remove icons that don't draw anything anymore 2016-05-03 12:59:13 +02:00
Benjamin Otte
b049b3de25 cssimagebuiltin: Remove unused variables 2016-05-03 12:59:13 +02:00
Benjamin Otte
2c2c60827e widget: Remove useless comment 2016-05-03 12:59:13 +02:00
Olivier Fourdan
e74ecfe22e wayland: fix up/down mix up in discrete events
The wayland specification for discrete step information for scroll and
other axes reads:

| The discrete value carries the directional information. e.g. a
| value of -2 is two steps towards the negative direction of this axis.

mutter sets a value of 1 for SCROLL_DOWN events and -1 for SCROLL_UP
events.

gdkdevice Wayland backend does the opposite, it translates a positive
discrete value as SCROLL_UP and a negative value as SCROLL_DOWN, which
ends up inverting the scrolling direction.

Fix the logic in gdkdevice Wayland to use a positive value as
SCROLL_DOWN and a negative value as SCROLL_UP so that it matches mutter
and weston logic.

https://bugzilla.gnome.org/show_bug.cgi?id=765907
2016-05-03 11:38:06 +02:00
Matthias Clasen
be201a5b71 css: Stop drawing double borders for builtins
The fallback code for rendering builtin checks, radios
and expanders was using border parameters. With the generic
gadget borders using the same parameters, this was giving
double borders.
2016-05-02 13:31:59 -04:00
Timm Bäder
38181bc3d2 shadowsvalue: Don't draw invisible box shadows 2016-05-02 19:28:33 +02:00
Matthias Clasen
ef7ccab188 defaultvalue test: Skip GdkMonitor::geometry
We never return NULL for ::geometry and ::workarea. Just skip
these properties.
2016-05-02 12:42:13 -04:00
Matthias Clasen
8dd8c4a9de GdkMonitor: Fix refresh-rate property
We were using g_value_set_boolean for an integer property.
2016-05-02 12:42:13 -04:00
Руслан Ижбулатов
b579fa82fe Use default VFS, not a local one (it has no network) 2016-05-02 14:45:44 +00:00
Matthias Clasen
9a03fc906a Fix gtk_paned_set_position to set position_set consistently
As pointed out in https://bugzilla.gnome.org/show_bug.cgi?id=765676,
we were failing to set position_set if the position did not change.
2016-05-02 07:42:06 -04:00
Carlos Soriano
264b2b78cd testnotebookdnd: add one GtkListBox as tab content
To make sure we test regressions on widgets that bubble up motion
handling and can trigger the motion handling code path on GtkNotebook.

https://bugzilla.gnome.org/show_bug.cgi?id=764395
2016-05-02 13:17:48 +02:00
Carlos Soriano
ddb0740a21 gtknotebook: avoid tab dnd from content
Before commit 6c1bee2377 we were setting an attribute of GtkNotebook
to track the pressed button if the pressed button happened on the
tab itself.
Later in the motion handling code we were checking whether the private
pressed button attribute was set or not in order to handle a tab dnd
or not.

In commit 6c1bee2377 the code changed and set the pressed button
variable unconditionally, which means, a motion event from within the
tab content triggered a tab reordering.

This happened only if the children hierarchy have a widget that bubbles
up both button press event, which sets the private pressed button
attribute; and motion events, which started the tab dnd checking the
private pressed button attribute.
A widget that experienced the regression was GtkListBox.

In order to fix it, set the button pressed variable only when it press
the tab itself, not the content.

https://bugzilla.gnome.org/show_bug.cgi?id=764395
2016-05-02 13:17:48 +02:00
Руслан Ижбулатов
bab628beb2 GtkPlacesView: check for network:// URI support before using it
Specifically, this URI is not supported on Windows, but GFile will
do its "best" and turn it into GLocalFile("$pwd/network"), with
spectacularly bad results.

https://bugzilla.gnome.org/show_bug.cgi?id=765858
2016-05-01 19:04:18 +00:00
Carlos Garnacho
cb6b5e4017 gdkevents: Free motion events discarded by motion compression
Those should be freed together with their list link.
2016-05-01 20:05:56 +02:00
Matthias Clasen
73e799474a dnd: Make sure to free a stashed event
I am not sure if this happens in practice, but better to be safe.
2016-05-01 13:26:35 -04:00
Matthias Clasen
0fe0ee897d gesture: Don't leak stashed events
These events were never freed.
2016-05-01 13:26:35 -04:00
Matthias Clasen
a047269428 Avoid copying an event
Not a big deal, but we can be a bit more efficient when generating
grab-broken events.
2016-05-01 13:26:35 -04:00
Matthias Clasen
a7ee3a6d80 Small docs improvement
Cross reference from gdk_event_get_keycode to
gdk_event_get_scancode.
2016-05-01 13:26:35 -04:00
Matthias Clasen
8041c012fe Drop unused macros
These have been sitting here forever, unused. Time to drop them
2016-05-01 13:26:35 -04:00
Matthias Clasen
6baac526b9 x11: drop a useless list
We were keeping all the event sources in a list, only to remove
them at the end of their life. Not useful.
2016-05-01 13:26:35 -04:00
Matthias Clasen
75e44c50ed wayland: drop a useless list
We were keeping all the event sources in a list, only to remove
them at the end of their life. Not useful.
2016-05-01 13:26:35 -04:00
Matthias Clasen
de894f38b5 Fix the build
I forgot to add an include here.
2016-05-01 13:26:35 -04:00
Matthias Clasen
a829b26de1 wayland: Tag the event source with the acutal display name 2016-05-01 10:52:31 -04:00
Matthias Clasen
55ea6e4dcc wayland: Make gdk_display_get_name work
It should just return the same as gdk_screen_make_display_name.
2016-05-01 10:51:41 -04:00
Matthias Clasen
309c6dfaf8 css: Use setters for font size and family
This avoid creating pango font descriptions all the time, when
the gtk-font-name setting hasn't actually changed.
2016-05-01 01:10:59 -04:00
Matthias Clasen
71d6816817 settings: Add setters for font family and size 2016-05-01 01:10:33 -04:00
Matthias Clasen
449732446b treeview: Use getter for gtk-enable-animations 2016-05-01 00:40:23 -04:00
Matthias Clasen
8457dff08a switch: Use getter for gtk-enable-animations 2016-05-01 00:40:08 -04:00
Matthias Clasen
df72478375 stack: Use getter for gtk-enable-animations 2016-05-01 00:39:55 -04:00
Matthias Clasen
5ee745dfee scrolled window: Use getter for gtk-enable-animations 2016-05-01 00:39:34 -04:00
Matthias Clasen
ff0107a4ac Use getter for gtk-enable-animations 2016-05-01 00:39:18 -04:00
Matthias Clasen
9d038df7de popover: Use getter for gtk-enable-animations 2016-05-01 00:39:03 -04:00
Matthias Clasen
e502702dd4 Use a variable consistently 2016-04-30 23:15:20 -04:00
Matthias Clasen
417eb0ad9c Use a better hash for arcs 2016-04-30 22:39:58 -04:00
Matthias Clasen
e5de6dd8b1 css: Use a getter for the enable-animations setting 2016-04-30 22:39:58 -04:00
Matthias Clasen
28625c16c0 dnd: Use a getter for the drag threshold 2016-04-30 22:39:58 -04:00
Matthias Clasen
8e62cee075 Add a few settings getters 2016-04-30 22:39:58 -04:00
Matthias Clasen
4151b6715c Trivial whitespace fix 2016-04-30 21:06:38 -04:00
Matthias Clasen
98f16fdf7a Use the new getter
This avoids the use of generic api in the per-event code path.
2016-04-30 20:59:16 -04:00
Matthias Clasen
7f4b575fc3 gdk: Add a private getter for GdkDevice::input-mode 2016-04-30 20:52:23 -04:00
Matthias Clasen
172093db8c Add a forgotten deprecation
gdk_display_get_screen is marked as deprecated in the docs.
2016-04-30 16:46:11 -04:00
Руслан Ижбулатов
3a095ad454 W32: support cairo library in non-standard locations
When checking for cairo_win32_surface_create_with_format in -lcairo,
temporarily put CAIRO_LIBS into LIBS so that AC_CHECK_LIB() can
find it in weird places like /usr/local/lib, where gcc would not look
on its own.

https://bugzilla.gnome.org/show_bug.cgi?id=765793
2016-04-29 15:56:54 +00:00
GNOME Translation Robot
15dbf35fd8 Updated Scottish Gaelic translation 2016-04-29 08:41:50 +00:00