Commit Graph

54351 Commits

Author SHA1 Message Date
Vadim Zeitlin
08be21f56d Correct generic wxListCtrl display of items with icons in list mode.
The changes of r70066 improved the layout for icon and small icon modes but
broke it for the list mode if items had icons because the item width should
account for the icon as well in this case. Simply disable the code added in
this revision when in list mode, we don't need to do anything then anyhow as
the layout already worked correctly for it.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@70077 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-12-21 13:56:50 +00:00
Vadim Zeitlin
7451b5c459 Guard against a possible crash in wxListCtrl::DeleteColumn().
We could crash when deleting a column after switching to report view from icon
view. As deleting a column works just fine under MSW in this case, make it
work in the generic version as well.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@70076 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-12-21 13:56:47 +00:00
Vadim Zeitlin
54d323d299 Document wxListCtrl::InReportView() and IsVirtual().
These functions are more convenient than directly testing for styles and are
already used outside wxWidgets do make them officially part of the public API.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@70075 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-12-21 13:07:18 +00:00
Vadim Zeitlin
921e411cc1 Ignore extra modify events after rename in wxFileSystemWatcher.
Document that such extra events may occur and generally improve the event
types documentation.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@70074 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-12-21 00:26:06 +00:00
Vadim Zeitlin
fceac6bbfe Provide native implementation of wx{Date,Time}PickerCtrl for wxOSX/Cocoa.
Use NSDatePicker to implement both of these controls. Almost all of
wxDatePickerCtrl styles are not supported in the native version but the basic
functionality does work and looks much better than the generic version (which
is still available as wxDatePickerCtrlGeneric if needed) under Mac.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@70071 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-12-20 21:27:14 +00:00
Vadim Zeitlin
36d07f78e4 Added helpers for translating between wxDateTime and NSDate.
These functions will be used in the upcoming native implementations of
wxDatePickerCtrl and wxTimePickerCtrl but could also be reused elsewhere in
wxOSX/Cocoa, notably in wxDataViewCtrl where strange ad hoc code is currently
used.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@70070 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-12-20 21:27:09 +00:00
Vadim Zeitlin
59a2c19914 Added wxTimePickerCtrl page to the widgets sample.
Even if this page is pretty trivial, add it for consistency with
wxDatePickerCtrl.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@70069 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-12-20 21:27:06 +00:00
Vadim Zeitlin
54450d0907 Reorganized the date picker page of the widgets sample.
Make it possible to set the picker styles and set its range and not only the
current value.

Also log the events generated by it.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@70068 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-12-20 21:27:02 +00:00
Vadim Zeitlin
7a7e178339 Ukrainian translations update from Yuri Chornoivan.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@70067 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-12-20 21:22:31 +00:00
Vadim Zeitlin
4d0c23087a Fix horizontal alignment in icon view in generic wxListCtrl.
Ensure that all the items in the same column have the same width, so that
their labels are centred.

Closes #9227.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@70066 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-12-20 21:21:38 +00:00
Vadim Zeitlin
8573b14550 Brazilian Portuguese translations update from Felipe.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@70065 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-12-20 17:42:04 +00:00
Vadim Zeitlin
00c784a4d1 Fix crash in wxRegion in wxOSX/Carbon.
Apparently some code expects to be able to call wxRegion::GetWXHRGN() even on
an invalid wxRegion. Return NULL in this case instead of crashing.

