Instead of deferring creation of wxPropertyGrid and other controls
to EVT_SIZE handler we can create them when wxPropertyGridManager
is created and its initial size is known.
This way we can avoid using a trick with magic number used as a flag
to determine when to create all controls in OnResize().
Closes#24171.
Passing window size divided by "scale" to CreateWithDIPSize() was wrong
as the resulting bitmap could be too small to cover the entire window
due to rounding errors, e.g. at 200% DPI the right and bottom row/column
was never drawn on if the window size in the corresponding direction was
odd.
This notably fixes their (dis)appearance in dark mode, where we always
draw them ourselves (otherwise we mostly only do it when using
non-default colour).
This was supposed to be "common part of all ctors" but there is just a
single ctor in this class and even this one doesn't really need to call
Bind(), which was the only thing done in Init() since the last commit,
as it can, and should be, called by Create() after successfully creating
the window instead.
No real changes, just a simplification.
Make memory leaks, such as the one fixed by the previous commit,
impossible by making a smart pointer instead of a raw one for this
object.
No real changes.
The pointer may have been already allocated when the code initializing
it in Create() when using dark mode is executed, so unconditionally
reassigning to it leaked memory.
Unary minus of wxPoint and multiplication with double are implemented
but undocumented. Many of operators that use integers types other
than int remain undocumented though.
The arithmetic operators for wxPoint and wxRealPoint are quite
repetitive and were made by copy-paste from the wxSize operators.
Because of that, some of the names are a bit misleading which this
commit changes. The changes are:
1. replace s/sz with p/pt for point variables (likely 's' comes from
copied code used for wxSize variables)
2. replace 'i' with 'f' for floating point types (likely 'i' comes
from copied code used for integer types)
3. replace 'factor' with 'divisor' for division operations (factors
are the multiplication operands, not division)
We need to do it when using XWayland for the same reasons as we had to
do it in the EGL version when using either XWayland or Wayland directly:
without this, we can block for up to 1 second in glXSwapBuffers() if the
window is hidden, see #23512.
Closes#24163.
Closes#24165.
Do this for consistency with wxSize which already had this operator/()
overload and operator*() in these classes which was already overloaded
for double.
Closes#24185.
Closes#24187.
These have been unused since e95354ec54 (added UTF-16/32-[LB]E conversions; got
rid of wxCharacterSet and simplified and fixed some bugs in remaining code, 2003-09-22)
Use the correct types instead of wxSize which was erroneously used
there ever since a5664fd6ef (Increase interoperability between wxPoint
and wxRealPoint introducing constructors which convert between the two
classes., 2010-06-09).
Closes#23804.
For some completely mysterious reason we don't get the expected mouse
click events when running under AppVeyor, something might be covering
the window and stealing the clicks for itself there.
As there doesn't seem to be anything to do about it, just skip the test
in this case.
Closes#24082.
Override required functions in wxHeaderCtrlSimple to avoid asserts if
its columns are reordered.
Also bring the code behaviour in agreement with the documentation by
calling UpdateColumn() after calling UpdateColumnVisibility().
Finally, only call UpdateColumnsOrder() if the corresponding event was
not processed as the application should use one xor the other mechanism
for reacting to columns reordering, but not both.
Closes#24108.
Closes#24172.
We don't have DISABLED_UTILS or DISABLED_DEMOS variables, so it's
useless to exclude them from the makefiles list -- just stop doing it.
This fixes a problem with using EGREP without preceding AC_PROG_EGREP
with autoconf 2.72, as EGREP is not defined any longer with this
version.
See #24168.
Non-integral coordinates and overlay scrollbars can cause the event to be
generated with coordinates that are still inside the window. Avoid this by
ensuring that integral coordinates are outside the window, and ignoring overlay
scrollbars. Also remove gdk_display_flush(), contrary to the very old comment
it does not seem to be necessary. Fixes wxScrolledWindow auto-scrolling.
Remove installed event handlers before trying to hide the popup,
as this could result in Destroy() being called twice under wxQt.
This happens to wxRichToolTip for example. i.e. Destroy() is called
once from wxPopupFocusHandler::OnKillFocus() after the call to Hide()
then, from wxRichToolTipPopup::OnTimer().
The fact that we cannot create a wxPopupWindow with a parent
is no longer valid after the recent changes to the wxQt port.
The wxRichToolTip (an instance of wxPopupWindow) will crash if
created without a parent under this port.