Commit Graph

33306 Commits

Author SHA1 Message Date
Vadim Zeitlin
2594929d9f Move include/wx/unix/execute.h to include/wx/unix/private.
This header is private and is not supposed to be used from the outside the
library.

See #16325.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76683 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-06-11 14:55:08 +00:00
Vadim Zeitlin
a8d5d7cdba Don't assert in wxOSX if a shaped window doesn't define a valid shape.
A window with wxFRAME_SHAPED style can still not defined any valid shape
actually, in which case wxFRAME_SHAPED should be just ignored.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76681 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-06-10 00:38:38 +00:00
Vadim Zeitlin
8aabad5e4c Fix wxMSW build without PCH after recent wxListBox font fix.
This should have been part of r76673.

See #3577.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76678 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-06-09 21:31:34 +00:00
Vadim Zeitlin
b6469b4369 Fix changing the label of a submenu in wxMSW.
Use position, not the ID, to find the native menu items to allow the code in
wxMenuItem::SetItemLabel() and DoSetBitmap() to also work with submenus and
not just the normal items.

Closes #16246.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76676 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-06-09 20:33:17 +00:00
Vadim Zeitlin
af692f090b Fix getting position of wxPopupWindow in wxMSW.
Don't offset the returned values by the parent window origin unnecessarily: as
popup windows are created as children of the desktop window in wxMSW, their
coordinates are already expressed in screen coordinate system (which is
exactly the same as display window coordinate system) and we must not try to
translate them to it once again, this is completely wrong and was probably a
left over from earlier wxPopupWindow implementation in which it wasn't created
as a child of desktop.

Closes #4440.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76675 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-06-09 20:33:11 +00:00
Vadim Zeitlin
b15f361171 Fix wxMSW wxCheckListBox appearance when using larger than normal fonts.
Update the height of the items when changing the font to ensure that there is
enough space to show the item text when using fonts larger than normal.

Closes #3577.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76673 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-06-09 00:54:17 +00:00
Vadim Zeitlin
82112b5de2 Fix changing wxWindow ID in wxMSW.
This must be done both at wxWidgets and MSW level, otherwise changing the ID
results in window not recognizing itself as the recipient of the messages sent
to it by Windows.

Closes #3697.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76672 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-06-09 00:54:12 +00:00
Vadim Zeitlin
be35fb7a15 Compilation fix for wxMSW with wxUSE_TOOLTIPS==0.
This is another fix after the changes of r76657, see #16265.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76667 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-06-05 11:29:34 +00:00
Vadim Zeitlin
d8933b2b8d Fix spurious assert when creating multiline wxTextCtrl from XRC.
Don't try to set the hint unconditionally, this doesn't work with multiline
text controls and so resulted in an assert when trying to create one from XRC
since the changes of r76629.

Closes #16317.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76666 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-06-05 00:28:46 +00:00
Vadim Zeitlin
f81a758d4e Stop Scintilla timer when the control doesn't have focus.
This avoids excessive CPU load due to generating completely unnecessary timer
notifications for every wxSTC control in a program.

Closes #14938.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76665 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-06-05 00:26:27 +00:00
Vadim Zeitlin
1d160160b7 Add cast to wxWindow to fix wxUniv/MSW compilation.
wxWindowMSW is different from (base class of) wxWindow in wxUniv and needs to
be converted to it explicitly.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76664 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-06-04 22:47:28 +00:00
Vadim Zeitlin
b60e0e085e Including missing header for wxUniv/MSW build.
Compilation fix after the changes of r76657, see #16265.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76663 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-06-04 22:47:23 +00:00
Vadim Zeitlin
fb55843f32 Compilation fix to wxMSW tooltip code when not using PCH.
Include the required header when not using PCH.

See #16265.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76662 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-06-04 21:34:17 +00:00
Vadim Zeitlin
35434eea52 Hide tooltip when its associated window is hidden in wxMSW.
Don't leave the tooltip shown on screen if the window it was shown for was
hidden or iconized (without moving the mouse, as that would have dismissed the
tooltip as well).

Closes #16265.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76657 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-06-02 01:15:39 +00:00
Vadim Zeitlin
8f39cd1301 Fix bug with removing items from menus with radio buttons in wxMSW.
Update the indices of the radio groups after removing an item from the menu.

See #14213.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76656 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-06-02 01:15:34 +00:00
Vadim Zeitlin
0ae3d1d22a Use wxWinAPI::Event wrapper class instead of raw Windows event handles.
This makes the code slightly shorter and, more importantly, more readable and
safer.

Closes #16233.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76655 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-06-02 01:15:30 +00:00
Vadim Zeitlin
793b8d519e Ensure that wxPreviewCanvas always gets idle event.
Use wxWS_EX_PROCESS_IDLE flag to ensure that the print preview receives idle
events even when wxIDLE_PROCESS_SPECIFIED global idle mode is used.

Closes #15104.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76652 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-06-02 01:15:16 +00:00
Vadim Zeitlin
40f2cf0a78 Allow access to the currently shown wxInfoBar buttons.
Add wxInfoBar::GetButtonCount(), GetButtonId() and HasButtonId() methods.

Closes #15110.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76651 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-06-02 01:15:11 +00:00
Vadim Zeitlin
1467e6c5df Revert "Correctly detect cancelled drag-and-drop operations in wxGTK."
This reverts r75745 (and r75749 fixing a minor problem in it) as this change
broke the reporting of the result of the drag and drop operation instead of
fixing it.

See #15930.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76649 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-06-02 00:16:13 +00:00
Vadim Zeitlin
24b2e3b720 Don't check for model in wxDataViewCtrl::InsertColumn() in wxOSX.
This isn't done in neither generic nor the GTK versions and prevents from
inserting the columns into the control before associating a model with it.

Closes #16257.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76647 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-06-01 16:46:05 +00:00
Vadim Zeitlin
e74d3e73b4 Relax checking window visibility in wxGLCanvas::SetCurrent().
It is enough for the window to be shown for SetCurrent() to work, it doesn't
have to be actually visible on screen, and checking for this using
IsShownOnScreen() resulted in false positives.

Closes #16193.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76644 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-06-01 16:28:38 +00:00
Vadim Zeitlin
e9b45c0cf4 Don't leak sort descriptors array in wxDataViewCtrl in wxOSX.
wxCocoaOutlineDataSource owns its sortDescriptors field, so it must release it
in its dealloc() (and also initialize it in its init(), no idea how did it
work without this being done before).

Closes #16231.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76642 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-06-01 16:23:28 +00:00
Vadim Zeitlin
bf9598aa21 Fix memory leak when using custom renderers in wxOSX wxDataViewCtrl.
wxDataViewRendererNativeData retains a reference to the cell passed to it, so
the cell must be released after passing it to wxDataViewRendererNativeData to
avoid leaking it.

Closes #16226.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76641 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-06-01 16:23:23 +00:00
Vadim Zeitlin
afae016fca Don't leak wxDataViewCtrl column objects in wxOSX/Cocoa.
NSOutlineView addTableColumn method takes ownership of the column passed to
it, so we must release it ourselves to avoid leaking it.

Closes #16223.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76640 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-06-01 16:23:19 +00:00
Vadim Zeitlin
10b7d587fa Don't recreate the native control in wxOSX wxDataViewCtrl dtor.
Don't call ClearColumns() which recreates the control in order to remove its
columns in wxOSX/Cocoa, just clean up the internal data, the control, and its
columns, will soon be deleted anyhow.

Closes #16210.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76639 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-06-01 16:23:15 +00:00
Vadim Zeitlin
f1f2ec9957 Remove spurious MSVC check around wxDF_HTML code in wxMSW.
For some reason, support for wxDF_HTML in clipboard code was disabled for
non-MSVC compilers. Enable it now as it's not compiler-specific at all.

