The previous error didn't make sense if CMAKE_CXX_STANDARD wasn't set,
so use a slightly different message in this case.
Also improve the comment explaining why we need C++17 in the first
place.
Co-Authored-By: Maarten Bent <MaartenBent@users.noreply.github.com>
Previously CMake would give an error if CMAKE_CXX_STANDARD wasn't
explicitly set to C++17 or greater when using CEF, but this is not
really needed if the compiler supports C++17 without any non-default
options, so check for this too.
If it isn't, as is the case for MSVS for example, we don't need to set
wxHAVE_CEF_DEBUG anyhow, as it's set automatically if _DEBUG is defined
during the build.
Co-Authored-By: Maarten Bent <MaartenBent@users.noreply.github.com>
Really fix wxSetCursorEvent handling for wxAUI done in commit f608b34
(Send set cursor events whenever there is mouse movement) without
breaking the other controls, i.e. wxSplitterWindow, wxHeaderCtrl and
wxGrid.
Pass the mouse position by const reference to QtSendSetCursorEvent().
Closes#24217.
To find a page by ID currently you have to use a recursive FindWindow
(which would also look at the child Panel windows). This function allows
for finding a page by ID more elegantly.
Closes#24211.
Add new wxWebViewConfigurationChromium class which corresponds to the
"native" configuration used in the other backends and contains (some)
fields of CefSettings in this one.
Add the option 'msw.native-dialogs-pmdpi' that will always show the native msw dialogs
as per monitor dpi aware, even when there are displays with different dpi.
Don't define operators for wx types in global scope.
This results in much better error messages when the compiler gives an
error about failing to resolve a call to some operator in user code
because it doesn't list all the wx-defined operators as candidates. In
practice, this cuts down error messages from 500 (!) lines to 2 with
gcc.
See #24190.
It is not necessary (nor beneficial) to derive these classes: wxQtActionGroup,
wxQtAction and wxQtShortcutHandler from wxQtSignalHandler ( which is intended
for use exclusively with wxWindow handlers only ).
This was probably done unintentionally in 8ccbd7e95d (Implement
operator/=(int) and operator*=(int) for wxPoint and wxRealPoint.,
2024-01-04) and results in warnings from clang.
In portable code CreateWithLogicalSize() must be used when its arguments
are logical coordinates, e.g. window sizes, so using CreateWithDIPSize()
was wrong and resulted in missized bitmaps in high DPI under MSW.
These functions behave in exactly the same way in this port, but using
CreateWithLogicalSize() seems to be more clear, as we're passing it the
coordinates in logical pixels (e.g. window sizes etc) and not DIPs.
No real changes.
This function should be used instead of CreateWithDIPSize() in portable
code, the latter is currently often used to do what this function is
doing, but this only works correctly in wxOSX and wxGTK3 but not wxMSW.
We can't rely on file /sys/power/state always existing, so just skip the
test (with a warning) instead of failing it if it does not exist, as is
the case at least under s390x and seemingly other non-desktop platforms.
Closes#24197.
Co-authored-by: Cliff Zhao <qzhao@suse.com>
This seems like the most sensible thing to do. Alternative would be to
not use XDG directories if ~/.config doesn't exist yet, but this doesn't
seem right, especially if wxCONFIG_USE_XDG is explicitly specified.
Still use the traditional dot file if it already exists, but prefer
using the new location otherwise, i.e. for the new program installation.
Add wxCONFIG_USE_HOME to allow forcing the use of the old location if
really necessary.
Also use the new style as default "old style" of MigrateLocalFile() so
that calling it even when using XDG layout in wxStandardPaths still
works as expected.
Add the errors logged by various file functions called from this
function to the returned error message instead of letting wxLog show
them as usual because it may be necessary to show an interactive message
box, asking the user about the action to take, if migrating the existing
file failed, and it is poor UI to show both the message box from wxLog
and this message box at the same time -- so avoid showing the former.