Refactor new macOS code to reduce #ifs, increase shared code, and fix warnings

This commit is contained in:
Cameron Gutman
2018-03-27 00:34:38 -07:00
parent 6cc165b589
commit e8832ed746
22 changed files with 73 additions and 293 deletions
+24
View File
@@ -0,0 +1,24 @@
//
// OSPortabilityDefs.h
// Moonlight
//
// Created by Cameron Gutman on 3/26/18.
// Copyright © 2018 Moonlight Stream. All rights reserved.
//
#ifndef OSPortabilityDefs_h
#define OSPortabilityDefs_h
#if TARGET_OS_IPHONE
#define OSImage UIImage
#define OSColor UIColor
#define OSView UIView
#define OSApplication UIApplication
#else
#define OSImage NSImage
#define OSColor NSColor
#define OSView NSView
#define OSApplication NSApplication
#endif
#endif /* OSPortabilityDefs_h */