Commit Graph

60453 Commits

Author SHA1 Message Date
Tobias Taschner
5b42e35f81 Suppress deprecation warning in wxGetOsVersion(). 2015-08-10 09:43:56 +02:00
Tobias Taschner
48f32f479a Make Mac OS X string translatable in wxGetOsDescription(). 2015-08-10 09:43:22 +02:00
Paul Cornett
4623c5ad9c Make rectangle size the same as is drawn by raster-based wxDCs
Outlined rectangles are one pixel larger with vector-based drawing,
adjust them to get consistent behavior.
Ellipses do not appear to need adjustment.
See #17091
2015-08-09 22:06:59 -07:00
Paul Cornett
bf6f3e35e8 Fix wxListBox mouse wheel scrolling with GTK3
Allow default handling for GDK_SCROLL_SMOOTH when we don't handle it. Closes #17097
2015-08-09 21:01:48 -07:00
Artur Wieczorek
02784ee671 Show wxART_EDIT icon in artprov sample.
Add this new icon to the resource browser.
2015-08-09 17:18:04 +02:00
Vadim Zeitlin
59beb5a40d Merge wxEditableListBox_button_icons branch of https://github.com/a-wi/wxWidgets.git
This improves wxEditableListBox appearance, especially under GTK.

Closes https://github.com/wxWidgets/wxWidgets/pull/66
2015-08-09 01:39:41 +02:00
Artur Wieczorek
c774494009 Use standard wxArtProvider icons for wxEditableListBox buttons.
This make wxEditableListBox appearance more native under the platforms where
the stock icons are used, e.g. GTK.

Closes #16885.
2015-08-09 01:39:41 +02:00
Artur Wieczorek
75467841ee Moved "edit" icon from wxEditableListBox to wxArtProvider.
"Edit" icon definition used internally in wxEditableListBox is moved to
wxDefaultArtProvider and exposed as wxART_EDIT.

While there is no native version of this icon yet, it could be added in the
future and in the meanwhile this commit will be useful to use only standard
bitmaps in wxEditableListBox.
2015-08-09 01:39:41 +02:00
Catalin
8e9c327221 Always strip trailing separators from wxFileName::GetTempDir() under MSW.
In the unlikely but still possible case when neither TMP nor TEMP environment
variables are defined under Windows, we use the standard ::GetTempPath()
function which can return a path with trailing backslashes, e.g. if it takes
it from USERPROFILE environment variable. Ensure that these backslashes are
stripped in this case as well.

Closes https://github.com/wxWidgets/wxWidgets/pull/67
2015-08-09 01:39:40 +02:00
Artur Wieczorek
c5d6f9d103 Improved retrieving bitmaps from wxArtProvider in propgrid sample.
Retrieve from wxArtProvider bitmaps of required size instead of rescaling them in the application.
2015-08-08 22:27:23 +02:00
Catalin
2a882b2bb3 Mention that temp dir is for current user. 2015-08-08 17:57:21 +03:00
Vadim Zeitlin
1255322426 Provide wxCheckOsVersion() implementation for iOS.
Duplicate the definition from the common code used for all non-OS X ports to
fix wxiOS linking errors.

See https://github.com/wxWidgets/wxWidgets/pull/62
2015-08-08 04:19:48 +02:00
Vadim Zeitlin
f7b38667ea No changes, just remove stray CRs from wxMSW wxGetOsVersion().
Commit 2b3633b3c0 somehow used incorrect EOLs
for this file, see https://github.com/wxWidgets/wxWidgets/pull/62
2015-08-08 04:14:11 +02:00
Vadim Zeitlin
271e8ab62e Don't compile Carbon wxGetOsVersion() as part of wxOSX/Cocoa.
It was already excluded for wxiOS, and this function has also a Cocoa-specific
implementation since 411027d5b4, so don't
compile it twice.

See https://github.com/wxWidgets/wxWidgets/pull/62
2015-08-08 01:29:35 +02:00
Artur Wieczorek
03d9c427e0 Fix size of some bitmaps returned by wxWindowsArtProvider.
Bitmaps obtained using SHGetStockIconInfo can have only some predefined sizes.
If size of the retrieved bitmap doesn't correspond to the needed size or the
size given by wxArtProvider::GetNativeSizeHint() then the bitmap should be
rescaled appropriately.

Closes #17071.

Closes https://github.com/wxWidgets/wxWidgets/pull/64
2015-08-08 01:08:14 +02:00
Artur Wieczorek
244ec264af Factor out duplicated code for bitmap scaling in wxArtProvider.
Move duplicated code responsible for rescaling bitmaps in wxArtProvider to the
shared wxArtPrvider::RescaleBitmap() method.

Additionally, make this new method work even in wxUSE_IMAGE==0 case.

See #17071.

See https://github.com/wxWidgets/wxWidgets/pull/64.
2015-08-08 01:04:46 +02:00
ArnaudD-FR
09e8876c0c Don't use global variables for generic wxDataViewCtrl sorting.
Improve code quality and also fix the following issue: when 2 or more
wxDataViewCtrl were frozen, only the first one was sorted on thaw as g_column
was erased by the first wxDataViewCtrl to be sorted and so preventing the
other one from being sorted.

