Commit Graph

16 Commits

Author SHA1 Message Date
Matthias Clasen
cda60c3c40 Another round of template binding api changes
We rename the gtk_widget_class_bind_template_child{_internal}
macros by appending a _private to their name. Otherwise, it
would be too magic to pass the 'public' names as arguments,
but affect a member of the Private struct. At the same time,

Add two new macros with the old names,
gtk_widget_class_bind_template_child{_internal} that operate
on members of the instance struct.
2013-07-26 16:29:12 -04:00
Emmanuele Bassi
89ae3524a3 Rename the widget template API
The macros and functions are inconsistently named, and are not tied to
the "template" concept - to the point that it seems plausible to use
them without setting the template.

The new naming scheme is as follows:

  gtk_widget_class_bind_template_child_full
  gtk_widget_class_bind_template_callback_full

With the convenience macros:

  gtk_widget_class_bind_template_child
  gtk_widget_class_bind_template_child_internal
  gtk_widget_class_bind_template_callback

https://bugzilla.gnome.org/show_bug.cgi?id=700898
https://bugzilla.gnome.org/show_bug.cgi?id=700896
2013-07-26 13:52:15 -04:00
Alexander Larsson
a8e84545d1 widget: Use a real offset in gtk_widget_class_automate_child
Using an offset from the struct means you can have children in
both the public and private (via G_PRIVATE_OFFSET) parts of the
instance. It also matches the new private macros nicer.

https://bugzilla.gnome.org/show_bug.cgi?id=702563

Signed-off-by: Emmanuele Bassi <ebassi@gnome.org>
2013-07-26 08:41:09 -04:00
Emmanuele Bassi
0899ef7cc9 gtk: Use new macros for defining private data
https://bugzilla.gnome.org/show_bug.cgi?id=702996
2013-07-09 09:30:02 +01:00
Tristan Van Berkom
3c39c388c9 GtkLockButton: Define children with a GtkBuilder template 2013-04-08 21:19:28 +09:00
Matthias Clasen
e4b5e94eb9 Make accessible implementations public
This commit exposes the get_type() functions and standard
headers for accessible implementations. This makes it possible
to derive from the GTK accessible implementations without
GType magic tricks. This is necessary, because we require the
a11y type hierarchy to be parallel to the widget type hierarchy.
So, if you derive a widget and need to adjust its a11y implementation,
you have to be able to derive its accessible implementation.

This commit probably exposes more than is absolutely necessary,
it also exposes accessibles of widgets that are unlikely candidates
for deriving from.
2012-12-27 11:23:22 -05:00
Benjamin Otte
b900016a05 a11y: Make lockbutton notify about state changes
In particular, ensure that the name of the lockbutton gets updated as
the displayed text of the lockbutton changes.

https://bugzilla.gnome.org/show_bug.cgi?id=677347
2012-07-09 03:12:13 +02:00
Benjamin Otte
58cf6dfaaf a11y: Get lockbutton text directly
Instead of letting the generic button code attempt to find the currently
displayed text, just return the text directly.

https://bugzilla.gnome.org/show_bug.cgi?id=677347
2012-07-09 02:58:22 +02:00
Benjamin Otte
fb1b025cbf a11y: Add separate accessible for GtkLockButton
The accessible doesn't do anything yet, this is just infrastructure
work.
2012-07-09 02:29:16 +02:00
Matthias Clasen
9cca320a7f Reword lockbutton docs
https://bugzilla.gnome.org/show_bug.cgi?id=659613
2012-05-26 13:29:48 -04:00
Matthias Clasen
050cba6a31 Fix malformed doc comments
Most of these are forgotten :'s and similar details
which gtk-doc now warns about.
2012-04-12 21:12:16 -04:00
Javier Jardón
9d0febc9a6 Change FSF Address 2012-02-27 17:06:11 +00:00
Cosimo Cecchi
3ef2e36637 lockbutton: ensure the lock symbolic icon is rendered 16x16px
https://bugzilla.gnome.org/show_bug.cgi?id=651734
2011-06-06 15:12:27 -04:00
Matthias Clasen
9fd0458f1c Simplify GtkLockButton
Now it is actually just a button, which makes things simpler
and is closer to what the designers want.
2011-05-25 20:19:08 -04:00
Matthias Clasen
e578489579 Allow NULL permissions
This is useful in some scenarios.
2011-05-21 09:12:40 -04:00
Matthias Clasen
1d647df176 Add a lock button widget
This is a special-purpose button that can be used together with
GPermission objects to control the sensitivity of system settings.

Suitable permission objects can e.g. be obtained from PolicyKit.

http://bugzilla.gnome.org/show_bug.cgi?id=626457
2011-05-06 22:44:38 -04:00