summaryrefslogtreecommitdiff
path: root/source/Asura.Editor/widgets/binding/_button.cpp
diff options
context:
space:
mode:
authorchai <chaifix@163.com>2019-03-29 22:28:40 +0800
committerchai <chaifix@163.com>2019-03-29 22:28:40 +0800
commit157530b8b6e11efc5573d5a0db8987a440197aa1 (patch)
treef9df79c013885e13dc81e7046c9828037eb29e2e /source/Asura.Editor/widgets/binding/_button.cpp
parente37b1dfd022bda4dfdcba243c0543c62c89db32f (diff)
*misc
Diffstat (limited to 'source/Asura.Editor/widgets/binding/_button.cpp')
-rw-r--r--source/Asura.Editor/widgets/binding/_button.cpp60
1 files changed, 0 insertions, 60 deletions
diff --git a/source/Asura.Editor/widgets/binding/_button.cpp b/source/Asura.Editor/widgets/binding/_button.cpp
deleted file mode 100644
index fbae64f..0000000
--- a/source/Asura.Editor/widgets/binding/_button.cpp
+++ /dev/null
@@ -1,60 +0,0 @@
-#include "../button.h"
-
-using namespace Luax;
-
-namespace AsuraEditor
-{
-
- LUAX_REGISTRY(Button)
- {
-
- // Button.EStatus.xxx
- LUAX_REGISTER_ENUM(state, "EStatus",
- { "NORMAL", BUTTON_STATUS_NORMAL },
- { "PUSHED", BUTTON_STATUS_PUSHED },
- { "HOVER", BUTTON_STATUS_HOVER },
- { "DISABLED", BUTTON_STATUS_DISABLED },
- { "FOCUSED", BUTTON_STATUS_FOCUSED }
- );
-
- // Button.EMsg.xxx
- LUAX_REGISTER_ENUM(state, "EMessage",
- { "CLICK", BUTTON_MSG_CLICK },
- { "HOVER", BUTTON_MSG_HOVER },
- { "FOCUS", BUTTON_MSG_KILLFOCUS }
- );
-
- }
-
- LUAX_POSTPROCESS(Button)
- {
-
- }
-
- // button:Connect(msg, callback)
- LUAX_IMPL_METHOD(Button, _Connect)
- {
- LUAX_STATE(L);
-
- Button* self = state.GetUserdata<Button>(1);
- int msg = state.CheckValue<int>(2);
- if (!lua_isfunction(L, 3))
- return state.ErrorType(3, "callback");
-
- LuaxMemberRef ref;
- self->SetLuaxMemberRef(state, ref, 3);
- if (ref)
- {
- self->mCallbacksRef.push_back(ref);
- Slot slot = Slot(state, (*self), ref.refID);
- self->Connect(msg, slot);
- }
- }
-
- // button:SetImage(image)
- LUAX_IMPL_METHOD(Button, _SetImage)
- {
-
- }
-
-} \ No newline at end of file