Move device-related code to device.c

Move the code to read the initial device info from scrcpy.c to a
separate file, device.c.
This commit is contained in:
Romain Vimont
2018-02-08 15:42:49 +01:00
parent 28c5cc030b
commit 3b06e7d500
4 changed files with 33 additions and 19 deletions

14
app/src/device.h Normal file
View File

@@ -0,0 +1,14 @@
#ifndef DEVICE_H
#define DEVICE_H
#include <SDL2/SDL_net.h>
#include <SDL2/SDL_stdinc.h>
#include "common.h"
#define DEVICE_NAME_FIELD_LENGTH 64
// name must be at least DEVICE_NAME_FIELD_LENGTH bytes
SDL_bool device_read_info(TCPsocket device_socket, char *name, struct size *frame_size);
#endif