Commit Graph

884 Commits

Author SHA1 Message Date
Matthias Clasen
3ae4c8f125 Adwaita: bring back the extra indirection
Without this, we are missing the 'Adwaita' component in the
path when resolving relative resources, and none of the assets
are found.
2014-06-13 14:44:38 -04:00
Matthias Clasen
6cc5908d88 Try to fix the continuous build
Making gtk.gresource.xml generated was causing a problem for
srcdir!=builddir builds from git. Builds from tarballs are
not affected, because the tarball contains the generated file.
2014-06-13 14:16:37 -04:00
Matthias Clasen
b4e1e01acc Include the Adwaita theme
This adds the resources for the Adwaita theme, and includes them
in libgtk, on all platforms.
2014-06-13 13:20:47 -04:00
Matthias Clasen
4c95dbb05b Don't include the win32 theme on Linux
No need to carry around these resources when we are not
going to use them.
2014-06-13 10:30:36 -04:00
Matthias Clasen
f1cf10fe86 Generate gtk.gresource.xml
This will help when including Adwaita. It will also let us
drop the win32 theme on Linux, hopefully.
2014-06-13 10:24:30 -04:00
Matthias Clasen
ec9cf6d7c3 GtkComboBox: Add private api to get the popup
This will be used to make the popup appear in the inspector.
2014-06-10 08:54:12 -04:00
Lieven van der Heide
c726226825 gtk: Add kinetic scrolling helper
GtkKineticScrolling implements the actual physics laws for friction
and springs. When created, position/velocity/boundaries/constants are
given, so at every gtk_kinetic_scrolling_tick() it returns the current
position, and whether the system is in rest.

https://bugzilla.gnome.org/show_bug.cgi?id=729608
2014-06-05 16:49:23 +02:00
Matthias Clasen
872fbfacd3 Split GtkWindowGroup into its own file
gtkwindow.c is too big and too messy. This is a small step
towards making it better.
2014-06-04 06:24:05 -04:00
Matthias Clasen
a28d2cb923 Move extract-strings to its own directory
This will hopefully help resolve the circular dependency between
libgtk linking against inspector/libgtkinspector and inspector/
needing extract-strings from gtk/.

I didn't preserve the EXEEXT decorations in this operation -
automake gave me stern warnings about it, so I just dropped them
all. Somebody who cross-builds GTK+ will have to reconstruct this.
2014-05-27 17:28:10 -04:00
Rico Tzschichholz
0b586e52c2 build: Fix typo 2014-05-24 09:52:41 +02:00
Rico Tzschichholz
86d4c26420 gtk: Fix make dist 2014-05-24 09:24:46 +02:00
Matthias Clasen
04703689b8 Deprecate GtkAligment
This has been dangling ever since 3.0.

https://bugzilla.gnome.org/show_bug.cgi?id=645781
2014-05-23 20:31:25 -04:00
Evan Nemerson
4a4b23bfad a11y: build directly into libgtk instead of an internal library
https://bugzilla.gnome.org/show_bug.cgi?id=730615
2014-05-23 19:20:59 -04:00
Matthias Clasen
42df9eda2d Prevent subclassing of gestures
For now, at least. We do this by hiding the instance and
class structures in private headers.
2014-05-23 19:54:28 +02:00
Carlos Garnacho
d768c2cb84 Remove GtkPressAndHold
This is replaced by GtkGestureLongPress, and all its callers have
been updated to use the replacement.
2014-05-23 19:54:26 +02:00
Carlos Garnacho
c7da5b54f5 Add GtkGesturePan
This gesture reports events on horizontal/vertical panning gestures.
2014-05-23 19:54:26 +02:00
Carlos Garnacho
d4d0f13c3a Add GtkGestureSingle
This is a GtkGesture subclass, specific to single-touch (or
mouse operated) gestures.
2014-05-23 19:54:22 +02:00
Carlos Garnacho
83dd050ab2 gesture: Add private getter to know whether a touch begin was handled
If GDK_TOUCH_BEGIN was handled/consumed for a sequence, or GDK_BUTTON_PRESS was
handled for the mouse gesture, this function will return TRUE.
2014-05-23 19:54:22 +02:00
Carlos Garnacho
450c754c7c Add GtkGestureMultiPress
This gesture handles any number of clicks, ensuring multiple presses
stay within thresholds and timeouts. When anything of that happens,
the gesture is reset and press count starts from 1 again.

