This assert seems to be quite useless and can be triggered if a key is
(perhaps accidentally) sent to a small (e.g. not yet fully laid out)
wxDataViewCtrl window.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@78146 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
The text control was left empty if the string value was not specified, but
it should use the numeric initial value instead in this case.
This notably affected wxSpinCtrlDouble under non-GTK platforms.
Closes#16621.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@78124 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
Expand wxStaticText controls in wxBusyInfo and centre them to avoid the
problem with their contents being truncated when using markup under wxOSX.
This should, of course, be fixed in wxStaticText itself, and when it is, this
change should be reverted. But for now this at least allows wxBusyInfo to
appear correctly under OS X.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@78065 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
Allow customizing wxBusyInfo window by passing wxBusyInfoFlags containing
information about the icon, title, colours and frame transparency to use.
Update the sample to show such "rich" busy info.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@78063 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
The title is not shown to the user anyhow because this frame doesn't have
wxCAPTION style. And if it were shown, it should have been translated, but as
it isn't, just remove it.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@78058 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
For some reason, the control always drew itself using wxSYS_COLOUR_BTNTEXT.
This is a good default, but it shouldn't ignore the explicitly set foreground
colour, so use it instead.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@78057 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
Check for the absence of modifiers before intercepting the TAB key, we only
want to do it for plain TAB or Shift-TAB but not Ctrl-TAB, for example, as
this prevented the user from switching between MDI windows when focus was on
wxDataViewCtrl.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@78052 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This makes the code (slightly) shorter and more clear and is more efficient as
selecting all items in wxDataViewCtrl is now a O(1) operation instead of being
O(N), where N is the number of items -- and the latter could take quite a long
time (and consume non-negligible amount of memory) for large N.
Increase the size of the virtual list control from 1000 to 10000000 in the
sample to show this.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@77905 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
Rename the existing but not implemented and never used OnItemAdd() method to
OnItemsInserted() and add OnItemsDeleted(), which is more efficient than
OnItemDelete() when many items are being removed from the control at once.
This is not used yet, but will be used in wxDataViewCtrl soon and maybe in the
other controls later.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@77904 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This is necessary for retrieving all the selected items at once: while doing
this is not recommended for a control with a potentially very large number of
items, it must be possible to allow using wxSelectionStore for wxDataViewCtrl
implementation as wxDataViewCtrl must implement its GetSelections() method.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@77902 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
No real changes, just don't make SelectRows() more complicated than necessary:
it is always called with its arguments in order, so it doesn't need to reorder
them and it is never called to deselect the items.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@77901 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
Shift clicking in a control with multiple selections without a previous
current row attempted to select all rows from the current one up to UINT_MAX
which resulted in a program freezing (and probably running out of memory in 64
bit builds).
Fix this by explicitly checking for the absence of the current item.
Closes#16582.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@77900 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This reverts r76824 as it is not necessary any longer, the fix in the previous
commit takes care of this problem more generally.
See #16365.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@77893 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This is mostly done to avoid warnings about converting the result of
multiplying and dividing an int by doubles back to int, but is also more
correct as wxMulDivInt32() rounds the result correctly instead of truncating
the fractional part, and is also a tiny bit more efficient under MSW where the
native ::MulDiv() is available.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@77748 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
Initialize m_buffer to avoid crashes when deleting it in Cairo-based
wxGraphicsContext implementation for bitmaps created from the native ones.
Don't leave the bitmap size uninitialized neither, this might not result in
crashes, but is definitely wrong as well.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@77718 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
Do it even if the start page has a previous page (e.g. because the wizard has
been started in the middle for some reason).
Closes#16535.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@77545 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
Don't prevent termination of the app if all windows are closed, except
for the preferences one (which may very well be hidden at the moment).
This only affects platforms where the preferences are modeless (GTK+, OS
X) and where the preferences window, once created, continues to exist,
but is hidden.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@77520 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This merges in the latest sources from GSoC 2014 wxQt project with just a few
minor corrections, mostly undoing wrong changes to common files in that branch
(results of a previous bad merge?) and getting rid of whitespace-only changes.
Also remove debug logging from wxGrid.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@77455 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
Override DoGetBestClientSize() instead of DoGetBestSize(), as we're really
computing just the size of our contents and like this we don't need to hard
code platform-dependent border sizes in this control itself.
Also use the client size in LayoutControls() for the same reason. This also
makes it unnecessary to pass it the width and height as it can find them on
its own. And x and y were never used in the first place, so remove them too.
Finally, center the bitmaps vertically.
Closes#16422.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@77083 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This is not necessary as wxDC already inherits RTL from the window itself and,
in fact, breaks the display when using RTL.
Closes#16250.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@77038 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
Ensure that the table pointer inside wxGrid is updated before initializing the
native column header as it uses wxGrid::GetColLabelValue() which doesn't work
correctly without a valid table pointer.
Closes#16399.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76976 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775