diff options
author | Andrei Karas <akaras@inbox.ru> | 2016-04-30 21:28:40 +0300 |
---|---|---|
committer | Andrei Karas <akaras@inbox.ru> | 2016-04-30 21:28:40 +0300 |
commit | b8fefae63e5ddd8a3463988fbfeaea25d389e225 (patch) | |
tree | a755e7e30af68e311758395f90ab82c15335a427 | |
parent | e70ebdb9b0186779ddcdc2d0f6d8eceb81c85101 (diff) | |
download | manaplus-b8fefae63e5ddd8a3463988fbfeaea25d389e225.tar.gz manaplus-b8fefae63e5ddd8a3463988fbfeaea25d389e225.tar.bz2 manaplus-b8fefae63e5ddd8a3463988fbfeaea25d389e225.tar.xz manaplus-b8fefae63e5ddd8a3463988fbfeaea25d389e225.zip |
Add copy constructor into MouseInput.
-rw-r--r-- | src/input/mouseinput.h | 23 |
1 files changed, 23 insertions, 0 deletions
diff --git a/src/input/mouseinput.h b/src/input/mouseinput.h index 7711381fa..e4efa93c9 100644 --- a/src/input/mouseinput.h +++ b/src/input/mouseinput.h @@ -82,6 +82,29 @@ class MouseInput final mRealY(0) { } + MouseInput(const MouseInput &m) : + mType(m.mType), + mButton(m.mButton), + mTimeStamp(m.mTimeStamp), + mX(m.mX), + mY(m.mY), + mRealX(m.mRealX), + mRealY(m.mRealY) + { + } + + MouseInput &operator=(const MouseInput &m) + { + mType = m.mType; + mButton = m.mButton; + mTimeStamp = m.mTimeStamp; + mX = m.mX; + mY = m.mY; + mRealX = m.mRealX; + mRealY = m.mRealY; + return *this; + } + ~MouseInput() { } |