Closes https://github.com/wxWidgets/wxWidgets/pull/63
2015-08-08 00:53:17 +02:00
VZ
3b573aa4d3 Merge pull request #62 from TcT2k/version_fixes
OS version checks improvements and updates.

Remove code for the no longer supported OS versions (MSW < XP, OS X < 10.7).

Add new `wxCheckOsVersion()` which should be used when testing for the OS version instead of comparing the versions directly which may not work reliably because of compatibility shims.
2015-08-08 00:44:28 +02:00
Tobias Taschner
5d364bf81e Update supported OS versions in Readme files. 2015-08-07 16:55:30 +02:00
Tobias Taschner
8bd14648cd Remove Cocoa code and precompiler defines targeting OS X versions prior to OS X 10.7. 2015-08-07 16:25:28 +02:00
Tobias Taschner
3f63ad5c61 Add constants for OS X 10.10. 2015-08-07 16:02:24 +02:00
Tobias Taschner
3250bae3a2 Implement wxCheckOsVersion() with NSProccessInfo on OS X.
Since OS X 10.10 NSProcessInfo has a method isOperatingSystemAtLeastVersion: which should be used compare the OS version if necessary.
2015-08-07 15:49:52 +02:00
Tobias Taschner
411027d5b4 Implement wxGetOsVersion() and wxGetOsDescription() with NSProcessInfo.
NSProcessInfo is the recommended way to determine OS X OS version, but the operatingSystemVersion property is only available in OS X 10.10+. Because of that a fallback to Gestalt() is implemented.

The NSProcessInfo.operatingSystemVersionString in the form “Version 10.10.4 (Build 14E46)"	now used by wxGetOsDescription() should be more useful to the user than the carbon implementations darwin version.
2015-08-07 15:49:23 +02:00
Tobias Taschner
c581188a73 Remove unused code in cocoa file dialog implementation.
The removed function was used for OS X versions prior to 10.7 and was not used any more.
2015-08-06 11:47:54 +02:00
Tobias Taschner
2b3633b3c0 Add wxCheckOsVersion() to implement platform based OS version checks.
Windows implements VerifyVersionInfo api since Win2k. Starting with Windows 8.1 GetVersionEx is deprecated and may not return the expected version number if the application does not contain the correct compatibility information in its manifest. VerifyVersionInfo works independent of manifest in the executable (and is the recommend way to check).

Existing code may already use wxPlatformInfo::CheckOSVersion() so the method forwards the call to wxCheckOsVersion if initialized for the current system.
2015-08-06 11:32:38 +02:00
Tobias Taschner
d8e291c27a Remove unused and outdated code in OS X wxGetOsVersion. 2015-08-06 10:16:50 +02:00
Tobias Taschner
93324ebe62 Update utils.h documentation with more current OS versions.
Some OS versions mentioned were a little bit outdated and the paragraph about wxGetHostName on Windows simply didn’t match the implementation any more.
2015-08-06 10:12:17 +02:00
Tobias Taschner
e9c04133d2 Remove code targeted at MacOS versions prior to OS X. 2015-08-06 09:50:47 +02:00
Tobias Taschner
388e82e70c Remove MSW code targeted at versions prior to WinXP.
In 3.1 WinXP is required so remove checks and code for prior versions.
2015-08-06 09:44:20 +02:00
Artur Wieczorek
0b821adf90 Fix layout of wxSlider labels after changing value range.
Size of labels with new values can be different then size of current labels
and hence they should be re-laid out every time when the range is changed.

Closes #17093.
2015-08-05 20:43:06 +02:00
Tobias Taschner
a8c98a1191 Fix wxGetWinVersion() for Windows 10
Check for Windows 10 was implemented as check for version 6.4 but the final version of Windows 10 actually returns 10.0.
2015-08-04 15:04:33 +02:00
Tobias Taschner
c87c432033 Fix wxGetOsDescription() for Windows 10.
Check for Windows 10 was implemented as check for version 6.4 but the final
version of Windows 10 actually returns 10.0.
2015-08-04 14:42:46 +02:00
Tobias Taschner
e97bd98e18 Update supported Windows and MSVC versions in the documentation.
The current master doesn't support Win9x any more but does support Windows 10
and MSVC 15 and while the platform details page of the manual was already
updated to reflect this, the more visible introduction page was not, update it
as well.

Also update MSW installation instructions in install.txt.
2015-08-04 14:41:10 +02:00
Tobias Taschner
0a502cd354 Update OS X version requirement in README.
OS X >= 10.7 is required in 3.1.
2015-08-04 14:37:21 +02:00
Vadim Zeitlin
9bc3ab1ea7 Add wxNativeWindow allowing to easily embed native widgets in wx.
Implement the class for wxMSW, wxGTK and wxOSX/Cocoa, show it in the widgets
sample and add documentation for it.
2015-08-03 17:57:42 +02:00
Vadim Zeitlin
ce95913319 Use wxWindow instead of wxControl in the widgets sample.
Not all widgets are controls and we don't use any of wxControl-specific
methods in the sample, so don't require RecreateWidget() to return a wxControl
when a simple wxWindow suffices.

