/[mcclim]/mcclim/views.lisp
ViewVC logotype

Contents of /mcclim/views.lisp

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.3 - (hide annotations)
Sun Nov 10 15:48:57 2002 UTC (11 years, 5 months ago) by gilbert
Branch: MAIN
Changes since 1.2: +1 -5 lines
Commit of patch submitted my Oliver Markovic.
Original message:

    Message-ID: <87bs4y1mhh.fsf@draco.home.lan>
    From: Oliver Markovic <qgo@gmx.net>
    To: free-clim@mikemac.com
    Subject: Protocol Classes
    Date: Sat, 09 Nov 2002 22:06:50 +0100

    Hi,

    Attached is a patch, which uses DEFINE-PROTOCOL-CLASS for all protocol
    classes as defined in the spec (not all were using that macro). I also
    added simple docstrings to the macro and changed the error message to
    something more civil :-)

    This should also add some required predicates, which were missing.

    I also noticed that protocol classes were given slots contradicting the
    definition in 2.5: "A protocol class is an "abstract" class with no
    slots and no methods (except perhaps for some default methods) [...]".
    But I guess that's no serious deviation from the spec though.

    greetz,
    --
     Oliver Markovic
1 moore 1.1 ;;; -*- Mode: Lisp; Package: CLIM-INTERNALS -*-
2    
3     ;;; (c) copyright 2001 by Tim Moore (moore@bricoworks.com)
4     ;;; This library is free software; you can redistribute it and/or
5     ;;; modify it under the terms of the GNU Library General Public
6     ;;; License as published by the Free Software Foundation; either
7     ;;; version 2 of the License, or (at your option) any later version.
8     ;;;
9     ;;; This library is distributed in the hope that it will be useful,
10     ;;; but WITHOUT ANY WARRANTY; without even the implied warranty of
11     ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12     ;;; Library General Public License for more details.
13     ;;;
14     ;;; You should have received a copy of the GNU Library General Public
15     ;;; License along with this library; if not, write to the
16     ;;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
17     ;;; Boston, MA 02111-1307 USA.
18    
19     (in-package :CLIM-INTERNALS)
20    
21     ;;; Views are defined here and not in presentations.lisp so that they
22     ;;; can be referenced in the streams code.
23    
24 gilbert 1.3 (define-protocol-class view ())
25 moore 1.1
26     (defclass textual-view (view)
27     ())
28    
29     (defclass textual-menu-view (textual-view)
30     ())
31    
32     (defclass textual-dialog-view (textual-view)
33     ())
34    
35     (defclass gadget-view (view)
36     ())
37    
38     (defclass gadget-menu-view (gadget-view)
39     ())
40    
41     (defclass gadget-dialog-view (gadget-view)
42     ())
43    
44     (defclass pointer-documentation-view (textual-view)
45     ())
46    
47     (defparameter +textual-view+ (make-instance 'textual-view))
48    
49     (defparameter +textual-menu-view+ (make-instance 'textual-menu-view))
50    
51     (defparameter +textual-dialog-view+ (make-instance 'textual-dialog-view))
52    
53     (defparameter +gadget-view+ (make-instance 'gadget-view))
54    
55     (defparameter +gadget-menu-view+ (make-instance 'gadget-menu-view))
56    
57     (defparameter +gadget-dialog-view+ (make-instance 'gadget-dialog-view))
58    
59     (defparameter +pointer-documentation-view+
60     (make-instance 'pointer-documentation-view))
61 mikemac 1.2
62     (defmethod stream-default-view (stream)
63     +textual-view+)
64    

  ViewVC Help
Powered by ViewVC 1.1.5