Commit Graph

36277 Commits

Author SHA1 Message Date
Jasper St. Pierre
ec61f290dc headerbar: Respect the show-close-button property 2013-12-12 21:55:06 -05:00
Jasper St. Pierre
01f5ff765b window: Update decorations when updating state
This fixes the maximize button not updating...
2013-12-12 21:55:02 -05:00
Matthias Clasen
a9eb813054 testtitlebar: Fix initial values
Make sure that the controls show the initial values fo the
headerbar properties, not the other way around.
2013-12-12 21:18:11 -05:00
Matthias Clasen
2f90781073 testtitlebar: more tests
Turn this into a GtkApplication with an app menu.
Allow to override the gtk-shell-shows-app-menu setting
and the decoration-button-layout style property.
2013-12-12 21:12:44 -05:00
Jasper St. Pierre
d9f92424b2 headerbar: Support all kinds of CSD decorations
Move the gtkwindow.c CSD code into GtkHeaderBar, and make it triggerable
by the show-close-button property, and remove shows-fallback-app-menu.

https://bugzilla.gnome.org/show_bug.cgi?id=720233
2013-12-12 19:30:59 -05:00
Matthias Clasen
d8401c5f0a GtkHeaderBar: treat "" as 'no subtitle'
This is one of the few cases where it makes some sense to blur
the line between and empty string and NULL: without this, it is
hard to reset the subtitle e.g. from a builder file. And we
have the has-subtitle property now to enforce subtitle size
allocation independently.
2013-12-12 19:29:52 -05:00
Volker Sobek
70eb35d569 GtkFileChooser: Don't fill location_entry if we just populated the file list
Only fill the location entry with the file name of the tree view's
selected file when the selection was done by the user.

When the file chooser's action is GTK_FILE_CHOOSER_ACTION_OPEN, it
selects the first file in the tree view once loading has finished. For
this case we don't want it to insert the file name in the location
entry, as it hinders efficient navigation using the location entry. To
achieve this, use a priv flag to keep track of whether the
selection-changed signal was caused by the file chooser itself.

https://bugzilla.gnome.org/show_bug.cgi?id=386569
2013-12-12 17:42:10 -06:00
Matthias Clasen
7ab7a262c1 Make testtitlebar more testy
Now that the nice titlebar example is in gtk3-demo, we can
use testtitlebar as an actual testbed for headerbar stuff.

This immediately reveals size allocation issues when titlebar
widgets change size.
2013-12-12 16:56:41 -05:00
Matthias Clasen
08202cb045 gtk-demo: Use title case consistently 2013-12-12 16:28:07 -05:00
Matthias Clasen
f7d4a2772b Add a header bar example to gtk-demo
This is basically standalone the testtitlebar example, turned
into a demo.
2013-12-12 16:28:07 -05:00
Daniel Mustieles
7a1bf9a919 Updated Spanish translation 2013-12-12 11:17:42 +01:00
Volker Sobek
d881edd33a testtitlebar: Fix -Wunused-variable warning
GtkWidget *title is no longer used.

https://bugzilla.gnome.org/show_bug.cgi?id=720296
2013-12-12 02:15:20 +01:00
Volker Sobek
06091ed457 GtkFileChooserDefault: Remove unused struct field
The field changing_folder is no longer used anywhere.

https://bugzilla.gnome.org/show_bug.cgi?id=720293
2013-12-12 01:33:37 +01:00
Jasper St. Pierre
37baeed66e headerbar: Remove unused private API
Don't remove gtkheaderbarprivate.h, even though it's empty,
since we'll add more to it soon.

