summaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAgeFilesLines
* gdk: Remove remainings of fake crossing event delivery across touchwip/carlosg/event-delivery-cleanupsCarlos Garnacho2017-09-152-12/+0
| | | | | | This was by all lights broken, and is basically an implementation detail of the X11 backend since the pointer emulating touch just steals the pointer cursor, so should be reimplemented there.
* gdk: Coalesce 2 GdkWindow fields in GdkPointerWindowInfo structCarlos Garnacho2017-09-153-28/+9
| | | | | | | One used to point to the toplevel and the other to the client-side window that the pointer pointed to. The latter was made to be like the former in most places, so put those together, and fix the remaining cases where the variable might not end up with a toplevel/native window.
* gdk: Remove unused variableCarlos Garnacho2017-09-152-4/+0
| | | | It was supporting API that has been removed.
* gdk: Remove implicit touch grab accountingCarlos Garnacho2017-09-153-137/+0
| | | | | | | | | | This is not necessary now that there's no client-side windows to track. The only removed piece that could make sense is emission of grab broken events, but it's already an stretch since the semantics of those with multi-touchpoint is unclear. Anyhow, This should be fixed at the GTK level, while we let GDK deal with seat/device level grabs.
* gdk: Remove motion hintsCarlos Garnacho2017-09-1513-144/+3
| | | | | Motion hints are now literally a thing of the past. Everything should be using the full motion event stream.
* gdk: Drop generation of synthesized crossing events on grabsCarlos Garnacho2017-09-152-466/+1
| | | | | | GDK just needs to care about toplevels nowadays, which means these events are already delivered from the windowing. We don't need to generate intra-window crossing events ourselves.
* gtk: Remove 2BUTTON and 3BUTTON events and event typesCarlos Garnacho2017-09-1515-247/+5
| | | | | | Those should be interpreted by widget-local gestures, not guessed at a high level with no notions of the specific context. Users will want GtkGestureMultiPress to replace these events.
* gdk: Remove array of event masksCarlos Garnacho2017-09-151-52/+0
| | | | | This has been unused since all events are just forwarded instead of checking client-side windows evmasks.
* gtklistbox: Remove enter/leave/motion event handlersCarlos Garnacho2017-09-151-79/+8
| | | | | | | | Those worked similarly to those in GtkFlowBox, but would additionally handle "active" state for child rows. Simplify this to just enabling/ disabling active state on gesture press/release, we don't get the nice state updates when hovering around with a mouse button pressed, but the rationale from flowbox applies here, and makes a nice cleanup.
* gtkcolorswatch: Remove enter/leave event handlersCarlos Garnacho2017-09-151-20/+0
| | | | Those just maintained prelight state, which is already managed internally.
* gtkbutton: Remove enter/leave event handlersCarlos Garnacho2017-09-151-32/+0
| | | | | | They just maintain priv->in_button and widget state up-to-date, this basically matters during user interaction, and is already maintained in the gesture ::update handler. This seems to be sufficient.
* gtkflowbox: Drop crossing/motion event handlersCarlos Garnacho2017-09-151-74/+2
| | | | | | | | | | | Those basically controlled priv->active_child_active, which would 1) trigger a redraw when the pointer enters/leaves it, and 2) ensure that press/release happen on the same child for it to be activated. The former is not necessary, and the latter can be simplified by just checking again the child on the coordinates given by the ::release gesture handler. This makes all enter/leave/motion_notify event handlers unneeded.
* gtkspinbutton: Remove motion notify handlerCarlos Garnacho2017-09-151-16/+0
| | | | It does nothing nowadays.
* gtkcalendar: Use scroll event controllerCarlos Garnacho2017-09-151-21/+27
|
* gtkscrolledwindow: Use scroll event controllerCarlos Garnacho2017-09-151-266/+143
| | | | | | | All kinetic scrolling initial velocity calculations are now taken from the scroll controller. The handling of timeouts to snap back when overshooting has been also made to just apply on devices that can't emit ::scroll-begin/end.
* gtkspinbutton: Use scroll event controllerCarlos Garnacho2017-09-151-28/+23
|
* gtkscalebutton: Use scroll event controllerCarlos Garnacho2017-09-151-36/+29
|
* gtkrange: Use scroll event controllerCarlos Garnacho2017-09-151-55/+30
|
* gtkpathbar: Use scroll event controllerCarlos Garnacho2017-09-151-21/+27
|
* gtkmenu: Use scroll event controllerCarlos Garnacho2017-09-152-28/+18
|
* gtkcombobox: Use scroll event controllerCarlos Garnacho2017-09-151-15/+25
|
* gtk: Add GtkEventControllerScrollCarlos Garnacho2017-09-154-0/+470
| | | | | | | | | | | | | | | This is a GtkEventController implementation to handle mouse scrolling. It handles both smooth and discrete events and offers a way for callers to tell their preference too, so smooth events shall be accumulated and coalesced on request. On capable devices, it can also emit ::scroll-begin and ::scroll-end enclosing all ::scroll events for a scroll operation. It also has builtin kinetic scrolling capabilities, reporting the initial velocity for both axes after ::scroll-end if requested.
* gdk/x11: Avoid delivering emulated scroll eventsCarlos Garnacho2017-09-151-20/+11
| | | | | We now just propagate the real event, and let the caller deal with smooth vs discrete.
* gdk/wayland: Drop emission of emulated scroll eventsCarlos Garnacho2017-09-151-8/+9
| | | | | A wl_pointer.frame can now only result on one scroll event being emitted.
* gtk: Change gtk_propagate_event() to propagate both ways.Carlos Garnacho2017-09-153-24/+29
| | | | | | | This change is made for consistency, it doesn't make sense to expose one-way propagation, as it can only break expectations from GTK+. This function might be made entirely private in the future, but it still makes sense to do this in one go for our internal usecases.
* gdk/x11: Drop motion/button events emulated from touchCarlos Garnacho2017-09-151-10/+9
| | | | | We now always listen to touch events. Just avoid delivering both types of events.
* eventcontroller: Drop event_mask APICarlos Garnacho2017-09-154-55/+0
| | | | This is unchecked, we can remove it entirely as well.
* gtkwidget: Drop pointer emulation out of touch eventsCarlos Garnacho2017-09-151-63/+1
| | | | | Users of touch events are required to either use a GtkGesture, or handle touch events themselves.
* gtk: Run GtkWidgetClass event signals inside a GtkEventControllerCarlos Garnacho2017-09-155-27/+185
| | | | | | | | This will allow further cleanups and optimizations in capture/target/bubble event delivery. For simplicity, ATM every widget will receive its own GtkEventControllerLegacy, it could be desirable to add finer control over this in the future, so widgets that fully use event controllers for input management can do away without this legacy piece.
* tests: Update testoverlay "Chase" testcase to gtk4 crossing eventsCarlos Garnacho2017-09-151-6/+3
| | | | | The intent is detecting enter events into the overlayed label, so just connect to ::enter-notify-event on the label with no GdkWindow checks.
* Expander: get_label() return is nullableDaniel Boles2017-09-151-2/+2
| | | | Also, use gchar to match the header.
* build: Declare cairo_libs outside MSVC check blockEmmanuele Bassi2017-09-151-1/+1
| | | | Otherwise there won't be a reference to it on non-MSVC builds.
* build: Add fallback dependency discovery for MSVCChun-wei Fan2017-09-151-9/+60
| | | | | | | | | | | | | | | For dependencies that do not generate pkg-config files for their Visual Studio build systems, we need to look for them using cc.has_header() and cc.find_library(), namely for Cairo and HarfBuzz, if one does not have crafted pkg-config files for them (which, by themselves may be error-prone). As a result, we will still try to look for Cairo and HarfBuzz using pkg-config, but will give another shot at them on Visual Studio using cc.has_header() and cc.find_library() if they couldn't be found via pkg-config. https://bugzilla.gnome.org/show_bug.cgi?id=785210
* build: Correct PangoCairo required versionChun-wei Fan2017-09-151-1/+1
| | | | | | | We ought to use pango_req instead of cairo_req for the version required for PangoCairo. https://bugzilla.gnome.org/show_bug.cgi?id=785210
* meson.build: Fix Vulkan library detection on Visual StudioChun-wei Fan2017-09-151-2/+9
| | | | | | | | | | | | | | The Vulkan .lib file that is supplied by the LunarG Vulkan SDK is vulkan-1.lib, not vulkan.lib, so make sure we look for the right libraries when building on Visual Studio (I am not sure whether the LunarG SDK will work for MinGW/mingw-w64 builds, as only Visual Studio .lib files are provided). Note that this will require one to set LIB and INCLUDE appropriately to find the Vulkan .lib and header files, and possibly PATH if one's video drivers do not contain the Vulkan runtime DLL. https://bugzilla.gnome.org/show_bug.cgi?id=785210
* testsuite: Fix builder test on Windows/MSVCChun-wei Fan2017-09-152-12/+24
| | | | | | | | Visual Studio does not support things like -Wl,export-dynamic, so we need to export those symbols by using __declspec(dllexport). So, we decorate these with macros which we define accordingly for this purpose. https://bugzilla.gnome.org/show_bug.cgi?id=785210
* gtk/gentypefuncs.py: Open files in utf-8 encodingChun-wei Fan2017-09-151-1/+7
| | | | | | | | | | On Python-3.x, we need to set the encoding when opening files, when this script is run, as it might contain items that are not supported by the system's locale (for example, non-English Windows). So, we use a wrapper to set the encoding on Python 3.x, but open the file as we did when using Python 2.x, since file encodings are not supported there. https://bugzilla.gnome.org/show_bug.cgi?id=785210
* gdk/gdkconfig.h.meson: Add GDK_WINDOWING_WIN32Chun-wei Fan2017-09-151-0/+1
| | | | | | | This is so that Meson can add this define once it is determined that we are building for Windows. https://bugzilla.gnome.org/show_bug.cgi?id=785210
* Expander: Annotate new()’s label arg as nullableDaniel Boles2017-09-141-1/+1
| | | | to match new_with_mnemonic()
* Expander: Replace (allow-none) with (nullable)Daniel Boles2017-09-141-3/+3
| | | | The former is deprecated in favour of the latter.
* Expander: Explain how to conditionally style arrowDaniel Boles2017-09-141-2/+2
|
* Spinner: Document how to select on animated in CSSDaniel Boles2017-09-141-1/+2
| | | | This is not particularly obvious, so it seems worth including.
* gtk-demo/theming: Don’t mislead about raised classDaniel Boles2017-09-141-2/+2
| | | | | | | | | | | | | | This class is not added by any widgets nor themed by Adwaita/HC. However, it is presented here as if it does something. It doesn’t. But we changed the 2 buttons with the .raised class to use symbolic icons, unlike their ‘unraised’ counterparts, which is unnecessarily confusing and might make people think .raised affects icons somehow. So, make them use the same icons in all cases; that way, if .raised is ever made to do anything, 6 years later, what it does will be clear. https://bugzilla.gnome.org/show_bug.cgi?id=644248
* widget-factory: Usefully demo Frame shadow typesDaniel Boles2017-09-141-30/+3
| | | | | | Instead of showing the 4 types except for GTK_SHADOW_NONE, which are all treated identically and provide no way for themes to differentiate, just keep 2 Frames, and make one of them GTK_SHADOW_NONE to demo a flat Frame
* Frame: Add missing fixed-width format to enumsDaniel Boles2017-09-141-2/+2
|
* build: Add directories to the summaryTimm Bäder2017-09-141-4/+9
|
* iconview: Stop using ::button-{press,release}-eventTimm Bäder2017-09-132-36/+56
| | | | Use a gesture instead.
* calendar: Stop using ::button-{press,release}-eventTimm Bäder2017-09-131-39/+53
|
* FlowBox: Explain how to avoid inflated min sizeDaniel Boles2017-09-121-0/+4
| | | | | | | | | | | | along the orthogonal orientation. It seems a FlowBox on its own can only handle being shrunk along its main orientation. The orthogonal requests a huge min size – reserving what it would need if the main orientation got its min size, which would flow all children in 1 line orthogonally. Adding it to a ScrolledWindow (any policy) enables free shrinking, so size_allocate() can reflow how users in this situation probably expect. https://bugzilla.gnome.org/show_bug.cgi?id=787021
* ColorButton: Don’t destroy dialog @ ::delete-eventHiroyuki Ito2017-09-121-0/+12
| | | | | | | | | | | | Without specifically connecting ::delete-event to something, the dialog will be destroyed when it is closed, for example by pressing Esc. This meant that when dismissing it this way, unlike by pressing Cancel, any custom palette would be lost when the dialog was next opened, and so on. Resolve this by making ::delete-event just do GTK_RESPONSE_CANCEL, so closing the dialog has the same effect as clicking its Cancel button. https://bugzilla.gnome.org/show_bug.cgi?id=787444