Update of /cvsroot/mahogany/M/src/gui
In directory usw-pr-cvs1:/tmp/cvs-serv18973/src/gui
Modified Files:
wxMDialogs.cpp
Log Message:
preparations for ADB expansion enhancements: no real changes yet but the
code refactored to allow for them soon
Index: wxMDialogs.cpp
===================================================================
RCS file: /cvsroot/mahogany/M/src/gui/wxMDialogs.cpp,v
retrieving revision 1.364
retrieving revision 1.365
diff -b -u -2 -r1.364 -r1.365
--- wxMDialogs.cpp 16 Apr 2002 13:37:18 -0000 1.364
+++ wxMDialogs.cpp 16 Apr 2002 22:48:23 -0000 1.365
@@ -438,11 +438,4 @@
// ----------------------------------------------------------------------------
-/// returns the argument if it's !NULL of the top-level application frame
-static inline wxWindow *GetDialogParent(const wxWindow *parent)
-{
- return parent == NULL ? mApplication->TopLevelFrame()
- : GetFrame(parent);
-}
-
// under Windows we don't use wxCENTRE style which uses the generic message box
// instead of the native one (and thus it doesn't have icons, for example)
@@ -979,66 +972,4 @@
{
return wxPDirSelector(confpath, message, pathOrig, parent);
-}
-
-int
-MDialog_AdbLookupList(ArrayAdbElements& aEntries,
- const wxWindow *parent)
-{
- //MGuiLocker lock;
- CloseSplash();
-
- wxArrayString aChoices;
-
- size_t nEntryCount = aEntries.Count();
- for( size_t nEntry = 0; nEntry < nEntryCount; nEntry++ )
- {
- aChoices.Add(aEntries[nEntry]->GetDescription());
- }
-
- static const char *DIALOG_NAME = "AdrListSelect";
- int x, y, w, h;
- wxMFrame::RestorePosition(DIALOG_NAME, &x, &y, &w, &h);
-
- int choice;
- if ( nEntryCount == 0 ) {
- // no matches at all
- choice = -1;
- }
- else if ( nEntryCount == 1 ) {
- // don't ask user to choose among one entry and itself!
- choice = 0;
- }
- else {
- wxSingleChoiceDialog dialog(
- GetDialogParent(parent),
- _("Please choose an entry:"),
- wxString(M_TITLE_PREFIX) +
- _("Expansion options"),
- nEntryCount,
- &aChoices[0]
- );
-
- // default width and height are too big for us
- if ( w == GetNumericDefault(MP_WIDTH) &&
- h == GetNumericDefault(MP_HEIGHT) ) {
- w = 300;
- h = 400;
- }
-
- dialog.Move(x, y);
- dialog.SetSize(w, h);
-
- if ( dialog.ShowModal() == wxID_OK ) {
- choice = dialog.GetSelection();
-
- // if the dialog wasn't cancelled, remember its size/position
- wxMFrame::SavePosition(DIALOG_NAME, &dialog);
- }
- else {
- choice = -1;
- }
- }
-
- return choice;
}
_______________________________________________
Mahogany-cvsupdates mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/mahogany-cvsupdates