Last change
on this file since 374 was
374,
checked in by epyon, 10 years ago
|
- MASSIVE commit
- common.hh - size_t, ptrdiff_t, nv:: namespace, NV_ALIGN_OF and basic template tools
- STL - algorithm.hh, iterator.hh, limits.hh, numeric.hh and type_info.hh
- STL - updates to memory, array and string
|
File size:
829 bytes
|
Rev | Line | |
---|
[319] | 1 | // Copyright (C) 2013-2014 ChaosForge Ltd
|
---|
[218] | 2 | // http://chaosforge.org/
|
---|
| 3 | //
|
---|
| 4 | // This file is part of NV Libraries.
|
---|
| 5 | // For conditions of distribution and use, see copyright notice in nv.hh
|
---|
| 6 |
|
---|
| 7 | #include "nv/lib/curses.hh"
|
---|
| 8 |
|
---|
| 9 | #if defined( NV_CURSES_DYNAMIC )
|
---|
| 10 |
|
---|
[319] | 11 | #include "nv/core/library.hh"
|
---|
[218] | 12 |
|
---|
[374] | 13 | #define FILE void
|
---|
[319] | 14 | #define NV_CURSES_FUN( rtype, fname, fparams ) rtype (*fname) fparams = nullptr;
|
---|
[218] | 15 | #include <nv/lib/detail/curses_functions.inc>
|
---|
[319] | 16 | #undef NV_CURSES_FUN
|
---|
[218] | 17 |
|
---|
| 18 | bool nv::load_curses_library( const char* path )
|
---|
| 19 | {
|
---|
| 20 | static nv::library curses_library;
|
---|
| 21 | if ( curses_library.is_open() ) return true;
|
---|
| 22 | curses_library.open( path );
|
---|
| 23 |
|
---|
[374] | 24 | # define NV_CURSES_FUN( rtype, fname, fparams ) *(void **) (&::fname) = curses_library.get(#fname);
|
---|
[218] | 25 | # include <nv/lib/detail/curses_functions.inc>
|
---|
[319] | 26 | # undef NV_CURSES_FUN
|
---|
[218] | 27 | return true;
|
---|
| 28 | }
|
---|
| 29 | #endif
|
---|
Note: See
TracBrowser
for help on using the repository browser.