change if statement in keyCallback (on C side) to a switch statement, so adding more cases becomes easier
This commit is contained in:
@@ -35,8 +35,10 @@ void writeClipboard(char* string, int stringSize) {
|
||||
|
||||
void keyCallback(RGFW_window* window, unsigned char key, unsigned char symbol, unsigned char keymod, unsigned char repeated, unsigned char pressed) {
|
||||
if (pressed || repeated) {
|
||||
if (key == RGFW_escape) {
|
||||
mltonEscape();
|
||||
switch (key) {
|
||||
case RGFW_escape:
|
||||
mltonEscape();
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user