Commit Graph

83 Commits

Author SHA1 Message Date
Ian McInerney
4ac648901d Don't allow using GetPath/GetFilename() with wxFD_MULTIPLE
GetPaths/GetFilenames() must be used instead when more than one file
could be selected: document this and assert if the wrong functions are
called.

Closes https://github.com/wxWidgets/wxWidgets/pull/1883
2020-06-22 14:04:10 +02:00
oneeyeman1
8748a476c3 Add flag for displaying hidden files in the file dialog
Add wxFD_SHOW_HIDDEN and implement support for it for all the major
ports.

Closes https://github.com/wxWidgets/wxWidgets/pull/1413

Closes #9342.
2019-07-16 19:59:48 +02:00
QuentinC
413abb066e Allow retrieving current filter from wxFileDialog extra controls
Add wxFileDialog::GetCurrentlySelectedFilterIndex() similar to the
existing GetCurrentlySelectedFilename(), which can be used to retrieve
the index of the currently selected filter and update the state of the
extra controls in wxFileDialog accordingly.

Implement this for wxMSW only by updating the internally stored value
from the native CDN_TYPECHANGE notification and also generating a
wxEVT_UPDATE_UI event to allow the extra controls to update themselves.

Closes https://github.com/wxWidgets/wxWidgets/pull/1310
2019-05-02 19:53:05 +02:00
Dimitri Schoolwerth
8f8d58d193 Use wx-prefixed macros throughout the repository.
Change {DECLARE,IMPLEMENT}_*CLASS and {DECLARE,BEGIN,END}_EVENT_TABLE
occurrences to use the wx-prefixed version of the macros.
2015-04-23 22:00:35 +04:00
Vadim Zeitlin
b7388f36f2 Change wxFD_MULTIPLE value to avoid conflict with wxDIALOG_NO_PARENT.
This avoids GTK+ warnings about creating a dialog without parent when a
wxFileDialog with wxFD_MULTIPLE style is created.

Closes #16863.
2015-03-02 14:32:53 +01:00
Vadim Zeitlin
47e13f2be0 Update wxFileDialog filter index when setting its path.
This ensures that GetFilename() and GetFilterIndex() always return consistent
results, even if the path was set programmatically, e.g. during unattended
tests using wxExpectModal<wxFileDialog>.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@77471 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-08-24 15:31:55 +00:00
Vadim Zeitlin
df13791078 Merge wxQT branch into the trunk.
This merges in the latest sources from GSoC 2014 wxQt project with just a few
minor corrections, mostly undoing wrong changes to common files in that branch
(results of a previous bad merge?) and getting rid of whitespace-only changes.
Also remove debug logging from wxGrid.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@77455 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-08-24 01:50:11 +00:00
Vadim Zeitlin
1ca1d77e01 Remove the inclusions of wx/cocoa headers which don't exist any more.
This should have been part of r76735: in addition to removing the old Cocoa
port headers, also remove the references to them from the common include
files.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76806 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-07-02 13:28:42 +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
050fabe3b9 Add wxFD_NO_FOLLOW style for wxFileDialog.
This style tells the dialog to return the paths of the link being selected
without dereferencing it.

Currently only implemented under wxMSW as the links are not dereferenced by
default in wxGTK anyhow. But we may want to change this and implement it there
too for consistency in the future.

Closes #15429.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76085 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-03-05 16:29:46 +00:00
Paul Cornett
967a94c91a remove WXWIN_COMPATIBILITY_2_6, add WXWIN_COMPATIBILITY_3_0
closes #15792

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@75532 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-01-04 20:07:33 +00:00
Vadim Zeitlin
3f66f6a5b3 Remove all lines containing cvs/svn "$Id$" keyword.
This keyword is not expanded by Git which means it's not replaced with the
correct revision value in the releases made using git-based scripts and it's
confusing to have lines with unexpanded "$Id$" in the released files. As
expanding them with Git is not that simple (it could be done with git archive
and export-subst attribute) and there are not many benefits in having them in
the first place, just remove all these lines.

If nothing else, this will make an eventual transition to Git simpler.

Closes #14487.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@74602 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2013-07-26 16:02:46 +00:00
Vadim Zeitlin
926df8a162 Add wxFileDialog::GetCurrentlySelectedFilename().
Also send wxEVT_UPDATE_UI events for the extra controls in wxFileDialog.