This fixes crash on startup of the widgets sample.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@70064 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-12-20 15:39:42 +00:00
Vadim Zeitlin
0d2a693bbd Add support for webview library to MSW bakefile presets.
The webview library wasn't linked in correctly when using MSW bakefile
presets. Fix this by adding the corresponding <sys-lib> for it (this needs to
be done for MSW only, under Unix it's handled by wx-config).

Closes #13789.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@70063 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-12-20 13:27:59 +00:00
Vadim Zeitlin
aa866feeaa Mention the dialog focus regression fix in wxMSW in the change log.
See #13765.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@70062 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-12-20 13:24:48 +00:00
Robin Dunn
3d2ee2fb05 Interface tweaks and fixes for Phoenix
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@70061 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-12-19 22:39:02 +00:00
Bryan Petty
b821341a03 Added missing semi-colon in versioninfo.h interface header.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@70060 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-12-19 21:16:01 +00:00
Dimitri Schoolwerth
4235f9f6c6 Cleaned up some of the code in wxSlider::DoMoveWindow.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@70052 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-12-19 13:14:24 +00:00
Vadim Zeitlin
ee4d438064 Added support for wxEXEC_MAKE_GROUP_LEADER to wxExecute().
Map it to the native CREATE_NEW_PROCESS_GROUP flag as it's broadly similar to
Unix semantics.

Closes #13676.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@70051 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-12-19 12:54:48 +00:00
Vadim Zeitlin
1c959a62ce Add possibility to set item background in generic wxDataViewCtrl.
Added wxDataViewItemAttr::SetBackgroundColour() and code to honour it in the
generic implementation of wxDataViewCtrl.

Closes #12621.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@70050 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-12-19 12:54:38 +00:00
Vadim Zeitlin
02106526ea Don't use dummy "inline" in wxDEPRECATED_CONSTRUCTOR definition.
Apparently we need this bogus "inline" for g++ < 3.4 but there is no reason to
use it for the other compilers and this results in linking errors with e.g.
MSVC, so remove it.

Closes #13775.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@70049 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-12-19 12:54:32 +00:00
Dimitri Schoolwerth
cac008ad62 Fixed min and max label values not being swapped when using wxSL_INVERSE in a horizontal MSW slider.
Changed wxSlider::GetLabelsSize to let the widthMin and widthMax values contain the width of what the minimum (always on the left/top) and maximum (always on the right/bottom) _label_ will contain. This is not the same as the minimum and maximum _value_ in case of using wxSL_INVERSE.

Also don't swap the position of the min/max labels in a horizontal slider with wxSL_INVERSE (just how the labels already stay in place in a vertical slider, regardless of wxSL_INVERSE usage), nor their width.

Regression since r65941.

Fixes #13416.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@70048 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-12-19 12:28:42 +00:00
Dimitri Schoolwerth
2a263bbbd7 Removed useless if statement in slider code.
The y position of the slider is already taken care of by the variable ySlider, changing labelOffset has no use.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@70047 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-12-19 12:16:52 +00:00
Dimitri Schoolwerth
e528cca7c1 Don't move the slider's value label if it's not being used.
An if statement was missing brackets and still moving the value label.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@70046 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-12-19 12:12:31 +00:00
Vadim Zeitlin
9efbfd5dbd Add a reminder to update version.bkl to inc_release script.
While docs/tech/tn0011.txt does document this, it's still too simple to forget
to update version.bkl, as my experience shows, so add a reminder to the script
itself too.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@70045 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-12-18 14:38:47 +00:00
Vadim Zeitlin
08670ea85a Update version to 2.9.4 in version.bkl too and rebake everything.
Change the version for Unix shared libraries too.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@70044 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-12-18 14:35:50 +00:00
Vadim Zeitlin
75cb911c7c Added wxFilePickerCtrl::SetInitialDirectory().
This method allows to configure the initial directory to be shown when
browsing for files in an initially empty wxFileDirPickerCtrl.

It is also available for wxDirPickerCtrl but is less useful there.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@70043 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-12-18 12:34:47 +00:00
Vadim Zeitlin
b9bb74e9fc No changes, just use wxScopedPtr instead of explicit "delete".
Use wxScopedPtr in wxGenericFileDirButton to ensure that the dialog created by
it is always destroyed, even if an exception is thrown while showing the
dialog or while processing the event we generate after showing it.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@70042 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-12-18 12:27:04 +00:00
Steve Lamerton
7f98bdd6a5 Ensure wxWebViewIE::SetPage clears the existing content before writing the new output. Also add a basic unit test to verify correctness in the future.
Fixes #13770

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@70041 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-12-18 11:51:52 +00:00
Vadim Zeitlin
913ce2990e Make wxPalette ctor and Create() const-correct in wxMSW.
The input data is never modified so should be const (it is also documented as
being const and actually is const in the other ports).

Closes #13776.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@70040 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-12-17 23:52:47 +00:00
Vadim Zeitlin
05f5b3f745 Define wxBitmapComboBox::Insert(void* clientData) overload in wxMSW.
This overload was declared in the header but not implemented, do add its
definition too.

Closes #13774.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@70039 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-12-17 23:52:43 +00:00
Vadim Zeitlin
ecc610f1af Corrected the name of EVT_WEB_VIEW_ERROR event table macro.
It was mistakenly spelt EVT_WEB_VIEW_ERRROR.

Closes #13772.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@70038 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-12-17 23:52:40 +00:00
Vadim Zeitlin
65ea1c9dca No changes, just fix typo in an example in webview docs.
See #13772.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@70037 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-12-17 23:52:36 +00:00
Vadim Zeitlin
7cb83a8b78 Don't activate MSW dialogs when setting their initial size.
As the dialog is not shown yet at this moment, activating it didn't work
correctly and the dialog didn't get the focus when it was shown later.
Fix this by preventing ::SetWindowPos() from activating it, which it does by
default.

Closes #13765.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@70036 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-12-17 23:04:50 +00:00
Dimitri Schoolwerth
a57ea0102f Fixed unreferenced parameter warning.
Parameter xmpData was unused in wxImage::Create when compiling with wxUSE_XPM set to 0.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@70022 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-12-17 01:13:22 +00:00
Vadim Zeitlin
c05b000c71 Incremented the version number to 2.9.4 everywhere.
The misc/scripts/inc_release script was used to update the versions.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@70021 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-12-16 22:12:49 +00:00
Vadim Zeitlin
69b554dccc Try to get more information about wxFileSystemWatcher unit test failures.
Log the original and new paths of the rename event to help debugging the extra
modification events detected during the buildbot builds.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@70020 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-12-16 21:11:19 +00:00
Vadim Zeitlin
bfbd873bfe Don't use wxTE_DONTWRAP style in Lines() wxTextCtrl unit case.
The last check in this test couldn't pass under MSW as it relied on the (long)
line of text being wrapped but the style used for the control prevented this
from happening. Not sure how could it have ever worked before but in any case
removing wxTE_DONTWRAP does make the test pass.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@70019 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-12-16 19:57:17 +00:00
Vadim Zeitlin
b281a92305 Keep the item being updated selected in wxMSW wxChoice::SetString().
Changing the text of the selected wxChoice (or wxComboBox, as it derives from
it in wxMSW) item made it unselected. Fix this by explicitly restoring the
selection to the item if needed.

Closes #13769.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@70018 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-12-16 19:47:58 +00:00
Vadim Zeitlin
5b130f274e Corrected test for region validity in wxMSW wxRegion::DoOffset().
Checking M_REGION is not enough as the region can be invalid (meaning
m_refData dereferenced inside M_REGION is NULL itself) and not just not
initialized, so it resulted in crashes and not just the expected assert
failure when wxRegion::Offset() was called for an invalid region.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@70017 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-12-16 19:47:55 +00:00
Vadim Zeitlin
03dc350fa6 Use IsThisEnabled() to test if AUI child is enabled, not IsEnabled().
IsEnabled() returns false if the parent window is disabled and calling
Enable() does not help with this, so we could keep trying and trying to enable
the window unsuccessfully if it was reenabled while its parent was disabled,
resulting in a never-ending stream of EVT_IDLE events.

Closes #13767.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@70016 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-12-16 19:33:31 +00:00
Vadim Zeitlin
35f92de300 Make multiline checkboxes wider in wxMSW to avoid word wrap.
At least for some versions of Windows (Server 2003 with classic look and feel)
the native checkboxes auto wrapped the label as it wrongly considered that the
width we specified for it was not big enough. Compensate for this by making
the checkbox wider -- this is just a hack but still better than corrupting the
checkbox display.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@70015 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-12-16 11:03:15 +00:00
Vadim Zeitlin
a97f71fa60 Output the value of --enable-debug option in configure.
As we use AC_ARG_ENABLE() instead of WX_ARG_ENABLE() for it, we need to call
AC_MSG_RESULT() explicitly or its value is never reported and configure output
is corrupted.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@70014 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-12-16 09:36:36 +00:00
Vadim Zeitlin
0c717dd16b Compilation fix for wxStopWatch with wxUSE_THREADS==0.
Use wxCRIT_SECT_DECLARE_MEMBER/wxCRIT_SECT_LOCKER macros which expand to
nothing in wxUSE_THREADS==0 case instead of using wxCriticalSection[Locker]
classes which are not defined then.

Also explicitly include wx/thread.h.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@70012 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-12-15 21:13:03 +00:00
Julian Smart
5dec941a5b Applied #13763 from dghart, to use primary selections if available
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@70011 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-12-15 11:32:58 +00:00
Vadim Zeitlin
9edd688dd3 Ensure that wxPropertyGrid::m_tlp is initialized early enough.
This member variable could be used before it was initialized as
OnTLPChanging() was called from Create() before Init2(), where m_tlp was
assigned NULL, was called.

Closes #13552.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@70009 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-12-15 00:22:48 +00:00
Vadim Zeitlin
81dd48085d No changes, just harmonized the EOLs in the ISS file.
Use consistent DOS EOLs for all the lines in this file.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@70007 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-12-14 18:42:11 +00:00
Václav Slavík
c9d3d00cdf Remove unnecessary m_editorCtrl assignment.
m_editorCtrl is WeakRef<>, so doing it is pointless, and it breaks VC6
compilation.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@70005 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-12-14 17:38:19 +00:00
Václav Slavík
a85b4023d1 Close wxDataViewCtrl inline editor when destroying the control.
If the wxDataViewCtrl control was destroyed while an inline editor
control was still active, it wouldn't get destroyed in the right order
and the ~wxWindow assert about unpopped event handlers would be
triggered.

Fix this by popping the handler as one of the first things in
wxDataViewRendererBase destructor.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@70002 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-12-14 16:00:30 +00:00
Václav Slavík
eff1c3e8ec Don't change horizontal scroll position needlessly in wxDataViewCtrl.
When ScrollTo() or EnsureVisible() was called in the generic
wxDataViewCtrl implementation with unspecified column, horizontal scroll
position was reset to left-most position, which doesn't make much sense.
Instead, leave horizontal position unchanged in this case and only
change it when explicitly requested.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@70001 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-12-14 15:53:28 +00:00
Václav Slavík
78e18e8d53 Ensure that current column is visible in generic wxDataViewCtrl.
When navigating between columns using keyboard, ensure visibility of the
newly selected column.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@70000 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-12-14 15:53:25 +00:00