Paul Cornett [Sun, 25 Nov 2012 02:49:42 +0000 (02:49 +0000)]
fix wxBitmapComboBox Gtk-CRITICAL assertion `GTK_IS_ENTRY (entry)' failed
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@73012
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
Paul Cornett [Sun, 25 Nov 2012 02:30:08 +0000 (02:30 +0000)]
non-pch build fix
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@73011
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
Paul Cornett [Sun, 25 Nov 2012 02:23:34 +0000 (02:23 +0000)]
Simplify GetDefaultAttributesFromGTKWidget() by passing the widget to use,
rather than a pointer to a function to create the widget
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@73010
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
Vadim Zeitlin [Sun, 25 Nov 2012 00:15:49 +0000 (00:15 +0000)]
Use idle time menu updating when using global menu bar in wxGTK.
We don't get wxEVT_MENU_OPEN events when using the global menu bar so don't
rely on them for updating the menu items status and fall back to idle time
menu updating if the global menu bar is used.
This required changing wxUSE_IDLEMENUUPDATES tests from compile- to run-time
ones.
Closes #14302.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@73009
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
Vadim Zeitlin [Sun, 25 Nov 2012 00:15:26 +0000 (00:15 +0000)]
Add wxApp::GTKIsUsingGlobalMenu() helper to wxGTK.
This allows to check whether the global menu is being used and will be mostly
useful for working around various bugs/problems uncovered by it.
See #14302.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@73008
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
Vadim Zeitlin [Sun, 25 Nov 2012 00:15:03 +0000 (00:15 +0000)]
Ignore menu events while modal dialogs are shown in wxGTK.
Normally menus are disabled in this case but not when running under Ubuntu
Unity, so add an explicit test for this to avoid breaking the program expected
flow of control by allowing the user to show the same modal dialog twice, for
example.
This is not ideal, it would be better to visually disable the menu while the
modal dialogs are shown but is better than nothing.
Closes #14823.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@73007
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
Vadim Zeitlin [Sat, 24 Nov 2012 23:01:45 +0000 (23:01 +0000)]
Blind compilation fix for VC6 after r73004.
Define wxDocTemplateVector for VC6 too, it's used in docview.cpp.
Also wrap too long lines.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@73006
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
Paul Cornett [Sat, 24 Nov 2012 21:49:04 +0000 (21:49 +0000)]
silence GCC warning "enumeral and non-enumeral type in conditional expression"
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@73005
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
Vadim Zeitlin [Sat, 24 Nov 2012 17:37:12 +0000 (17:37 +0000)]
Add wxDocManager::Get{Views,Documents,Templates}Vector().
Add accessors returning more convenient wxVectors to supplement the existing
ones giving access to internally used wxLists.
Closes #14814.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@73004
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
Vadim Zeitlin [Sat, 24 Nov 2012 17:36:44 +0000 (17:36 +0000)]
Add wxList::AsVector<>() helper.
This can be useful in legacy code using wxList to progressively replace it
with wxVector.
See #14814.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@73003
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
Vadim Zeitlin [Sat, 24 Nov 2012 17:36:19 +0000 (17:36 +0000)]
Don't include wx/utils.h from wx/vector.h.
This will allow to include wx/vector.h from wx/list.h which is itself included
from wx/utils.h by breaking this circular dependency.
Don't use wxMin(), defined in wx/utils.h, in order to do this.
See #14814.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@73002
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
Vadim Zeitlin [Sat, 24 Nov 2012 00:33:44 +0000 (00:33 +0000)]
Use wxBufferedPaintDC for wxStyledTextCtrl drawing in wxGTK.
GTK+ doesn't seem to use double buffering for Scintilla window for some
reason, resulting in bad flicker when it's updated, e.g. when the user types
into it.
Force the use of double buffering at wxWidgets level by using
wxBufferedPaintDC for painting it. This may be inefficient if GTK+ does double
buffer it in some cases but at least it gets rid of the flicker.
Closes #12704, #14828.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@73001
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
Vadim Zeitlin [Sat, 24 Nov 2012 00:33:19 +0000 (00:33 +0000)]
Add check for destroying window with mouse capture in wxGTK.
We already have an assert checking for this at wxWindowBase level but it seems
that it wasn't always triggered somehow (maybe because we crashed before
getting there?), so do it sooner.
Closes #14602.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@73000
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
Stefan Csomor [Fri, 23 Nov 2012 19:02:01 +0000 (19:02 +0000)]
support for custom app controllers, override OSXCreateAppController in wxApp subclass
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72999
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
Vadim Zeitlin [Fri, 23 Nov 2012 14:34:31 +0000 (14:34 +0000)]
Fix ribbon bar scroll buttons visibility bug.
Fix scroll buttons update code in wxRibbonPage.
Closes #14844.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72998
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
Vadim Zeitlin [Fri, 23 Nov 2012 14:32:15 +0000 (14:32 +0000)]
Add possibility to delay showing wxRichToolTip.
Optionally show the tooltip after a delay instead of doing it immediately when
Show() is called.
Closes #14846.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72997
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
Stefan Csomor [Fri, 23 Nov 2012 07:55:58 +0000 (07:55 +0000)]
fixing overrelease and out-of-bounds write, fixes #13725
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72996
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
Vadim Zeitlin [Tue, 20 Nov 2012 12:49:53 +0000 (12:49 +0000)]
Implement GetSizeFromTextSize() for wxSpinCtrl.
Implement it for the native MSW and GTK versions and the generic one used in
the other ports and also for wxSpinCtrlDouble under MSW.
Also test this function in the spin page of the widgets sample.
Closes #14840.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72995
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
Vadim Zeitlin [Tue, 20 Nov 2012 12:49:29 +0000 (12:49 +0000)]
Make wxSpinCtrlGenericBase a wxCompositeWindow.
This takes care of propagating methods setting fonts and colours to the
subwindows automatically, so that setting font for the generic wxSpinCtrl now
works, unlike before.
Closes #14839.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72994
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
Vadim Zeitlin [Tue, 20 Nov 2012 12:49:03 +0000 (12:49 +0000)]
Revert all wxNOEXCEPT-related changes.
This reverts r72978, 72984, 72989 and 72992. Do not use wxNOEXCEPT for
wxTextCtrl dtor as this breaks compilation of any user-defined classes
inheriting from it unless they use wxNOEXCEPT as well and the benefits
(fixing a harmless warning for the niche ICC compiler) are just not worth
the compatibility breakage.
See #14826.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72993
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
Vadim Zeitlin [Tue, 20 Nov 2012 00:57:25 +0000 (00:57 +0000)]
Fix another compilation problem after wxNOEXCEPT introduction.
Also add wxNOEXCEPT to wxTextCtrl dtor definition in wxMSW.
See #14826.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72992
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
Vadim Zeitlin [Mon, 19 Nov 2012 18:07:55 +0000 (18:07 +0000)]
Add wxTL_NO_HEADER style to wxTreeListCtrl.
Closes #14838.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72990
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
Vadim Zeitlin [Mon, 19 Nov 2012 18:01:01 +0000 (18:01 +0000)]
More compilation fixes after wxNOEXCEPT introduction.
This is a temporary change, r72984 and the following changes (see #14826) will
probably be reverted soon anyhow, but for now at least fix wxGTK compilation.
Closes #14837.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72989
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
Stefan Csomor [Mon, 19 Nov 2012 13:06:01 +0000 (13:06 +0000)]
implementing delayed freezing, fixes #12865
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72988
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
Vadim Zeitlin [Mon, 19 Nov 2012 12:52:18 +0000 (12:52 +0000)]
Add wxFSW_EVENT_UNMOUNT wxFileSystemWatcher flag and implement it for Linux.
This flag generates the corresponding event when the file system containing
the watched directory is unmounted. Currently it is only implemented for
Linux where unmounting now generates this event instead of an error.
Closes #14834.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72987
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
Vadim Zeitlin [Mon, 19 Nov 2012 12:51:54 +0000 (12:51 +0000)]
Convert wxFSW_EVENT_{WARNING,ERROR} to string correctly.
Previously these types were not handled at all, resulting in asserts.
See #14834.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72986
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
Vadim Zeitlin [Mon, 19 Nov 2012 11:54:12 +0000 (11:54 +0000)]
Implement wxLocale::GetSystemEncodingName() for wxOSX.
Use CFStringGetNameOfEncoding() to get the canonical name of the encoding from
OS X itself.
Closes #2571.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72985
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
Vadim Zeitlin [Mon, 19 Nov 2012 11:53:49 +0000 (11:53 +0000)]
Add wxNOEXCEPT to all wxTextCtrl dtors.
Fix compilation with some compilers after r72978 which added wxNOEXCEPT to
wxTextCtrlBase dtor and wxTextCtrl dtor in wxMSW but not in all the other
ports.
See #14826.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72984
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
Paul Cornett [Mon, 19 Nov 2012 04:17:42 +0000 (04:17 +0000)]
put both versions of wxGetMousePosition in one place so they can use one implementation
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72983
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
Paul Cornett [Mon, 19 Nov 2012 02:29:24 +0000 (02:29 +0000)]
fix object referencing with wxSL_MIN_MAX_LABELS
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72982
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
Vadim Zeitlin [Sun, 18 Nov 2012 00:17:07 +0000 (00:17 +0000)]
Define SPI_GETCARETWIDTH ourselves if it's not defined.
This fixes another compilation error for VC6.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72981
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
Vadim Zeitlin [Sun, 18 Nov 2012 00:14:37 +0000 (00:14 +0000)]
Compilation fixes for VC6 after MSWGetComboBoxInfo() introduction.
Don't use COMBOBOXINFO outside of WINVER checks, we can only use
tagCOMBOBOXINFO that we forward declared ourselves.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72980
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
Vadim Zeitlin [Sat, 17 Nov 2012 23:56:47 +0000 (23:56 +0000)]
Fix path returned from wxGTK wxFileDialog too.
This is similar to the fixes to wxDirDialog in r72779.
Closes #14786.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72979
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
Vadim Zeitlin [Sat, 17 Nov 2012 23:56:23 +0000 (23:56 +0000)]
Add wxNOEXCEPT and use it for std::streambuf-derived classes.
This fixes warnings from Intel compiler about overriding function using a
different exception specification than the base one and also incidentally
provides a handy macro that can be useful in other situations.
Closes #14826.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72978
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
Vadim Zeitlin [Sat, 17 Nov 2012 23:56:00 +0000 (23:56 +0000)]
Add wxFSW_EVENT_ATTRIB wxFileSystemWatcher flag.
This flag allows to monitor changes to the file attributes, such as file
modification time.
This patch adds the flag, support for it under Linux and the corresponding
modifications to the sample and the test suite.
Closes #14833.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72977
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
Vadim Zeitlin [Sat, 17 Nov 2012 23:55:35 +0000 (23:55 +0000)]
Fix typo in include/wx/generic/private/richtooltip.h header guard.
A wrong symbol was being defined.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72976
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
Robin Dunn [Sat, 17 Nov 2012 22:17:10 +0000 (22:17 +0000)]
Fix broken and missing DataView interface items for Phoenix
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72966
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
Steve Lamerton [Sat, 17 Nov 2012 13:34:09 +0000 (13:34 +0000)]
Fixed unused parameter warnings for webview on OSX.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72965
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
Paul Cornett [Fri, 16 Nov 2012 07:35:53 +0000 (07:35 +0000)]
avoid deprecated functions with GTK3
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72964
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
Paul Cornett [Fri, 16 Nov 2012 07:30:07 +0000 (07:30 +0000)]
silence warnings about unhandled enum value in switch
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72963
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
Paul Cornett [Fri, 16 Nov 2012 07:24:29 +0000 (07:24 +0000)]
Remove code that has no effect
Adjusting the wxEVT_ENTER_WINDOW mouse position is pointless, execution won't reach that far if
gdk_event->window != gtk_widget_get_window(widget), and GetClientAreaOrigin() always returns (0,0).
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72962
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
Vadim Zeitlin [Thu, 15 Nov 2012 22:24:22 +0000 (22:24 +0000)]
Support monitoring only some events in wxGTK wxFileSystemWatcher.
Call inotify() with the appropriate flags instead of always using IN_ALL_EVENTS.
Closes #14832.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72961
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
Vadim Zeitlin [Thu, 15 Nov 2012 18:48:55 +0000 (18:48 +0000)]
Restore setting focus to generic wxDataViewCtrl on any mouse click.
The changes of r72632 resulted in focus not being given to
wxDataViewMainWindow on right or middle click, restore this behaviour.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72960
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
Vadim Zeitlin [Thu, 15 Nov 2012 18:45:42 +0000 (18:45 +0000)]
Document how to build wxOSX/Carbon under recent OS X.
Mention that Xcode 3 is needed for this.
Closes #14524.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72959
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
Vadim Zeitlin [Thu, 15 Nov 2012 12:22:05 +0000 (12:22 +0000)]
Add back WINVER check to fix VC6 compilation of wxMSW.
The changes of r72953 removed the check for WINVER around the code using
COMBOBOXINFO but it's still needed with VC^, so restore it.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72958
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
Paul Cornett [Wed, 14 Nov 2012 18:19:25 +0000 (18:19 +0000)]
Fix GetClientSize() when scrollbars are present
The value of GtkScrolledWindowClass.scrollbar_spacing seems to be invalid (-1).
Use the style property "scrollbar-spacing" instead.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72957
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
Paul Cornett [Wed, 14 Nov 2012 16:55:24 +0000 (16:55 +0000)]
re-enable using our own resize grip with GTK3, themes can (and do) disable the native grip
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72956
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
Vadim Zeitlin [Wed, 14 Nov 2012 13:48:23 +0000 (13:48 +0000)]
Implement wxComboCtrl::GetSizeFromTextSize().
Improve calculation of wxComboCtrl best size which doesn't work correctly for
non-default fonts as shown by r72935. It is still not perfect but better now.
Closes #14825.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72955
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
Vadim Zeitlin [Wed, 14 Nov 2012 13:47:59 +0000 (13:47 +0000)]
Implement DoGetSizeFromTextSize() for wxMSW wx{Choice,Combobox,TextCtrl}.
Refactor and improve the existing DoGetBestSize() implementations to use
DoGetBestSize().
Closes #14816.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72954
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
Vadim Zeitlin [Wed, 14 Nov 2012 13:47:36 +0000 (13:47 +0000)]
No changes, just refactor wxMSW wxComboBox code calling GetComboBoxInfo().
Move the code dynamically loading this function to the base wxChoice class to
make it possible to use it from there in the upcoming commit.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72953
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
Vadim Zeitlin [Wed, 14 Nov 2012 13:47:13 +0000 (13:47 +0000)]
Handle wxBORDER_NONE in wxGTK wxTextCtrl::DoGetSizeFromTextSize().
Don't add margins for the controls without borders, they are not used in this
case.
See #14816.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72952
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
Vadim Zeitlin [Wed, 14 Nov 2012 13:46:50 +0000 (13:46 +0000)]
Don't call setlocale("") on startup by default any longer.
This undoes the changes of r44773 because calling setlocale() resulted in C
locale being set differently from C++ locale which was confusing and led to
huge slowdowns in any code using std::stream with at least MinGW. And setting
the C++ locale to be the same, as r72719 tried to do, doesn't seem to be
practical as it results in immediate crashes under OS X and MinGW when used
under XP.
Do provide wxApp::SetCLocale() helper to explicitly do what was previously
done implicitly, even though currently it is a trivial wrapper for setlocale()
and we don't even need to call gtk_set_locale() as it has never done anything
else and is deprecated since GTK+ 2.24.
Closes #14780.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72951
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
Vadim Zeitlin [Wed, 14 Nov 2012 00:16:16 +0000 (00:16 +0000)]
Optionally allow showing tooltips for disabled ribbon buttons.
Add wxRibbonButtonBar::SetShowToolTipsForDisabled() to allow enabling the
tooltips even for the disabled buttons.
Closes #14820.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72950
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
Paul Cornett [Tue, 13 Nov 2012 17:38:29 +0000 (17:38 +0000)]
re-enable drawing our own resize grip with GTK3, themes can (and do) disable the native grip
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72949
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
Václav Slavík [Tue, 13 Nov 2012 12:36:32 +0000 (12:36 +0000)]
Fix wxGTK's wxFileDialog:Get/SetFilename() to be in sync.
The m_fileName and m_dir variables, managed by the base class, were out
of sync when the dialog wasn't shown yet, because the wxGTK
implementation didn't always set them. GetFilename() following
SetFilename(x) could return something other than x. Fixed by calling the
base class version.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72948
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
Vadim Zeitlin [Mon, 12 Nov 2012 15:50:13 +0000 (15:50 +0000)]
Replace a template function with template class to fix VC6 build.
VC6 doesn't like template methods, so use a helper template class instead,
hopefully this will finally allow it to compile the test suite again.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72947
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
Stefan Csomor [Mon, 12 Nov 2012 13:36:46 +0000 (13:36 +0000)]
making sure we have an initial frame buffer, even though the first initial rootview controller lead to an empty framebuffer
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72946
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
Vadim Zeitlin [Sun, 11 Nov 2012 13:10:21 +0000 (13:10 +0000)]
Use wxID_EXIT for the "Quit" item in the exec sample.
This fixes the behaviour of the standard "Quit" menu item under OS X.
See #3204.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72945
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
Vadim Zeitlin [Sat, 10 Nov 2012 12:40:47 +0000 (12:40 +0000)]
Disallow drop downs on AUI check buttons.
This doesn't make much sense and disallowing it makes check items consistent
with radio ones as previously you could set up a dropdown for the former but
not for the latter.
Also update the documentation of the relevant methods.
Closes #14795.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72944
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
Vadim Zeitlin [Sat, 10 Nov 2012 12:22:32 +0000 (12:22 +0000)]
Fix crashes after using "wildcard" wxEvtHandler::Disconnect().
When not specifying the function to disconnect, the associated event sink was
destroyed too early resulting in crashes later. Fix this and add unit tests
verifying that things work as expected and at least don't crash.
Closes #14563.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72943
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
Vadim Zeitlin [Sat, 10 Nov 2012 12:22:09 +0000 (12:22 +0000)]
No changes, just fix a harmless warning in FileSystemWatcherTestCase.
Fix an unused parameter warning under non-Unix platforms.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72942
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
Vadim Zeitlin [Sat, 10 Nov 2012 12:21:46 +0000 (12:21 +0000)]
Fix filename test compilation with VC6.
Just disable tests resulting in an internal compiler error.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72941
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
Vadim Zeitlin [Sat, 10 Nov 2012 00:53:42 +0000 (00:53 +0000)]
Fix link errors with VC 11 in DLL STL build.
Don't declare wxWindowList as DLL-exported. It's unnecessary and appears to
create problems for VC 11.
Closes #14741.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72940
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
Vadim Zeitlin [Sat, 10 Nov 2012 00:53:17 +0000 (00:53 +0000)]
Simplify wxEVT_PAINT handling in wxScrollHelperBase.
Just always call the virtual OnDraw() if wxEVT_PAINT wasn't handled. This is
much simpler than connecting our own special handler just to set a flag saying
whether the event was processed which was very complicated and didn't work
anyhow for the statically connected wxEVT_PAINT handlers.
See #14757.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72939
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
Vadim Zeitlin [Sat, 10 Nov 2012 00:52:54 +0000 (00:52 +0000)]
Cache HDC used for painting for the entire duration of WM_PAINT processing.
This fixes a long standing problem with 2 wxPaintDC created one after another
(and not with nested lifetimes, which was handled by the caching mechanism
previously used) not working correctly. And as this was exactly what happened
when handling wxEVT_PAINT for wxScrolled, it also fixes drawing artefacts when
using scrolled windows.
Closes #14757.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72938
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
Vadim Zeitlin [Sat, 10 Nov 2012 00:52:31 +0000 (00:52 +0000)]
Fix incorrect wxSizerFlags::Border() call in the scroll sample.
Using 20 instead of a wxDirection resulted in an assert, fix the syntax.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72937
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
Vadim Zeitlin [Sat, 10 Nov 2012 00:52:08 +0000 (00:52 +0000)]
Set ID correctly for wxScrollWinEvents generated by wxScrollHelper.
Add forgotten wxEvent::SetId() calls.
See #14757.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72936
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
Vadim Zeitlin [Fri, 9 Nov 2012 21:11:37 +0000 (21:11 +0000)]
Add wxControl::GetSizeFromTextSize() to size the control to its text.
This function can be used to size a, say, wxTextCtrl to be exactly of the size
needed to enter the given amount of text in it.
This patch adds wxGTK implementation for wxTextCtrl, wxChoice and wxCombobox;
changes to the samples and the documentation.
Closes #14812.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72935
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
Paul Cornett [Fri, 9 Nov 2012 06:17:11 +0000 (06:17 +0000)]
avoid deprecated functions with GTK3
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72934
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
Robin Dunn [Fri, 9 Nov 2012 05:02:52 +0000 (05:02 +0000)]
wxBrushList and wxFontList do not derive from wxList.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72933
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
Paul Cornett [Thu, 8 Nov 2012 17:47:16 +0000 (17:47 +0000)]
don't assign NULL to wxUIntPtr, wxUIntPtr is not a pointer, closes #14811
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72927
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
Paul Cornett [Thu, 8 Nov 2012 17:34:04 +0000 (17:34 +0000)]
avoid using deprecated gdk_cursor_unref() with GTK3
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72926
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
Paul Cornett [Thu, 8 Nov 2012 17:18:40 +0000 (17:18 +0000)]
Disable GTK2-specific code to change theme when building wxGTK3.
It doesn't work with GTK3, it causes deprecation warnings, and allowing
an app to change its theme is a dumb idea
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72925
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
Stefan Csomor [Thu, 8 Nov 2012 15:46:23 +0000 (15:46 +0000)]
support for freeze and thaw under cocoa
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72924
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
Vadim Zeitlin [Thu, 8 Nov 2012 14:20:53 +0000 (14:20 +0000)]
No changes, just remove unnecessary forward declarations.
wxToggleBitmapButton doesn't exist any more, don't forward declare it.
wxToggleButton does exist but is (fully) declared just below, so don't forward
declare it neither.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72923
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
Vadim Zeitlin [Wed, 7 Nov 2012 18:10:38 +0000 (18:10 +0000)]
Another Nepalese translations update from Him Prasad Gautam.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72922
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
Paul Cornett [Wed, 7 Nov 2012 17:58:23 +0000 (17:58 +0000)]
update fullscreen state when it is changed by the WM
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72921
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
Jouk Jansen [Wed, 7 Nov 2012 10:02:04 +0000 (10:02 +0000)]
Update OpenVMS make-files
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72920
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
Jouk Jansen [Wed, 7 Nov 2012 09:00:25 +0000 (09:00 +0000)]
Fix for specific filename syntax of OpenVMS
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72919
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
Paul Cornett [Wed, 7 Nov 2012 06:32:51 +0000 (06:32 +0000)]
add GTK3 implementations for remaining renderer functions
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72918
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
Vadim Zeitlin [Tue, 6 Nov 2012 23:57:06 +0000 (23:57 +0000)]
Don't leave orphan taskbar icon window alive if setting it up fails.
This fixes a rare bug which happens when we fail to install the task bar icon
under MSW for whatever reason (the only known way to reproduce it is to try to
do it very quickly after resume from suspend but there might be other
situations in which this happens). In this case we must delete the icon as we
are not going to get any timeout expiration notifications for it and so if we
don't delete it immediately, it would remain alive forever, preventing the
application from exiting as it counts as a top level window.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72917
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
Vadim Zeitlin [Tue, 6 Nov 2012 23:56:44 +0000 (23:56 +0000)]
Keep item data in sync with their position in wxEditableListBox.
When swapping the items, we also need to swap their client data and not just
their labels.
Closes #14800.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72916
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
Vadim Zeitlin [Tue, 6 Nov 2012 23:56:21 +0000 (23:56 +0000)]
Restore propagation of EVT_SEARCHCTRL_CANCEL_BTN events to the parent.
This was broken by r72581, add event.Skip() call to the handler for this event
added there.
Also add a handler for this event to the corresponding page of the widgets
sample to be able to test this.
Closes #14799.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72915
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
Vadim Zeitlin [Tue, 6 Nov 2012 23:54:47 +0000 (23:54 +0000)]
Fix regression with wxAuiToolBar gripper and overflow members initialization.
The changes of r72785 moved m_gripperVisible and m_overflowVisible
initialization to Init() but this was too early as these fields depend on the
window style only set when it's really created, so re-initialize them to their
proper values in Create().
Closes #14794.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72914
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
Vadim Zeitlin [Tue, 6 Nov 2012 23:54:25 +0000 (23:54 +0000)]
Use wxAUI_TB_DEFAULT_STYLE instead of 0 as default style value.
No real changes.
See #14794.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72913
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
Vadim Zeitlin [Tue, 6 Nov 2012 23:54:02 +0000 (23:54 +0000)]
Minor improvements to wxEVT_COMMAND_DIRCTRL_CHANGED generation.
Set the event object for this event. Also don't skip the original tree event
if the wxEVT_COMMAND_DIRCTRL_CHANGED event was handled and disallowed.
Closes #14792.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72912
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
Vadim Zeitlin [Tue, 6 Nov 2012 23:53:39 +0000 (23:53 +0000)]
Add wxUSE_BASE checks for wxLog classes in the interface header.
Also rearrange them so that the derived classes always appear after the base
ones, otherwise SWIG can't compile this file.
Closes #14784.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72911
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
Vadim Zeitlin [Tue, 6 Nov 2012 23:53:17 +0000 (23:53 +0000)]
Add wxUSE_{BASE,GUI} checks to interface headers.
This allows to define just one of them to run some tool, e.g. SWIG, on only
the classes defined in the base or in the core library (both are defined by
default for Doxygen itself).
Closes #14785.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72910
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
Paul Cornett [Tue, 6 Nov 2012 17:43:34 +0000 (17:43 +0000)]
add GTK3-specific code for DrawItemSelectionRect(), fixes drawing selected tree control item
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72908
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
Vadim Zeitlin [Tue, 6 Nov 2012 16:51:41 +0000 (16:51 +0000)]
No changes, just fix indentation in wxDataViewMainWindow::Expand().
The code was indented two extra levels for some reason.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72907
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
Vadim Zeitlin [Tue, 6 Nov 2012 16:51:18 +0000 (16:51 +0000)]
Update the current row after item deletion in generic wxDataViewCtrl.
Also change the code changing the current item to collect the range checks
inside OnVerticalNavigation() itself instead of doing them in the caller.
Closes #14802.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72906
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
Vadim Zeitlin [Tue, 6 Nov 2012 16:50:56 +0000 (16:50 +0000)]
Never collapse invisible root item in generic wxDataViewCtrl.
Since the changes of r72325, the root item could be collapsed and marked as
not having any children but this was wrong because no items could be added to
it after this.
Just ignore any attempts to collapse it.
Closes #14801.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72905
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
Vadim Zeitlin [Tue, 6 Nov 2012 16:25:18 +0000 (16:25 +0000)]
Remove __WXMSW__ check around background erasing in generic wxDataViewCtrl.
The background was erased only under MSW for some reason, do it everywhere
now.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72904
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
Stefan Csomor [Tue, 6 Nov 2012 06:35:29 +0000 (06:35 +0000)]
fixing compile for ios
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72903
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
Stefan Csomor [Tue, 6 Nov 2012 06:31:29 +0000 (06:31 +0000)]
supporting iOS 6 autorotate
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72902
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
Vadim Zeitlin [Sun, 4 Nov 2012 23:55:22 +0000 (23:55 +0000)]
Slightly improve the date/time dialogs in the calendar sample.
Use CreateStdDialogButtonSizer() instead of constructing
wxStdDialogButtonSizer directly, not only this is shorter but it also makes
the "OK" button default correctly.
Also initialize the labels instead of leaving them initially empty.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72898
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
Vadim Zeitlin [Sun, 4 Nov 2012 23:55:00 +0000 (23:55 +0000)]
Don't move the insertion point if text didn't change in wxTextEntry.
This avoids accidentally resetting the selection if SetValue() is called again
with the same value.
Closes #13728.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72897
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
Vadim Zeitlin [Sun, 4 Nov 2012 23:54:37 +0000 (23:54 +0000)]
Make hack for button creation in wxOSX more robust.
Don't crash when creating a plain wxButton with wxBU_NOTEXT style. This
happened because we skipped creating the peer (real implementation) in this
case entirely on the assumption that we were creating a wxBitmapButton, but
this is not necessarily the case. So now test that the creation of the peer is
really disabled before skipping it (this required adding ShouldCreatePeer()
accessor).
Merging wxWidgetImpl::CreateButton() and CreateBitmapButton() (and the same
thing for toggle buttons) would still be a better solution but while it's
trivial to do for Cocoa, it isn't for Carbon. And we can't use a single
function for Cocoa but different functions for Carbon, so for now just
continue to use this hack.
Closes #13622.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72896
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
Vadim Zeitlin [Sun, 4 Nov 2012 23:54:15 +0000 (23:54 +0000)]
Ensure that paths used inside wxOSX are always in NFC form.
OSX uses NFKD but this is unexpected for wx applications, so normalize the
string to use the composed form whenever we receive a file system path from OS
X.
Closes #13504.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72895
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
Vadim Zeitlin [Sun, 4 Nov 2012 23:53:52 +0000 (23:53 +0000)]
Add wxCFStringRef::AsStringWithNormalizationFormC() Cocoa overload.
Provide an overload taking NSString and casting it to CFStringRef, just as for
AsStringWithNormalizationFormC().
See #13504.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72894
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775