]> git.saurik.com Git - wxWidgets.git/commitdiff
[1001483] Added wxPasswordEntryDialog analagous to wxTextEntryDialog, allows detectin...
authorKevin Hock <hockkn@yahoo.com>
Tue, 9 Nov 2004 19:13:15 +0000 (19:13 +0000)
committerKevin Hock <hockkn@yahoo.com>
Tue, 9 Nov 2004 19:13:15 +0000 (19:13 +0000)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@30398 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775

docs/latex/wx/category.tex
docs/latex/wx/passdlg.tex [new file with mode: 0644]
docs/latex/wx/tcommdlg.tex
include/wx/generic/textdlgg.h

index b62983d59ee6c57fe484b007272af908878caf70..517185ec069b67e2f9c44439130514415d7259fe 100644 (file)
@@ -68,6 +68,7 @@ in an application.
 \twocolitem{\helpref{wxMultiChoiceDialog}{wxmultichoicedialog}}{Dialog to get one or more selections from a list}
 \twocolitem{\helpref{wxSingleChoiceDialog}{wxsinglechoicedialog}}{Dialog to get a single selection from a list and return the string}
 \twocolitem{\helpref{wxTextEntryDialog}{wxtextentrydialog}}{Dialog to get a single line of text from the user}
+\twocolitem{\helpref{wxPasswordEntryDialog}{wxpasswordentrydialog}}{Dialog to get a password from the user}
 \twocolitem{\helpref{wxFontDialog}{wxfontdialog}}{Font chooser dialog}
 \twocolitem{\helpref{wxPageSetupDialog}{wxpagesetupdialog}}{Standard page setup dialog}
 \twocolitem{\helpref{wxPrintDialog}{wxprintdialog}}{Standard print dialog}
