Commit Graph

36486 Commits

Author SHA1 Message Date
Mike Gorse
e529dfe949 A11y: Fix text functions for table cells
Keep the PangoLayout around, and refresh in update_cache.

https://bugzilla.gnome.org/show_bug.cgi?id=707729
2014-01-13 23:51:26 -05:00
Cosimo Cecchi
197785744b window: add an is-maximized property to GtkWindow
With proper notifications, plus an accessor method for that state. This
allows client to just listen to notify::is-maximized instead of tracking
window-state-event.

https://bugzilla.gnome.org/show_bug.cgi?id=698786
2014-01-13 23:13:37 -05:00
Matthias Clasen
1691bb741d Don't implement popup_menu in GtkWindow
This leads to disastruous results, since each menu is itself
in a GtkWindow, so holding down the menu key leads to a neverending
cascade of menus on top of menus.

https://bugzilla.gnome.org/show_bug.cgi?id=722106
2014-01-13 22:59:59 -05:00
John Lindgren
7a411eb6dd Fix memory leak in GtkTreeViewAccessible
https://bugzilla.gnome.org/show_bug.cgi?id=722030
2014-01-13 22:30:38 -05:00
Yosef Or Boczko
d0787765bc Add separator before "Always on Top" to the CSD window
https://bugzilla.gnome.org/show_bug.cgi?id=722076
2014-01-13 22:25:24 -05:00
Matthias Clasen
0de1173600 Fix a memory leak
https://bugzilla.gnome.org/show_bug.cgi?id=722029
2014-01-13 22:22:29 -05:00
Tim Lunn
17b6819991 gdk: Don't leak GValue when xsetting is unknown
https://bugzilla.gnome.org/show_bug.cgi?id=722070
2014-01-13 22:20:28 -05:00
Benjamin Otte
60968a1fec reftests: Add reftest for 0px border fix
https://bugzilla.gnome.org/show_bug.cgi?id=721800
2014-01-14 03:38:04 +01:00
Benjamin Otte
cd184b0f40 themingengine: Don't draw 0px borders
Theming code gets confused when computing the spacing for 0px wide dots
and then divides by 0. And then cairo complains and stops drawing
anything forever out of spite and then we end up with a single color
screen.

https://bugzilla.gnome.org/show_bug.cgi?id=721800
2014-01-14 03:38:04 +01:00
Daniel Mustieles
8a4da7f157 Updated Spanish translation 2014-01-13 14:15:34 +01:00
Chun-wei Fan
202d9c4a35 build/: Rename a Shared MSVC NMake Makefile
Rename testsrules_msvc.mak to detectenv_msvc.mak and remove some package-
specific stuff from it, to reflect on the nature that this NMake Makefile
is shared.
2014-01-13 17:19:07 +08:00
Chun-wei Fan
7115ccd3b0 MSVC Builds: Rework Introspection Build
The current approach of building the introspection files for GTK works, but
is often cumbersome as one needs to set many environmental variables before
launching a solution file, which runs a Windows batch script to generate
the .gir/.typelib files. It was also possible to hand-run the batch script
from the Visual Studio command prompt, but even more environmental
variables need to be set.

This changes the approach to build the introspection files using an NMake
Makefile (but elimating from the Visual Studio Project Files the part to
build the introspection files) to:
-Make it clearer to the person building the introspection files what
 environmental variables are needed, specifically for PKG_CONFIG_PATH and
 MINGWDIR and CFG (formerly CONF). Setting stuff like VSVER, PLAT and BASEDIR
 is no longer required, which was a bit clunky.

-Allows some more easier flexibility on the build of the intropsection files.
2014-01-13 16:05:32 +08:00
Dimitris Spingos
0f53cd66db Updated Greek translation 2014-01-13 09:51:46 +02:00
Yosef Or Boczko
6e0049dc47 Updated Hebrew translation 2014-01-13 07:44:27 +02:00
Chun-wei Fan
f70c0afd65 Update gtk-install.*props
Make sure the needed public headers for GTK master is "installed", and re-
order some items so that it is easier when the headers lists are
automatically acquired from the various Makefile.am's.
2014-01-13 12:39:04 +08:00
Chun-wei Fan
396f01681b build/win32/vs9/Makefile: Fix typo 2014-01-13 12:02:12 +08:00
Matthias Clasen
6718a21b1c Add move and resize to the csd window menu
With the previous commit, these operations can be implemented
now.
2014-01-12 22:25:20 -05:00
Matthias Clasen
7125cdc5ff X11: Support keyboard-initiated move and resize operations
The EWMH defines _NET_WM_MOVERESIZE_SIZE_KEYBOARD and
_NET_WM_MOVERESIZE_MOVE_KEYBOARD for operations that are not
initiated by a button-press event. Allow using these by passing
a button of 0 to gdk_window_begin_move/resize_drag.
2014-01-12 22:25:19 -05:00
Matthias Clasen
2232430a5a Redo csd window-dragging
The window-dragging code had a number of issues: The code was
starting a drag on every button press, never bothering to cancel
them. This leads to the odd hand cursor occurring between the two
clicks to maximize. We relied on GDK's multi-click detection, which
gives us triple-clicks when we really want sequences of double-clicks.
Lastly, we didn't propery restrict double-click handling to the primary
button, so e.g. if you had a window on an empty workspace, double-right
click on the titlebar would maximize it, which is not intended.

