Move it from wxCheckBox to wxControl to allow reusing this code in other
classes, notably wxRadioButton in the upcoming commits.
See #10137.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76455 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
Just use wxArrayInt::Index() instead of doing a linear search in the array
manually. Also use RemoveAt() + Insert() instead of manually iterating over
the items.
See #16110.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76454 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
Fix the logic for finding the correct position to drop the column at when
ending a drag move operation. The old code dropped it one position too far to
the left when it was dropped on the "far" (i.e. right with LTR layout) part of
the target column.
See #16110.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76453 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
Using negative column widths used for hidden columns when updating the column
positions after dragging one of them to a new position totally broke their
display. Fix this by ignoring the hidden columns.
Closes#16110.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76452 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
Allow the renderer to specify the best height at the given width (or vice
versa) instead of the best size in both direction which is not defined for
e.g. wxGridCellAutoWrapStringRenderer.
Closes#15943.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76451 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
Modal dialogs shown during wxBusyCursor effect shouldn't show the busy cursor
as they do accept input, but did in wxMSW (as could be seen in e.g. the
widgets sample after enabling the "Global busy cursor" in the menu and showing
the text entry dialog via "Text|Set Help Hint").
Fix this by explicitly checking for the special case of having a modal dialog
as parent at wxWindow level as doing it in wxDialog simply didn't work as its
WM_SETCURSOR handler wasn't called at all for determining the cursor to use
for its children because they handled WM_SETCURSOR themselves in the global
busy state, without letting DefWindowProc(), which propagates this message
upwards the window hierarchy, to have it at all.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76449 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
The new projects are easier to customize as the build options can now be
specified in wx_vc10_local.props file. They also have correct dependencies and
avoid sharing violations when copying wx/setup.h.
Finally, they also use the correct names for the webview DLL, see #15820.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76448 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This avoids the assert which happened when trying to show the next
notification message in SetUpIcon() as the icon was null while the reference
count was positive.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76447 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
The parent of wxRibbonPanel is not always a wxRibbonPage, it can also be the
containing wxFrame itself if the panel is a temporarily expanded one created
when the user clicks a panel reduced to a button. So don't rely on the cast of
the parent to wxRibbonPage to always work. This is ugly but at least avoids a
crash.
Closes#16215.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76437 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
Don't intersect the total rectangle with the uninitialized work area one
resulting in an empty rectangle being returned from wxGetClientDisplayRect()
if X11 server doesn't support _NET_WORKAREA (this is the case for at least
Cygwin X11 server).
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76434 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
SetSize() is useless here as it is simply ignored by the sizer which will fit
the window to its initial size anyhow.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76430 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
The two compilers are binary compatible and by pretending that Intel compiler
is the same as MSVC, we allow using ICC to build applications using DLLs built
with MSVC.
Closes#9437.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76425 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This fixes problems with parallel builds in Visual Studio 2012 or 2013 IDE as
multiple projects may try to copy setup.h file at once, resulting in errors.
Use _custom_build project as a common dependency to ensure that the copy step
is done only once.
Closes#16177.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76419 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
Under MSW a thread has both an ID, returned by wxThread::GetId(), and a
handle, which couldn't be retrieved so far. Add an accessor to do it.
Closes#16170.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76418 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
Creating the status bar before the menu bar but associating it with the frame
after creating the menu bar resulted in a status bar of completely wrong height.
Fix this by enforcing the default height on the status bar when it's attached
to the frame.
Closes#10956.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76417 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
Remove or reset the corresponding bitmap if the provided one is invalid
instead of asserting, this is what wxGTK does and this behaviour seems to be
more useful.
Also document this behaviour as it's now implemented in both wxMSW and wxGTK.
Closes#13569.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76415 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
Allow calling this function not only from inside DoWriteText(): first, because
the existing code could be doing this (although this is only a concern in 3.0
branch as it was made private in the trunk) and second because it could
actually happen if the text limit was exceeded by user typing in the control.
See #15980.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76413 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
There is no need to do it as this is done by DoWriteText() and
AdjustSpaceLimit() doesn't work correctly if called from outside of it now.
Because of this, also make it private to prevent other accidental calls to it.
Closes#15980.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76412 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
We did it up to MSVC 11 but this still seems to work just fine without /EHa
with MSVC 12 too, so relax the version check to allow it to pass.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76410 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This does not solve the actual problem of this function not returning the
correct value for Windows 8+ any more, but at least allows to compile the
library without warnings with MSVC 12 and later.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76409 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
We don't support systems predating Windows 2000 SP4 any more, so there is no
need to check for them. This also allows to get rid of the code checking for
conversion correctness.
Also remove the broken URLs from the comments, they didn't contain any
particularly useful information anyhow.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76406 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
A condition was checking for the wrong CDN_XXX message range resulting in CDN_INITDONE and CDN_SELCHANGE no longer being processed. Broken since r75937 (branches/WX_3_0_BRANCH/) and r75941 (trunk/).
See #16003.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76394 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775