https://bugzilla.gnome.org/show_bug.cgi?id=720233
2013-12-11 19:28:30 -05:00
Jasper St. Pierre
e582404e90 wayland: Fix order of xdg-shell requests 2013-12-11 19:28:30 -05:00
Yosef Or Boczko
7e2fdad6c5 Updated Hebrew translation 2013-12-11 13:37:38 +02:00
Fran Diéguez
a756a99884 Updated Galician translations 2013-12-11 10:27:47 +01:00
Jehan
57f59010b8 Gettext comment for "default:LTR" must be before the string
https://bugzilla.gnome.org/show_bug.cgi?id=720096
2013-12-10 23:31:47 -05:00
Matthias Clasen
8596a34b8b Simplify a check
Whenever titlebar is set, title_box is pointing to the
same widget, so we can just always use title_box here.
Pointed out by Jasper St. Pierre.
2013-12-10 23:19:36 -05:00
Matthias Clasen
50a206223f Trivial typo fix 2013-12-10 23:03:12 -05:00
Matthias Clasen
0191760bdc Use ::has-subtitle in testtitlebar
This also gets simplified.
2013-12-10 23:03:12 -05:00
Matthias Clasen
05d34f9a5b Use ::has-subtitle when constructing CSD titlebars
GtkWindow was constructing a custom title label to
avoid the size reservation for a subtitle. This is
now easier with the ::has-subtitle property.
2013-12-10 23:03:12 -05:00
Matthias Clasen
1a6a86a867 GtkHeaderBar: Add a ::has-subtitle property
It is a fairly common case to just want a title, and not
reserve extra space for a subtitle. This is much easier
to get right by setting a boolean property than by
constructing a custom title widget.
2013-12-10 23:03:12 -05:00
Matthias Clasen
b6a6729ce1 Fix a segfault in the event axes demo
Seems that pointer_info can be NULL, after all.
2013-12-10 23:03:12 -05:00
Matthias Clasen
da08592ea1 Update headerbar title from window title
This removes a possible source of confusion in our API.
The title is now synchronized both ways between the window
and the headerbar.

https://bugzilla.gnome.org/show_bug.cgi?id=720067
2013-12-10 20:45:42 -05:00
Matthias Clasen
5918a4dae8 Sync the window title initially
When setting a custom titlebar that happens to be a GtkHeaderBar,
we connect to notify::title to pick up title changes on the headerbar,
but we forgot to sync the title initially. Fix that.
2013-12-10 18:44:26 -05:00
Matthias Clasen
f08df56211 Disconnect signal handlers
We connect to notify::title on app-provided titlebars, but
we forgot to disconnect the signal handler when unsetting
the titlebar.
2013-12-10 18:21:58 -05:00
Matthias Clasen
73bd03c9ed Add a function to determine the text direction
This function can be used in the rare cases where the locale
has to be changed after gtk_init(). Based on a patch
by Jehan <jehan@girinstud.io>.

https://bugzilla.gnome.org/show_bug.cgi?id=720096
2013-12-10 17:34:23 -05:00
William Jon McCann
7ba0083fc9 demo: only set transient if demo returns a toplevel 2013-12-09 09:55:39 +01:00
William Jon McCann
35a249466f demo: put run button on the left
It is a bit annoying to have to go over to the right side to click it.
2013-12-09 09:26:08 +01:00
Jasper St. Pierre
fe584b9f00 wayland: Update to latest xdg-shell.xml 2013-12-07 13:25:38 -05:00
Jasper St. Pierre
4844ef88db wayland: Make sure to call use_unstable_version 2013-12-07 13:25:38 -05:00
Benjamin Otte
b6f9ce8a73 button: Allow :hover on insensitive buttons
You can still hover a mouse on insensitive elements; it's up to the
theme to disable that.
This is in line with the HTML/CSS interpretation of :hover.

Insensitive elements still cannot be clicked.

https://bugzilla.gnome.org/show_bug.cgi?id=719486
2013-12-07 01:39:38 +01:00
Benjamin Otte
0bff206915 gdk: Add some return_if_fail() warnings
so we have a better chance of catching the correct cause of bugs like

