summaryrefslogtreecommitdiffstatshomepage
path: root/3rdparty/bgfx/examples/common/entry/entry_p.h
diff options
context:
space:
mode:
Diffstat (limited to '3rdparty/bgfx/examples/common/entry/entry_p.h')
-rw-r--r--3rdparty/bgfx/examples/common/entry/entry_p.h20
1 files changed, 18 insertions, 2 deletions
diff --git a/3rdparty/bgfx/examples/common/entry/entry_p.h b/3rdparty/bgfx/examples/common/entry/entry_p.h
index fa4792a5cb5..6776610b636 100644
--- a/3rdparty/bgfx/examples/common/entry/entry_p.h
+++ b/3rdparty/bgfx/examples/common/entry/entry_p.h
@@ -1,5 +1,5 @@
/*
- * Copyright 2011-2017 Branimir Karadzic. All rights reserved.
+ * Copyright 2011-2018 Branimir Karadzic. All rights reserved.
* License: https://github.com/bkaradzic/bgfx#license-bsd-2-clause
*/
@@ -9,11 +9,12 @@
#define TINYSTL_ALLOCATOR entry::TinyStlAllocator
#include <bx/spscqueue.h>
+#include <bx/filepath.h>
#include "entry.h"
#ifndef ENTRY_CONFIG_USE_NOOP
-# define ENTRY_CONFIG_USE_NOOP (BX_PLATFORM_QNX)
+# define ENTRY_CONFIG_USE_NOOP 0
#endif // ENTRY_CONFIG_USE_NOOP
#ifndef ENTRY_CONFIG_USE_SDL
@@ -84,6 +85,7 @@ namespace entry
Size,
Window,
Suspend,
+ DropFile,
};
Event(Enum _type)
@@ -170,6 +172,13 @@ namespace entry
Suspend::Enum m_state;
};
+ struct DropFileEvent : public Event
+ {
+ ENTRY_IMPLEMENT_EVENT(DropFileEvent, Event::DropFile);
+
+ bx::FilePath m_filePath;
+ };
+
const Event* poll();
const Event* poll(WindowHandle _handle);
void release(const Event* _event);
@@ -276,6 +285,13 @@ namespace entry
m_queue.push(ev);
}
+ void postDropFileEvent(WindowHandle _handle, const bx::FilePath& _filePath)
+ {
+ DropFileEvent* ev = BX_NEW(getAllocator(), DropFileEvent)(_handle);
+ ev->m_filePath = _filePath;
+ m_queue.push(ev);
+ }
+
const Event* poll()
{
return m_queue.pop();