Mark the function as deprecated. It should not be part of the public API. It
cannot be overridden and manually calling it has no lasting effect because
DrawCaption calls it as well.
Closes https://github.com/wxWidgets/wxWidgets/pull/943
Not creating it when the default image wasn't found resulted in a crash,
so always create wxStaticBitmap using a fallback bitmap if necessary.
Also add a wxCHECK_RET to prevent the crash from happening in a similar
situation in the future.
Preserve compatiblity font descriptions serialized using
wxNativeFontInfo::ToString() in older versions of wxWidgets and load
them correctly, instead of asserting.
aedf89b098 originally did this, then
d355af3420 reversed it as "not needed".
Turns out it is, for old serializations.
Reverse d355af3420 and implement the same
backward compatible logic in wxOSX. wxMSW uses win32-native description
and doesn't need this.
Avoid casting addresses to "long", as it can be smaller than pointer
size on some platforms and notably is under Win64.
Use wxUIntPtr instead, which is guaranteed to be large enough.
See https://github.com/wxWidgets/wxWidgets/pull/940
Always add offset and address of a stack element, even if there is no
symbolic function name, as this can still be helpful. If possible add
module as well.
Closes https://github.com/wxWidgets/wxWidgets/pull/940
The code handling the mouse events assumed the drop down button with was
10px, but wxAuiMSWToolBarArt uses a different width (14px). So clicking
on the left-most 4 pixels was not registered as a drop down click.
Allow the get (and set) the width of the drop down button of the
ToolBarArt.
Increase the detection area for drop down events, because the drop down
button is drawn 1 pixel larger than the actual size.
Rename some variables where dropdown was used instead of overflow.
Closes https://github.com/wxWidgets/wxWidgets/pull/939
In 10.14's dark mode, all views are layer-backed and the assumption that child
windows are redrawn with their parent may not be correct. Change Refresh() to
explicitly refresh child windows too.
Also explicitly refresh the page before showing it in wxPreferences, because
otherwise generic windows wouldn't be drawn correctly.
Set toplevel window's background colour to the correct value of
NSColor.windowBackgroundColor (i.e. wxSYS_COLOUR_APPWORKSPACE). Without this,
the window's frame would be rendered slightly incorrectly, because of the way
the dark mode blends colors - even when no part of the window's interior, where
the background color would be used, is visible.
Add an explicit cast to avoid warnings when compiling with this option.
While just casting double to float is not the best idea, it seems quite
unlikely that anybody would pass a value outside of float range to this
ctor.
There is no need to use ConvertFromLegacyWeightIfNecessary() here as the
string representation is not supposed to contain the legacy weight
constants. And it was also used incorrectly, resulting in build errors
for e.g. wxDFB.
wxTreebook is supposed to allow not specifying any valid window for the
top-level pages, but this didn't work any longer, probably since the
changes of 02a92e23f3 (see #4379), as a
possibly null page was dereferenced without checking, resulting in a
crash.
Fix this by adding a missing check.
Also rename DoGetNonNullPage() to TryGetNonNullPage() to make it more
clear that this function can return null and add a unit test checking
that calling AddPage(NULL) really works (or at least doesn't crash).
See https://github.com/wxWidgets/wxWidgets/pull/921
Remove SetWindowMenuLabelTranslated() which was only called once and so
didn't seem to be worth having. Also get rid of WINDOW_MENU_LABEL for
the same reason: it was used only once and imposed the use of
gettext_noop() which is not needed any longer.
Rename GetWindowMenuLabelTranslated() to have a MSW prefix in order to
indicate that it's a private MSW function and not part of the public wx
API.
Also renamed "Translated" to "Current" to (hopefully) more clearly
indicate why do we need to keep this variable.
If the locale is changed while the MDI window menu is active, the menubar entry labelled with the previous translation will not be removed. The previous translation is now remembered and used to locate the menubar entry.
Add the source files of the generic dialogs to the project,
similar as is done in the bakefile.
See previous commits 573e887a4c and
6415bd553f, which partially reverted it,
for the full story.