Skip to content

Commit

Permalink
Merge pull request #1568 from dgelessus/pygluehelpers_include_order
Browse files Browse the repository at this point in the history
Split off the parts of pyGlueHelpers.h that don't require Python.h
  • Loading branch information
Hoikas authored Mar 4, 2024
2 parents 5807230 + 1bc7ac6 commit da1a02b
Show file tree
Hide file tree
Showing 234 changed files with 957 additions and 776 deletions.
1 change: 1 addition & 0 deletions Sources/Plasma/FeatureLib/pfPython/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -207,6 +207,7 @@ set(pfPython_GLUE
pyGameScoreGlue.cpp
pyGameScoreMsgGlue.cpp
pyGeometry3Glue.cpp
pyGlueDefinitions.h
pyGlueHelpers.h
pyGmBlueSpiralGlue.cpp
pyGmMarkerGlue.cpp
Expand Down
6 changes: 3 additions & 3 deletions Sources/Plasma/FeatureLib/pfPython/cyAccountManagement.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -46,12 +46,12 @@ You can contact Cyan Worlds, Inc. by email [email protected]
// PURPOSE: Python wrapper for account management functions
//

#include <Python.h>

#include "pyGlueHelpers.h"
#include "cyAccountManagement.h"

#include "plNetClientComm/plNetClientComm.h"

#include "pyGlueHelpers.h"

PyObject* cyAccountManagement::GetPlayerList()
{
const std::vector<NetCommPlayer>& playerList = NetCommGetPlayerList();
Expand Down
10 changes: 5 additions & 5 deletions Sources/Plasma/FeatureLib/pfPython/cyAccountManagementGlue.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -40,15 +40,15 @@ You can contact Cyan Worlds, Inc. by email [email protected]
*==LICENSE==*/

#include <Python.h>
#include <string_theory/string>

#include "cyAccountManagement.h"
#include "pyGlueHelpers.h"
#include "pyEnum.h"

#include <string_theory/string>

#include "plMessage/plAccountUpdateMsg.h"

#include "pyEnum.h"
#include "pyGlueHelpers.h"

PYTHON_GLOBAL_METHOD_DEFINITION_NOARGS(PtGetAccountPlayerList, "Returns list of players associated with the current account")
{
return cyAccountManagement::GetPlayerList();
Expand Down
6 changes: 4 additions & 2 deletions Sources/Plasma/FeatureLib/pfPython/cyAnimation.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -46,12 +46,14 @@ You can contact Cyan Worlds, Inc. by email [email protected]
// PURPOSE: Class wrapper to map animation functions to plasma2 message
//

#include "cyAnimation.h"

#include "plgDispatch.h"
#include "pyKey.h"

#include "cyAnimation.h"
#include "plMessage/plAnimCmdMsg.h"

#include "pyKey.h"

cyAnimation::cyAnimation()
: fAnimName(), fNetForce()
{
Expand Down
6 changes: 5 additions & 1 deletion Sources/Plasma/FeatureLib/pfPython/cyAnimation.h
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,11 @@ You can contact Cyan Worlds, Inc. by email [email protected]

#include <string_theory/string>

#include "pyGlueHelpers.h"
#include "pnKeyedObject/plKey.h"

#include "pyGlueDefinitions.h"

class pyKey;

class cyAnimation
{
Expand Down
5 changes: 2 additions & 3 deletions Sources/Plasma/FeatureLib/pfPython/cyAnimationGlue.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -40,11 +40,10 @@ You can contact Cyan Worlds, Inc. by email [email protected]
*==LICENSE==*/

#include <Python.h>
#include "pyKey.h"

#include "cyAnimation.h"

#include "pyGlueHelpers.h"
#include "pyKey.h"

// glue functions
PYTHON_CLASS_DEFINITION(ptAnimation, cyAnimation);
Expand Down
41 changes: 19 additions & 22 deletions Sources/Plasma/FeatureLib/pfPython/cyAvatar.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -40,42 +40,39 @@ You can contact Cyan Worlds, Inc. by email [email protected]
*==LICENSE==*/

#include <Python.h>
#include "cyAvatar.h"

#include <string_theory/format>

#include "plFileSystem.h"
#include "plgDispatch.h"
#include "pyKey.h"
#include "plPhysical.h"

#include "cyAvatar.h"

#include "plAvatar/plAvatarMgr.h"
#include "plMessage/plAvatarMsg.h"
#include "plMessage/plOneShotMsg.h"
#include "plMessage/plMultistageMsg.h"
#include "pnMessage/plNotifyMsg.h"
#include "plGImage/plMipmap.h"
#include "pySceneObject.h"
#include "pyColor.h"
#include "pyImage.h"
#include "pnSceneObject/plSceneObject.h"

#include "plAvatar/plOneShotMod.h"
#include "plAvatar/plMultistageBehMod.h"
#include "plAnimation/plAGAnim.h" // to get the BodyUsage enum
#include "plAvatar/plArmatureMod.h"
#include "plAvatar/plAvatarClothing.h"
#include "plAvatar/plAvatarMgr.h"
#include "plAvatar/plAvBrainHuman.h" // needed to call the emote
#include "plAvatar/plClothingLayout.h"
#include "plAvatar/plArmatureMod.h"
#include "plAvatar/plAvBrainHuman.h" // needed to call the emote
#include "plAnimation/plAGAnim.h" // to get the BodyUsage enum
#include "plAvatar/plMultistageBehMod.h"
#include "plAvatar/plOneShotMod.h"
#include "plDrawable/plMorphSequence.h"
#include "plDrawable/plSharedMesh.h"
#include "plInputCore/plAvatarInputInterface.h"
#include "plMessage/plAvatarMsg.h"
#include "plMessage/plMultistageMsg.h"
#include "plMessage/plOneShotMsg.h"
#include "plMessage/plSimStateMsg.h"

#include "plVault/plVault.h"

#include "plDrawable/plSharedMesh.h"

#include "pnSceneObject/plSceneObject.h"
#include "plDrawable/plMorphSequence.h"
#include "pyColor.h"
#include "pyGlueHelpers.h"
#include "pyImage.h"
#include "pyKey.h"
#include "pySceneObject.h"

///////////////////////////////////////////////////////////////////////////
//
Expand Down
11 changes: 6 additions & 5 deletions Sources/Plasma/FeatureLib/pfPython/cyAvatar.h
Original file line number Diff line number Diff line change
Expand Up @@ -53,15 +53,16 @@ You can contact Cyan Worlds, Inc. by email [email protected]

#include "pnKeyedObject/plKey.h"

#include "pyGlueHelpers.h"
#include "pyGlueDefinitions.h"

class plArmatureMod;
class plClothingItem;
class plFileName;
class pySceneObject;
class pyColor;
class plMipmap;
class plClothingItem;
class plArmatureMod;
class plMorphSequence;
class pyColor;
class pyKey;
class pySceneObject;
namespace ST { class string; }

class cyAvatar
Expand Down
10 changes: 5 additions & 5 deletions Sources/Plasma/FeatureLib/pfPython/cyAvatarGlue.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -40,20 +40,20 @@ You can contact Cyan Worlds, Inc. by email [email protected]
*==LICENSE==*/

#include <Python.h>
#include "cyAvatar.h"

#include <string_theory/string>

#include "plFileSystem.h"

#include "pyKey.h"
#include "plAvatar/plAvBrainHuman.h"

#include "cyAvatar.h"
#include "pyColor.h"
#include "pyEnum.h"
#include "pyGlueHelpers.h"
#include "pyKey.h"
#include "pySceneObject.h"

#include "plAvatar/plAvBrainHuman.h"

// glue functions
PYTHON_CLASS_DEFINITION(ptAvatar, cyAvatar);

Expand Down
18 changes: 10 additions & 8 deletions Sources/Plasma/FeatureLib/pfPython/cyCamera.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -40,20 +40,22 @@ You can contact Cyan Worlds, Inc. by email [email protected]
*==LICENSE==*/

#include "plgDispatch.h"
#include "pyKey.h"
#include "hsResMgr.h"

#include "cyCamera.h"

#include "pnMessage/plCameraMsg.h"
#include "plMessage/plInputEventMsg.h"
#include "hsResMgr.h"
#include "plgDispatch.h"

#include "pnKeyedObject/plFixedKey.h"
#include "pnKeyedObject/plUoid.h"
#include "pnMessage/plCameraMsg.h"

#include "plMessage/plInputEventMsg.h"

#include "pfCamera/plVirtualCamNeu.h"
#include "pfCamera/plCameraModifier.h"
#include "pfCamera/plCameraBrain.h"
#include "pfCamera/plCameraModifier.h"
#include "pfCamera/plVirtualCamNeu.h"

#include "pyKey.h"

cyCamera::cyCamera()
{
Expand Down
9 changes: 7 additions & 2 deletions Sources/Plasma/FeatureLib/pfPython/cyCamera.h
Original file line number Diff line number Diff line change
Expand Up @@ -50,9 +50,14 @@ You can contact Cyan Worlds, Inc. by email [email protected]
//

#include "HeadSpin.h"
#include "pyGlueHelpers.h"

#include "pnKeyedObject/plKey.h"
#include "pfCamera/plVirtualCamNeu.h"

#include "pfCamera/plVirtualCamNeu.h"

#include "pyGlueDefinitions.h"

class pyKey;

class cyCamera
{
Expand Down
6 changes: 3 additions & 3 deletions Sources/Plasma/FeatureLib/pfPython/cyCameraGlue.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -40,11 +40,11 @@ You can contact Cyan Worlds, Inc. by email [email protected]
*==LICENSE==*/

#include <Python.h>
#include "pyKey.h"

#include "cyCamera.h"

#include "pyGlueHelpers.h"
#include "pyKey.h"

// glue functions
PYTHON_CLASS_DEFINITION(ptCamera, cyCamera);

Expand Down
3 changes: 2 additions & 1 deletion Sources/Plasma/FeatureLib/pfPython/cyDraw.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -40,9 +40,10 @@ You can contact Cyan Worlds, Inc. by email [email protected]
*==LICENSE==*/

#include "cyDraw.h"

#include "plgDispatch.h"

#include "cyDraw.h"
#include "pnMessage/plEnableMsg.h"

cyDraw::cyDraw(plKey sender, plKey recvr)
Expand Down
2 changes: 1 addition & 1 deletion Sources/Plasma/FeatureLib/pfPython/cyDraw.h
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ You can contact Cyan Worlds, Inc. by email [email protected]

#include "pnKeyedObject/plKey.h"

#include "pyGlueHelpers.h"
#include "pyGlueDefinitions.h"

class cyDraw
{
Expand Down
6 changes: 3 additions & 3 deletions Sources/Plasma/FeatureLib/pfPython/cyDrawGlue.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -40,11 +40,11 @@ You can contact Cyan Worlds, Inc. by email [email protected]
*==LICENSE==*/

#include <Python.h>
#include "pyKey.h"

#include "cyDraw.h"

#include "pyGlueHelpers.h"
#include "pyKey.h"

// glue functions
PYTHON_CLASS_DEFINITION(ptDraw, cyDraw);

Expand Down
3 changes: 2 additions & 1 deletion Sources/Plasma/FeatureLib/pfPython/cyInputInterface.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -41,8 +41,9 @@ You can contact Cyan Worlds, Inc. by email [email protected]
*==LICENSE==*/

#include "cyInputInterface.h"
#include "plMessage/plInputIfaceMgrMsg.h"

#include "plInputCore/plTelescopeInputInterface.h"
#include "plMessage/plInputIfaceMgrMsg.h"

cyInputInterface::cyInputInterface() :
fTelescopeInterface()
Expand Down
2 changes: 1 addition & 1 deletion Sources/Plasma/FeatureLib/pfPython/cyInputInterface.h
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ You can contact Cyan Worlds, Inc. by email [email protected]
// PURPOSE: Class wrapper to map InputInterface functions to plasma2 message
//

#include "pyGlueHelpers.h"
#include "pyGlueDefinitions.h"

class plInputInterface;

Expand Down
4 changes: 2 additions & 2 deletions Sources/Plasma/FeatureLib/pfPython/cyInputInterfaceGlue.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -40,10 +40,10 @@ You can contact Cyan Worlds, Inc. by email [email protected]
*==LICENSE==*/

#include <Python.h>

#include "cyInputInterface.h"

#include "pyGlueHelpers.h"

// glue functions
PYTHON_CLASS_DEFINITION(ptInputInterface, cyInputInterface);

Expand Down
Loading

0 comments on commit da1a02b

Please sign in to comment.