See #16297.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76633 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-05-31 14:30:45 +00:00
Vadim Zeitlin
ceb39f4174 Allow viewing read-only long string wxPropertyGrid properties values.
When wxLongStringProperty is read-only, it should still be possible to view
its value by opening the dialog normally used for editing it, otherwise this
value cannot be seen (nor copied, which is also useful sometimes) at all.

Closes #14945.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76631 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-05-31 14:21:23 +00:00
Vadim Zeitlin
e5f9b9cfad Return all information from wxListCtrl::GetItem() if no mask specified.
This is more useful than returning nothing and is consistent with the generic
version behaviour.

Closes #3666.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76630 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-05-31 14:21:16 +00:00
Vadim Zeitlin
21fd108d23 Add support for "hint" property in wxTextCtrl XRC handler.
It is convenient to allow specifying the hints directly in the resources.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76629 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-05-30 16:35:58 +00:00
Paul Cornett
60972cc037 Fix X 'BadPixmap' crash in Blit() with mask when GTK+ <= 2.16, closes #16303
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76626 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-05-30 16:29:13 +00:00
Vadim Zeitlin
89d16faf30 Fix cancelling choice of custom colour in wxPropertyGrid.
When using wxPGEditor_Choice colour property, cancelling the choice of the
custom colour reset the previously selected custom colour.

Fix this by correcting the test for the custom colour which didn't work
before.

Closes #15542.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76624 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-05-29 23:48:51 +00:00
Vadim Zeitlin
c7fd48db6b Correct handling of the characters outside of the BMP in wxSTC.
The code mapping positions for the units of the UTF-13/32 string used by
wxWidgets to positions for the units of the UTF-8 string used by Scintilla
didn't work correctly for the characters outside of the BMP, i.e. Unicode code
points >= 0x10000.

See #15621.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76623 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-05-29 23:48:46 +00:00
Vadim Zeitlin
3410aa372f Fix wrong resulting string length in UTF-16 to wchar_t conversion.
Don't optimize the returned length for surrogate-less case, this does save a
pass of the string but at the price of returning a wrong result, which is not
worth it, just compute the really required length exactly.

Closes #16298.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76622 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-05-29 23:48:40 +00:00
Stefan Csomor
28207132ce work around OS X bug, fixes #16292
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76614 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-05-27 21:09:39 +00:00
Paul Cornett
0b92a2083d Fix setting client data when adding items to a sorted wxListBox, broken in r74317
closes #16290


git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76605 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-05-26 07:30:42 +00:00
Paul Cornett
4b6c6a2fbd fix wxStaticText improperly wrapping text when initial size is fully specified, closes #16278
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76602 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-05-24 18:39:56 +00:00
Vadim Zeitlin
d2d7a07b7a Return wxWinVersion_[78] correctly from wxMSW wxGetWinVersion().
This is especially important because the workaround of r76152 for IFileDialog
bug under Windows Vista also applied under later Windows versions as they were
not detected correctly.

Closes #16286.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76600 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-05-22 20:35:50 +00:00
Vadim Zeitlin
494c9c9b0b Avoid showing the colour selection dialog twice in wxPropertyGrid.
Selecting "Custom" in a colour property cell resulted in the colour selection
dialog being shown twice if it was cancelled the first time.

Fix this by using wxPG_PROPERTY_SPECIFIC to indicate that the value is just
being queried and the user shouldn't be asked to enter it, as it is already in
the other places.

Closes #15543.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76597 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-05-22 14:36:00 +00:00
Vadim Zeitlin
d96fd33985 Don't destroy wxFont from its GetFaceName() in wxMSW.
wxFont::GetFaceName() could destroy the HFONT used by the font accidentally,
avoid it by not invalidating the font when caching its face name.

Closes #16273.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76595 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-05-22 14:35:49 +00:00
Václav Slavík
32084ab7ce Fix wxOSX warnings about unused variables.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76581 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-05-19 17:23:06 +00:00
Václav Slavík
7a25cf4932 Don't use the deprecated 'register' storage specifier.
It is not only useless with any modern C++ compiler, but also deprecated
in C++11.  Removing it fixes Clang warnings on the subject.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76580 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-05-19 17:23:02 +00:00
Stefan Csomor
1b3cba17e8 guarding against deleted 'self' during the mouse handler, setting peer ptr to NULL during destruction
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76579 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-05-19 16:58:18 +00:00
Stefan Csomor
cea11b591e in order to get all focus set events, store field in editor and catch becomeFirstResponder there, see #14269
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76578 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-05-18 16:33:57 +00:00
Stefan Csomor
3ba1c7e166 allowing reentrancy on NSPanels makeResponder as in NSWindow, see #14269
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76577 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-05-18 13:59:09 +00:00
Stefan Csomor
e65104f198 refactoring to common code for updating selections, using common focus code, see #14269
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76576 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-05-18 10:46:12 +00:00
Stefan Csomor
2b99f92872 refactoring to common code for focus set and lost events, so that changes can be made a single place, see #14269
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76575 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-05-18 10:44:24 +00:00
Vadim Zeitlin
31b8c29fcd Fix bugs in wxEnumProperty introduced by r76562.
The compilation fixes introduced run-time fixes due to not account for the use
of NULL pointers (which are not accepted as choices cache but are accepted as
choices values, go figure).

Closes #16266.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76569 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-05-18 00:24:13 +00:00
Stefan Csomor
91f25e0bbd using the base class wxHAS_NATIVE_ENABLED_MANAGEMENT in cocoa disabling/enabling child windows, fixes #16232, fixes #15495
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76565 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-05-17 19:14:21 +00:00
Paul Cornett
c13a63a26a Fix wxSystemSettings::GetColour() returning transparent colors with GTK3, closes #16255
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76564 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-05-17 17:34:36 +00:00
Vadim Zeitlin
ebc6161c59 Compilation fixes to wxPropertyGrid after r76558.
We can't use _() in the static wxChar* arrays: first, because this doesn't
compile and second because if it did compile, it still wouldn't work as no
message catalogs are loaded yet when the static arrays are initialized.

Use wxTRANSLATE() instead and arrange for the strings to be translated when
they are really used. This is rather ugly and perhaps it would be better to
avoid passing untranslated labels array to the property classes but at least
the code compiles again now.

See #16266.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76562 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-05-17 13:41:27 +00:00
Vadim Zeitlin
0d54910b43 Don't use X11-only GDK functions in wxGTK/Win32 build.
Add GDK_WINDOWING_X11 checks to allow compiling wxGTK display code under
Win32.

Closes #16270.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76561 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-05-17 12:29:54 +00:00
Vadim Zeitlin
da4ca22383 Use non-deprecated pen and brush style constants in wxOSX code.
Use wx{PEN,BRUSH}STYLE_{SOLID,TRANSPARENT} instead of the old
wx{SOLID,TRANSPARENT}.

Closes #16269.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76560 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-05-17 12:29:41 +00:00
Vadim Zeitlin
401957aba6 Make names of properties used in wxPropertyGrid translatable.
Use _() around these user-visible strings, not wxT().

Closes #16266.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76558 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-05-17 12:29:31 +00:00
Vadim Zeitlin
d94e807cfc Fix querying the value of wxEnumProperty in wxPropertyGridEditor.
Doing this changed the internal state of the control and resulted in the
choice not being updated.

Fix this by using wxPG_PROPERTY_SPECIFIC.

Closes #15449.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76557 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-05-17 12:29:26 +00:00
Vadim Zeitlin
a380c1e46f Add public wxDegToRad() and wxRadToDeg() functions.
Define these functions just once in wx/math.h instead of duplicating them in a
dozen of places.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76555 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-05-17 12:29:15 +00:00
Vadim Zeitlin
e9f4d80887 Remove checks for ancient gcc/MinGW versions.
Don't test for wxUSE_NORLANDER_HEADERS, this is always true since many, many
years.

