X-Git-Url: https://ncurses.scripts.mit.edu/?p=ncurses.git;a=blobdiff_plain;f=c%2B%2B%2Fcursesapp.h;h=7e995d2e39c63abdcf045c1216fbdf540719806d;hp=998f14f1ce37a49eac1bfd8800c99d028fc6aac2;hb=76af49c338ca828b39306fcf93c6d49dfaf11dfc;hpb=661078ddbde3ce0f3b06e95642fbb9b5fef7dca1 diff --git a/c++/cursesapp.h b/c++/cursesapp.h index 998f14f1..7e995d2e 100644 --- a/c++/cursesapp.h +++ b/c++/cursesapp.h @@ -1,6 +1,6 @@ // * This makes emacs happy -*-Mode: C++;-*- /**************************************************************************** - * Copyright (c) 1998 Free Software Foundation, Inc. * + * Copyright (c) 1998-2003,2005 Free Software Foundation, Inc. * * * * Permission is hereby granted, free of charge, to any person obtaining a * * copy of this software and associated documentation files (the * @@ -28,17 +28,17 @@ ****************************************************************************/ /**************************************************************************** - * Author: Juergen Pfeifer 1997 * + * Author: Juergen Pfeifer, 1997 * ****************************************************************************/ -// $Id: cursesapp.h,v 1.3 1998/02/11 12:13:41 tom Exp $ +// $Id: cursesapp.h,v 1.11 2005/05/28 21:57:44 tom Exp $ -#ifndef _CURSESAPP_H -#define _CURSESAPP_H +#ifndef NCURSES_CURSESAPP_H_incl +#define NCURSES_CURSESAPP_H_incl #include -class NCursesApplication { +class NCURSES_IMPEXP NCursesApplication { public: typedef struct _slk_link { // This structure is used to maintain struct _slk_link* prev; // a stack of SLKs @@ -86,11 +86,24 @@ protected: // be the exit value of your application. virtual int run() = 0; - // The constructor is protected, so you may use it in your derived // class constructor. The argument tells whether or not you want colors. NCursesApplication(bool wantColors = FALSE); + NCursesApplication& operator=(const NCursesApplication& rhs) + { + if (this != &rhs) { + *this = rhs; + } + return *this; + } + + NCursesApplication(const NCursesApplication& rhs) + : b_Colors(rhs.b_Colors), + Root_Window(rhs.Root_Window) + { + } + public: virtual ~NCursesApplication(); @@ -160,4 +173,4 @@ public: }; -#endif // _CURSESAPP_H +#endif /* NCURSES_CURSESAPP_H_incl */