Initial Gamepad support
Adds initial ingame gamepad support to minetest. Full Formspec support is not implemented yet and can be added by a later change.
This commit is contained in:
@@ -29,6 +29,7 @@ with this program; if not, write to the Free Software Foundation, Inc.,
|
||||
#include "modalMenu.h"
|
||||
#include "guiTable.h"
|
||||
#include "network/networkprotocol.h"
|
||||
#include "client/joystick_controller.h"
|
||||
#include "util/string.h"
|
||||
#include "util/enriched_string.h"
|
||||
|
||||
@@ -278,6 +279,7 @@ class GUIFormSpecMenu : public GUIModalMenu
|
||||
|
||||
public:
|
||||
GUIFormSpecMenu(irr::IrrlichtDevice* dev,
|
||||
JoystickController *joystick,
|
||||
gui::IGUIElement* parent, s32 id,
|
||||
IMenuManager *menumgr,
|
||||
InventoryManager *invmgr,
|
||||
@@ -433,10 +435,11 @@ protected:
|
||||
video::SColor m_default_tooltip_color;
|
||||
|
||||
private:
|
||||
IFormSource *m_form_src;
|
||||
TextDest *m_text_dst;
|
||||
unsigned int m_formspec_version;
|
||||
std::string m_focused_element;
|
||||
IFormSource *m_form_src;
|
||||
TextDest *m_text_dst;
|
||||
unsigned int m_formspec_version;
|
||||
std::string m_focused_element;
|
||||
JoystickController *m_joystick;
|
||||
|
||||
typedef struct {
|
||||
bool explicit_size;
|
||||
@@ -494,6 +497,8 @@ private:
|
||||
bool parseSizeDirect(parserData* data, std::string element);
|
||||
void parseScrollBar(parserData* data, std::string element);
|
||||
|
||||
void tryClose();
|
||||
|
||||
/**
|
||||
* check if event is part of a double click
|
||||
* @param event event to evaluate
|
||||
|
Reference in New Issue
Block a user