home *** CD-ROM | disk | FTP | other *** search
/ Tools / WinSN5.0Ver.iso / NETSCAP.50 / WIN1998.ZIP / ns / cmd / xfe / src / PrefsLang.h < prev    next >
Encoding:
C/C++ Source or Header  |  1998-04-08  |  2.3 KB  |  79 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.    PrefsLang.h -- Language preference dialog 
  20.    Created: Linda Wei <lwei@netscape.com>, 11-Nov-96.
  21.  */
  22.  
  23. #ifndef _xfe_prefslang_h
  24. #define _xfe_prefslang_h
  25.  
  26. #include "Dialog.h"
  27. #include "PrefsDialog.h"
  28.  
  29. struct PrefsDataLang
  30. {
  31.     MWContext *context;
  32.  
  33.     Widget   lang_list;
  34.     Widget   other_text;
  35.     Widget   temp_default_button;
  36.  
  37.     char   **avail_lang_regs;
  38.     int      avail_cnt;
  39. };
  40.  
  41. class XFE_PrefsLangDialog : public XFE_Dialog
  42. {
  43. public:
  44.  
  45.     // Constructors, Destructors
  46.  
  47.     XFE_PrefsLangDialog(XFE_PrefsDialog *prefsDialog,
  48.                         XFE_PrefsPageBrowserLang *langPage,
  49.                         Widget           parent,    
  50.                         char            *name,  
  51.                         Boolean          modal = TRUE);
  52.  
  53.     virtual ~XFE_PrefsLangDialog();
  54.  
  55.     virtual void show();                // pop up dialog
  56.     void initPage();                    // initialize dialog
  57.     Boolean verifyPage();               // verify page
  58.     MWContext *getContext();            // return the context
  59.     XFE_PrefsPageBrowserLang *getLangPage(); // return the language page
  60.     XFE_PrefsDialog *getPrefsDialog();  // return the pref dialog                                               
  61.     // Callbacks
  62.  
  63.     static void cb_ok(Widget, XtPointer, XtPointer);
  64.     static void cb_cancel(Widget, XtPointer, XtPointer);
  65.     static void cb_focusOther(Widget, XtPointer, XtPointer);
  66.     static void cb_loseFocusOther(Widget, XtPointer, XtPointer);
  67.  
  68. private:
  69.  
  70.     // User data
  71.  
  72.     XFE_PrefsDialog          *m_prefsDialog;
  73.     XFE_PrefsPageBrowserLang *m_langPage;
  74.     PrefsDataLang            *m_prefsDataLang;
  75. };
  76.  
  77. #endif /* _xfe_prefslang_h */
  78.  
  79.