Commit Graph

50856 Commits

Author SHA1 Message Date
Václav Slavík
10265e6c41 wxOwnerDrawnComboBox: handle Home and End keys as native control does.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@63863 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-04-05 17:18:58 +00:00
Václav Slavík
174b5c87bc Pass events around with ProcessEvent(), not AddPendingEvent().
The latter adds the event for later processing. As a result, the event
appears to be processed to the caller, even if the handled it was passed
to called Skip() on it. ProcessEvent() doesn't suffer from this problem,
it may modify the event as expected.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@63862 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-04-05 17:18:55 +00:00
Václav Slavík
293987e80c wxOwnerDrawnComboBox: handle numpad navigation keys.
For consitency with the native control, up/down/pgup/pgdown keys should
be handled even when pressed on the numpad.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@63861 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-04-05 17:18:50 +00:00
Václav Slavík
f408451314 Implement native mousewheel behaviour in wxOwnerDrawnComboBox.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@63860 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-04-05 17:18:46 +00:00
Václav Slavík
ffe42ca627 In wxPopupFocusHandler, watch for EVT_CHAR, not EVT_KEY_DOWN.
We should close the popup only if neither of these events was processed;
previously, EVT_CHAR would never reach the popup in open state, as it
would be closed automatically.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@63859 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-04-05 17:18:41 +00:00
Stefan Csomor
88695e9ab8 moving OnInit back
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@63858 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-04-05 12:44:31 +00:00
Vadim Zeitlin
4ee4c7b948 Add support for gradient stops to wxGraphicsContext.
Allow specifying a set of gradient stops instead of just the beginning and
ending colours. Add the new wxGraphicsGradientStop(s) classes and new
wxGraphicsContext::Create{Linear,Radial}GradientBrush() overloads. Also change
the same methods of wxGraphicsRenderer to take wxGraphicsGradientStops instead
of a pair of colours.

Implement the new API for MSW and Cairo. OS X still uses just the two colours
for now.

Closes #11897.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@63857 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-04-05 12:15:11 +00:00
Vadim Zeitlin
cd300ef760 Add wxTransparentColour global pseudo-variable.
Introduce a symbolic name for a fully transparent colour.

See #11897.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@63856 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-04-05 11:44:33 +00:00
Vadim Zeitlin
f49c80c105 Use helper wxColourToColor function in wxMSW wxGraphicsContext code.
Don't repeat Color ctor from wxColour all the time.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@63855 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-04-05 11:44:28 +00:00
Paul Cornett
cffda6922a avoid setting negative window size
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@63854 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-04-05 01:07:24 +00:00
Paul Cornett
9914bfbb77 freeze whole window for TLW
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@63853 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-04-05 01:06:39 +00:00
Paul Cornett
2f55b88cb0 avoid permanently frozen TLW when frozen child is destroyed with GTK+ 2.18
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@63852 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-04-05 00:45:21 +00:00
Jaakko Salli
1237a25bc4 Resolve GCC's 'type-punned pointer will break strict-aliasing rules' warning by breaking up code in wxAny GetValue() and SetValue() functions into several lines (fixes #11865)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@63850 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-04-04 15:22:43 +00:00
Vadim Zeitlin
63d690d7c5 Fix wxTaskBarIcon to work under all Windows versions.
When the code was compiled using a new SDK, creating wxTaskBarIcon failed
under older Windows systems because of a too big NOTIFYICONDATA size specified
by the program.

Fix this by using the fixed NOTIFYICONDATA_V2_SIZE to get old version of the
struct which nevertheless contains everything we need and even fall back to
NOTIFYICONDATA_V1_SIZE for Win9x if needed.

Closes #11886.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@63849 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-04-04 13:19:58 +00:00
Vadim Zeitlin
961f4d0ce6 Correct compilation breakage of r63832.
wx/setup.h can't use wxCHECK_VISUALC_VERSION() which is defined in
wx/platform.h _after_ wx/setup.h inclusion.

Replace wxCHECK_VISUALC_VERSION() with manual tests for _MSC_VER.

Also add more comments to explain what's going on.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@63842 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-04-03 12:25:52 +00:00
Stefan Csomor
22ed9d1186 shuffling code back from eventloop to common app utils
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@63841 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-04-03 09:58:19 +00:00
Stefan Csomor
7b896860bf no special casing for iphone necessary
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@63840 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-04-03 09:49:10 +00:00
Stefan Csomor
7e04f44c8d fixing wrong version commit
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@63839 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-04-03 09:43:30 +00:00
Stefan Csomor
7f08aa6ce9 support for toggle bitmap button
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@63838 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-04-03 09:10:38 +00:00
Stefan Csomor
2439f1d968 fixing multilib build
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@63837 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-04-03 06:59:33 +00:00
Vadim Zeitlin
41616c8ac6 Correct typo in configure introduced in r63832.
See #11892.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@63833 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-04-02 21:30:46 +00:00
Vadim Zeitlin
cde23b64b5 Allow using wxGraphicsContext with MinGW if gdiplus.h is available.
MinGW doesn't include gdiplus.h but it can be installed independently by the
user. Allow to use it if it's available:

- Include windows.h when checking for it in configure as this is apparently
  needed for its compilation.
- Don't reset wxUSE_GRAPHICS_CONTEXT to 0 for non-Microsoft compilers, instead
  just define it as 0 by default for them, allowing the user to simply change
  the definition in wx/msw/setup.h.

Closes #11892.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@63832 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-04-02 19:30:41 +00:00
Vadim Zeitlin
f836fe354b Fix crash in wxMediaCtrl::GetDownloadProgress() with ActiveMovie backend.
IActiveMovie::get_FilterGraph() may return S_FALSE, i.e. succeed, while
leaving the output pointer NULL. Check for this and don't dereference the
pointer before checking for its validity.

