Commit 952e5f3 introduced logging wxEVT_SLIDER events in addition to
scrolling events but the event count was incorrect as the wxEVT_SLIDER
handler and scrolling events handler kept their own event count.
Fix this by using a static member variable shared by both event handlers.
Avoid sending spurious wxEVT_LIST_ITEM_{FOCUSED, SELECTED, DESELECTED}
events and make the generic version consistent with the behaviour of the
native wxMSW one.
Also add/extend the tests and slightly improve the sample.
Closes https://github.com/wxWidgets/wxWidgets/pull/2044
Generating such events could result in mishandling some key presses as
special keys, e.g. the Turkish "ş" characters was mistakenly processed
as F12 because F12 corresponds to its Unicode character code (U+015F).
Avoid this by only setting wxKeyEvent::m_keyCode for printable
characters (while still making the actual key available in m_uniChar).
This makes wxOSX consistent with wxGTK and documented behaviour.
Closes https://github.com/wxWidgets/wxWidgets/pull/2081
Don't send the event when it's redundant, i.e. doesn't really notify
about the change in the slider value.
Also add a test case for wxEVT_SLIDER and show these events in the
widgets sample.
Closes https://github.com/wxWidgets/wxWidgets/pull/2080Closes#18929.
wxgtk_initialize_web_extensions() tries to find extensions in the
location where "make install" puts them. If that fails, either because
wx wasn't installed yet, or it was deployed (e.g. in static build)
without them, it looks into additional places - paths relative to CWD.
This is to faciliate running wx samples and tests, but by being enabled
in release builds too, it allowed loading unexpected executable code
from untrusted locations. For example, on typical desktops, one could
put malicious .so files into $HOME/lib to have them loaded by
wxWebView-using applications.
Address this by making the helper paths relative to the executable's
location, not working directory.
Don't log failure to load the extension during initialization, because
it isn't needed for many uses of wxWebView. Instead, only report the
failure at the time when functionality depending on it is used.
Also use g_warning() for logging consistently with other failures in
this file. This doesn't interrupt the user, yet shows the problem highly
visibly in the console.
Change wxGetInstallPrefix() to return a string instead of const
wxChar*. The latter was incorrectly obtained from a temporary string if
WXPREFIX was set. While it's possible to fix in a backward compatible
manner without changing the function's signature, it's not worth the
effort for something pretty obscure and used mostly internally.
As it is stated in matrix.cpp wxTransformMatrix was intended to be used
in wxDC to replace the basic system of scaling/translation but actually
it was never used.
Because applying affine transformations can be done with wxAffineMatrix2D
and wxDC::SetTransformMatrix() we can get rid of this dead code.
Closes#13114.
Add missing ":" in the beginning of Git pathspecs to make the exclusions
really work.
Also add entries for Makefile.in, which is not caught by **/*akefile*,
and other files in the root directory containing hard TABs.
Check for the presence of alpha channel before using it in the fallback
code.
Also add a unit test exercising this branch of the code and which
crashed before.
No real changes, just execute only the tests relevant for the section
being executed instead of always running the code loading PNG images
when running a section not using them at all.
This has the advantages of being a bit faster to execute (and the total
test suite run time does add up) and, more importantly, showing the
right amount of tests when executing a single section: e.g. now it's 1
in the simplest case, as expected, and not 5.
The disadvantage is, of course, slightly more code duplication, but it
doesn't seem a huge problem in practice and making each section code
more self-contained is arguably worth it.
Also, compensate for this somewhat by extracting all XPM definitions at
the function level: those are only initialized once (being static), so
there is no need to duplicate them.
Finally, also call AddHandler() once instead of once per section as
before.
Add new image test files added in 6e8da8641c (Add alpha blending for
wxImage::Paste, 2020-09-23) and 1f0ade29f0 (Fix using mask colour even
if there is no mask in wxImage::Paste, 2020-09-30) to Makefile, so that
they're copied to the build directory and could be found by the test
there, otherwise running wxImage::Paste test when building outside of
the source directory failed.
Save global fallback encoding when switching to it, so GetEncoding() can still return the correct value if global fallback encoding is changed later. Also do not switch to wxFONTENCODING_MAX when it is set as global fallback encoding.
Actually do what the comment says is intended. wxLogInfo() and
wxLogVerbose() differ in that only the latter must be explicitly
enabled with --verbose.
wxWidgets already has a mechanism for locating plugins under
$libdir/wx/*, there's no reason to duplicate it with another
compile-time symbol.
As a consequence, this makes the library relocatable via WXPREFIX again.
Fix the location where the web-extension plugin is installed to be
consistent with the primary bakefile-based build system: i.e. to use
lib/wx/x.y.z for devel versions and lib/wx/x.y for stable.
This reverts commit 374db28747 (Fix wxMSW ListCtrl drawing of horizontal
rules for new items, 2016-05-04) and also commit bb3177dd3b (Avoid
infinite repaint loop in wxListCtrl with wxLC_HRULES, 2020-07-24) which
fixed one problem with the original change, but not all of them, as it
was still easily possible to get into an infinite repaint loop.
So just return to the simplest and not too bad, even if not optimal,
solution of refreshing everything after changing a column width when
using horizontal rules.
See #17158, #18850.
Closes#18927.
Make the names more clear and similar to the names of member variables
to which they correspond and also use them consistently in the
documentation.
This reverts the changes to this interface header done in 5925893eed
(Fix various doxygen issues in the documentation, 2019-10-20).