Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
OBJS = main.o mouselist.o
SOURCE = main.c mouselist.c
HEADER = mouselist.h miscellaneous.h
HEADER = mouselist.h
OUT = ghub-gui
CC = gcc
FLAGS = -g -c -Wall
Expand Down
2 changes: 1 addition & 1 deletion main.c
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
// Copyright 2020 Mikhail ysph Subbotin

#include <stdbool.h>
#include <stdio.h>
#include <stdlib.h>
#include <stdint.h>
#include <time.h>
#include <libusb-1.0/libusb.h>

#include "mouselist.h"
#include "miscellaneous.h"

#define LIBUSB_OPTION_LOG_LEVEL 0
#define LIBUSB_LOG_LEVEL_ERROR 1
Expand Down
11 changes: 0 additions & 11 deletions miscellaneous.h

This file was deleted.

8 changes: 4 additions & 4 deletions mouselist.c
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ bool searchItem(Item* head, const int search_idProduct) {
return current->interface;
current = current->next;
}
return FALSE;
return false;
}

// FIXME: use generics
Expand All @@ -70,7 +70,7 @@ const int getInterface(Item* head, const int search_idProduct) {
return current->interface;
current = current->next;
}
return FALSE;
return false;
}
// FIXME: use generics
const char* getName(Item* head, const int search_idProduct) {
Expand All @@ -80,7 +80,7 @@ const char* getName(Item* head, const int search_idProduct) {
return current->name;
current = current->next;
}
return "UNDEFINED";
return "UNDEFINED"; // not sure if that should be like that, but I'm not touching it
}
// FIXME: use generics
const uint8_t getByte3(Item* head, const int search_idProduct) {
Expand All @@ -90,7 +90,7 @@ const uint8_t getByte3(Item* head, const int search_idProduct) {
return current->mByte3;
current = current->next;
}
return FALSE;
return false;
}
const int getSize(Item* head) {
int length = 0;
Expand Down
3 changes: 1 addition & 2 deletions mouselist.h
Original file line number Diff line number Diff line change
Expand Up @@ -3,12 +3,11 @@
#ifndef MOUSE_LIST_H
#define MOUSE_LIST_H

#include <stdbool.h>
#include <stdio.h>
#include <stdlib.h>
#include <stdint.h>

#include "miscellaneous.h"

#define WIRED_OR_CABLE 1
#define WIRELESS_RECEIVER 2
#define CABLE_BUT_SECOND 2
Expand Down