Commit Graph

40909 Commits

Author SHA1 Message Date
Jasper St. Pierre
a91c88768e inspector: Remove unused variable 2014-11-07 16:33:43 -08:00
Matthias Clasen
ee01ee249f inspector: Look for themes in the right places
Match the places that GtkCssProvider looks in, so we show all
the themes that GTK+ would actually find.
2014-11-07 14:19:59 -05:00
Carlos Garnacho
af6eab850e wayland: Schedule a clock tick instead of wl_surface_commit()ting directly
Instead of possibly calling wl_surface_commit() out of
GdkFrameClock::after-paint, tick the transient parent clock so ::after-paint
can be eventually run.

This ensures that the subsurface coordinates (considered part of the state
of the parent) aren't committed untimely, and guaranteed to be orderly with
the wl_subsurface-relative state.

This is a gtk-side fix for https://bugzilla.gnome.org/show_bug.cgi?id=738887
2014-11-07 17:24:10 +01:00
Carlos Garnacho
964abf7423 wayland: Don't translate a NULL region into an empty one
cairo_region_copy(NULL) will effectively return an empty region, as this
function is always meant to return valid memory. This however inverts the
meaning of the NULL region and results in entirely non-clickable windows.
2014-11-07 17:23:54 +01:00
Carlos Garnacho
52a90758f9 gtkwindow: claim the press sequence when clicking on the titlebar
This event might not have an action yet, but certainly accounts, and
should be triggering recognition.

This fixes a crash when attempting to drag CSD windows through touch. As
since cfaec2d2f5, gtk_gesture_single_get_current_sequence() would
rightfully return NULL if the gesture didn't enter recognition, making
event lookup fail.
2014-11-07 13:54:10 +01:00
Carlos Garnacho
4df13b7262 treeview: remove single-click activation from GtkGestureMultiPress::pressed
This is already handled in GtkGestureMultiPress::release, and more in
concordance with how it was done pre-gestures.

https://bugzilla.gnome.org/show_bug.cgi?id=737891
2014-11-07 13:49:43 +01:00
Matthias Clasen
1e3e544bfd Revert "Add new API to docs"
This reverts commit 41e9eaf64f.
2014-11-07 07:12:22 -05:00
Matthias Clasen
5442293ce7 inspector: include private gdk headers
...the advantages of living in the same tree.
2014-11-07 07:11:38 -05:00
Matthias Clasen
7e405c286f Don't make the gl flags API
We need to export the symbols so they can be used in the
inspector, but we don't really want to make this supported
public API, so keep them out of installed headers.
2014-11-07 07:10:49 -05:00
Matthias Clasen
41e9eaf64f Add new API to docs 2014-11-06 23:37:00 -05:00
Matthias Clasen
0ecd08ed04 inspector: Add GL flags 2014-11-06 23:35:38 -05:00
Matthias Clasen
5d0d1e524e Export API to set GL flags
This will be used in the inspector.
2014-11-06 23:29:16 -05:00
Lapo Calamandrei
d859cf19f6 Adwaita: scrollbar styling overhaul
- finally added the missing border;
  - proper backdrop state styling;
  - tweaked overlay indicator;
  - sidebar special casing gone for now.
2014-11-07 00:03:29 +01:00
Jasper St. Pierre
22ad7b7782 gdkgl: Make some helper functions static 2014-11-06 13:48:20 -08:00
Ryan Lortie
ec729d0649 mir: rework cursors a bit
Store the cursor name on the cursor (rather than always using its type).

Use this when setting a cursor on a surface.

The mir server will fallback to using standard cursors from the cursor
theme if the name used is not one of those defined by mir, which is more
or less what we want to happen here in case of creating a cursor by
name.
2014-11-06 16:18:53 -05:00
William Hua
063f79b594 mir: enable csd 2014-11-06 16:18:53 -05:00
William Hua
2fdb266c0d mir: set cursor 2014-11-06 16:18:53 -05:00
Matthias Clasen
f60b2a11c5 Drop an unneeded include 2014-11-06 15:17:09 -05:00
Matthias Clasen
f229f96d69 GtkModelButton: protect against show_all
We don't want the labels to be shown when there's already
an icon.
2014-11-06 15:03:51 -05:00
Alexander Larsson
41bf293efd GdkWindow: Drop gl matrix setup which is not needed anymore. 2014-11-06 20:37:24 +01:00
Alexander Larsson
61eabc4778 gdk_gl_texture_from_surface: Enable scissor test 2014-11-06 20:37:10 +01:00
Alexander Larsson
56631d02bd gdk_gl_texture_quad: Fix handling of window scales 2014-11-06 19:33:58 +01:00
Lapo Calamandrei
c756cef80a Adwaita: remove last child border on backdrop column headers 2014-11-06 17:21:50 +01:00
Lapo Calamandrei
d781599b0d Adwaita: initial overlay indicator styling 2014-11-06 12:40:40 +01:00
Alexander Larsson
1f3f933edf GdkX11GLContext: Use bitblit for swap if no buffer age support
If buffer age is undefined and the updated area is not the whole
window then we use bit-blits instead of swap-buffers to end the
frame.

