No real changes, this is a pure refactoring after the changes of the
parent commit which resolved another inconsistency in handling of right
and middle mouse button clicks.
There doesn't seem to be any reason to generate right click events in
any case, whether there is an item under the mouse or not, but only
generate middle clicks if there is a normal (and not any other kind of)
item under the mouse.
Change the code to also do it unconditionally for consistency.
Just use GetPopupMenuSelectionFromUser() which handles this internally.
Also document that ShowDropDown() returns -1 if the menu is dismissed.
No real changes.
For unknown reasons we used exactly the same code for sending event with
valid and invalid tool ID instead of just setting a variable containing
the tool ID and then using it.
Fix this now.
No real changes.
Don't call wxGetMousePosition() when this information is already
available as part of wxGetMouseState() return value that we may need
anyhow.
No real changes.
This is shorter and arguably more clear than passing pairs of
coordinates everywhere, so change the code to consistently do it.
Also remove unnecessary temporary variables.
No real changes.
Don't call m_overflowSizerItem->GetRect() unnecessarily: all fields of
overflow_rect were overwritten immediately after assigning the result of
this call to it, so this was just useless.
Also replace "cli_rect" with "cli_size" as we only used the size part
anyhow.
No real changes.
They were wrongly recognized as clicks on the overflow item due to the
hit test check being correct for horizontal toolbars only.
Fix this by using the same, simpler and much more obviously correct,
check that was already used for the left mouse button and just tests if
GetOverflowRect() contains the point.
Closes#26242.
Null argument is allowed in wxHtmlHelpController::ReadCustomization()
and is potentially useful here to prevent the use of a dangling pointer.
Also explicitly document that this parameter can be null.
Closes#26238.
When wxUSE_UNICODE_UTF8 is set to 1, strings use UTF-8 and are still
char strings and not wchar_t ones, but when using wx own implementation
of vsnprintf(), "%s" expected a wide string and not a normal one.
Fix this at wxPrintfFormatConverterUtf8 level.
Closes#26236.
Store these values in DIPs internally and apply FromDIP() when using
them.
This is simpler and possibly more precise than rescaling them when
getting wxEVT_DPI_CHANGED event and the only awkward part is that we
need to use ToDIP() in the setter functions, but this is arguably not
very important as these functions are hardly ever used anyhow.
See #26235.
Closes#26076.
Make it more readable by indenting it according to the nesting level and
also showing virtual size only if it's different from the actual size,
as otherwise it is just redundant.
Also don't show maximum size at at all, it's never set anyhow.
Add wxHAS_SIZER_DEBUG to allow enabling sizer debugging by predefining
this symbol and without necessarily recompiling everything with
wxDEBUG_LEVEL > 1.
There is really no reason for it not to be.
There also doesn't seem to be any reason for it to be virtual, but keep
this just to warn any people who override it in their code so that they
could add "const".
Cairo 1.18 broke using cairo_public redefinition hack used before to
avoid declaring Cairo functions as being dll-imported. Use the new way
to prevent this from happening but still define cairo_public when using
older versions.
Note that, unfortunately, we can't do it unconditionally because this
results in a macro redefinition warning with newer versions which is
impossible to disable using gcc.
As the new hack is even worse than the existing one, move it into its
own header to avoid duplicating it in both between src/common/cairo.cpp
and src/generic/graphicc.cpp.
Closes#26224.
We provide a fall back in case of error, so seeing this error in the
build logs is confusing.
This slightly amends the changes of b2cb336b78 (Fix wx-config symlink in
out-of-tree installs, 2024-06-18).
See #24622.
The recent 94a54f68af (Fix script used to change macOS install names
with configure, 2026-02-18) broke it by using realpath not available
until macOS 13.
Return to using (nested) readlink calls.
See #25675, #26200.
Use ICoreWebView2_22::
AddWebResourceRequestedFilterWithRequestSourceKinds() when available
(closes#25816).
Also fix memory file system issues.
Closes#25816.
Closes#26214.
wxAuiToolBar gets wxEVT_SIZE events due to relayout done by wxAuiManager
whenever any sash is being dragged, but this doesn't necessarily
actually change its size, so avoid refreshing it in this case, as this
results in very noticeable flicker, especially when the toolbar has any
controls inside it.
This commit is best viewed ignoring whitespace-only changes.
Closes#26142.
Closes#26212.
This is a "forward port" of 31c8641771 (Fix script used to change macOS
install names with configure, 2026-02-18) from 3.2 branch.
See #23143, #25173, #25182, #25675.
Closes#26200.
wxWindow::GetRect() does not always report client coordinates,
so use wxWindow::GetScreenRect() and wxWindow::ClientToScreen()
to test mouse and autoscroll zone with consistent coordinate
system.
Closes#26226.
This fixes the problem with the menu items becoming completely invisible
when switching from dark to light mode.
Co-authored-by: Mohmed abdel-fattah <memoarfaa@gmail.com>
Co-authored-by: Maarten Bent <MaartenBent@users.noreply.github.com>
Previously only saving columns positions was implemented, but they were
never restored.
Closes#26222.
Signed-off-by: Vadym Hrynchyshyn <vadimgrn@gmail.com>
Mostly just add autorelease to avoid various objects being leaked, but
also add manual calls to release for the code which is not necessarily
executed inside a GUI application and so can't rely on autorelease pool
existence.
This makes the tooltip unreadable because using background colours with
alpha channel doesn't work correctly for wxPopupWindow (or, rather,
wxNonOwnedWindow) in wxGTK currently and wxSYS_COLOUR_INFOBK uses alpha
in the default GTK theme.
Closes#26185.
Don't allow shrinking the dialog below its minimum size.
Also don't allow resizing single line entry dialogs vertically at all,
as the extra vertical space would be wasted anyhow and just makes the
dialog look bad.
Closes#25739.
Closes#26213.
Implement this function as a trivial wrapper for wglGetProcAddress(),
glXGetProcAddressARB() or eglGetProcAddress() depending on the platform
(currently not implemented for macOS).
Account for the known bug in some Windows OpenGL drivers by checking for
manifestly invalid return values and handling them as null.
Use the new function in wxGL code itself and in the pyramid sample.
Closes#9215.
Closes#26209.