This reverts commit 8c9ba23eae, reversing
changes made to 5192feb38e.
Upcoming commits will try to work around the issues with art IDs related
to wxNO_IMPLICIT_WXSTRING_ENCODING in a different way.
Also add GlobalPtrLock::GetSize() and use it instead of calling
GetSizeFromBuffer() as it's more direct and doesn't require the use of
::GlobalHandle().
Instead of just passing a boolean flag indicating whether
wxEVT_GRID_RANGE_SELECTED should be sent, pass wxEventType to send, with
wxEVT_NULL being interpreted as "don't send anything".
No real changes yet, but this will allow using the existing functions to
send wxEVT_GRID_RANGE_SELECTING and not only SELECTED in the upcoming
commits.
Use the same art provider for a floating frame detached from an existing
wxAuiManager as was used by the original wxAuiManager itself, to ensure
that the appearance of this frame is consistent with the appearance of
its parent.
Implementing this required adding wxAuiDockArt::Clone() to allow copying
it in the new frame and this patch also adds GetAuiManager() to
wxAuiFloatingFrame, similar to the existing method in wxAuiNotebook, in
order to allow changing the dock art from the application code if
desired.
Closes https://github.com/wxWidgets/wxWidgets/pull/2022Closes#18882.
Make the wxART_* constants const wxStrings to improve compatibility with
pre-3.1.4 code and, in particular, allow taking the address of these
constants.
See https://github.com/wxWidgets/wxWidgets/pull/1996
Remove m_isSelecting and StartSelecting() from wxGridSelection to avoid
inconsistency of wxGridSelection selecting mode state with wxGrid state,
as wxGrid already has m_isDragging field which tells it if the selection
state is final or not.
Instead, just allow wxGrid to specify the event to send from
ExtendCurrentBlock().
We still need a separate EndSelecting() for sending the final
wxEVT_GRID_RANGE_SELECTED event, but send it only for the last selection
block, and not all the selected blocks, as this makes more sense (there
should be one SELECTED event for each block and it was already sent for
the other blocks before) and is consistent with the events generated
when performing the same actions from keyboard.
This will allow the applications that are only interested in the final
selection to ignore the intermediate SELECTING events, which are now
sent as soon as the selection changes while dragging the mouse, and only
handle the final SELECTED ones, when the drag is over.
This is not needed any longer after the changes of the last commit.
Note that the (still existent) public wxGetDisplaySizeMM() didn't use
this function, but used PPI instead.
Don't try computing the PPI ourselves from the physical size and the
number of pixels, this doesn't work and nobody else does it like this.
Just assume that we're using standard PPI by default and use
toolkit-specific functions for the platforms with support for high DPI.
This is similar to CreatePopupMenu(), but the menu pointer returned by
the new function won't be deleted by wxWidgets, allowing it to return
the same pointer every time it is called.
Closes#18886.
This was already done for clang -Winconsistent-missing-override, but
gcc has a similar warning since 5.1 and, moreover, latest versions of
clang support this gcc warning as well, so add a special macro which
handles both compilers and use it in all wx macros defining virtual
functions instead of just disabling one of the clang warnings.
Closes https://github.com/wxWidgets/wxWidgets/pull/2000
This is conceptually the same as the ratio of the current DPI to the
standard one, but can be implemented more directly for wxGTK3 and wxOSX
(although the latter doesn't implement it yet).
The global wxCurrentPopupWindow used by wxMSW wasn't reset in this case
and resulted in a crash during the next mouse or focus event.
Do it in wxPopupWindow dtor now, and not just when the popup is hidden.
The pre-3.1.4 definitions of the constants were just string literals,
while the type were wxString typedefs. To avoid implicit conversion
these were converted to actual wxStrings.
While the interface now matched the implementation, this has several
drawbacks:
- every use of the "constant" now is a string construction at runtime
- the constant now is an rvalue, i.e. it is impossible to take its
address.
The latter breaks its use from wxPython.
The IDs are moved to a separate file which can be included multiple
times, once from the header to have the declarations in place, and once
to instantiate the wxStrings. Using a common file avoids the declaration
and definition going out of sync.
Use the same 100 DIPs as in wxMSW, to make the default behaviour more
useful.
Also update documentation to explain which size component should, and
should not, be specified when creating the slider.
Closes https://github.com/wxWidgets/wxWidgets/pull/2012
The constants for wxFILE_EXISTS_FIFO and wxFILE_EXISTS_SOCKET were
wrongly defined, mixing up their decimal and hexadecimal values,
resulting in wxFILE_EXISTS_FIFO & wxFILE_EXISTS_DIR being wrongly non
zero.
Fix this by redefining these bit masks correctly to avoid overlapping
the other values.
Closes#18846.
Fix problem with wxUSE_HTML added in 05cce8d89d (Add wxUSE_HTML check to
wxHtmlListBox header, 2020-05-28) not being defined when this header is
the first one to be included.