summaryrefslogtreecommitdiffstats
path: root/tools/objectsnapper/code/commands/snapselected.h
blob: 55e0f0d21d6ee20fa43314b1824afb96c9467b9a (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
//=============================================================================
// Copyright (C) 2002 Radical Entertainment Ltd.  All rights reserved.
//
// File:        snapselectedcmd.h
//
// Description: Blahblahblah
//
// History:     18/03/2002 + Created -- Cary Brisebois
//
//=============================================================================

#ifndef SNAPSELECTEDCMD_H
#define SNAPSELECTEDCMD_H

//========================================
// Nested Includes
//========================================
#include "main/mayaincludes.h"
#include "precompiled/PCH.h"

//========================================
// Forward References
//========================================

//=============================================================================
//
// Synopsis:    Blahblahblah
//
//=============================================================================

class SnapSelectedCmd : public MPxCommand
{
public:
    SnapSelectedCmd();
    virtual ~SnapSelectedCmd();

    static void* creator();
    virtual MStatus doIt( const MArgList& args );
    virtual MStatus undoIt();
    virtual MStatus redoIt();
    virtual bool isUndoable() const;

    static const char* stringId;

private:

    MDagPathArray   mObjDagPaths;
    MVectorArray    mOldPositions;
    MVectorArray    mNewPositions;
    
    void GetChildMeshNames( MDagPath objDagPath, MStringArray& names );

    //Prevent wasteful constructor creation.
SnapSelectedCmd( const SnapSelectedCmd& snapselectedcmd );
SnapSelectedCmd& operator=( const SnapSelectedCmd& snapselectedcmd );
};

#endif //SNAPSELECTEDCMD_H