home *** CD-ROM | disk | FTP | other *** search
/ Tools / WinSN5.0Ver.iso / NETSCAP.50 / WIN1998.ZIP / ns / cmd / xfe / src / BookmarkMenu.h < prev    next >
Encoding:
C/C++ Source or Header  |  1998-04-08  |  2.1 KB  |  73 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.    BookmarkMenu.h -- class for doing the dynamic bookmark menus
  20.    Created: Chris Toshok <toshok@netscape.com>, 19-Dec-1996.
  21.  */
  22.  
  23.  
  24.  
  25. #include "BookmarkBase.h"
  26.  
  27. #ifndef _xfe_bookmarkmenu_h
  28. #define _xfe_bookmarkmenu_h
  29.  
  30. // This class can be used with a DYNA_CASCADEBUTTON or
  31. // DYNA_MENUITEMS.
  32.  
  33. class XFE_BookmarkMenu : public XFE_BookmarkBase
  34. {
  35. public:
  36.     
  37.     // this function occupies the generateCallback slot in a menuspec.
  38.     static void generate        (Widget, void *, XFE_Frame *);
  39.  
  40.     static void generateQuickfile    (Widget, void *, XFE_Frame *);
  41.  
  42.     virtual void    enableDropping            ();
  43.     virtual void    disableDropping            ();
  44.  
  45.     virtual void    enableFiling            ();
  46.     virtual void    disableFiling            ();
  47.  
  48. protected:
  49.  
  50.     virtual void    prepareToUpdateRoot        ();
  51.     virtual void    reallyUpdateRoot        ();
  52.  
  53. private:
  54.  
  55.     XFE_BookmarkMenu        (MWContext *    bookmarkContext,
  56.                              Widget            cascade,
  57.                              XFE_Frame *    frame,
  58.                              XP_Bool        onlyHeaders,
  59.                              XP_Bool        fancyItems);
  60.  
  61.     Widget                _cascade;            // Cascade widget to popup from
  62.     Widget                _subMenu;            // Sub menu
  63.     Cardinal            _firstSlot;            // First slot for bookmark items
  64.  
  65.     static void        destroy_cb            (Widget,XtPointer,XtPointer);
  66.     static void        update_cb            (Widget,XtPointer,XtPointer);
  67.  
  68.     void            setFixedItemSensitive        (XP_Bool);
  69.  
  70. };
  71.  
  72. #endif /* _xfe_bookmarkmenu_h */
  73.