Use attributes where possible

This commit is contained in:
Martin Natano
2023-04-19 20:55:30 +02:00
parent a93fc07896
commit 093675cdc3
23 changed files with 142 additions and 133 deletions
+17 -7
View File
@@ -24,7 +24,7 @@ void ScreenSyncOverlay::Init()
m_overlay.Load(THEME->GetPathB(m_sName, "overlay"));
AddChild(m_overlay);
Update( 0 );
}
@@ -134,10 +134,20 @@ bool ScreenSyncOverlay::Input( const InputEventPlus &input )
bool bIncrease = true;
switch( input.DeviceI.button )
{
case KEY_F4: a = RevertSyncChanges; break;
case KEY_F9: bIncrease = false; /* fall through */
case KEY_F10: a = ChangeSongBPM; break;
case KEY_F11: bIncrease = false; /* fall through */
case KEY_F4:
a = RevertSyncChanges;
break;
case KEY_F9:
bIncrease = false;
[[fallthrough]];
case KEY_F10:
a = ChangeSongBPM;
break;
case KEY_F11:
bIncrease = false;
[[fallthrough]];
case KEY_F12:
if( INPUTFILTER->IsBeingPressed( DeviceInput(DEVICE_KEYBOARD, KEY_RSHIFT)) ||
INPUTFILTER->IsBeingPressed( DeviceInput(DEVICE_KEYBOARD, KEY_LSHIFT)) )
@@ -292,7 +302,7 @@ void ScreenSyncOverlay::HideHelp()
/*
* (c) 2001-2005 Chris Danford
* All rights reserved.
*
*
* Permission is hereby granted, free of charge, to any person obtaining a
* copy of this software and associated documentation files (the
* "Software"), to deal in the Software without restriction, including
@@ -302,7 +312,7 @@ void ScreenSyncOverlay::HideHelp()
* copyright notice(s) and this permission notice appear in all copies of
* the Software and that both the above copyright notice(s) and this
* permission notice appear in supporting documentation.
*
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
* OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT OF