Optionally, the gesture can be given a rectangle, used in in presses > 1
to ensure the consecutive presses happen on user imposed areas.
2014-05-23 19:54:21 +02:00
Carlos Garnacho
8026bc3651 Add GtkGestureDrag
This gesture interprets and reports drags as an offset to the drag
start point.
2014-05-23 19:54:21 +02:00
Carlos Garnacho
9db3c2d893 Add GtkGestureZoom
This gesture interprets and reports relative scale differences when fed
with events from two different GdkEventSequences.
2014-05-23 19:54:21 +02:00
Carlos Garnacho
2495b518c1 Add GtkGestureRotate
This gesture implementation recognizes rotations when fed with
events from two different GdkEventSequences
2014-05-23 19:54:21 +02:00
Carlos Garnacho
8733e2a918 Add GtkGestureSwipe
This gesture implementation recognices swipes on any direction.
The "swipe" signal has the X/Y velocity vector components, so
those can be used for direction guessing and velocity thresholds.
2014-05-23 19:54:21 +02:00
Carlos Garnacho
88d554d3ba Add GtkGestureLongPress
This gesture interprets long presses with variable delays
and thresholds
2014-05-23 19:54:21 +02:00
Carlos Garnacho
8f113e07fd Add GtkGesture
This a more specific abstract type that handles one or multiple
streams of pointer/touch events.
2014-05-23 19:54:21 +02:00
Carlos Garnacho
e2b8ef8c66 Add GtkEventController
This is a basic abstract type that handles GdkEvents.
2014-05-23 19:54:21 +02:00
Matthias Clasen
59c9d24bbf inspector: stop being a module
Moving the inspector into libgtk lets use reuse internals without
having to add public API for everything or inventing awkward private
call conventions.

https://bugzilla.gnome.org/show_bug.cgi?id=730095
2014-05-14 21:23:44 -04:00
Matthias Clasen
a600718846 Deprecate GtkArrow
https://bugzilla.gnome.org/show_bug.cgi?id=729564
2014-05-13 23:50:13 -04:00
Benjamin Otte
965cd4a9c0 css: Add GtkCssTransformValue
The value implements the 2D parts of CSS transforms. See
  http://www.w3.org/TR/css3-transforms/
For the specification.