No real changes.
2015-08-03 17:57:42 +02:00
Vadim Zeitlin
2509e7927a Handle GTK_POLICY_EXTERNAL new in GTK+ 3.16 too.
Apparently this still doesn't display any scrollbars in the window itself, so
from our point of view it is equivalent to GTK_POLICY_NEVER.
2015-08-03 17:57:33 +02:00
Vadim Zeitlin
0bb45d7387 Remove commented out code in wxWindowMac::MacPostControlCreate().
This code was moved into SetPeer() ~4 years ago in d15694e8, there is really
no need to keep a copy of it here as well.

No real changes.
2015-08-03 17:40:56 +02:00
Vadim Zeitlin
004b5a4f49 Don't use "u" option with ar(1).
It seems like it was never really needed as we always delete the archive
before creating it anyhow and there is no advantage in "updating" it if it
doesn't exist. Worse, with recent ar versions (like the one from binutils 2.25
in Debian Sid), using "u" results in a somewhat unclear warning

ar: `u' modifier ignored since `D' is the default (see `U')

so just get rid of it to avoid the warning.
2015-08-03 17:40:30 +02:00
Tobias Taschner
270d1a5916 Changed doc of EnableFullScreenView() to reflect OS X 10.10+ behaviour 2015-08-03 14:39:38 +02:00
Vadim Zeitlin
949d2eeaa5 Provide correct documentation for wxWindow::SetPosition().
Just refer to Move(), this is trivial but necessary as otherwise Doxygen
"helpfully" reuses the first comment in the section for the otherwise
undocumented SetPosition() which didn't make any sense at all.
2015-08-02 19:51:57 +02:00
Vadim Zeitlin
6339837ffa Correct the documentation of wxFrame ctor parent argument.
It doesn't result in the frame floating over its parent, this is what
wxFRAME_FLOAT_ON_PARENT style is for, it just means that the frame is
minimized/restored when its parent is.
2015-08-02 15:31:54 +02:00
Vadim Zeitlin
27bb67355a Avoid deprecation warnings for gtk_widget_modify_bg() in wxGTK3.
We still need to use this function as its replacement is itself deprecated in
GTK+ 3.16, so just suppress the warnings for now.

Closes #17084.
2015-08-02 15:18:14 +02:00
Tobias Taschner
658eca2896 Avoid run-time warnings for OS X version checks under 10.10+.
Remove UMAGetSystemVersion() function calling which produced the following
warning on the console for every call:

WARNING: The Gestalt selector gestaltSystemVersion is returning 10.9.4 instead
of 10.10.4. Use NSProcessInfo's operatingSystemVersion property to get correct
system version number.*

Replace UMAGetSystemVersion with wxPlatformInfo::CheckOSVersion() which
internally uses wxGetOSVersion, which uses Gestalt calls not resulting in this
runtime warning.

Closes https://github.com/wxWidgets/wxWidgets/pull/55
2015-08-02 03:15:11 +02:00
Vadim Zeitlin
237739ba01 Update OS X version examples in wxOSX readme.
Don't use the not supported any longer 10.5.
2015-08-02 03:11:37 +02:00
Vadim Zeitlin
8ea6b080bc Update the required OS X version in the introduction manual page.
While the platform details page correctly mentioned 10.7, the more visible
introduction page still spoke about 10.5 and even PPC.
2015-08-02 03:09:02 +02:00
Tobias Taschner
ab065e1ad9 Removed OS X code targeted at versions prior to OS X 10.7.
At least 10.7 is required in 3.1 anyhow, so don't check for it needlessly.

See https://github.com/wxWidgets/wxWidgets/pull/55
2015-08-02 03:05:51 +02:00
Vadim Zeitlin
00dacea7de Correct the default value of wxThread::Wait() flags in the documentation.
It is wxTHREAD_WAIT_DEFAULT, which can be/still is different from
wxTHREAD_WAIT_BLOCK.
2015-08-02 02:44:41 +02:00
Vadim Zeitlin
1f16829c01 Skip drawing empty AUI panes.
This seems to be unnecessary and generates GTK+ warnings as it results in
passing rectangle with negative (after accounting for padding/margins) size to
gtk_paint_box() in wxAuiGtkTabArt, as could be seen e.g. when closing
"wxTextCtrl 2" tab in the aui sample.
2015-07-31 16:45:13 +02:00
Vadim Zeitlin
0e5f3612df Fix assert when adding controls to wxAuiToolBar.
The code was always wrong as it added the control to a new sizer when it was
still element of an old one, but this went unnoticed until the changes of
efce9b2306 which now trigger an assert.

Fix this by deleting the old sizer, and thus breaking the association between
it and the controls inside it, before adding the controls to the new one.

Closes #17080.
2015-07-31 16:40:09 +02:00