Also do it for the other call in this function just in case. And rearrange the
code to be slightly more readable.

Closes #11894.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@63831 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-04-02 19:30:34 +00:00
Vadim Zeitlin
bd044e27b3 Show labels for controls in wxOSX/Carbon toolbars.
Add a call to HIToolbarItemSetLabel().

Closes #11885.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@63830 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-04-02 19:30:29 +00:00
Stefan Csomor
2318a5d74c keeping m_labelOrig untouched, solves test failures (FM)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@63829 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-04-02 18:19:03 +00:00
Stefan Csomor
62068535c5 simplifying modal event loop handling
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@63828 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-04-02 14:52:08 +00:00
Stefan Csomor
175e9d71cd moving OnInit to a later stage to avoid Carbon Emulation artifacts by the OS, fixes #11839
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@63827 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-04-02 12:27:39 +00:00
Paul Cornett
4cf018e14e move everything inside wxUSE_RIBBON wrapper
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@63819 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-04-01 17:16:57 +00:00
Paul Cornett
16eac072eb avoid setting negative window sizes
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@63818 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-04-01 17:00:44 +00:00
Paul Cornett
8536ce5b3f don't try to create a color named "Default"
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@63817 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-04-01 16:59:34 +00:00
Jouk Jansen
94a1ccb9cd Fix OpenVMS compile support for new version in src/stc
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@63816 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-04-01 09:59:19 +00:00
Francesco Montorsi
00e075e551 Committing modified version of jwiesemann's patch (see #11223):
Fix wxURL copy ctor and assignment: the default ones provided by the compiler are wrong because wxURL uses pointers internally. 
Also add a test for copy & assignment in URLTestCase.

Closes #11223

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@63806 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-03-30 21:38:31 +00:00
Paul Cornett
38442edb48 Remove unnecessary declarations.
Contrary to the comment, they are not used often, in fact only once each
and in the same file.


git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@63805 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-03-30 16:14:11 +00:00
Jouk Jansen
a41115011c correcting typo in commit 63803
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@63804 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-03-30 12:02:16 +00:00
Jouk Jansen
7126436ab4 Defining wxCOMPILE_TIME_ASSERT for OpenVMS
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@63803 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-03-30 11:54:37 +00:00
Robin Dunn
9e96e16fe0 Apply patch (plus some additional changes) upgrading Scintilla to version 2.03. Closes #11765, #11748, #11346
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@63792 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-03-30 03:50:06 +00:00
Francesco Montorsi
a7d354c6d7 better docs for Get/SetLabel methods
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@63786 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-03-29 21:31:27 +00:00
Vadim Zeitlin
af9b20332c Fix compilation breakage in r63783.
Added missing #endif.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@63785 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-03-29 21:24:44 +00:00
Vadim Zeitlin
97aa1a74db Only allow opening existing files in docview framework.
Use wxFD_FILE_MUST_EXIST when asking the user for the name of the file to
open.

Closes #11866.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@63784 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-03-29 21:24:39 +00:00
Vadim Zeitlin
e7678d7d03 Add wxUSE_FSWATCHER dependency on wxUSE_THREADS for wxMSW.
wxFileSystemWatcher implementation uses threads under MSW and can't be
compiled when wxUSE_THREADS==0.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@63783 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-03-29 20:57:41 +00:00
Jaakko Salli
e954958f98 For better support of wxValidators, invoke wxValidator::Validate() directly. Also remove obsolete flag wxPG_FL_VALIDATION_FAILED and make wxPropertyGrid::DoEditorValidate() virtual.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@63782 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-03-29 18:17:55 +00:00
Václav Slavík
c44a49b852 Use fixed screen DPI of 96 when printing HTML.
Unlike font sizes, which depend on screen resolution because of weird
wxFont API, pixel sizes used elsewhere (and in particular, for images)
shouldn't depend on screen DPI.

This finally makes the output independent of screen size.

Fixes #10942.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@63781 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-03-29 14:19:06 +00:00
Václav Slavík
5a21001cdd Removed useless wxDisplaySize() calls from wxHtmlPrintout.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@63780 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-03-29 14:18:58 +00:00
Vadim Zeitlin
bd9532a416 Add wxBitmap unit test.
This should have been part of r63774.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@63778 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-03-29 09:59:05 +00:00
Paul Cornett
a89c31bb34 build fix for IRIX
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@63777 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-03-29 06:45:00 +00:00
Paul Cornett
ad4a907bb7 non-pch build fix
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@63776 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-03-29 06:44:16 +00:00
Paul Cornett
f089940f68 Reverse hierarchy of wxPizza GdkWindows
widget->window must be topmost in order for GTK+ to calculate DND drop coordinates correctly
fixes #11834


git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@63775 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-03-29 01:16:06 +00:00
Vadim Zeitlin
27297c823a Implement wxMask copy ctor for wxGTK.
Without copy ctor copying masks simply crashed because the same pointer was
deleted twice.

Also added a (completely trivial but better than nothing...) unit test for
wxBitmap to check that copying masks does work now.

Closes #11854.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@63774 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-03-28 23:20:49 +00:00
Vadim Zeitlin
6f4968ce94 Suppress gcc warnings about double to int conversion.
This change might actually make the code more correct as well although in
practice it probably doesn't change anything.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@63773 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-03-28 23:20:41 +00:00
Vadim Zeitlin
eb08702932 Fix bug in wxMBConv_cf::FromWChar() in OS X.
Apparently CFStringGetBytes() doesn't always behave as expected, work around
this by checking that the returned buffer size is not greater than the size we
passed in.

Closes #11859.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@63772 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-03-28 22:39:39 +00:00