Merge branch 'method_Unmangle' into PBR_PR

This commit is contained in:
Azaezel 2018-12-12 14:54:22 -06:00
commit 1eed979a9c
632 changed files with 3935 additions and 3450 deletions

View file

@ -2139,7 +2139,7 @@ ConsoleDocFragment _pushDialog(
"void pushDialog( GuiControl ctrl, int layer=0, bool center=false);"
);
DefineConsoleMethod( GuiCanvas, pushDialog, void, (const char * ctrlName, S32 layer, bool center), ( 0, false), "(GuiControl ctrl, int layer=0, bool center=false)"
DefineEngineMethod( GuiCanvas, pushDialog, void, (const char * ctrlName, S32 layer, bool center), ( 0, false), "(GuiControl ctrl, int layer=0, bool center=false)"
"@hide")
{
GuiControl *gui;
@ -2176,7 +2176,7 @@ ConsoleDocFragment _popDialog2(
"void popDialog();"
);
DefineConsoleMethod( GuiCanvas, popDialog, void, (GuiControl * gui), (nullAsType<GuiControl*>()), "(GuiControl ctrl=NULL)"
DefineEngineMethod( GuiCanvas, popDialog, void, (GuiControl * gui), (nullAsType<GuiControl*>()), "(GuiControl ctrl=NULL)"
"@hide")
{
if (gui)
@ -2204,7 +2204,7 @@ ConsoleDocFragment _popLayer2(
"void popLayer(S32 layer);"
);
DefineConsoleMethod( GuiCanvas, popLayer, void, (S32 layer), (0), "(int layer)"
DefineEngineMethod( GuiCanvas, popLayer, void, (S32 layer), (0), "(int layer)"
"@hide")
{
@ -2362,7 +2362,7 @@ ConsoleDocFragment _setCursorPos2(
"bool setCursorPos( F32 posX, F32 posY);"
);
DefineConsoleMethod( GuiCanvas, setCursorPos, void, (Point2I pos), , "(Point2I pos)"
DefineEngineMethod( GuiCanvas, setCursorPos, void, (Point2I pos), , "(Point2I pos)"
"@hide")
{
@ -2647,7 +2647,7 @@ DefineEngineMethod( GuiCanvas, setWindowPosition, void, ( Point2I position ),,
object->getPlatformWindow()->setPosition( position );
}
DefineConsoleMethod( GuiCanvas, isFullscreen, bool, (), , "() - Is this canvas currently fullscreen?" )
DefineEngineMethod( GuiCanvas, isFullscreen, bool, (), , "() - Is this canvas currently fullscreen?" )
{
if (Platform::getWebDeployment())
return false;
@ -2658,14 +2658,14 @@ DefineConsoleMethod( GuiCanvas, isFullscreen, bool, (), , "() - Is this canvas c
return object->getPlatformWindow()->getVideoMode().fullScreen;
}
DefineConsoleMethod( GuiCanvas, minimizeWindow, void, (), , "() - minimize this canvas' window." )
DefineEngineMethod( GuiCanvas, minimizeWindow, void, (), , "() - minimize this canvas' window." )
{
PlatformWindow* window = object->getPlatformWindow();
if ( window )
window->minimize();
}
DefineConsoleMethod( GuiCanvas, isMinimized, bool, (), , "()" )
DefineEngineMethod( GuiCanvas, isMinimized, bool, (), , "()" )
{
PlatformWindow* window = object->getPlatformWindow();
if ( window )
@ -2674,7 +2674,7 @@ DefineConsoleMethod( GuiCanvas, isMinimized, bool, (), , "()" )
return false;
}
DefineConsoleMethod( GuiCanvas, isMaximized, bool, (), , "()" )
DefineEngineMethod( GuiCanvas, isMaximized, bool, (), , "()" )
{
PlatformWindow* window = object->getPlatformWindow();
if ( window )
@ -2683,21 +2683,21 @@ DefineConsoleMethod( GuiCanvas, isMaximized, bool, (), , "()" )
return false;
}
DefineConsoleMethod( GuiCanvas, maximizeWindow, void, (), , "() - maximize this canvas' window." )
DefineEngineMethod( GuiCanvas, maximizeWindow, void, (), , "() - maximize this canvas' window." )
{
PlatformWindow* window = object->getPlatformWindow();
if ( window )
window->maximize();
}
DefineConsoleMethod( GuiCanvas, restoreWindow, void, (), , "() - restore this canvas' window." )
DefineEngineMethod( GuiCanvas, restoreWindow, void, (), , "() - restore this canvas' window." )
{
PlatformWindow* window = object->getPlatformWindow();
if( window )
window->restore();
}
DefineConsoleMethod( GuiCanvas, setFocus, void, (), , "() - Claim OS input focus for this canvas' window.")
DefineEngineMethod( GuiCanvas, setFocus, void, (), , "() - Claim OS input focus for this canvas' window.")
{
PlatformWindow* window = object->getPlatformWindow();
if( window )
@ -2712,7 +2712,7 @@ DefineEngineMethod( GuiCanvas, setMenuBar, void, ( GuiControl* menu ),,
return object->setMenuBar( menu );
}
DefineConsoleMethod( GuiCanvas, setVideoMode, void,
DefineEngineMethod( GuiCanvas, setVideoMode, void,
(U32 width, U32 height, bool fullscreen, U32 bitDepth, U32 refreshRate, U32 antialiasLevel),
( false, 0, 0, 0),
"(int width, int height, bool fullscreen, [int bitDepth], [int refreshRate], [int antialiasLevel] )\n"
@ -2812,7 +2812,7 @@ DefineConsoleMethod( GuiCanvas, setVideoMode, void,
Con::setVariable( "$pref::Video::mode", vm.toString() );
}
ConsoleMethod( GuiCanvas, showWindow, void, 2, 2, "" )
DefineEngineMethod(GuiCanvas, showWindow, void, (),, "")
{
if (!object->getPlatformWindow())
return;
@ -2822,7 +2822,7 @@ ConsoleMethod( GuiCanvas, showWindow, void, 2, 2, "" )
object->getPlatformWindow()->setDisplayWindow(true);
}
ConsoleMethod( GuiCanvas, hideWindow, void, 2, 2, "" )
DefineEngineMethod(GuiCanvas, hideWindow, void, (),, "")
{
if (!object->getPlatformWindow())
return;
@ -2832,30 +2832,29 @@ ConsoleMethod( GuiCanvas, hideWindow, void, 2, 2, "" )
object->getPlatformWindow()->setDisplayWindow(false);
}
ConsoleMethod( GuiCanvas, cursorClick, void, 4, 4, "button, isDown" )
DefineEngineMethod(GuiCanvas, cursorClick, void, (S32 buttonId, bool isDown), , "")
{
const S32 buttonId = dAtoi(argv[2]);
const bool isDown = dAtob(argv[3]);
object->cursorClick(buttonId, isDown);
}
ConsoleMethod( GuiCanvas, cursorNudge, void, 4, 4, "x, y" )
DefineEngineMethod(GuiCanvas, cursorNudge, void, (F32 x, F32 y), , "")
{
object->cursorNudge(dAtof(argv[2]), dAtof(argv[3]));
object->cursorNudge(x, y);
}
// This function allows resetting of the video-mode from script. It was motivated by
// the need to temporarily disable vsync during datablock cache load to avoid a
// significant slowdown.
bool AFX_forceVideoReset = false;
ConsoleMethod( GuiCanvas, resetVideoMode, void, 2,2, "()")
DefineEngineMethod(GuiCanvas, resetVideoMode, void, (), , "")
{
PlatformWindow* window = object->getPlatformWindow();
if( window )
if (window)
{
GFXWindowTarget* gfx_target = window->getGFXTarget();
if ( gfx_target )
GFXWindowTarget* gfx_target = window->getGFXTarget();
if (gfx_target)
{
AFX_forceVideoReset = true;
gfx_target->resetMode();

View file

@ -2898,7 +2898,7 @@ static ConsoleDocFragment _sGuiControlSetExtent2(
"GuiControl", // The class to place the method in; use NULL for functions.
"void setExtent( Point2I p );" ); // The definition string.
DefineConsoleMethod( GuiControl, setExtent, void, ( const char* extOrX, const char* y ), (""),
DefineEngineMethod( GuiControl, setExtent, void, ( const char* extOrX, const char* y ), (""),
"( Point2I p | int x, int y ) Set the width and height of the control.\n\n"
"@hide" )
{