Remove tests for gcc version < 3.3, notably 2.95: the minimal supported gcc
version is 3.4.

Closes #15727.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76549 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-05-16 13:01:35 +00:00
Vadim Zeitlin
8c7d31e615 Remove obsolete MSVC version tests.
Don't compare __VISUALC__ with versions 1200 (VC6) and earlier, such tests are
always true or always false now that we don't support VC6 any more, so just
remove them simplifying the code.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76548 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-05-16 13:01:29 +00:00
Vadim Zeitlin
15f255cebb Remove support for Digital Mars compiler.
This compilers is not being developed any longer since many years, drop
support for it.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76547 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-05-16 13:01:23 +00:00
Vadim Zeitlin
49b8d79c87 Remove (Open)Watcom support.
This compiler is not being developed since several years and almost certainly
can't be used to build the current wxWidgets sources anyhow, so remove all
support for it, including a lot of extremely ugly workarounds for its bugs
with template functions.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76546 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-05-16 13:01:06 +00:00
Vadim Zeitlin
36666a975f Add default argument for the overridden base class Connect() in wxHTTP.
This allows to call Connect(wxIPV4address) on a wxHTTP object, without
having to explicitly specify the second argument (this was documented as being
a Watcom-specific problem, but actually it wasn't).

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76545 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-05-16 13:00:32 +00:00
Vadim Zeitlin
6e738c167d Fix image resolution options setting in wxBMPHandler code.
This was broken by the changes of r76144 as the resolution information read
from the bitmap was never used due to a typo in Resolution::Init().

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76538 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-05-16 09:59:07 +00:00
Vadim Zeitlin
6b8ad8489b Work around bogus "use of possibly uninitialized variable" warning.
Resolution::m_x and m_y were always initialized before use but g++ 4.2 still
complained about them being possibly not initialized, so do initialize them.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76537 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-05-16 09:59:03 +00:00
Vadim Zeitlin
c6f102e1a4 Remove unused variables to avoid compilation warnings.
Don't call CFGetRetainCount() unnecessarily.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76536 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-05-16 09:59:00 +00:00
Vadim Zeitlin
0d4ad161d5 Remove support for Win9x from wxMSW.
Most importantly, this allows us to remove all MSLU-related stuff.

Some functions which were previously loaded dynamically can now be just used
directly, too.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76535 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-05-16 02:33:40 +00:00
Vadim Zeitlin
01f9accd19 Remove wxPM, wxWidgets port to OS/2.
This port is not used and is not being worked on, so remove it to reduce the
amount of the code which needs to be updated for every global change.

Also remove tests for VisualAge compiler which isn't used since ages.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76533 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-05-15 23:56:58 +00:00
Vadim Zeitlin
f4b80e5337 Remove MSVC6 support.
Don't support this compiler any more, this allows to get rid of tons of
MSVC6-specific workarounds, in particular we can now use Bind() and natural
template functions calls in the library code.

Also remove MSVC6 project and solution files and don't generate them when
bakefile_gen is ran any more (removing the remaining occurrences of msvc6prj
from the bakefiles results in weird bake-time errors, so it's simpler to just
leave them there).

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76532 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-05-15 22:32:17 +00:00
Vadim Zeitlin
28f9670787 Use wxMemorySize type in Unix implementation of wxGetFreeMemory().
This should avoid overflows on 32 bit systems with more than 2GB of RAM.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76531 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-05-14 12:40:24 +00:00
Vadim Zeitlin
390c0e19c9 Check result of fgets() and sscanf() in wxGetFreeMemory().
This fixes g++ -Wunused-result warnings and also actually makes the code more
robust.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76530 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-05-14 12:40:21 +00:00
Stefan Csomor
f90f4c27ea support for enable/disable and capitalization in ios
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76525 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-05-13 20:48:46 +00:00
Stefan Csomor
6511cb8c5f fixing compile in case of absent wxSpinCtrl
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76523 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-05-13 20:03:00 +00:00
Stefan Csomor
750ca509ac order than the current OnInit handling for cocoa and carbon we still have to use the native callback for ios
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76522 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-05-13 20:02:22 +00:00
Stefan Csomor
705f6c1c8b allowing compile under ios, where menus are not available
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76521 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-05-13 19:55:12 +00:00
Stefan Csomor
2497099aaa fixing compile under ios
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76520 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-05-13 19:54:01 +00:00
Vadim Zeitlin
0b1a181c23 Fix print preview in 64 bit MinGW wxMSW builds.
Don't hardcode wrong PRINTDLG structure size for 64 bit builds.

In fact, don't hardcode it at all as it just doesn't seem to be necessary to
do it, the comment about Cygwin getting it wrong seems to be out of date.

Closes #16256.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76508 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-05-12 13:14:42 +00:00
Vadim Zeitlin
3c656a46ec Fix cast from "void*" to integer type in wxThread::Exit() for non-MSVC.
This fixes another problem in 64 bit Cygwin build.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76507 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-05-12 13:14:39 +00:00
Vadim Zeitlin
5c0bcb7412 Use DWORD instead of unsigned long in wxFileSystemWatcher wxMSW code.
These two types are not the same in 64 bit Cygwin builds, so fix the build by
just using DWORD everywhere.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76506 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-05-12 13:14:36 +00:00
Vadim Zeitlin
8c26773f2f Don't use _{get,ch}drive() functions in Cygwin builds.
They are not available there when not using MinGW headers, e.g. in 64 bit
builds.

Also simplify the code by using wxHAS_DRIVE_FUNCTIONS instead of complicated
(and sometimes negated) checks for MinGW32 version.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76504 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-05-12 13:14:30 +00:00
Vadim Zeitlin
933c86960d Don't use LCID and WXLCID interchangeably in wxMSW code.
Similarly to the problem with WXDWORD and DWORD, LCID is actually an unsigned
int and not unsigned long in 64 bit Cygwin builds, so it's a different type.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76503 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-05-12 13:14:27 +00:00
Vadim Zeitlin
8b7398889d Add casts from long to LONG to fix 64 bit Cygwin wxMSW build.
In 64 bits, LONG is actually defined as int in Cygwin gcc headers, so is
different from long -- even if both types use identical representation.

Just add the casts to fix this for now, as this is the smallest ABI-preserving
change. Ideally, something better and less ugly would need to be done in the
future.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76502 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-05-12 13:14:24 +00:00
Vadim Zeitlin
f825884f74 Don't use DWORD and WXDWORD interchangeably in wxMSW code.
WXDWORD is defined as unsigned long, while DWORD is defined as unsigned int in
64 bit builds using Cygwin gcc, so they are not the same type (although they
do have the same size) and using the latter instead of the former in the
function definition results in errors in this build configuration.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76501 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-05-12 13:14:20 +00:00
Vadim Zeitlin
dbbe0811c7 Use __WIN64__ instead of MSVC-specific _WIN64 in wxIsPlatform64Bit().
Make the code work correctly for 64 bit builds with other compilers, e.g. gcc.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76499 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-05-12 13:14:14 +00:00
Dimitri Schoolwerth
8848bb8369 Fixed code checking for bit flags.
Use "flag & bitmask" instead of "flag && bitmask" (resulted in LLVM compiler warning: "Use of logical '&&' with constant operand").

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76497 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-05-11 23:16:56 +00:00
Dimitri Schoolwerth
6451d23158 Added support for using OS X' full screen API (available since OS X 10.7).
Added EnableFullScreenView() to have a full screen button in the title bar and also allowing ShowFullScreen() to make use of the newer full screen API.

See #14357.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76495 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-05-11 22:41:13 +00:00
Vadim Zeitlin
1558349361 Improve RTL support in wxStyledTextCtrl.
Use the correct HDC, inheriting the right text orientation, when creating
wxMemoryDC in SurfaceImpl code.

There may still be problems with the actual RTL languages, but at the very
least English text displayed in RTL locale is not mirrored any more.

Closes #16230.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76493 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-05-10 16:16:01 +00:00
Vadim Zeitlin
021bd17d49 Fix crash in generic wxDataViewCtrl::AssociateModel(NULL).
Don't use the possibly dangling pointer.

Closes #16249.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76491 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-05-10 16:15:52 +00:00
Vadim Zeitlin
d53f93f607 Fix wxRichTextCtrl code compilation with wxUSE_XML==0.
Add missing wxUSE_XML checks.

Closes #16251.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76490 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-05-10 16:15:46 +00:00
Vadim Zeitlin
47138ac8fa Add wxStyledTextCtrl copy/paste text events.
Add wxEVT_STC_CLIPBOARD_{COPY,PASTE} events, allowing to transform the text
being copied from or pasted into wxStyledTextCtrl.

Closes #16191.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76487 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-05-08 14:43:45 +00:00
Vadim Zeitlin
0acb665006 Remove wxStyledTextEvent::m_text and m_dragText.
These fields were unnecessary and duplicated m_cmdString inherited from the
base class.

Also use base class GetString() instead of the redundant GetText() and
GetDragText() in the code, even though these methods are still kept for
backwards compatibility.

See #16191.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76486 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-05-08 14:43:38 +00:00
Vadim Zeitlin
e532b3f234 Fix harmless warning about using wxCONTROL_CHECKED in ternary operator.
Add wxCONTROL_NONE which is just a symbolic name for 0 and use it in the code
to avoid g++ 4.8 warnings about mixing enum and int in conditional expression.

Closes #16242.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76484 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-05-08 14:43:27 +00:00
Vadim Zeitlin
9ccfe76e43 Compilation fix for PCH-less build of wxMSW.
Include wx/msw/ownerdrawnbutton.h usually included via wx/checkbox.h from the
PCH.

Closes #16241.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76483 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-05-08 14:43:21 +00:00
Vadim Zeitlin
baf28b5fe3 Make wxGetPangoContext() work even without open display.
Use default Pango font map if we don't have any default screen in wxGTK.

Closes #16240.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76482 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-05-07 15:24:50 +00:00
Vadim Zeitlin
5b56498f88 Allow using sizers for laying out wxMDIClientWindow in wxMSW.
Let the user code put wxMDIParentFrame::GetClientWindow() into a sizer and
manage it as any other window, instead of having to do it manually.

Closes #16196.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76473 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-05-06 18:20:38 +00:00
Vadim Zeitlin
dd59bdf40b Define BS_TYPEMASK for the compilers which don't have it.
Fixes compilation with MinGW after wxMSWOwnerDrawnButton introduction.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76466 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-05-06 11:44:07 +00:00
Paul Cornett
a0f10ec1d6 Implement access to a global toplevel GdkWindow in a way that does not require always having an extra GtkWindow.
And don't use "RootWindow" in the name, it is not a root window in the X11 sense.
Also add wxGetPangoContext() to get access to a PangoContext.


git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76465 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-05-05 15:53:27 +00:00
Vadim Zeitlin
70387b4857 Fix wxMSW owner drawn buttons appearance in "selected" state.
Draw the buttons (i.e. checkboxes and radio buttons) correctly when the space
key is pressed.

See #10137.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76464 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-05-05 14:47:45 +00:00
Vadim Zeitlin
06292da40f Add a TODO comment to wxGTK wxToolBar::FindToolForPosition().
Replace the out of date comment saying that GTK+ doesn't have a function to do
this with a TODO comment mentioning the name of the function which should be
used here.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76463 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-05-05 14:42:40 +00:00
Vadim Zeitlin
8a245f0ec3 Fix handling of multiple and rectangular selections in wxSTC.
Copy and paste rectangular selections in the standard format, this is
especially important under Windows where a (de facto) standard clipboard
format for such selections exists.

Also fix handling of multipaste, i.e. pasting clipboard contents into several
locations at once.

Closes #16221.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76462 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-05-05 14:42:35 +00:00
Vadim Zeitlin
29ff6f3e3b Fix resetting owner drawn radio buttons to normal state.
Ensure that we bring the native button in sync with the real state of the
radio button when we switch to normal state.

Also avoid using BM_GETCHECK for the owner drawn buttons as we don't use
BM_SETCHECK for them (as it's useless).

See #10137.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76460 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-05-04 22:13:39 +00:00
Vadim Zeitlin
cc73050b73 Factor out common owner drawn code from wx{Check,Radio}Box.
Create wxMSWOwnerDrawnButton class which contains all of this code.

Currently the methods of this class are (still) implemented in
src/msw/control.cpp.

See #10137.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76459 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-05-04 22:13:28 +00:00
Vadim Zeitlin
f1be272d32 Fix pressed owner-drawn checkbox appearance in wxMSW.
Handle the "pressed" state correctly in wxCheckBox::MSWOnDraw().

See #10137.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76458 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-05-04 22:13:22 +00:00
Vadim Zeitlin
81b931f8d1 Fix the size of owner-drawn checkbox and radiobuttons under Vista and later.
The size of the native buttons has changed between XP and Vista, so add
version check to draw the buttons of correct size under all Windows versions.

See #10137.

REBASE: squash with aa5d7c5 Fix the size of owner-drawn check and radio boxes under Vista and later.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76457 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-05-04 22:13:17 +00:00
Vadim Zeitlin
fd65d4b4f5 Implement setting foreground colour for wxRadioButton in wxMSW.
Native radio buttons don't support changing their foreground colour, so use
owner drawn buttons if SetForegroundColour() was called, similarly to what was
already done for wxCheckBox.

Closes #10137.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76456 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-05-04 22:13:12 +00:00
Vadim Zeitlin
3fc6738025 Refactor owner drawn buttons drawing code in wxMSW.
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
2014-05-04 22:13:07 +00:00
Vadim Zeitlin
34d3e680c8 Use wxArrayInt methods instead of duplicating them.
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
2014-05-04 22:13:02 +00:00
Vadim Zeitlin
c03557f0be Fix position of the column after drag-move operation in wxGrid.
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
2014-05-04 22:12:57 +00:00
Vadim Zeitlin
50fe1fadc2 Fix changing column order in wxGrid when some columns are hidden.
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
2014-05-04 22:12:47 +00:00
Vadim Zeitlin
2e8988c3d6 Add wxGridCellRenderer::GetBest{Height,Width}() and use them in wxGrid.
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
2014-05-04 22:12:42 +00:00
Vadim Zeitlin
07427c4fbd Fix busy cursor handling in modal dialogs under MSW.
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
2014-05-04 22:12:32 +00:00
Vadim Zeitlin
51871b7b5a Reset icon ref count when deleting the icon in wxMSW balloon icons code.
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
2014-05-04 22:12:05 +00:00
Paul Cornett
2eb7668968 build fix for systems lacking vswscanf when wxUSE_UNICODE==0
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76441 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-05-03 16:31:41 +00:00
Julian Smart
5b8e5e81b6 Implemented keyboard selection and better cell navigation for tables
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76440 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-05-03 13:07:16 +00:00
Vadim Zeitlin
eeccbf98f4 Don't crash when dismissing expanded ribbon panel.
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
2014-05-02 14:19:48 +00:00
Paul Cornett
605e637f47 send changed event when selecting a special directory from wxDirPickerCtrl combobox
closes #16064


git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76436 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-05-01 16:57:50 +00:00
Vadim Zeitlin
2fbda42aed Fix wxGetClientDisplayRect() when _NET_WORKAREA is not supported.
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
2014-04-30 14:11:01 +00:00
Stefan Csomor
617e17b746 supporting alpha channel correctly from clipboard, closes #16198
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76431 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-30 06:59:42 +00:00
Stefan Csomor
012ccdf8a5 adding support for multi-line text in rotated text, fixes #16216
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76428 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-29 18:22:54 +00:00
Stefan Csomor
337454f387 fix memory leak for initial empty menubar, see #15666
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76426 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-29 14:18:30 +00:00
Vadim Zeitlin
07ff314c13 Make "Close" button affirmative ID in standard dialog button sizer.
This allows to use the Escape key to close a dialog with the "Close" button
only.

Closes #16185.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76422 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-28 11:28:35 +00:00
Vadim Zeitlin
d75eb338c2 Fix precision in wxGraphicsContext::{Stroke,Draw}Lines() under MSW.
Use floating point coordinates instead of ints which were used for some
reason, resulting in a loss of precision.

Closes #16187.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76420 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-27 22:42:04 +00:00
Vadim Zeitlin
ccaebf6520 Add wxThread::MSWGetHandle().
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
2014-04-27 22:41:50 +00:00
Vadim Zeitlin
2b7c7464ad Fix wrong wxStatusBar height in wxMSW in some circumstances.
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
2014-04-27 22:41:45 +00:00
Vadim Zeitlin
cbe6495307 Allow dropping data outside of item area in wxDataViewCtrl.
Implement this change for the generic and the native GTK versions and document
it.

Closes #16152.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76416 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-27 22:41:40 +00:00
Vadim Zeitlin
555e57912e Bring wxMSW wxBitmap::SetBitmapXXX(wxBitmap()) in line with wxGTK.
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
2014-04-27 22:40:05 +00:00
Vadim Zeitlin
ec112197f2 Micro optimization of checking for alpha transparency.
Use faster accessors to the image size.

Closes #16148.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76414 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-27 22:39:59 +00:00
Vadim Zeitlin
2e079a988d Make wxMSW wxTextCtrl::AdjustSpaceLimit() safe to call in all cases.
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
2014-04-27 22:39:54 +00:00
Vadim Zeitlin
934ce46464 Don't call AdjustSpaceLimit() explicitly in wxMSW wxTextCtrl any more.
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
2014-04-27 22:39:49 +00:00
Vadim Zeitlin
6700ea5ad2 Fix warning about using "deprecated" close() in MSVC build.
Use wxClose(), which is the same as _close() for MSVC.

Closes #16212.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76411 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-27 22:39:43 +00:00
Vadim Zeitlin
acf6264309 Get rid of deprecated warnings for ::GetVersionEx().
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
2014-04-27 22:39:37 +00:00
Vadim Zeitlin
2964de72a5 Don't duplicate wxGetOsVersion() in wxMSW wxGUIAppTraits.
Just call wxGetOsVersion() instead of using the Windows ::GetVersionEx()
function directly.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76408 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-27 22:39:34 +00:00
Vadim Zeitlin
761e0c12a0 Remove Windows version check from wxMBConv_win32.
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
2014-04-27 22:39:28 +00:00
Stefan Csomor
f18d7097da adding wxFALLTHROUGH where until now we had comments, allows for code-analysis support
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76399 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-26 17:36:32 +00:00
Paul Cornett
6c6362401c Delay GtkIMContext calls until widget is realized.
This may avoid a locking bug seen on Ubuntu which causes a deadlock.
See #16202


git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76398 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-26 17:11:31 +00:00
Dimitri Schoolwerth
37ba576b4a Fixed wxFileDialog::MSWOnInitDone and wxFileDialog::MSWOnSelChange never being called.
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
2014-04-24 23:25:10 +00:00
Stefan Csomor
4360902f4e in order to get rid of the warnings completely use the former font descriptor creation sequence and cache the result immediately, fixes #15999
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76393 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-23 13:40:18 +00:00
Stefan Csomor
60578d63f4 add our own Apple Event handler for the quit app event, fixes #16200
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76392 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-22 21:21:19 +00:00
Stefan Csomor
fe49efa19a The Human Interface Guidelines recommend using NSSmallSquareBezelStyle now
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76391 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-22 18:20:54 +00:00
Julian Smart
90143c254c Added wxRichTextCtrl::DoLayoutBuffer so an application can perform custom tasks before or after layout.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76390 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-22 16:27:29 +00:00
Julian Smart
1a16259223 Draw an unknown field using a fallback field type, so it's not invisible.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76389 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-22 16:25:48 +00:00
Julian Smart
871a1976b2 Don't Sync() if there is no buffer. This allows derived classes that handle the buffer differently (e.g. reuse the buffer).
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76386 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-22 16:23:53 +00:00
Vadim Zeitlin
7ab7ff693b Add wxGraphicsRenderer::GetName() and GetVersion() methods.
Allow the code to determine which underlying technology is used for
implementing wxGraphics API. This is needed by the unit tests to account for
the known differences between platforms and may be useful in other cases.

Closes #16154.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76380 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-20 12:45:10 +00:00
Paul Cornett
b61a4acd0f fix building or running on GTK < 2.14 after r76365
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76367 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-18 02:30:51 +00:00
Paul Cornett
0e212a65eb Add a separate GTK-specific wxDisplay implementation.
This separates the GTK implementation from Unix/X11, except for the wxVideoMode
stuff, and _NET_WORKAREA when GTK < 3.4. wxDisplay and wxClientDisplayRect()
should now work as well as they can with Wayland.


git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76365 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-17 17:36:10 +00:00
Paul Cornett
0021653f7e use correct signature for callback
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76363 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-17 15:21:42 +00:00
Paul Cornett
f8b4d39e0f use a prefix match for interactive search
having to type in the whole string to get a match is worthless


git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76362 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-17 06:22:14 +00:00
Paul Cornett
c60cef10bc Avoid assertion failure when GtkTreeView interactive search is started.
The treeview does an unselect_all causing a "changed" signal with no selection.
The problem is easily triggered by pressing Ctrl-F (the "start-interactive-search" key binding)


git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76361 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-17 06:09:09 +00:00
Václav Slavík
e81c3f87e3 Initialize wxFileDialog::m_filter{Panel,Choice} in ctor.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76358 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-16 16:41:04 +00:00
Paul Cornett
5fa3e7866e don't use Cairo functions when wxUSE_CAIRO==0
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76353 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-15 17:23:59 +00:00
Paul Cornett
a467105b1e wxASSERT(false) --> wxFAIL
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76352 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-15 16:16:58 +00:00
Paul Cornett
ceae28f3f0 initialize members in ctor, avoid int-to-bool warnings
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76351 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-15 16:16:38 +00:00
Paul Cornett
33995579d0 avoid unused variable warning with wxUSE_VALIDATORS==0
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76350 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-15 16:16:22 +00:00
Paul Cornett
07b1a1d6a0 use gtk_window_set_opacity() in SetTransparent() when GTK >= 2.12
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76349 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-15 16:07:44 +00:00
Paul Cornett
dc9ace761f fix wxClientDisplayRect() when wxUSE_DISPLAY==0
GDK_WINDOWING_X11 was not getting defined, causing hard coded size to be used


git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76348 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-15 15:46:47 +00:00
Vadim Zeitlin
1ccbf7f0c3 Use wxWS_EX_VALIDATE_RECURSIVELY in native Cocoa wxPreferencesEditor too.
Transfer data recursively for consistency with the generic implementation and
because this generally just makes more sense.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76328 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-13 22:07:38 +00:00
Vadim Zeitlin
ba4d3d31a6 Add error handling to wxSound under wxOSX.
Don't assume that we can open any file as a sound, check for the return value
from AudioServicesCreateSystemSoundID().

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76325 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-12 22:56:21 +00:00
Vadim Zeitlin
5276dfa416 Don't use timer inside wxSound in wxOSX/Cocoa.
The timer is only used by Carbon code, there is no need for it in Cocoa, so
don't complicate things by starting it unnecessarily.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76324 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-12 22:56:17 +00:00
Vadim Zeitlin
48b21dee76 Fix crash when playing invalid sounds under wxOSX.
Sound ID 0 is not actually invalid, it is returned by
AudioServicesCreateSystemSoundID() when it fails to open the file and
currently we don't consider this to be an error. However, because we never
called AudioServicesDisposeSystemSoundID() for this sound ID, we continued to
receive the notifications from the callback registered by
AudioServicesAddSystemSoundCompletion() for it even after the corresponding
sound object was destroyed, resulting in crashes when playing it more than
once.

Fix this by keeping a separate flag indicating whether we're playing a sound
and always disposing of the sound if we are, even if ID is 0.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76323 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-12 22:56:13 +00:00
Vadim Zeitlin
719f6df326 Call wxDataViewRenderer::Validate() under OS X too.
Ensure that the custom renderers get a chance to validate (and maybe change)
the value entered by user, as previously it was completely impossible with the
native OS X implementation of wxDataViewCtrl.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76322 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-12 22:56:10 +00:00
Vadim Zeitlin
bf00e40c4b Compilation fix for MinGW in GDI+ code.
Don't use the XXXModeInvalid constants which are missing from MinGW headers
for some reason.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76317 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-12 00:11:02 +00:00
Paul Cornett
c6f8d54324 build fix for wxUSE_VALIDATORS==0
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76313 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-11 15:53:41 +00:00
Paul Cornett
680f50f471 build fix for wxUSE_TOGGLEBTN==0
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76311 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-11 04:48:57 +00:00
Paul Cornett
3dcb256bea build fix for wxUSE_DRAG_AND_DROP==0
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76310 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-11 04:48:37 +00:00
Paul Cornett
c1d1a5ad5e build fix for wxUSE_THREADS==0
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76309 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-11 04:48:12 +00:00
Paul Cornett
f2e5faeb0a fix invisible multi-line wxTextCtrl selection when custom foreground/background color is used with GTK3
closes #16176


git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76308 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-10 15:57:28 +00:00
Paul Cornett
79b8852011 fix invisible wxTextCtrl selection when custom foreground/background color is used with GTK3
closes #16176


git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76307 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-09 04:41:33 +00:00
Vadim Zeitlin
fc014a6f19 Don't set wxINTERPOLATION_GOOD quality by default in wxGDIPlusContext.
This is inconsistent with wxOSX and also doesn't play well with the existence
of wxINTERPOLATION_DEFAULT which is different from wxINTERPOLATION_GOOD.

See #14134.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76305 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-08 21:38:09 +00:00
Stefan Csomor
8ecd1a8b95 fixes #16169
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76302 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-08 09:14:11 +00:00
Vadim Zeitlin
275bc1fe6d Remove "default" clause from enums in wxGDIPlusContext code.
This will allow the compiler to give us a warning if more elements are added
to the enum later but not added to the switch.

Also add error checking to Graphics::SetSmoothingMode() call.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76301 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-07 20:34:45 +00:00
Vadim Zeitlin
38de6a5231 Fix mismatch between GDI+ and wxGraphicsContext interpolation quality.
Use wxGDIPlusContext own method instead of using GDI+ method directly when
setting the interpolation mode in wxGDIPlusContext initialization code to
ensure that m_interpolation field matches the real interpolation mode used.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76300 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-07 20:34:41 +00:00
Vadim Zeitlin
6bdf5d357d Initialize wxGraphicsContext::m_interpolation field.
This member wwas never initialized, resulting in erratic behaviour of
SetInterpolationQuality() which compared its parameter with m_interpolation.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76299 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-07 20:34:37 +00:00
Julian Smart
9b8b5b085d Object position calculation correction
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76294 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-07 16:23:05 +00:00
Paul Cornett
75297d8842 avoid warnings about double-to-float conversion
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76293 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-06 19:33:26 +00:00
Paul Cornett
23aa1404be avoid warning about shadowed variable
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76292 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-06 19:30:22 +00:00
Paul Cornett
f771a15d9e cast to proper type to avoid warning
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76291 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-06 19:28:50 +00:00
Paul Cornett
d86715a3a3 remove unused macro definition
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76290 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-06 19:27:58 +00:00
Paul Cornett
e003c663fd avoid warning about unreachable code
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76289 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-06 19:27:31 +00:00
Vadim Zeitlin
7238d2761f Don't use %i format specifier for size_t values.
In 64 bit build, size_t can be 64 bits while %i expects a 32 bit value.
Fix this by just avoiding the unnecessary use of size_t, the number of entries
in the index is not going to be greater than 2^32.

Closes #16163.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76287 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-05 10:44:54 +00:00
Vadim Zeitlin
eed86ca61a Fix warning about %lu being used with an int in 32 bit wxOSX build.
NSUInteger is unsigned long in 64 bit builds, but unsigned int in 32 bits, so
case it to long explicitly to avoid warnings about using it with %lu format
specifier.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76286 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-05 10:44:51 +00:00
Vadim Zeitlin
337afc2471 Remove unused variables from wxRichTextListStylePage code.
This avoids warnings about them.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76283 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-04 18:32:31 +00:00
Paul Cornett
ab9f9bc492 avoid preprocessor directives inside macro invocation
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76282 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-04 16:55:28 +00:00
Paul Cornett
70b7d04f0b remove unused member functions
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76281 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-04 16:46:00 +00:00
Paul Cornett
9b41d18b25 remove unused macro definitions
and limit others to the configurations which use them

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76280 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-04 16:44:30 +00:00
Paul Cornett
010e897e48 assertion messages don't need to be translated
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76279 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-04 16:00:03 +00:00
Paul Cornett
ba962b00cb remove redundant assertion messages, wxLogError has already been called
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76278 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-04 15:56:29 +00:00
Vadim Zeitlin
4c76ae6707 Add more precise wxRibbonBar::ShowPanels() overload.
The existing overload taking bool didn't allow to specify whether the panel
should be just expanded or expanded and pinned, add a new one supporting this.

Also fix a bug with not updating the ribbon state in the old method.

Closes #16133.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76277 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-04 15:28:51 +00:00
Paul Cornett
e83f66259e fix typo in size 2530 --> 3530
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76273 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-04 15:26:09 +00:00
Paul Cornett
87bb3c9c4f fix some asserts that were clearly meant to be wxFAIL_MSG
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76272 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-04 15:09:15 +00:00
Paul Cornett
8009bf50ae fix more memory leaks
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76271 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-04 06:45:27 +00:00
Paul Cornett
cfe6604d5d fix missing semicolon typo
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76269 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-04 06:36:59 +00:00
Paul Cornett
15dd9e117c Improve conversion between wxPaperSize and GtkPaperSize
by using a table to map the screwy Windows DMPAPER_* stuff, which wxWidgets stupidly uses.
Eliminates many "Gtk-WARNING **: Unknown paper size", and the occasional
"GLib-GObject-CRITICAL **: g_object_unref: assertion `G_IS_OBJECT (object)' failed".
And fixes approximately one zillion memory leaks.


git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76268 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-04 06:05:23 +00:00
Julian Smart
fcec1f4e02 Removed unnecessary list renumbering
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76265 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-03 13:53:42 +00:00
Vadim Zeitlin
ec679be512 Fix return value of wxRichMessageDialog with only an "OK" button.
Apply the same workaround as was applied in r67771 to wxMessageDialog to
wxRichMessageDialog and map IDCANCEL returned from it to IDOK if "Cancel" is
the only button in the dialog -- as in this case it's really just a renamed
(for convenience of allowing the user to use "Esc" to close it) "OK".

Closes #16153.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76257 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-02 22:39:09 +00:00
Paul Cornett
0da8eb2786 Fix invalid use of g_object_get_property()
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76252 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-01 17:45:01 +00:00
Vadim Zeitlin
0930541da9 Fix recently introduced assert when using owner drawn items in wxMSW.
Relax the check added in r76202, the item might not be added to its parent
menu yet even if the menu is not NULL.

See #13878.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76251 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-01 12:46:52 +00:00
Jouk Jansen
cb9a769aad Update OpenVMS compile support
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76250 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-01 09:02:42 +00:00
Jouk Jansen
225daa32d7 OpenVMS (Alpha only) uses != operator in std::find ->needs operator defenition
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76249 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-04-01 08:56:05 +00:00
Julian Smart
9ab80ed818 Use style sheet when copying to the clipboard if available
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76243 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-03-31 16:11:08 +00:00
Stefan Csomor
174faa04aa single wxFALLTHROUGH change to test different builds
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76242 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-03-31 15:47:20 +00:00
Stefan Csomor
8f7ca8a4a7 fixing parameter type
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76241 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-03-31 15:46:53 +00:00
Stefan Csomor
2c2bfbfa4d fixing extra semicolon
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76240 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-03-31 15:46:24 +00:00
Stefan Csomor
a20a842791 getting rid of clang warning due to variable size array
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76239 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-03-31 15:46:05 +00:00
Stefan Csomor
e4350cf2b9 silencing paranoid analyzer
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76238 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-03-31 15:45:26 +00:00
Stefan Csomor
17c7a92386 fixing include style
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76237 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-03-31 15:44:56 +00:00
Stefan Csomor
4399637c4c adding correct return type
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76234 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-03-31 12:34:48 +00:00
Stefan Csomor
1b32b97966 adding minimal ios support for webview
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76232 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-03-31 07:55:36 +00:00
Stefan Csomor
b7b24349e1 removing extra semicola
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76231 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-03-31 07:28:10 +00:00
Stefan Csomor
bd2ce32ca4 removing unnecessary header
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76229 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-03-31 06:15:18 +00:00
Stefan Csomor
ebd4460c42 fixing extra semicola
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76228 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-03-31 06:02:58 +00:00
Paul Cornett
f65efb1e26 use wxDialog::ShowModal() rather than gtk_dialog_run()
so all the things wxDialog::ShowModal() does are not bypassed


git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76227 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-03-31 02:16:01 +00:00
Paul Cornett
8e52f498c5 Prevent dialog widget from being destroyed during ShowModal()
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76226 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-03-30 19:23:07 +00:00
Stefan Csomor
ba0337764d adding empty base class implementation for OnNextIteration, call from OSXDoRun, allowing console event loop to override
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76223 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-03-30 11:46:59 +00:00
Paul Cornett
08a02f640a adjust size hints when decor size changes, to prevent changing a set client size during initial show
closes #15794


git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76221 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-03-30 01:52:11 +00:00
Paul Cornett
8b4ae731d3 use wxOVERRIDE
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76220 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-03-30 00:02:23 +00:00
Vadim Zeitlin
ddd7ce624a Avoid overflows when calculating metafile coordinates in wxMSW.
Use MulDiv() instead of naive multiplication followed by division as this
could overflow, and did when large paper sizes were used in print preview.

Closes #16138.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76219 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-03-29 16:53:57 +00:00
Vadim Zeitlin
9a5d02f2c3 Another PrepareForItem()-related fix in generic wxDataViewCtrl.
This fix is similar to the previous commit but more speculative, as we
currently don't have a bug scenario for it. Still, it seems to be wrong to
call PrepareForItem() just before GetLineStart() which undoes its effect, so
exchange the order of the calls.

See #16132.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76218 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-03-29 16:53:51 +00:00
Vadim Zeitlin
607e950899 Fix clicking on activatable toggle column in generic wxDataViewCtrl.
Call PrepareForItem() after calling GetLineStart() as the latter calls
PrepareForItem() for other items internally, undoing the effects of the first
call.

Closes #16132.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76217 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-03-29 16:53:46 +00:00
Vadim Zeitlin
c51d3e8f04 Fix use of expander in non left most position in wxDataViewCtrl.
Correct the expander rectangle definition to work when the expander column
left boundary is not 0, i.e. if the expander column is not the left most one.

Closes #16131.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76216 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-03-29 16:53:40 +00:00
Vadim Zeitlin
68a483a340 Simplify wxMSW wxToolBar controls support implementation.
Rely on being able to set the separator size, which is supported since
comctl32.dll v4.71 (the version distributed with IE 4.0...).

This allows to remove big chunks of code dealing with multiple separators and
simplifies the rest.

Closes #16129.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76215 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-03-29 16:53:34 +00:00
Václav Slavík
f8e96589d9 Don't emit wxEVT_TEXT in wxMSW's wxTextCtrl::SetFont().
Native text control sends EN_CHANGE when the font changes, producing a
wxEVT_TEXT event as if the user changed the value. This is not the case,
so supress the event.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76210 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-03-29 13:06:40 +00:00
Václav Slavík
dab101876e OS X: fix wxFileDialog::SetupExtraControls()'s sandbox test.
OS X 10.9 (possibly earlier) don't have nil contentView in NSSavePanel
anymore, a NSRemoteView instance is used. The wx code that follows this
test still crashes under sandbox, though, so update the check to use the
APP_SANDBOX_CONTAINER_ID environment variable, which is only set when
running under the sandbox.

This is just another quick fix for the existing uncomfortably long-lived
sandbox crash hotfix, not a proper solution.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76206 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-03-29 13:02:25 +00:00
Vadim Zeitlin
da319a87cd Make wxMSW owner drawn menu item code more clear and correct.
The user-visible effect of this change is that removing the item from the menu
and adding it back doesn't lose its icon any more.

At the code level, wxMenuItem::SetBitmaps() and related methods are
implemented outside of "#if wxUSE_OWNER_DRAWN" which allows to use them even
in minimalistic library builds. And IsOwnerDrawn() is not used any more to
determine whether the item has bitmaps, just only if it's really owner drawn,
making the code more clear and fixing at least the bug above and possible more.

Closes #13878.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76202 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-03-27 00:02:28 +00:00
Vadim Zeitlin
d94b858bc9 Rename wxMenuItem::MustUseOwnerDrawn() to MSWMustUseOwnerDrawn().
No real changes, just make it clear that this method is MSW-specific and is
about using owner drawn items at MSW level and not wx one.

See #13878.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76201 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-03-27 00:02:22 +00:00
Vadim Zeitlin
d9a5f4a0bb Close monitoring thread handles as soon as possible in wxMSW.
Don't leave the handles of all threads used for monitoring the child processes
open until the main process termination, rather close them as soon as the
monitored process terminates.

This ensures that we don't accumulate potentially unbounded number of open
handles if we keep launching new child processes. An even better idea would be
to actually use a single thread for monitoring all of them, but this fix is
much simpler and should fix the most acute problem for now.

Closes #16123.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76200 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-03-27 00:02:16 +00:00
Vadim Zeitlin
da91677e97 Add missing wxUSE_WXDIB checks.
Fix compilation with wxUSE_WXDIB==0.

Closes #16113.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76197 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-03-24 18:46:18 +00:00
Vadim Zeitlin
338cf327b0 Don't change bitmap depth in wxMSW when copying it.
Sometimes, creating a DDB may fail to create the bitmap of the requested
depth and so a copy of wxBitmap could have a different depth than the original
wxBitmap.

Avoid this problem by falling back on using DIB if DDB with the right depth
couldn't be created.

Closes #11640.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76196 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-03-24 18:46:10 +00:00
Vadim Zeitlin
907832bd21 Fix reentrancy issues in wxMSW wxTextCtrl max length handling code.
The changes of r75940 didn't work correctly if the handler of wxEVT_TEXT in
some text control modified a (potentially) different text control, as the same
global variable was reused with disastrous results. Avoid this by keeping a
stack of insertion lengths instead.

Using a per-control field would work too, but would be a bit wasteful as the
size of the stack will rarely be more than 1 (and never much more) and this
change can also be applied to 3.0 branch without breaking ABI.

Additionally, fix another problem in r75940 which used 0 as a special marker
for the insertion length, which result in redoing each insertion of empty
string (which is another word for Remove()) twice unnecessarily, by using -1
instead.

Closes #15980.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76193 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-03-24 13:06:11 +00:00
Vadim Zeitlin
a3da62503f Fix setting menu item bitmaps after appending them in wxMSW.
Update the bitmap used by Windows when using non-owner-drawn items with
bitmaps.

Closes #9388.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76191 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-03-23 15:18:37 +00:00
Vadim Zeitlin
67b128e186 Refactor wxMSW: move some code from wxMenu to wxMenuItem.
This will allow reusing it for other wxMenuItem bitmap-related operations.

See #9388.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76190 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-03-23 15:18:31 +00:00
Vadim Zeitlin
c3b5dc5e8f Fix toolbar repainting after deleting a tool in wxMSW.
The toolbar was in an inconsistent state when recalculating the sizes of the
separators used as placeholders for the controls and stretch spacers as the
tool was already deleted from the native toolbar but still present in wx
internal toolbar data and this resulted in discrepancies between the indices
in the native and wx toolbars.

Fix this by specially marking the already deleted but not yet removed tool and
ignoring it during the recalculations.

This makes the old, and only partially successful, attempt to work around this
bug in DoDeleteTool() unnecessary and so the code is actually simplified by
this change.

Closes #16095.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76189 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-03-23 00:57:18 +00:00
Vadim Zeitlin
de22d0def4 Fix wxFileSystemWatcher::RemoveAll() to actually work.
We need to call DoRemove() on all watcher objects to really remove them, just
removing our record of them was not enough and e.g. resulted in errors if we
tried to re-add a previously watched path again.

Closes #15531.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76187 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-03-23 00:57:09 +00:00
Vadim Zeitlin
5b43c1858d Fix handling deletion of watched directory in MSW wxFileSystemWatcher.
Don't log an incomprehensible error when the watched directory itself is
deleted, but generate wxFSW_EVENT_DELETE for it. This is consistent with the
behaviour under Unix and generally more useful.

Closes #13294.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76186 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-03-23 00:57:03 +00:00
Vadim Zeitlin
305e766f0f Small refactoring in wxFileSystemWatcher MSW implementation.
Make wxIOCPService::GetStatus() smarter about its return value, it makes sense
to encapsulate the convention used to indicate the thread exit condition
inside wxIOCPService class itself instead of sharing it between it
wxIOCPThread itself.

It will also make it easier to detect more detailed error conditions in this
code.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76185 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-03-23 00:57:00 +00:00
Vadim Zeitlin
cc125e64b3 Handle normalization of directory names correctly in wxFileHistory.
Don't use relative path for the directories, which can also be managed by
wxFileHistory, because they don't have any and the old code resulted in
showing an empty string for them.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76179 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-03-22 22:03:34 +00:00
Vadim Zeitlin
33ad33d447 Add wxOVERRIDE and use it in common and wxOSX code.
Make overriding virtual methods more explicit and enable additional checks
provided by C++11 compilers when "override" is used.

Closes #16100.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76173 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-03-20 13:26:28 +00:00
Vadim Zeitlin
34e4f66d6a Compilation fix in wchar_t build after r76171.
Don't concatenate narrow wxLongLongFmtSpec with wide strings, just don't use
wxT() at all.

Closes #14685.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76172 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-03-20 13:26:01 +00:00
Vadim Zeitlin
8c4b1dcbd0 Add wxInt64 support to wxText{Input,Output}Stream.
Add explicit Read64[S]() and Write64() methods.

Closes #14685.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76171 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-03-19 22:57:44 +00:00
Vadim Zeitlin
399371921f Add font colour support to wxFontPickerCtrl.
Currently this is only really implemented under Windows, just as the colour
support in wxFontDialog, but make the API available under all platforms for
consistency.

Closes #11614.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76160 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-03-18 17:23:13 +00:00
Vadim Zeitlin
9e7dbef726 Use helper GetPickerWidget() function in wxFontPickerCtrl.
No real changes, just use a helper function instead of an ugly M_PICKER macro.

See #11614.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76159 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-03-18 17:23:06 +00:00
Vadim Zeitlin
09eebae182 Add margin to the right of the message in wxGenericProgressDialog.
For some reason the border was used only on the left side but not on the right
one, resulting in the ugly looking label flush to the right dialog border if
it was long enough.

Closes #16094.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76156 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-03-18 14:21:51 +00:00
Julian Smart
b4d02eafa3 Improved calculation of spanning column widths.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76154 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-03-18 09:14:42 +00:00
Vadim Zeitlin
a489001977 Disable the use of new style wxDirDialog under Vista.
IFileDialog-based dialog has a bug making it return a wrong path sometimes
under Vista, disable its use there to avoid it.

Closes #16005.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76152 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-03-16 13:05:47 +00:00
Paul Cornett
5e6dd2fcb4 build fixes for wxUniversal
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76150 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-03-15 19:34:31 +00:00
Paul Cornett
d2e4b3520b for GTK+ 3.6 and later, invalidate cached best size when GTK's style cache is updated, see #16088
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76149 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-03-15 18:44:02 +00:00
Vadim Zeitlin
f9b4d6b18c Fix showing of 32bpp bitmaps without alpha in wxMSW wxStaticBitmap.
The native control doesn't make a secret copy of the image in this case (0RGB
bitmap, i.e. 32bpp ARGB bitmap with all alpha values set to 0) and just shows
the bitmap we assigned to it directly, so we must not delete it in this case,
otherwise nothing is shown at all.

Closes #16084.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76148 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-03-14 19:22:31 +00:00
Vadim Zeitlin
6b296279ba Also free internal handlers when wxMSW wxStaticBitmap is destroyed.
r76142 fixed the resource leak when wxStaticBitmap image was replaced by
another one but the leak still happened at the end, when the wxStaticBitmap
was destroyed.

Fix it there as well in the same way.

Closes #16068.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76147 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-03-14 19:22:26 +00:00
Vadim Zeitlin
c8a35a6f17 Fix recently introduced compilation error in wxUSE_PALETTE==0 build.
Add missing "#if wxUSE_PALETTE" tests.

Closes #16083.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76146 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-03-14 19:22:16 +00:00
Vadim Zeitlin
371928415a Add support for loading old V1 bitmap files to wxBMPHandler.
Such files are apparently still seen in the wild, even though this format has
been superseded since Windows 3.0 (!).

Closes #3433.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76144 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-03-14 01:36:54 +00:00
Stefan Csomor
ffeba70599 adding 10.5 compatibility again
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76143 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-03-13 17:09:00 +00:00
Vadim Zeitlin
8fa2694395 Fix resource leak in wxMSW wxStaticBitmap when using RGBA icons.
Release the old handle if it wasn't freed by STM_SETIMAGE itself.

Closes #16068.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76142 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-03-13 16:20:08 +00:00
Vadim Zeitlin
c2ac6643cc Avoid unused variable warning in wxUSE_VALIDATORS==0 build.
Closes #16076.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76140 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-03-13 16:17:15 +00:00
Vadim Zeitlin
1e832755cf Use wxScopedXXX<> instead of explicit memory management in wxBMPHandler.
Make the code simpler and ensure there are no memory leaks in it.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76136 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-03-12 23:04:32 +00:00