diff --git a/docs/latex/wx/passdlg.tex b/docs/latex/wx/passdlg.tex
new file mode 100644 (file)
index 0000000..8960e2f
--- /dev/null
@@ -0,0 +1,42 @@
+\section{\class{wxPasswordEntryDialog}}\label{wxpasswordentrydialog}
+
+This class represents a dialog that requests a one-line password string from the user.
+It is implemented as a generic wxWidgets dialog.
+
+\wxheading{Derived from}
+
+\helpref{wxTextEntryDialog}{wxtextentrydialog}\\
+\helpref{wxDialog}{wxdialog}\\
+\helpref{wxWindow}{wxwindow}\\
+\helpref{wxEvtHandler}{wxevthandler}\\
+\helpref{wxObject}{wxobject}
+
+\wxheading{Include files}
+
+<wx/textdlg.h>
+
+\wxheading{See also}
+
+\helpref{wxPassowrdEntryDialog overview}{wxpasswordentrydialogoverview}
+
+\latexignore{\rtfignore{\wxheading{Members}}}
+
+\membersection{wxPasswordEntryDialog::wxPasswordEntryDialog}\label{wxpasswordentrydialogctor}
+
+\func{}{wxPasswordEntryDialog}{\param{wxWindow* }{parent}, \param{const wxString\& }{message},\rtfsp
+\param{const wxString\& }{caption = "Enter password"}, \param{const wxString\& }{defaultValue = ""}, \param{long }{style = wxOK \pipe wxCANCEL \pipe wxCENTRE}, \param{const wxPoint\& }{pos = wxDefaultPosition}}
+
+Constructor. Use \helpref{wxTextEntryDialog::ShowModal}{wxtextentrydialogshowmodal} to show the dialog.
+
+\wxheading{Parameters}
+
+\docparam{parent}{Parent window.}
+
+\docparam{message}{Message to show on the dialog.}
+
+\docparam{defaultValue}{The default value, which may be the empty string.}
+
+\docparam{style}{A dialog style, specifying the buttons (wxOK, wxCANCEL)
+and an optional wxCENTRE style. You do not need to specify the wxTE_PASSWORD style, it is always applied.
+
+\docparam{pos}{Dialog position.}
index ab04ca7b56d3186a4f9e80f6c60ef359d2b1625f..564a734ebb0f259290828e8133aca696e25ee96e 100644 (file)
@@ -3,6 +3,7 @@
 Classes: \helpref{wxColourDialog}{wxcolourdialog}, \helpref{wxFontDialog}{wxfontdialog},
 \rtfsp\helpref{wxPrintDialog}{wxprintdialog}, \helpref{wxFileDialog}{wxfiledialog},\rtfsp
 \helpref{wxDirDialog}{wxdirdialog}, \helpref{wxTextEntryDialog}{wxtextentrydialog},\rtfsp
+\helpref{wxPasswordEntryDialog}{wxpasswordentrydialog},\rtfsp
 \helpref{wxMessageDialog}{wxmessagedialog}, \helpref{wxSingleChoiceDialog}{wxsinglechoicedialog},\rtfsp
 \helpref{wxMultiChoiceDialog}{wxmultichoicedialog}
 
@@ -178,6 +179,13 @@ Classes: \helpref{wxTextEntryDialog}{wxtextentrydialog}
 This is a dialog with a text entry field. The value that the user
 entered is obtained using \helpref{wxTextEntryDialog::GetValue}{wxtextentrydialoggetvalue}.
 
+\subsection{wxPasswordEntryDialog overview}\label{wxpasswordentrydialogoverview}
+
+Classes: \helpref{wxPasswordEntryDialog}{wxpasswordentrydialog}
+
+This is a dialog with a password entry field. The value that the user
+entered is obtained using \helpref{wxTextEntryDialog::GetValue}{wxtextentrydialoggetvalue}.
+
 \subsection{wxMessageDialog overview}\label{wxmessagedialogoverview}
 
 Classes: \helpref{wxMessageDialog}{wxmessagedialog}
index a95f4acec3950bd5a186bf4a6b8def49a3564f43..46883085abcf793d4221992264d10e808d6ba30d 100644 (file)
@@ -28,6 +28,7 @@
 class WXDLLEXPORT wxTextCtrl;
 
 WXDLLEXPORT_DATA(extern const wxChar*) wxGetTextFromUserPromptStr;
+WXDLLEXPORT_DATA(extern const wxChar*) wxGetPasswordFromUserPromptStr;
 
 #define wxTextEntryDialogStyle (wxOK | wxCANCEL | wxCENTRE | wxWS_EX_VALIDATE_RECURSIVELY)
 
@@ -69,6 +70,24 @@ private:
     DECLARE_NO_COPY_CLASS(wxTextEntryDialog)
 };
 
+// ----------------------------------------------------------------------------
+// wxPasswordEntryDialog: dialog with password control, [ok] and [cancel]
+// ----------------------------------------------------------------------------
+
+class WXDLLEXPORT wxPasswordEntryDialog : public wxTextEntryDialog
+{
+public:
+    wxPasswordEntryDialog(wxWindow *parent,
+                      const wxString& message,
+                      const wxString& caption = wxGetPasswordFromUserPromptStr,
+                      const wxString& value = wxEmptyString,
+                      long style = wxTextEntryDialogStyle,
+                      const wxPoint& pos = wxDefaultPosition);
+private:
+    DECLARE_DYNAMIC_CLASS(wxPasswordEntryDialog)
+    DECLARE_NO_COPY_CLASS(wxPasswordEntryDialog)
+};
+
 // ----------------------------------------------------------------------------
 // function to get a string from user
 // ----------------------------------------------------------------------------
@@ -84,7 +103,7 @@ wxGetTextFromUser(const wxString& message,
 
 wxString WXDLLEXPORT
 wxGetPasswordFromUser(const wxString& message,
-                      const wxString& caption = wxGetTextFromUserPromptStr,
+                      const wxString& caption = wxGetPasswordFromUserPromptStr,
                       const wxString& default_value = wxEmptyString,
                       wxWindow *parent = (wxWindow *) NULL,
                       wxCoord x = wxDefaultCoord,