https://bugzilla.gnome.org/show_bug.cgi?id=719977
2013-12-07 01:39:38 +01:00
Benjamin Otte
860138b302 filechooser: Don't crash if invalid thumbnails exist
Failing to load a thumbnail returns a NULL pixbuf. Since the hidpi
patches this wasn't checked when creating the surface. Result: assertion
failure.

https://bugzilla.gnome.org/show_bug.cgi?id=719977
2013-12-07 01:39:38 +01:00
Torsten Schönfeld
904bc27250 gtkradio*: add (allow-none) annotations were appropriate
https://bugzilla.gnome.org/show_bug.cgi?id=679563
2013-12-06 23:57:16 +01:00
Carlos Garnacho
bd2f875141 demo: Add demo for advanced event information management
This demo condenses the essentials of advanced management of
input events. Depending on the information available in input events,
this demo will try to represent as much information as possible for
those.

https://bugzilla.gnome.org/show_bug.cgi?id=719987
2013-12-06 20:08:37 +01:00
Matthias Clasen
8d3a91d6ba docs: Add a missing Since: tag 2013-12-05 09:08:35 -05:00
Matthias Clasen
8fbda8efce Don't distribute generated sources
This was causing problems when building 3.10.6 against an older
wayland.
2013-12-05 09:07:19 -05:00
Lars Uebernickel
d736e8baf9 GtkMenuItem: only set 'separator' class on the separator line
To make the separator line distinguishable from the widget's normal
border from css.

https://bugzilla.gnome.org/show_bug.cgi?id=719861
2013-12-05 12:35:12 +01:00
Matthias Clasen
9bfe7525ce Fix make dist 2013-12-05 01:04:10 -05:00
Carlos Garnacho
f6c9a33841 x11: Handle XINotifyPassiveGrab/Ungrab in focus events
The focus handling code is shared between core and XI2 implementations,
so just handle the extra XI2 types for passive grabs. Those must be dealt
with in the same way than active grabs. Focus events with this crossing
mode could happen currently through the XIGrabFocusIn passive grab.

https://bugzilla.gnome.org/show_bug.cgi?id=719762
2013-12-04 21:22:23 -05:00
Carlos Garnacho
3dbabbd2e5 x11: Handle all XI2 crossing mode values in switch
This fixes potential assertions if a GTK+ app gets to receive
a XINotifyPassiveGrab/Ungrab pointer crossing event, currently
triggerable by XIGrabEnter passive grabs.

http://bugzilla.gnome.org/show_bug.cgi?id=719762
2013-12-04 21:22:23 -05:00
Jasper St. Pierre
96d2eeb6ba recentchooserdefault: Clean up load_id when we have nothing left to do
Returning FALSE from a GSourceFunc will implicitly remove it, so we need
to do this in order to make the new g_source_remove happy.
2013-12-04 19:29:06 -05:00
Piotr Drąg
f059053614 Updated POTFILES.skip 2013-12-04 19:17:50 +01:00
Lionel Landwerlin
45216c4f60 window: enable client side decorations deactivation with wayland backend 2013-12-04 17:24:48 +00:00
Matthias Clasen
e2745794b1 Revert "gdkwindow-x11: Don't set WM_TAKE_FOCUS if accept_focus is FALSE"
This reverts commit 809aab2c8e.
2013-12-04 11:21:42 -05:00
Jehan
4e4c248077 Bug 712536 - Themes with gap_(start|end)_file but no actual file crash
Code factorization in commit 34fd123 reintroduced bug fixed in 0d396ab
with non-equivalent factorized tests.
2013-12-05 00:53:17 +13:00
Benjamin Otte
f765bb8803 treeview: Don't draw a background for the bin window
The bin window's background would have to be drawn in the bin window's
size and inside the pixel cache draw function to not cause transparency
issues.

But because it's unnecessary as the view window draws the same
background, we just skip it.

https://bugzilla.gnome.org/show_bug.cgi?id=709027
2013-12-04 10:40:03 +01:00
Victor Ibragimov
a90ed567ed Tajik translation updated 2013-12-04 14:13:13 +05:00