This allows us to not repaint the entire window unnecessarily if
buffer_age is not supported, like e.g. with DRI2.
2014-11-06 12:24:43 +01:00
Alexander Larsson
21189b9f7e Add gdk_gl_context_has_framebuffer_blit()
This checks if the context supports GL_EXT_framebuffer_blit
2014-11-06 12:24:43 +01:00
Alexander Larsson
5f9e6ec2dc GdkGL: Fix up GL_ARB_texture_rectangle support
This broke when gdk_gl_texture_quad moved to shaders. We need
a specialized shader for the rectangle case.
2014-11-06 12:24:43 +01:00
Alexander Larsson
650c9f3b7e Add support for GDK_GL=texture-rectangles
This allows us to test our support for GL_ARB_texture_rectangle
2014-11-06 12:24:43 +01:00
Alexander Larsson
90a5fa80af Add GDK_GL env var and GdkGLFlags
This moves the GDK_ALWAYS_USE_GL env var to GDK_GL=always.
It also changes GDK_DEBUG=nogl to GDK_GL=disable, as GDK_DEBUG
is really only about debug loggin.

It also adds some completely new flags:

 software-draw-gl:
   Always use software fallback for drawing gl content to a cairo_t.
   This disables the fastpaths that exist for drawing directly to
   a window and instead reads back the pixels into a cairo image
   surface.

 software-draw-surface:
   Always use software fallback for drawing cairo surfaces onto a
   gl-using window.  This disables e.g. texture-from-pixmap on X11.

 software-draw:
   Enables both the above.
2014-11-06 12:24:43 +01:00
Alexander Larsson
7fde5213b0 gdk_cairo_draw_from_gl: Remove useless call
The glFramebufferTexture2DEXT call makes no sense here, we're
not using the texture as a framebuffer, just as a normal
texture source.
2014-11-06 12:24:43 +01:00
Alexander Larsson
9372cbdbf8 GdkWindow: Try to use a Core 3.2 GL profile for the paint context
If this is supported we avoid a lot of legacy baggage which we don't
need.
2014-11-06 12:24:43 +01:00
Alexander Larsson
e417b18373 gdk_gl_texture_quad: Use shaders to texture things
This is the modern way OpenGL works, and using it will let us
switch to a core context for the paint context, and work on
OpenGL ES 2.0.
2014-11-06 12:24:43 +01:00
Alexander Larsson
c78e7e7f17 GdkGL: Rename "context" to "paint_context" to clarify things a bit 2014-11-06 12:24:43 +01:00
Alexander Larsson
aaa335b9e8 gdk_cairo_draw_from_gl: Document that this changes the current context 2014-11-06 12:24:43 +01:00
Alexander Larsson
8c6395d8a1 GdkGLContextX11: Use passed in context, not get_current() 2014-11-06 12:24:43 +01:00
Alexander Larsson
10a44e8f7a Add gdk_gl_texture_quad() helper
Right now this just centralizes the glBegin/glEnd code, but
this will be replaced with buffer objects later.
2014-11-06 12:24:43 +01:00
Alexander Larsson
3c34ca3405 gdkgl: Don't constantly re-create the tmp framebuffer 2014-11-06 12:24:43 +01:00
Dimitris Spingos
0ac24904bd Updated Greek translation 2014-11-06 13:49:23 +02:00
Matthias Clasen
5a01208f55 GtkHeaderBar: Queue a resize when pack-type is changed
Otherwise, buttons appear to stick to the wrong side in glade.
2014-11-06 01:05:51 -05:00
Robert Ancell
053b65a21a mir: Handle pointer up/down events without a button mask set (i.e. touch events)
The Mir backend was checking for button mask changes to generate the appropriate
GDK event. When Mir generates a touch event it has no button mask. In this case
we'll just generate a primary button event.
2014-11-06 11:15:52 +13:00
Lapo Calamandrei
fdc01f80af Adwaita: dim GtkPlacesSidebar icons color 2014-11-05 16:01:28 +01:00
Benjamin Otte
0e44722fd8 tests: Add deprecation guards
It's the last test still spewing these and I'm too lazy to do a proper
fix.
2014-11-05 13:06:32 +01:00
Matthias Clasen
dd7a851f69 widget-factory: Fill up page 2 properly
The collapsed expander leaves and odd empty corner, so expand
it initially.
2014-11-05 06:29:47 -05:00
Matthias Clasen
45c0461f9b widget-factory: Add another osd
This is modeled after the totem osd.
2014-11-05 06:13:39 -05:00
Alexander Larsson
dd721acb84 GdkGLContextX11: Only set swap interval when it changed 2014-11-05 12:02:18 +01:00
Alexander Larsson
e4bf60224b GdkGL: Fix and clean up gdk_cairo_draw_from_gl()
This was unnecessarily creating a framebuffer in the texture case,
and it was not properly setting up a framebuffer with the texture
as source in the software fallback w/ texture source case.
2014-11-05 09:54:05 +01:00
Robert Ancell
c41231cc0f mir: Don't assert on unknown Mir events.
If we get a Mir event we don't understand generate a warning instead of an assert.
2014-11-05 15:50:55 +13:00
Matthias Clasen
e2882e4845 GtkHeaderBar: Make the position child property writable
Glade asssumes that it is, and without this, rearranging children
in glade is very cumbersome.
2014-11-04 16:56:25 -05:00
Carlos Garnacho
d9a433daf7 gtkwindow: Resort to regular event bubbling by all means on non-toplevels
If the multipress gesture is not created (ie. not a toplevel GtkWindow),
also avoid possibly calling gtk_widget_event() on the events gotten here.
2014-11-04 19:03:27 +01:00
Carlos Garnacho
03a30e462e gtkwindow: Do not create the multipress gesture for plugs
GtkPlugs may "qualify" as toplevels, even though they're not meant to
be WM manipulated, so refuse to create the multipress gesture for these
too.
2014-11-04 19:03:18 +01:00