Skip to content

Commit

Permalink
Refactor: Relocated console, FS1, and help to libdoomsday
Browse files Browse the repository at this point in the history
This sizable commit relocates a couple of the most central Doomsday
subsystems into the libdoomsday library: console, FS1, and help.

Very little functionality has actually changed, though:

- Uri is now in libdoomsday, so it needs to use a callback to
  resolve symbols in the URI.

- FS1 depends on ResourceClass, however the resource subsystem is not
  ready for relocation; a callback was added to allow getting a
  ResourceClass instance based on its ID number.

The old console implementation has been cleaned up by splitting it
into several source files.

These changes enable relocating other subsystems that rely on console
and FS1.
  • Loading branch information
skyjake committed May 3, 2014
1 parent a1432e5 commit c844017
Show file tree
Hide file tree
Showing 203 changed files with 4,237 additions and 4,568 deletions.
13 changes: 13 additions & 0 deletions doomsday/api/api_console.h
Expand Up @@ -37,6 +37,7 @@ DENG_API_TYPEDEF(Con)
void (*AddCommandList)(ccmdtemplate_t const* cmdList);
void (*AddVariableList)(cvartemplate_t const* varList);

/// @return Type of the variable associated with @a path if found else @c CVT_NULL
cvartype_t (*GetVariableType)(char const* name);

byte (*GetByte)(char const* name);
Expand All @@ -45,7 +46,19 @@ DENG_API_TYPEDEF(Con)
char const* (*GetString)(char const* name);
Uri const* (*GetUri)(char const* name);

/**
* @copydoc CVar_SetInteger()
* @param svflags @ref setVariableFlags
*/
void (*SetInteger2)(char const* name, int value, int svflags);

/**
* Changes the value of an integer variable.
* @note Also used with @c CVT_BYTE.
*
* @param var Variable.
* @param value New integer value for the variable.
*/
void (*SetInteger)(char const* name, int value);

