home *** CD-ROM | disk | FTP | other *** search
/ Tools / WinSN5.0Ver.iso / NETSCAP.50 / WIN1998.ZIP / ns / cmd / xfe / src / PrefsApplEdit.h < prev    next >
Encoding:
C/C++ Source or Header  |  1998-04-08  |  2.7 KB  |  82 lines

  1. /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*-
  2.  *
  3.  * The contents of this file are subject to the Netscape Public License
  4.  * Version 1.0 (the "NPL"); you may not use this file except in
  5.  * compliance with the NPL.  You may obtain a copy of the NPL at
  6.  * http://www.mozilla.org/NPL/
  7.  *
  8.  * Software distributed under the NPL is distributed on an "AS IS" basis,
  9.  * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the NPL
  10.  * for the specific language governing rights and limitations under the
  11.  * NPL.
  12.  *
  13.  * The Initial Developer of this code under the NPL is Netscape
  14.  * Communications Corporation.  Portions created by Netscape are
  15.  * Copyright (C) 1998 Netscape Communications Corporation.  All Rights
  16.  * Reserved.
  17.  */
  18. /*
  19.    PrefsApplEdit.h -- Applications "edit" preference dialog 
  20.  
  21.    Created: Linda Wei <lwei@netscape.com>, 01-Nov-96.
  22.  */
  23.  
  24. #ifndef _xfe_prefsappledit_h
  25. #define _xfe_prefsappledit_h
  26.  
  27. #include "Dialog.h"
  28. #include "xeditor.h"
  29. #include "PrefsData.h"
  30. class XFE_PrefsDialog;
  31. class XFE_PrefsPageGeneralAppl;
  32.  
  33. class XFE_PrefsApplEditDialog : public XFE_Dialog
  34.  
  35. {
  36. public:
  37.  
  38.     // Constructors, Destructors
  39.  
  40.     XFE_PrefsApplEditDialog(XFE_PrefsDialog *prefsDialog,
  41.                             Widget           parent,    
  42.                             char            *name,  
  43.                             XFE_PrefsPageGeneralAppl *prefsPageGeneralAppl,
  44.                             Boolean          modal = TRUE);
  45.  
  46.     virtual ~XFE_PrefsApplEditDialog();
  47.  
  48.     void show();                        // pop up dialog
  49.     void initPage(Boolean  newFlag,
  50.                   int      pos);        // initialize dialog
  51.     Boolean verifyPage();               // verify page
  52.     void installChanges();              // install changes
  53.     MWContext *getContext();            // return the context
  54.     XFE_PrefsDialog *getPrefsDialog();  // return the pref dialog                                               
  55.     PrefsDataGeneralAppl *getPrefsDataGeneralAppl();  
  56.  
  57.     // Callbacks
  58.  
  59.     friend void prefsApplEditCb_ok(Widget, XtPointer, XtPointer);
  60.     friend void prefsApplEditCb_cancel(Widget, XtPointer, XtPointer);
  61.     friend void prefsApplEditCb_toggleHandledBy(Widget, XtPointer, XtPointer);
  62.     friend void prefsApplEditCb_browseAppl(Widget, XtPointer, XtPointer);
  63.     friend void prefsApplEditCb_setHandledBy(Widget, XtPointer, XtPointer);
  64.     friend void prefsApplEditCb_selectPlugin(Widget, XtPointer, XtPointer);
  65.  
  66. private:
  67.  
  68.     void buildPluginList(char *mimeType);
  69.     void pluginSelected(char *pluginName);
  70.     Bool handleByPlugin(char *type);
  71.  
  72.     // User data
  73.  
  74.     XFE_PrefsDialog              *m_prefsDialog;
  75.     XFE_PrefsPageGeneralAppl     *m_prefsPageGeneralAppl;
  76.     PrefsDataApplEdit            *m_prefsDataApplEdit;
  77.     PrefsDataGeneralAppl         *m_prefsDataGeneralAppl;
  78. };
  79.  
  80. #endif /* _xfe_prefsappledit_h */
  81.  
  82.