home *** CD-ROM | disk | FTP | other *** search
/ Tools / WinSN5.0Ver.iso / NETSCAP.50 / WIN1998.ZIP / ns / cmd / xfe / src / NewsPromptDialog.h < prev    next >
Encoding:
C/C++ Source or Header  |  1998-04-08  |  2.3 KB  |  78 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.    NewsPromptDialog.h -- dialog for letting the user specify how many articles to download
  20.    Created: Chris Toshok <toshok@netscape.com>, 2-Mar-97.
  21.  */
  22.  
  23.  
  24.  
  25. #ifndef _xfe_newsserverdialog_h
  26. #define _xfe_newsserverdialog_h
  27.  
  28. #include "xp_core.h"
  29. #include "Dialog.h"
  30.  
  31. class XFE_NewsPromptDialog: public XFE_Dialog
  32. {
  33. public:
  34.     XFE_NewsPromptDialog(Widget parent,
  35.                          int numMessages);
  36.  
  37.     virtual ~XFE_NewsPromptDialog();
  38.  
  39.     /* changes the delete response to UNMAP so we can keep the
  40.        dialog around after it's popped down, and returns True
  41.        if Ok was pressed, and False otherwise (either cancel or
  42.        the WM close button was pressed. 
  43.  
  44.        This method calls fe_eventLoop so we can return with the
  45.        user's response from here. 
  46.  
  47.        since we UNMAP instead of DESTROY, you need to delete the
  48.        instance after you're through with it.*/
  49.     XP_Bool post();
  50.  
  51.     XP_Bool getDownloadAll();
  52.  
  53. private:
  54.     XP_Bool m_retVal;
  55.     XP_Bool m_downloadall;
  56.     XP_Bool m_doneWithLoop;
  57.  
  58.     Widget m_label;
  59.  
  60.     Widget m_alltoggle;
  61.     Widget m_nummessages_toggle;
  62.     Widget m_nummessages_text;
  63.     Widget m_nummessages_caption;
  64.     Widget m_markothersread_toggle;
  65.  
  66.     void ok();
  67.     void cancel();
  68.     void toggle(Widget, XtPointer);
  69.     void toggle_markread();
  70.  
  71.     static void ok_cb(Widget, XtPointer, XtPointer);
  72.     static void cancel_cb(Widget, XtPointer, XtPointer);
  73.     static void toggle_cb(Widget, XtPointer, XtPointer);
  74.     static void toggle_markread_cb(Widget, XtPointer, XtPointer);
  75. };
  76.  
  77. #endif /* _xfe_newsserverdialog_h */
  78.