All it does is give us an expressive way to define Cairo matrices (and
their transforms)
2014-05-14 04:28:33 +02:00
Benjamin Otte
633ec8184d css: Add support for -gtk-icontheme("icon-name")
This allows using icons from the icontheme as images in CSS. The
reasoning is that this allows to give the image control about how it's
scaled (by using the icon theme's scaling method. So we can get crisp
images at different resolutions.
2014-05-14 04:28:33 +02:00
Matthias Clasen
069a2603ef inspector: Add a setting to disable the keybinding
This will be needed for lockdown, e.g. on the login screen.
https://bugzilla.gnome.org/show_bug.cgi?id=730007
2014-05-13 15:20:36 -04:00
Matthias Clasen
ec0a60a248 Deprecate GtkMisc
This has been dangling ever since 3.0.
2014-05-13 08:45:00 -04:00
Matthias Clasen
49733154a6 Deprecate GtkNumerableIcon
It was a failed experiment, it is basically unused, and it complicates
code in GtkIconTheme that we want to rework.
2014-05-11 22:02:32 -04:00
Benjamin Otte
3a72e2fb24 css: Implement "unset"
Quoting the spec:
  If the cascaded value of a property is the unset keyword,
  then if it is an inherited property, this is treated as
  inherit, and if it is not, this is treated as initial.

Spec in question:
  http://dev.w3.org/csswg/css-cascade/

Also use unset in the reset-to-defaults.css we use to reset css in
reftests.
2014-05-11 03:23:55 +02:00
Ryan Lortie
5137e491dc GtkPopover: new approach to menu model binding
Instead of using GtkMenuTracker to flatten the sections into a single
linear menu, handle the sections ourselves by nesting boxes.

Each section gets an inner and outer box.  The inner box numbers its
children in the way that the tracker instructs.  The outer box
containes the inner box and the separator, if appropriate.

Having the two separate boxes will allow us to change the orientation of
the inner box if we want to pack widgets horizontally within a section.
2014-04-28 14:14:42 -04:00
Matthias Clasen
fee33b1a81 Clean up private headers
This commit adds a few missing private headers, and cleans up
some irregularities in the existing ones
2014-04-05 02:06:29 -04:00
Руслан Ижбулатов
0d53a581b4 Give CC to instrospection scanner
Introspection scanner-generation script gets compiler from the CC
environment, we need to set it.

https://bugzilla.gnome.org/show_bug.cgi?id=722817
2014-04-01 11:50:35 +00:00
Tim Waugh
aaae0ca8ba New cloudprint GTK+ print module for Google Cloud Print.
This is a web service provided by Google that allows people to
share their printers (https://www.google.com/cloudprint/learn/).

In addition to being able to print to printers shared on Google Cloud
Print, there is an equivalent of "Print to file" in the form of "Save to
Google Drive".

The cloudprint module uses gnome-online-accounts to obtain the OAuth 2.0
access token for the Google account.

Currently it can discover available printers, get simple details about
them such as display name and status, and submit jobs without any
special options.

https://bugzilla.gnome.org/show_bug.cgi?id=723368
2014-02-28 11:45:03 +01:00
Carlos Garnacho
eb0f86d485 popover: Always apply the window shape
In practice this shape is only used to outline the popover when it is
above native windows, in the most normal full-csw case the shape won't apply
visibly, so popovers will still be able to cast a shadow there.

If there are native windows below the popover, the shape will exclude the
shadow, so there are no alpha contents above the window. One worst case that
might happen is that the popover lays above patches of native/client-side
windows, so the shadow could come and go around the border. But first let's
see whether that happens often or visibly enough before adding something more
convoluted.
2014-02-20 16:36:34 +01:00
Matthias Clasen
8bfa5e4611 Drop GtkCenterBox
Its functionality has been subsumed in GtkBox.
2014-02-16 23:05:21 -05:00
William Jon McCann
d0a654e4b9 Add new ActionBar
https://bugzilla.gnome.org/show_bug.cgi?id=723929
2014-02-12 08:08:03 -05:00
William Jon McCann
c86ee0558c Rename GtkActionBar to GtkCenterBox
https://bugzilla.gnome.org/show_bug.cgi?id=723929
2014-02-12 08:08:03 -05:00
Matthias Clasen
bf9ce3ad25 Introduce GtkModelButton
Similar in spirit to GtkModelMenuItem, this private GtkButton subclass
can connect to a GtkMenuTrackerItem and present itself as either a
regular button, a check button, or a radio button. Activation and
state tracking is done through the GAction that is associated with
the menu tracker item.

https://bugzilla.gnome.org/show_bug.cgi?id=723014
2014-02-07 15:11:50 -05:00
Carlos Garnacho
2d9c09d6c0 popover: Add private _gtk_popover_set_apply_shape() call
Popovers no longer sets a shape, unless this function is called. This
function exists so widgets that are potentially placed on top of other
native windows can get a popover that's nicely shaped, even if it has
no border shadow around.

https://bugzilla.gnome.org/show_bug.cgi?id=723556
2014-02-04 21:29:25 +01:00
William Jon McCann
d87ea4776a Merge GtkFileChooserWidget and GtkFileChooserDefault
It seems that alternate implementations of GtkFileChooserWidget
never materialized. The split between GtkFileChooserWidget and
GtkFileChooserDefault is awkward. The immediate problem is that
it makes it difficult to document the keybinding signals. So it
makes sense to drop the abstraction and just have one thing.

https://bugzilla.gnome.org/show_bug.cgi?id=723157
2014-01-28 23:09:42 -05:00
William Jon McCann
4a11acdc8c resources: move resources into a subdirectory 2014-01-23 21:04:59 -05:00
Carlos Garnacho
61ab302c75 Add GtkMagnifier
This is a private widget that takes another widget on construction, and is able
to render parts of it, possibly at a different magnification level.
2014-01-22 17:10:05 +01:00
Carlos Garnacho
caeb896096 Introduce GtkPopover
Now that the GtkBubbleWindow object has been cleaned up and made
more generic, rename it as GtkPopover and make it public.
2014-01-22 17:10:04 +01:00
Ryan Lortie
fdc66af5ce quartz: add a default application menu
When running on quartz, it is no longer expected for applications to
provide their own application menu.  Instead, they should simply ensure
that they provide "app.about", "app.preferences" and "app.quit" actions
(which many apps are already doing).

A default menu will be shown that looks like the one presented by all
other Mac OS applications, containing menu items for the above actions,
as well as the typical "Hide app", "Hide Others and "Show All" items and
the "Services" submenu.

If an application does explicitly set an application menu (via
gtk_application_set_app_menu()) then it will be respected, as before.

https://bugzilla.gnome.org/show_bug.cgi?id=720552
2014-01-17 23:14:20 -05:00
Matthias Clasen
106bcc7f5e Make it possible to set use-header-bar from a setting
This commit introduces a private convenience API that derived
dialogs can call in their instance init. This is necessary to
make the setting work as intended in the face of 3rd party
dialogs derived e.g. from GtkFileChooserDialog, which are
created with g_object_new.
2014-01-17 17:52:08 -05:00