This commit solves all three problem by a doing our own double-click
detection, and only starting a drag when the pointer goes out of
'double-click range'. We change the way dragging is implemented for
menubars and toolbars to just letting events bubble up, so they
get the same behaviour as the titlebar. To make this work, we
have to select for pointer motion events in a few more places.
2014-01-12 22:25:19 -05:00
Matthias Clasen
f940a60fd5 gtk-demo: Use primary-toolbar style in the application example
Adwaita correctly restricts window-dragging to primary toolbars,
Mark our toolbar as primary to test this.
2014-01-12 22:25:19 -05:00
Matthias Clasen
5657b805d7 Some struct repacking
Save a few bytes here and there.
2014-01-12 22:25:19 -05:00
Fran Diéguez
2871c41d51 Updated Galician translations 2014-01-13 01:47:06 +01:00
Andika Triwidada
0a768d274d Changed obsolete FSF portal addresses to web address
Fixed https://bugzilla.gnome.org/show_bug.cgi?id=721530
2014-01-12 19:56:49 +07:00
Matthias Clasen
902ebaafd5 gtk3-demo: avoid a resizing problem
Two changes that sneaked in during the GtkApplication port
made it so that the window would not let you shrink it again
after you've made it larger. This also yielded very surprising
results when unmaximizing the window: it would come back to
have a minimum width slightly larger than the screen, making
maximization fail from then on.
2014-01-11 18:06:06 -05:00
Tong Hui
c68feef583 Update Chinese simplified translation 2014-01-11 10:26:28 +08:00
Jasper St. Pierre
8a1fb19e88 gtkwindow: Rename get_decoration_size => get_shadow_width 2014-01-10 12:10:33 -05:00
Ignacio Casal Quinteiro
99ee1875ab gtkapplication: add missing annotation for set_accels_for_action 2014-01-10 15:19:05 +01:00
Alexander Larsson
ceaeb02ade README: Add note about gtk_text_view_add_child_in_window changes 2014-01-10 12:08:52 +01:00
Alexander Larsson
664fe89f6e GtkTextView: Fix scrolling of added children
The behaviour of gtk_text_view_add_child_in_window() used to be
quite broken. It scrolled with the window during scrolling, then
jumped to the absolute position when the widget resized. Furthermore,
in 3.10 we broke the first feature, making it always be fixed.

The "proper" way to handle this is to always follow scrolling. This
is what the only user so far (gedit) wants, and if you want some
kind of overlay you should use GtkOverlay instead.

So, this changes the behaviour to something that is internally consistent
and works. I.e. all added widgets scroll with the textview as needed.

https://bugzilla.gnome.org/show_bug.cgi?id=711826
2014-01-10 12:08:52 +01:00
Alexander Larsson
59bf558995 testtextview: Add test for gtk_text_view_add_child_in_window
https://bugzilla.gnome.org/show_bug.cgi?id=711826
2014-01-10 12:08:51 +01:00
Milo Casagrande
2544135d91 [l10n] Updated Italian translation. 2014-01-10 09:08:12 +01:00
Rico Tzschichholz
ed5d9b3c3e x11: Add/Fix '(type *)' g-i annotations 2014-01-09 21:47:04 +01:00
Ryan Lortie
7291d3e780 Simplify GtkActionHelper
Now that the last GMenuModel-based user of GtkActionHelper is gone, we
can substantially simplify it.

https://bugzilla.gnome.org/show_bug.cgi?id=721836
2014-01-08 18:21:26 -05:00
William Hua
649ff84d91 Use GtkMenuTracker for Quartz backend.
https://bugzilla.gnome.org/show_bug.cgi?id=710351
2014-01-08 18:16:05 -05:00
William Hua
2a109250d5 Move get_key_equivalent() to gdk quartz utils.
https://bugzilla.gnome.org/show_bug.cgi?id=710351
2014-01-08 17:42:19 -05:00
Christian Kirbach
92fcc31c8a Updated German translation 2014-01-08 23:26:41 +01:00
Ryan Lortie
d31bf779bb GtkMenuTracker: fix hidden-when='' vs. separators
Ensure that adding hidden-when='' to a menu item does not produce an
extra separator item as a side effect.

