Merge pull request #43742 from qarmin/editor_modules_default_values
Initialize class/struct variables with default values in platform/ and editor/
This commit is contained in:
commit
90bdba576a
87 changed files with 411 additions and 540 deletions
|
|
@ -56,7 +56,7 @@ typedef GLXContext (*GLXCREATECONTEXTATTRIBSARBPROC)(Display *, GLXFBConfig, GLX
|
|||
|
||||
struct vendor {
|
||||
const char *glxvendor;
|
||||
int priority;
|
||||
int priority = 0;
|
||||
};
|
||||
|
||||
vendor vendormap[] = {
|
||||
|
|
|
|||
|
|
@ -63,25 +63,25 @@
|
|||
|
||||
// Hints for X11 fullscreen
|
||||
typedef struct {
|
||||
unsigned long flags;
|
||||
unsigned long functions;
|
||||
unsigned long decorations;
|
||||
long inputMode;
|
||||
unsigned long status;
|
||||
unsigned long flags = 0;
|
||||
unsigned long functions = 0;
|
||||
unsigned long decorations = 0;
|
||||
long inputMode = 0;
|
||||
unsigned long status = 0;
|
||||
} Hints;
|
||||
|
||||
typedef struct _xrr_monitor_info {
|
||||
Atom name;
|
||||
Bool primary;
|
||||
Bool automatic;
|
||||
int noutput;
|
||||
int x;
|
||||
int y;
|
||||
int width;
|
||||
int height;
|
||||
int mwidth;
|
||||
int mheight;
|
||||
RROutput *outputs;
|
||||
Bool primary = false;
|
||||
Bool automatic = false;
|
||||
int noutput = 0;
|
||||
int x = 0;
|
||||
int y = 0;
|
||||
int width = 0;
|
||||
int height = 0;
|
||||
int mwidth = 0;
|
||||
int mheight = 0;
|
||||
RROutput *outputs = nullptr;
|
||||
} xrr_monitor_info;
|
||||
|
||||
#undef CursorShape
|
||||
|
|
|
|||
|
|
@ -49,15 +49,6 @@
|
|||
static const char *ignore_str = "/dev/input/js";
|
||||
#endif
|
||||
|
||||
JoypadLinux::Joypad::Joypad() {
|
||||
fd = -1;
|
||||
dpad = 0;
|
||||
devpath = "";
|
||||
for (int i = 0; i < MAX_ABS; i++) {
|
||||
abs_info[i] = nullptr;
|
||||
}
|
||||
}
|
||||
|
||||
JoypadLinux::Joypad::~Joypad() {
|
||||
for (int i = 0; i < MAX_ABS; i++) {
|
||||
if (abs_info[i]) {
|
||||
|
|
|
|||
|
|
@ -56,17 +56,16 @@ private:
|
|||
Input::JoyAxis curr_axis[MAX_ABS];
|
||||
int key_map[MAX_KEY];
|
||||
int abs_map[MAX_ABS];
|
||||
int dpad;
|
||||
int fd;
|
||||
int dpad = 0;
|
||||
int fd = -1;
|
||||
|
||||
String devpath;
|
||||
input_absinfo *abs_info[MAX_ABS];
|
||||
input_absinfo *abs_info[MAX_ABS] = {};
|
||||
|
||||
bool force_feedback;
|
||||
int ff_effect_id;
|
||||
uint64_t ff_effect_timestamp;
|
||||
bool force_feedback = false;
|
||||
int ff_effect_id = 0;
|
||||
uint64_t ff_effect_timestamp = 0;
|
||||
|
||||
Joypad();
|
||||
~Joypad();
|
||||
void reset();
|
||||
};
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue