pcsx2: properly init structure with the { } pattern

Remove also 2 unused variables

GCC warning is still disabled as it generates lots of false positive. GCC5 and later will improve the situation

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=36750
This commit is contained in:
Gregory Hainaut 2016-08-12 18:46:16 +02:00
parent 823670e4c5
commit 214253c579
4 changed files with 38 additions and 12 deletions

View File

@ -1167,7 +1167,18 @@ void SysCorePlugins::Load( const wxString (&folders)[PluginId_Count] )
pcsx2_GetBoolean, pcsx2_GetBoolean,
pcsx2_GetString, pcsx2_GetString,
pcsx2_GetStringAlloc, pcsx2_GetStringAlloc,
pcsx2_OSD_WriteLn pcsx2_OSD_WriteLn,
NULL, // AddMenuItem
NULL, // Menu_Create
NULL, // Menu_Delete
NULL, // Menu_AddItem
{ 0 }, // MenuItem
{ 0 }, // Console
{ 0 }, // ConsoleW
{ 0,0,0,0,0,0,0,0 },
}; };
m_mcdPlugin = FileMcd_InitAPI( &myself ); m_mcdPlugin = FileMcd_InitAPI( &myself );

View File

@ -100,8 +100,6 @@ struct GlobalCommandDescriptor
const wxChar* Tooltip; // text displayed in toolbar tooltips and menu status bars. const wxChar* Tooltip; // text displayed in toolbar tooltips and menu status bars.
bool AlsoApplyToGui; // Indicates that the GUI should be updated if possible. bool AlsoApplyToGui; // Indicates that the GUI should be updated if possible.
int ToolbarIconId; // not implemented yet, leave 0 for now.
}; };
// -------------------------------------------------------------------------------------- // --------------------------------------------------------------------------------------

View File

@ -25,7 +25,6 @@ struct GenericListViewColumn
{ {
const wchar_t *name; const wchar_t *name;
float size; float size;
int flags;
}; };
class GenericListView: public wxListView class GenericListView: public wxListView

View File