https://bugzilla.gnome.org/show_bug.cgi?id=688421
2014-01-08 14:31:16 -05:00
Ryan Lortie
2bcb4fc354 bloatpad: test hidden-when=''
Cook up some silly cases to test out the hidden-when='' attribute.

 - make sure hidden-when='action-missing' shows/hides items based on
   actions being created and destroyed

 - make sure hidden-when='action-disabled' shows/hides items based on
   actions being enabled and disabled

 - make sure hidden-when='action-missing' doesn't hide items when the
   action is merely disabled

https://bugzilla.gnome.org/show_bug.cgi?id=688421
2014-01-08 14:21:19 -05:00
Ryan Lortie
2112af719a GtkMenuTracker: remove hidden items from the menu
Modify the tracker so that it manages the visibility of
GtkMenuTrackerItem by issuing insert and remove callbacks to the
user of the tracker.

This works by treating the GtkMenuTrackerItem as a virtual section which
contains 1 item when the item is visible and 0 items when it is hidden.

For efficiency reasons, we only employ this trick in the case that the
item has a hidden-when='' attribute set on it.

https://bugzilla.gnome.org/show_bug.cgi?id=688421
2014-01-08 14:21:19 -05:00
Ryan Lortie
2b1aa12f01 GtkMenuTrackerItem: add an internal 'visible' flag
Add an internal API for checking if a GtkMenuTrackerItem is visible,
along with a signal for reporting changes in that flag.  The item will
become invisible in situations according to the new hidden-when=''
attribute, which can be set to 'action-disabled' or 'action-missing'.

This new flag doesn't actually do anything yet, and none of the
consumers of GtkMenuTracker do anything with it (nor should they).  A
followup patch will address the issue.

https://bugzilla.gnome.org/show_bug.cgi?id=688421
2014-01-08 14:21:18 -05:00
Ryan Lortie
8efb1404cb GtkMenuTracker: rework action removal a bit
Refactor the code in the action observer remove function in order to
make way for the (efficient) handling of hiding of the item in the case
that hidden-when='' is given.

https://bugzilla.gnome.org/show_bug.cgi?id=688421
2014-01-08 14:21:18 -05:00
Ryan Lortie
8256b88eb1 GtkMenuTrackerItem: small logic tweak
Strictly speaking, can_activate should always be set back to FALSE when
the action disappears from the muxer (since we can't activate it
anymore) but we forgot to do that.

This 'bug' could never cause a problem because 'can_activate' is never
directly queried for anything at all and the item would get marked
insensitive anyway.  As soon as the action was re-added, can_activate
would be recalculated based on the new action before anything else could
happen.

All the same, this should be cleared here.

https://bugzilla.gnome.org/show_bug.cgi?id=688421
2014-01-08 14:21:18 -05:00
Ryan Lortie
fb14a78271 GtkMenuTracker: cache result of hash lookup
Remove a hash lookup from the separator sync logic (which is run every
time we change a menu).  Instead, we do the lookup when creating the
section and cache the result.

This refactor will also help us in a future commit to add support for
hiding menu items based on missing actions.

https://bugzilla.gnome.org/show_bug.cgi?id=688421
2014-01-08 14:21:17 -05:00
Ignacio Casal Quinteiro
75ef6096c1 colorbutton: fix crash when destroying the colorbutton from the color-set signal 2014-01-08 14:38:33 +01:00
Daniel Mustieles
e94152dfbe Updated Spanish translation 2014-01-08 12:44:09 +01:00
Alexander Larsson
d07913840a PixelCache: Ensure clean cairo_t state in draw
This adds save/restore calls to the clear-to-transparent call in
the pixel cache, to avoid changing the default color of the
cairo_t. It also removes a call set_operator call that is no longer
necessary (it was trying to manually restore the state).

https://bugzilla.gnome.org/show_bug.cgi?id=721480
2014-01-08 10:48:56 +01:00
Steve Langasek
256561db2f fix prototypes of signal callbacks in the test suite
The signal callbacks are defined to take pointers as their arguments, but the
callbacks found in testsuite/gtk/builder.c are passing a GParamSpec by value
as the second argument.  This confuses and angers the compiler on ppc64el,
resulting in segfaults after return from the function due to stack-smashing
by the (completely-unused) argument.

https://bugzilla.gnome.org/show_bug.cgi?id=721700
2014-01-08 10:43:52 +01:00
William Hua
6b865d5312 Add icon menu to bloatpad.
https://bugzilla.gnome.org/show_bug.cgi?id=710351
2014-01-08 02:20:21 -05:00
William Hua
fd13713230 GtkIconInfo: add gtk_icon_info_is_symbolic()
https://bugzilla.gnome.org/show_bug.cgi?id=710351
2014-01-08 02:10:14 -05:00
Ryan Lortie
146f3a988d gtkapplication-quartz: clean up inhibit code
When testing with bloatpad, the existing inhibit code seems not to be
working at all.  Replace it with a cleaner and simpler version that
works.

https://bugzilla.gnome.org/show_bug.cgi?id=720551
2014-01-07 23:08:45 -05:00