The combination of these changes allows extra controls to update their state
depending on the current selection in the dialog. Show a simple example of
doing it in the dialogs sample.

Closes #15235.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@74071 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2013-05-31 23:21:27 +00:00
Vadim Zeitlin
bd362275b8 Remove Palm OS port.
The platform targeted by this port doesn't exist any more and the port never
achieved really working state so remove the code to avoid having to maintain
it.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@70345 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-01-15 01:05:28 +00:00
Vadim Zeitlin
7430a4bbf8 Make wxFileDialog::Set/SetPath() behave consistently.
wxFileDialog::GetPath() didn't return the value set by a previous call to
SetPath() in wxMSW version. Fix this and also implement SetPath() and
SetDirectory() methods in the generic versions in the same way as
SetFilename().

Closes #3672.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@62722 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2009-11-26 16:17:00 +00:00
Vadim Zeitlin
c0c133e13b add wx-prefixed and semicolon-requiring versions of DECLARE_NO_{COPY,ASSIGN}_CLASS macros
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@58757 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2009-02-08 11:45:59 +00:00
Vadim Zeitlin
f92ec19302 no changes, just corrected/completed a comment truncated in the last commit
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@58495 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2009-01-29 12:52:55 +00:00
Vadim Zeitlin
26078494a0 add wxHAS_MULTIPLE_FILEDLG_FILTERS symbol to be used instead of explicit tests for the platforms
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@58492 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2009-01-29 12:50:06 +00:00
Vadim Zeitlin
d6dae1b443 minor fixes for custom controls support in wxFileDialog: slightly improve documentation, make variable names more clear and add more WinCE checks (closes #10416)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@58353 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2009-01-24 14:04:25 +00:00
Vadim Zeitlin
6fa6d65956 allocate size for the extra controls in the file dialog (#9679)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@58270 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2009-01-21 15:32:02 +00:00
Stefan Csomor
ef0e92205a fixing file paths after renaming
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@54125 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2008-06-11 19:17:41 +00:00
Francesco Montorsi
53a2db124c substitute WXDLLEXPORT with WXDLLIMPEXP_CORE and WXDLLEXPORT_DATA with WXDLLIMPEXP_DATA_CORE
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@52834 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2008-03-26 15:06:00 +00:00
Vadim Zeitlin
8ce68f7fc0 add support for custom controls in file dialog in wxGTK and generic versions; also allow using generic dialogs in the sample with wxGTK2 (patch 1846837)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@52252 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2008-03-02 14:33:47 +00:00
Vadim Zeitlin
a85ad1db05 use generic dialogs under Palm (generic.diff part of patch 1894861)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@52234 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2008-03-02 01:20:08 +00:00
Vadim Zeitlin
f36e602b3f make various control names constants of type char, not wxChar, as this is more compatible with the old ANSI build and it doesn't make much sense to use wchar_t for ASCII strings anyhow
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@49873 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2007-11-12 21:37:46 +00:00
Vadim Zeitlin
ff654490b7 removed all compile- and run-time checks for GTK+ < 2.4; don't include the generic files which are now never used in wxGTK in the build
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@49660 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2007-11-05 22:31:24 +00:00
Robert Roebling
700d08c109 [ 1823588 ] gtk filedlg - droping support for gtk 2.2
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@49649 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2007-11-05 18:43:14 +00:00
Vadim Zeitlin
0cf3e587a2 added new and improved wxFileCtrl implementation (patch 1763164)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@48733 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2007-09-17 00:14:34 +00:00
Vadim Zeitlin
b2f0b9342a removed unused wxUSE_XXX options (patch 1759328)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@47765 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2007-07-28 00:08:01 +00:00
Václav Slavík
6dc2e82330 fix Watcom compilation: removed templates for wxFileSelector() compatibility with passing NULL
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@47231 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2007-07-08 08:40:37 +00:00
Václav Slavík
f8bcb37d99 changed wxFileSelector() etc. functions to use wxString (so that any forms of strings can be used with it, not just wxChar*), while still preserving compatibility with passing NULL to them)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@46317 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2007-06-04 09:53:17 +00:00
Vadim Zeitlin
c1dc9f8394 removed WXWIN_COMPATIBILITY_2_4 from common and wxMSW files (patch 1675546)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@44625 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2007-03-07 11:35:04 +00:00
Vadim Zeitlin
cc197ed421 restored (as deprecated) accidentally removed wx{Dir|File}Dialog::Get/SetStyle()
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@44027 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2006-12-21 19:26:48 +00:00
Robert Roebling
45f4109c41 Move the wxFD_... flags back into m_windowStyle
as requested. Add the list if flags, with which
    the wxFD_ flags have to cooperate into the
    header of wxFileDialog.


git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@42495 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2006-10-27 08:45:22 +00:00
Robert Roebling
b014db05bb Add m_fsStyle next to m_windowStyle
Add HasFdFlag()
  Use it for all tests in all variants of
    wxFileDialogs. That way it will be easier
    to change again centrally, if required.


git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@42399 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2006-10-25 13:26:47 +00:00
Vadim Zeitlin
9f057af5ef wxFD_PREVIEW implementation for wxGTK (slightly modified patch 1520690)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@40292 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2006-07-24 23:48:06 +00:00
Robert Roebling
a84f5f39b8 Correct compilation for GTK < 2.4.
Remove double testing for __WXMGL__ and __WXX11__
    after testing for __UNIVERSAL__


git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@39631 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2006-06-08 10:05:42 +00:00
Włodzimierz Skiba
e031f1df56 wxFD_* constants without 2.6 compatibility (heavily extended and modified patch #1497305).
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@39469 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2006-05-30 07:25:35 +00:00
Vadim Zeitlin
ff3e84ffdc File/dir dialog styles and other changes (patch 1488371):
- check invalid combinations of styles in wxFileDialogBase::Create()
- use wxFD_XXX naming convention for wxFileDialog styles
- replaces wxDD_NEW_DIR_BUTTON with wxDD_DIR_MUST_EXIST
- removes #ifdef __WXGTK24__ / #endif blocks from wxGTK code
- removes wxFileDialogBase::Get/SetStyle and wxFileDialogBase::m_fileName
- renames wxDirDialogGTK to wxDirDialog


git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@39402 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2006-05-28 23:32:12 +00:00
Michael Wetherell
7e52dfd26d gtk1 fixes
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@37075 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2006-01-23 14:29:29 +00:00
Mart Raudsepp
1be7a35c5e Include gtk1 headers for non-gtk2. I don't really like this CPP logic, or more exactly __WXGTK__ without __WXGTK20__
being GTK1, oh well.
Might have missed some.


git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@37066 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2006-01-23 03:27:34 +00:00
Mart Raudsepp
63ec432bd7 Move constant strings to .rodata/.data.rel.ro ELF segment from .data by making them really const.
If any more exotic toolchain decides to not export these strings into the core library anymore, let me know. Try to
compile the notebook sample, for example.
TODO: Move strings not meant for wxCore out of wxCore to the appropriate library.


git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@36891 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2006-01-16 14:59:55 +00:00
Vadim Zeitlin
1e966cc4c8 remvoed wxFileDialogBase::m_parent as there is already one in wxWindow
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@36121 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2005-11-08 01:33:33 +00:00
Mart Raudsepp
8907154c1a Nuke #pragma implementation/interface's
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@35650 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2005-09-23 12:56:45 +00:00
Włodzimierz Skiba
2ecf902bc8 Use defs.h (and automatically setup.h and chkconf.h) before first wxUSE_* check (bug #1164141).
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@32852 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2005-03-16 16:18:31 +00:00
Vadim Zeitlin
fe6cf12844 init member variables properly (patch 1156088)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@32660 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2005-03-08 00:29:56 +00:00
Włodzimierz Skiba
16cba29d3a Warning fixes for MinGW.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@31552 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2005-01-21 18:48:22 +00:00
Włodzimierz Skiba
eecb33b018 Old API deprecated. Use new and remove old usage where necessary.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@31305 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2005-01-10 17:21:16 +00:00
Robert Roebling
4e1901b70e Moved the implemtation of the generic and the
native GTK 2.4 file dialogs into one place
   by making wxFileDialog derive from the
   generic variant and by then choosing which
   implementation to use. Later, we'll add
   run-time checks.


git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@30868 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2004-12-05 20:30:18 +00:00
Václav Slavík
9755e73bd9 applied modified patch with native GTK wxFileDialog
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@30622 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2004-11-19 00:30:24 +00:00