void (*SetFloat2)(char const* name, float value, int svflags);
Expand Down
2 changes: 1 addition & 1 deletion doomsday/api/dd_share.h
Expand Up @@ -143,7 +143,7 @@ enum {
DD_UNUSED1,
DD_MOUSE_INVERSE_Y,
DD_FULLBRIGHT, ///< Render everything fullbright?
DD_CCMD_RETURN,
DD_CCMD_RETURN_obsolete,
DD_GAME_READY,
DD_DEDICATED,
DD_NOVIDEO,
Expand Down
42 changes: 6 additions & 36 deletions doomsday/client/client.pro
Expand Up @@ -204,11 +204,8 @@ DENG_HEADERS += \
include/client/clpolymover.h \
include/clientapp.h \
include/color.h \
include/con_bar.h \
include/con_config.h \
include/con_main.h \
include/dd_def.h \
include/dd_help.h \
include/dd_loop.h \
include/dd_main.h \
include/dd_pinit.h \
Expand All @@ -233,17 +230,6 @@ DENG_HEADERS += \
include/edit_bias.h \
include/edit_map.h \
include/face.h \
include/filehandle.h \
include/filesys/file.h \
include/filesys/filehandlebuilder.h \
include/filesys/fileinfo.h \
include/filesys/fs_main.h \
include/filesys/fs_util.h \
include/filesys/lumpindex.h \
include/filesys/manifest.h \
include/filesys/searchpath.h \
include/filesys/sys_direc.h \
include/filetype.h \
include/game.h \
include/games.h \
include/gl/gl_defer.h \
Expand Down Expand Up @@ -335,7 +321,7 @@ DENG_HEADERS += \
include/resource/fontscheme.h \
include/resource/hq2x.h \
include/resource/image.h \
include/resource/lumpcache.h \
include/resource/manifest.h \
include/resource/material.h \
include/resource/materialarchive.h \
include/resource/materialmanifest.h \
Expand All @@ -355,9 +341,6 @@ DENG_HEADERS += \
include/resource/texturescheme.h \
include/resource/texturevariantspec.h \
include/resource/tga.h \
include/resource/wad.h \
include/resource/zip.h \
include/resourceclass.h \
include/settingsregister.h \
include/sys_system.h \
include/tab_anorms.h \
Expand Down Expand Up @@ -386,6 +369,7 @@ DENG_HEADERS += \
include/ui/dialogs/videosettingsdialog.h \
include/ui/dialogs/vrsettingsdialog.h \
include/ui/editors/rendererappearanceeditor.h \
include/ui/progress.h \
include/ui/widgetactions.h \
include/ui/widgets/busywidget.h \
include/ui/widgets/consolecommandwidget.h \
Expand Down Expand Up @@ -428,7 +412,6 @@ DENG_HEADERS += \
include/updater/updateavailabledialog.h \
include/updater/updatersettings.h \
include/updater/updatersettingsdialog.h \
include/uri.hh \
include/versioninfo.h \
include/world/blockmap.h \
include/world/bsp/bsptreenode.h \
Expand Down Expand Up @@ -528,6 +511,8 @@ else:unix {
# Platform-independent sources.
SOURCES += \
src/alertmask.cpp \
src/api_console.cpp \
src/api_filesys.cpp \
src/api_uri.cpp \
src/audio/audiodriver.cpp \
src/audio/audiodriver_music.cpp \
Expand All @@ -551,11 +536,7 @@ SOURCES += \
src/client/clpolymover.cpp \
src/clientapp.cpp \
src/color.cpp \
src/con_bar.cpp \
src/con_config.cpp \
src/con_data.cpp \
src/con_main.cpp \
src/dd_help.cpp \
src/dd_loop.cpp \
src/dd_main.cpp \
src/dd_pinit.cpp \
Expand All @@ -566,16 +547,6 @@ SOURCES += \
src/def_read.cpp \
src/edit_bias.cpp \
src/face.cpp \
src/filesys/file.cpp \
src/filesys/filehandle.cpp \
src/filesys/fileid.cpp \
src/filesys/fs_main.cpp \
src/filesys/fs_scheme.cpp \
src/filesys/fs_util.cpp \
src/filesys/lumpindex.cpp \
src/filesys/manifest.cpp \
src/filesys/searchpath.cpp \
src/filesys/sys_direc.cpp \
src/game.cpp \
src/games.cpp \
src/gl/dgl_common.cpp \
Expand Down Expand Up @@ -669,6 +640,7 @@ SOURCES += \
src/resource/fontscheme.cpp \
src/resource/hq2x.cpp \
src/resource/image.cpp \
src/resource/manifest.cpp \
src/resource/material.cpp \
src/resource/materialanimation.cpp \
src/resource/materialarchive.cpp \
Expand All @@ -687,8 +659,6 @@ SOURCES += \
src/resource/texturescheme.cpp \
src/resource/texturevariant.cpp \
src/resource/tga.cpp \
src/resource/wad.cpp \
src/resource/zip.cpp \
src/settingsregister.cpp \
src/sys_system.cpp \
src/tab_tables.c \
Expand Down Expand Up @@ -722,6 +692,7 @@ SOURCES += \
src/ui/mouse_qt.cpp \
src/ui/nativeui.cpp \
src/ui/p_control.cpp \
src/ui/progress.cpp \
src/ui/styledlogsinkformatter.cpp \
src/ui/sys_input.cpp \
src/ui/ui2_main.cpp \
Expand Down Expand Up @@ -756,7 +727,6 @@ SOURCES += \
src/updater/updater.cpp \
src/updater/updatersettings.cpp \
src/updater/updatersettingsdialog.cpp \
src/uri.cpp \
src/world/api_map.cpp \
src/world/api_mapedit.cpp \
src/world/blockmap.cpp \
Expand Down
153 changes: 0 additions & 153 deletions doomsday/client/include/cbuffer.h

This file was deleted.

0 comments on commit c844017

Please sign in to comment.