@ -476,48 +476,56 @@ static const GlobalCommandDescriptor CommandDeclarations[] =
States_FreezeCurrentSlot, States_FreezeCurrentSlot,
pxL( "Save state" ), pxL( "Save state" ),
pxL( "Saves the virtual machine state to the current slot." ), pxL( "Saves the virtual machine state to the current slot." ),
false,
}, },
{ "States_DefrostCurrentSlot", { "States_DefrostCurrentSlot",
States_DefrostCurrentSlot, States_DefrostCurrentSlot,
pxL( "Load state" ), pxL( "Load state" ),
pxL( "Loads a virtual machine state from the current slot." ), pxL( "Loads a virtual machine state from the current slot." ),
false,
}, },
{ "States_DefrostCurrentSlotBackup", { "States_DefrostCurrentSlotBackup",
States_DefrostCurrentSlotBackup, States_DefrostCurrentSlotBackup,
pxL( "Load State Backup" ), pxL( "Load State Backup" ),
pxL( "Loads virtual machine state backup for current slot." ), pxL( "Loads virtual machine state backup for current slot." ),
false,
}, },
{ "States_CycleSlotForward", { "States_CycleSlotForward",
States_CycleSlotForward, States_CycleSlotForward,
pxL( "Cycle to next slot" ), pxL( "Cycle to next slot" ),
pxL( "Cycles the current save slot in +1 fashion!" ), pxL( "Cycles the current save slot in +1 fashion!" ),
false,
}, },
{ "States_CycleSlotBackward", { "States_CycleSlotBackward",
States_CycleSlotBackward, States_CycleSlotBackward,
pxL( "Cycle to prev slot" ), pxL( "Cycle to prev slot" ),
pxL( "Cycles the current save slot in -1 fashion!" ), pxL( "Cycles the current save slot in -1 fashion!" ),
false,
}, },
{ "Frameskip_Toggle", { "Frameskip_Toggle",
Implementations::Frameskip_Toggle, Implementations::Frameskip_Toggle,
NULL, NULL,
NULL, NULL,
false,
}, },
{ "Framelimiter_TurboToggle", { "Framelimiter_TurboToggle",
Implementations::Framelimiter_TurboToggle, Implementations::Framelimiter_TurboToggle,
NULL, NULL,
NULL, NULL,
false,
}, },
{ "Framelimiter_SlomoToggle", { "Framelimiter_SlomoToggle",
Implementations::Framelimiter_SlomoToggle, Implementations::Framelimiter_SlomoToggle,
NULL, NULL,
NULL, NULL,
false,
}, },
{ "Framelimiter_MasterToggle", { "Framelimiter_MasterToggle",
@ -538,69 +546,79 @@ static const GlobalCommandDescriptor CommandDeclarations[] =
Implementations::GSwindow_ZoomIn, Implementations::GSwindow_ZoomIn,
NULL, NULL,
NULL, NULL,
false,
}, },
{ "GSwindow_ZoomOut", { "GSwindow_ZoomOut",
Implementations::GSwindow_ZoomOut, Implementations::GSwindow_ZoomOut,
NULL, NULL,
NULL, NULL,
false,
}, },
{ "GSwindow_ZoomToggle", { "GSwindow_ZoomToggle",
Implementations::GSwindow_ZoomToggle, Implementations::GSwindow_ZoomToggle,
NULL, NULL,
NULL, NULL,
false,
}, },
{ "GSwindow_ZoomInY", Implementations::GSwindow_ZoomInY, NULL, NULL, }, { "GSwindow_ZoomInY" , Implementations::GSwindow_ZoomInY , NULL, NULL, false},
{ "GSwindow_ZoomOutY", Implementations::GSwindow_ZoomOutY, NULL, NULL, }, { "GSwindow_ZoomOutY" , Implementations::GSwindow_ZoomOutY , NULL, NULL, false},
{ "GSwindow_ZoomResetY", Implementations::GSwindow_ZoomResetY, NULL, NULL, }, { "GSwindow_ZoomResetY" , Implementations::GSwindow_ZoomResetY , NULL, NULL, false},
{ "GSwindow_OffsetYminus", Implementations::GSwindow_OffsetYminus, NULL, NULL, }, { "GSwindow_OffsetYminus", Implementations::GSwindow_OffsetYminus, NULL, NULL, false},
{ "GSwindow_OffsetYplus", Implementations::GSwindow_OffsetYplus, NULL, NULL, }, { "GSwindow_OffsetYplus" , Implementations::GSwindow_OffsetYplus , NULL, NULL, false},
{ "GSwindow_OffsetXminus", Implementations::GSwindow_OffsetXminus, NULL, NULL, }, { "GSwindow_OffsetXminus", Implementations::GSwindow_OffsetXminus, NULL, NULL, false},
{ "GSwindow_OffsetXplus", Implementations::GSwindow_OffsetXplus, NULL, NULL, }, { "GSwindow_OffsetXplus" , Implementations::GSwindow_OffsetXplus , NULL, NULL, false},
{ "GSwindow_OffsetReset", Implementations::GSwindow_OffsetReset, NULL, NULL, }, { "GSwindow_OffsetReset" , Implementations::GSwindow_OffsetReset , NULL, NULL, false},
{ "Sys_SuspendResume", { "Sys_SuspendResume",
Implementations::Sys_SuspendResume, Implementations::Sys_SuspendResume,
NULL, NULL,
NULL, NULL,
false,
}, },
{ "Sys_TakeSnapshot", { "Sys_TakeSnapshot",
Implementations::Sys_TakeSnapshot, Implementations::Sys_TakeSnapshot,
NULL, NULL,
NULL, NULL,
false,
}, },
{ "Sys_RenderswitchToggle", { "Sys_RenderswitchToggle",
Implementations::Sys_RenderToggle, Implementations::Sys_RenderToggle,
NULL, NULL,
NULL, NULL,
false,
}, },
{ "Sys_LoggingToggle", { "Sys_LoggingToggle",
Implementations::Sys_LoggingToggle, Implementations::Sys_LoggingToggle,
NULL, NULL,
NULL, NULL,
false,
}, },
{ "Sys_FreezeGS", { "Sys_FreezeGS",
Implementations::Sys_FreezeGS, Implementations::Sys_FreezeGS,
NULL, NULL,
NULL, NULL,
false,
}, },
{ "Sys_RecordingToggle", { "Sys_RecordingToggle",
Implementations::Sys_RecordingToggle, Implementations::Sys_RecordingToggle,
NULL, NULL,
NULL, NULL,
false,
}, },
{ "FullscreenToggle", { "FullscreenToggle",
Implementations::FullscreenToggle, Implementations::FullscreenToggle,
NULL, NULL,
NULL, NULL,
false,
}, },
// Command Declarations terminator: // Command Declarations terminator: